[Libreoffice-commits] core.git: Branch 'aoo/trunk' - 3 commits - set_soenv.in solenv/gbuild
Jim Jagielski
jim at apache.org
Tue Jul 3 22:10:43 UTC 2018
set_soenv.in | 3 ++-
solenv/gbuild/Library.mk | 1 +
solenv/gbuild/platform/macosx.mk | 16 ++++++++++++++--
3 files changed, 17 insertions(+), 3 deletions(-)
New commits:
commit a38be85fd66236e041a2a0d24b2ed11b2cbc68ee
Author: Jim Jagielski <jim at apache.org>
Date: Tue Jul 3 22:04:26 2018 +0000
restore until I can figure out a way to handle this crud which assumes everything is a .so
diff --git a/set_soenv.in b/set_soenv.in
index b4acb948299e..af8a7d8f1632 100644
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -96,7 +96,7 @@ my ( $oldPATH, $SRC_ROOT, $SO_HOME, $JAVA_HOME, $JDK, $JAVAFLAGS, $OOO_SHELL,
$SOLARSRC, $DEVROOT, $SOLARVER, $SOLARVERSION, $WORKDIR, $OUTDIR, $SOLARENV,
$STAR_INIROOT, $STAR_INIROOTOLD, $STAR_STANDLST, $STAR_SSCOMMON, $STAR_SSOLARINI,
$DMAKEROOT, $CLASSPATH, $XCLASSPATH, $COMPATH, $CXX_X64_BINARY, $LINK_X64_BINARY, $LIBMGR_X64_BINARY,
- $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH,
+ $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH, $SDKROOT,
$PATH, $SOLAREXTRAINC, $SOLAREXTRALIB, $SOLARLIB,
$SOLARINC, $LOCALINI, $FRAMEWORKSHOME, $COMEX, $PERL,
$COMP_ENV, $ILIB, $JAVAHOME, $PSDK_HOME, $DIRECTXSDK_LIB, $USE_NEW_SDK, $FRAME_HOME,
@@ -1765,6 +1765,7 @@ if ( $platform =~ m/darwin/ )
# http://developer.apple.com/technotes/tn2002/tn2064.html
ToFile( "MACOSX_DEPLOYMENT_TARGET", "@MACOSX_DEPLOYMENT_TARGET@", "e" );
ToFile( "MACOSX_SDK_PATH", "@MACOSX_SDK_PATH@", "e" );
+ ToFile( "SDKROOT", "@SDKROOT@", "e" );
}
if ( $platform =~ m/freebsd/ )
{
diff --git a/solenv/gbuild/Library.mk b/solenv/gbuild/Library.mk
index f10dc030a284..b1a35af99a6a 100644
--- a/solenv/gbuild/Library.mk
+++ b/solenv/gbuild/Library.mk
@@ -102,6 +102,7 @@ gb_Library_get_runtime_filename = \
define gb_Library_is_udk_versioned
$(or \
+ $(filter-out $(OS),MACOSX),\
$(filter $(patsubst %:$(notdir $(1)),%,$(filter %:$(notdir $(1)),$(gb_Library_FILENAMES))),$(gb_Library_RTVERLIBS)),\
$(filter $(patsubst %:$(notdir $(1)),%,$(filter %:$(notdir $(1)),$(gb_Library_FILENAMES))),$(gb_Library_UNOVERLIBS)))
endef
diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk
index fc54d1e66f1b..065080a1ec2c 100644
--- a/solenv/gbuild/platform/macosx.mk
+++ b/solenv/gbuild/platform/macosx.mk
@@ -288,6 +288,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(subst \d,$$,$(RPATH)) \
$(T_LDFLAGS) $(gb_macos_LDFLAGS) \
$(if $(VERSIONMAP),$(gb_Library_VERSIONMAPFLAG) $(VERSIONMAP)) \
+ $(if $(call gb_Library_is_udk_versioned,$(1)),-Wl$(COMMA)-h$(notdir $(1)).$(gb_UDK_MAJOR)) \
$(call gb_LinkTarget__get_liblinkflags,$(LINKED_LIBS)) \
$(foreach object,$(COBJECTS),$(call gb_CObject_get_target,$(object))) \
$(foreach object,$(CXXOBJECTS),$(call gb_CxxObject_get_target,$(object))) \
@@ -295,7 +296,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(foreach object,$(GENCXXOBJECTS),$(call gb_GenCxxObject_get_target,$(object))) \
$(foreach lib,$(LINKED_STATIC_LIBS),$(call gb_StaticLibrary_get_target,$(lib))) \
$(LIBS) \
- -o $(1) \
+ -o $(if $(call gb_Library_is_udk_versioned,$(1)),$(1).$(gb_UDK_MAJOR),$(1)) \
`cat $${DYLIB_FILE}` && \
$(if $(filter Library,$(TARGETTYPE)),\
$(PERL) $(SOLARENV)/bin/macosx-change-install-names.pl Library $(LAYER) $(1) && \
@@ -303,6 +304,12 @@ $(call gb_Helper_abbreviate_dirs,\
rm -f $${DYLIB_FILE})
endef
+define gb_LinkTarget__command_symlink_udk_versioned_library
+ $(if $(call gb_Library_is_udk_versioned,$(1)),
+ $(call gb_Helper_abbreviate_dirs,\
+ rm -f $(1) && ln -s $(notdir $(1)).$(gb_UDK_MAJOR) $(1)))
+endef
+
# parameters: 1-linktarget 2-cobjects 3-cxxobjects
define gb_LinkTarget__command_staticlink
$(call gb_Helper_abbreviate_dirs,\
@@ -318,6 +325,7 @@ endef
define gb_LinkTarget__command
$(call gb_Output_announce,$(2),$(true),LNK,4)
$(if $(filter Library GoogleTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1),$(2)))
+$(if $(filter Library,$(TARGETTYPE)),$(call gb_LinkTarget__command_symlink_udk_versioned_library,$(1)))
$(if $(filter StaticLibrary,$(TARGETTYPE)),$(call gb_LinkTarget__command_staticlink,$(1)))
endef
@@ -375,7 +383,11 @@ endef
define gb_Library_Library_platform
$(call gb_LinkTarget_get_target,$(2)) : RPATH := $(call gb_Library_get_rpath,$(1))
$(call gb_LinkTarget_get_target,$(2)) : LAYER := $(call gb_Library_get_layer,$(1))
-
+ifneq (,$(call gb_Library_is_udk_versioned,$(call gb_Library_get_target,$(1))))
+$(call gb_Library_get_target,$(1)) \
+$(call gb_Library_get_clean_target,$(1)) : AUXTARGETS += \
+ $(call gb_Library_get_target,$(1)).$(gb_UDK_MAJOR)
+endif
endef
commit b56b55bb53f1f9dfcc073e2707db748881eb38da
Author: Jim Jagielski <jim at apache.org>
Date: Tue Jul 3 21:42:23 2018 +0000
nope... still broke. Need to convince it to ignore UDK
diff --git a/set_soenv.in b/set_soenv.in
index af8a7d8f1632..b4acb948299e 100644
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -96,7 +96,7 @@ my ( $oldPATH, $SRC_ROOT, $SO_HOME, $JAVA_HOME, $JDK, $JAVAFLAGS, $OOO_SHELL,
$SOLARSRC, $DEVROOT, $SOLARVER, $SOLARVERSION, $WORKDIR, $OUTDIR, $SOLARENV,
$STAR_INIROOT, $STAR_INIROOTOLD, $STAR_STANDLST, $STAR_SSCOMMON, $STAR_SSOLARINI,
$DMAKEROOT, $CLASSPATH, $XCLASSPATH, $COMPATH, $CXX_X64_BINARY, $LINK_X64_BINARY, $LIBMGR_X64_BINARY,
- $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH, $SDKROOT,
+ $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH,
$PATH, $SOLAREXTRAINC, $SOLAREXTRALIB, $SOLARLIB,
$SOLARINC, $LOCALINI, $FRAMEWORKSHOME, $COMEX, $PERL,
$COMP_ENV, $ILIB, $JAVAHOME, $PSDK_HOME, $DIRECTXSDK_LIB, $USE_NEW_SDK, $FRAME_HOME,
@@ -1765,7 +1765,6 @@ if ( $platform =~ m/darwin/ )
# http://developer.apple.com/technotes/tn2002/tn2064.html
ToFile( "MACOSX_DEPLOYMENT_TARGET", "@MACOSX_DEPLOYMENT_TARGET@", "e" );
ToFile( "MACOSX_SDK_PATH", "@MACOSX_SDK_PATH@", "e" );
- ToFile( "SDKROOT", "@SDKROOT@", "e" );
}
if ( $platform =~ m/freebsd/ )
{
diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk
index 065080a1ec2c..fc54d1e66f1b 100644
--- a/solenv/gbuild/platform/macosx.mk
+++ b/solenv/gbuild/platform/macosx.mk
@@ -288,7 +288,6 @@ $(call gb_Helper_abbreviate_dirs,\
$(subst \d,$$,$(RPATH)) \
$(T_LDFLAGS) $(gb_macos_LDFLAGS) \
$(if $(VERSIONMAP),$(gb_Library_VERSIONMAPFLAG) $(VERSIONMAP)) \
- $(if $(call gb_Library_is_udk_versioned,$(1)),-Wl$(COMMA)-h$(notdir $(1)).$(gb_UDK_MAJOR)) \
$(call gb_LinkTarget__get_liblinkflags,$(LINKED_LIBS)) \
$(foreach object,$(COBJECTS),$(call gb_CObject_get_target,$(object))) \
$(foreach object,$(CXXOBJECTS),$(call gb_CxxObject_get_target,$(object))) \
@@ -296,7 +295,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(foreach object,$(GENCXXOBJECTS),$(call gb_GenCxxObject_get_target,$(object))) \
$(foreach lib,$(LINKED_STATIC_LIBS),$(call gb_StaticLibrary_get_target,$(lib))) \
$(LIBS) \
- -o $(if $(call gb_Library_is_udk_versioned,$(1)),$(1).$(gb_UDK_MAJOR),$(1)) \
+ -o $(1) \
`cat $${DYLIB_FILE}` && \
$(if $(filter Library,$(TARGETTYPE)),\
$(PERL) $(SOLARENV)/bin/macosx-change-install-names.pl Library $(LAYER) $(1) && \
@@ -304,12 +303,6 @@ $(call gb_Helper_abbreviate_dirs,\
rm -f $${DYLIB_FILE})
endef
-define gb_LinkTarget__command_symlink_udk_versioned_library
- $(if $(call gb_Library_is_udk_versioned,$(1)),
- $(call gb_Helper_abbreviate_dirs,\
- rm -f $(1) && ln -s $(notdir $(1)).$(gb_UDK_MAJOR) $(1)))
-endef
-
# parameters: 1-linktarget 2-cobjects 3-cxxobjects
define gb_LinkTarget__command_staticlink
$(call gb_Helper_abbreviate_dirs,\
@@ -325,7 +318,6 @@ endef
define gb_LinkTarget__command
$(call gb_Output_announce,$(2),$(true),LNK,4)
$(if $(filter Library GoogleTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1),$(2)))
-$(if $(filter Library,$(TARGETTYPE)),$(call gb_LinkTarget__command_symlink_udk_versioned_library,$(1)))
$(if $(filter StaticLibrary,$(TARGETTYPE)),$(call gb_LinkTarget__command_staticlink,$(1)))
endef
@@ -383,11 +375,7 @@ endef
define gb_Library_Library_platform
$(call gb_LinkTarget_get_target,$(2)) : RPATH := $(call gb_Library_get_rpath,$(1))
$(call gb_LinkTarget_get_target,$(2)) : LAYER := $(call gb_Library_get_layer,$(1))
-ifneq (,$(call gb_Library_is_udk_versioned,$(call gb_Library_get_target,$(1))))
-$(call gb_Library_get_target,$(1)) \
-$(call gb_Library_get_clean_target,$(1)) : AUXTARGETS += \
- $(call gb_Library_get_target,$(1)).$(gb_UDK_MAJOR)
-endif
+
endef
commit bcf12622492d148e11369921c5faf258681f5c6e
Author: Jim Jagielski <jim at apache.org>
Date: Tue Jul 3 21:29:28 2018 +0000
Get macOS building again... Use (old) SDKROOT as needed for older platforms and also support the UDK versioning which was added for Linux, Solaris and FreeBSD but which broke macOS horribly. I *think* this is right. Sometimes, as much as dmake is a pain, the constant breakage due to the change to gbuild is sometimes much, much worse. Esp since we HAVE the sources for dmake.
diff --git a/set_soenv.in b/set_soenv.in
index b4acb948299e..af8a7d8f1632 100644
--- a/set_soenv.in
+++ b/set_soenv.in
@@ -96,7 +96,7 @@ my ( $oldPATH, $SRC_ROOT, $SO_HOME, $JAVA_HOME, $JDK, $JAVAFLAGS, $OOO_SHELL,
$SOLARSRC, $DEVROOT, $SOLARVER, $SOLARVERSION, $WORKDIR, $OUTDIR, $SOLARENV,
$STAR_INIROOT, $STAR_INIROOTOLD, $STAR_STANDLST, $STAR_SSCOMMON, $STAR_SSOLARINI,
$DMAKEROOT, $CLASSPATH, $XCLASSPATH, $COMPATH, $CXX_X64_BINARY, $LINK_X64_BINARY, $LIBMGR_X64_BINARY,
- $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH,
+ $MSPDB_PATH, $MIDL_PATH, $CSC_PATH, $MACOSX_DEPLOYMENT_TARGET, $MACOSX_SDK_PATH, $SDKROOT,
$PATH, $SOLAREXTRAINC, $SOLAREXTRALIB, $SOLARLIB,
$SOLARINC, $LOCALINI, $FRAMEWORKSHOME, $COMEX, $PERL,
$COMP_ENV, $ILIB, $JAVAHOME, $PSDK_HOME, $DIRECTXSDK_LIB, $USE_NEW_SDK, $FRAME_HOME,
@@ -1765,6 +1765,7 @@ if ( $platform =~ m/darwin/ )
# http://developer.apple.com/technotes/tn2002/tn2064.html
ToFile( "MACOSX_DEPLOYMENT_TARGET", "@MACOSX_DEPLOYMENT_TARGET@", "e" );
ToFile( "MACOSX_SDK_PATH", "@MACOSX_SDK_PATH@", "e" );
+ ToFile( "SDKROOT", "@SDKROOT@", "e" );
}
if ( $platform =~ m/freebsd/ )
{
diff --git a/solenv/gbuild/platform/macosx.mk b/solenv/gbuild/platform/macosx.mk
index fc54d1e66f1b..065080a1ec2c 100644
--- a/solenv/gbuild/platform/macosx.mk
+++ b/solenv/gbuild/platform/macosx.mk
@@ -288,6 +288,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(subst \d,$$,$(RPATH)) \
$(T_LDFLAGS) $(gb_macos_LDFLAGS) \
$(if $(VERSIONMAP),$(gb_Library_VERSIONMAPFLAG) $(VERSIONMAP)) \
+ $(if $(call gb_Library_is_udk_versioned,$(1)),-Wl$(COMMA)-h$(notdir $(1)).$(gb_UDK_MAJOR)) \
$(call gb_LinkTarget__get_liblinkflags,$(LINKED_LIBS)) \
$(foreach object,$(COBJECTS),$(call gb_CObject_get_target,$(object))) \
$(foreach object,$(CXXOBJECTS),$(call gb_CxxObject_get_target,$(object))) \
@@ -295,7 +296,7 @@ $(call gb_Helper_abbreviate_dirs,\
$(foreach object,$(GENCXXOBJECTS),$(call gb_GenCxxObject_get_target,$(object))) \
$(foreach lib,$(LINKED_STATIC_LIBS),$(call gb_StaticLibrary_get_target,$(lib))) \
$(LIBS) \
- -o $(1) \
+ -o $(if $(call gb_Library_is_udk_versioned,$(1)),$(1).$(gb_UDK_MAJOR),$(1)) \
`cat $${DYLIB_FILE}` && \
$(if $(filter Library,$(TARGETTYPE)),\
$(PERL) $(SOLARENV)/bin/macosx-change-install-names.pl Library $(LAYER) $(1) && \
@@ -303,6 +304,12 @@ $(call gb_Helper_abbreviate_dirs,\
rm -f $${DYLIB_FILE})
endef
+define gb_LinkTarget__command_symlink_udk_versioned_library
+ $(if $(call gb_Library_is_udk_versioned,$(1)),
+ $(call gb_Helper_abbreviate_dirs,\
+ rm -f $(1) && ln -s $(notdir $(1)).$(gb_UDK_MAJOR) $(1)))
+endef
+
# parameters: 1-linktarget 2-cobjects 3-cxxobjects
define gb_LinkTarget__command_staticlink
$(call gb_Helper_abbreviate_dirs,\
@@ -318,6 +325,7 @@ endef
define gb_LinkTarget__command
$(call gb_Output_announce,$(2),$(true),LNK,4)
$(if $(filter Library GoogleTest Executable,$(TARGETTYPE)),$(call gb_LinkTarget__command_dynamiclink,$(1),$(2)))
+$(if $(filter Library,$(TARGETTYPE)),$(call gb_LinkTarget__command_symlink_udk_versioned_library,$(1)))
$(if $(filter StaticLibrary,$(TARGETTYPE)),$(call gb_LinkTarget__command_staticlink,$(1)))
endef
@@ -375,7 +383,11 @@ endef
define gb_Library_Library_platform
$(call gb_LinkTarget_get_target,$(2)) : RPATH := $(call gb_Library_get_rpath,$(1))
$(call gb_LinkTarget_get_target,$(2)) : LAYER := $(call gb_Library_get_layer,$(1))
-
+ifneq (,$(call gb_Library_is_udk_versioned,$(call gb_Library_get_target,$(1))))
+$(call gb_Library_get_target,$(1)) \
+$(call gb_Library_get_clean_target,$(1)) : AUXTARGETS += \
+ $(call gb_Library_get_target,$(1)).$(gb_UDK_MAJOR)
+endif
endef
More information about the Libreoffice-commits
mailing list