forked from Floorp-Projects/Floorp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug 915735 - Build ICU as a shared library where JS is built as a sha…
…red library; r=glandium
- Loading branch information
Showing
20 changed files
with
361 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -101,6 +101,27 @@ | |
#endif | ||
#endif | ||
#endif | ||
#ifdef MOZ_SHARED_ICU | ||
#ifdef XP_WIN | ||
#ifdef MOZ_DEBUG | ||
@BINPATH@/icudtd@[email protected] | ||
@BINPATH@/icuind@[email protected] | ||
@BINPATH@/icuucd@[email protected] | ||
#else | ||
@BINPATH@/icudt@[email protected] | ||
@BINPATH@/icuin@[email protected] | ||
@BINPATH@/icuuc@[email protected] | ||
#endif | ||
#elif defined(XP_MACOSX) | ||
@BINPATH@/libicudata.@[email protected] | ||
@BINPATH@/libicui18n.@[email protected] | ||
@BINPATH@/libicuuc.@[email protected] | ||
#elif defined(XP_UNIX) | ||
@BINPATH@/libicudata.so.@MOZ_ICU_VERSION@ | ||
@BINPATH@/libicui18n.so.@MOZ_ICU_VERSION@ | ||
@BINPATH@/libicuuc.so.@MOZ_ICU_VERSION@ | ||
#endif | ||
#endif | ||
|
||
[browser] | ||
; [Base Browser Files] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
dnl This Source Code Form is subject to the terms of the Mozilla Public | ||
dnl License, v. 2.0. If a copy of the MPL was not distributed with this | ||
dnl file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
|
||
dnl Set the MOZ_ICU_VERSION variable to denote the current version of the | ||
dnl ICU library, and also the MOZ_SHARED_ICU which would be true if we are | ||
dnl linking against a shared library of ICU, either one that we build from | ||
dnl our copy of ICU or the system provided library. | ||
|
||
AC_DEFUN([MOZ_CONFIG_ICU], [ | ||
icudir="$_topsrcdir/intl/icu/source" | ||
if test ! -d "$icudir"; then | ||
icudir="$_topsrcdir/../../intl/icu/source" | ||
if test ! -d "$icudir"; then | ||
AC_MSG_ERROR([Cannot find the ICU directory]) | ||
fi | ||
fi | ||
version=`sed -n 's/^[[:space:]]*#[[:space:]]*define[[:space:]][[:space:]]*U_ICU_VERSION_MAJOR_NUM[[:space:]][[:space:]]*\([0-9][0-9]*\)[[:space:]]*$/\1/p' "$icudir/common/unicode/uvernum.h"` | ||
if test x"$version" = x; then | ||
AC_MSG_ERROR([cannot determine icu version number from uvernum.h header file $lineno]) | ||
fi | ||
MOZ_ICU_VERSION="$version" | ||
if test -n "${JS_SHARED_LIBRARY}${MOZ_NATIVE_ICU}"; then | ||
MOZ_SHARED_ICU=1 | ||
fi | ||
AC_SUBST(MOZ_ICU_VERSION) | ||
AC_SUBST(MOZ_SHARED_ICU) | ||
]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
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 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.