intl/icu-patches/bug-915735
author Kai Engert <kaie@kuix.de>
Wed, 11 Mar 2015 20:13:42 +0100
changeset 257596 758a094c8b7e66c67cd2998b30d0f2d89c4d74e4
parent 173863 099f65a712a8d098bd44ee45794724fbf9f8b0a6
child 530901 022d97621e5b0758fade155e697c48874f0d3b97
permissions -rw-r--r--
Bug 1137470, landing NSS_3_18_RC0 minus bug 1132496, r=nss-confcall, a=lsblakk

Bug 915735 - Fix linking the ICU libraries on Mac

diff --git a/intl/icu/source/config/mh-darwin b/intl/icu/source/config/mh-darwin
index 97d6bfc..fe1490e 100644
--- a/intl/icu/source/config/mh-darwin
+++ b/intl/icu/source/config/mh-darwin
@@ -23,21 +23,17 @@ ARFLAGS += -c
 COMPILE.c=	$(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -fno-common -c
 COMPILE.cc=	$(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) -fno-common -c
 
 ## Commands to make a shared library
 SHLIB.c=	$(CC) -dynamiclib -dynamic $(CFLAGS) $(LDFLAGS) $(LD_SOOPTIONS)
 SHLIB.cc=	$(CXX) -dynamiclib -dynamic $(CXXFLAGS) $(LDFLAGS) $(LD_SOOPTIONS)
 
 ## Compiler switches to embed a library name and version information
-ifeq ($(ENABLE_RPATH),YES)
-LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name $(libdir)/$(notdir $(MIDDLE_SO_TARGET))
-else
-LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name $(notdir $(MIDDLE_SO_TARGET))
-endif
+LD_SONAME = -Wl,-compatibility_version -Wl,$(SO_TARGET_VERSION_MAJOR) -Wl,-current_version -Wl,$(SO_TARGET_VERSION) -install_name @executable_path/$(notdir $(MIDDLE_SO_TARGET))
 
 ## Compiler switch to embed a runtime search path
 LD_RPATH=
 LD_RPATH_PRE= -Wl,-rpath,
 
 ## Environment variable to set a runtime search path
 LDLIBRARYPATH_ENVVAR = DYLD_LIBRARY_PATH