endif
endif
-MAC_OS_X_VERSION_MIN_REQUIRED=101000
-OSX_HOST_VERSION_MIN_STRING=10.10
+MAC_OS_X_VERSION_MIN_REQUIRED=101100
+OSX_HOST_VERSION_MIN_STRING=10.11
ifndef IPHONEOS_DEPLOYMENT_TARGET
IOS_VERSION_TARGET_STRING=10.0
THUMB_FLAG =
endif
-# even for a crossbuild host build, we want to use the target's latest tzdata as pointed to by latest_tzdata.tar.gz
-ifeq "$(shell test -d $(SDKPATH)/usr/local/share/tz && echo YES )" "YES"
- export TZDATA:=$(SDKPATH)/usr/local/share/tz/$(shell readlink $(SDKPATH)/usr/local/share/tz/latest_tzdata.tar.gz)
+# even for a crossbuild host build, we want to use the target's latest tzdata as pointed to by latest_tzdata.tar.gz;
+# first try RC_EMBEDDEDPROJECT_DIR (<rdar://problem/28141177>), else SDKPATH.
+ifdef RC_EMBEDDEDPROJECT_DIR
+ ifeq "$(shell test -L $(RC_EMBEDDEDPROJECT_DIR)/TimeZoneData/usr/local/share/tz/latest_tzdata.tar.gz && echo YES )" "YES"
+ export TZDATA:=$(RC_EMBEDDEDPROJECT_DIR)/TimeZoneData/usr/local/share/tz/$(shell readlink $(RC_EMBEDDEDPROJECT_DIR)/TimeZoneData/usr/local/share/tz/latest_tzdata.tar.gz)
+ endif
+endif
+ifndef TZDATA
+ ifeq "$(shell test -L $(SDKPATH)/usr/local/share/tz/latest_tzdata.tar.gz && echo YES )" "YES"
+ export TZDATA:=$(SDKPATH)/usr/local/share/tz/$(shell readlink $(SDKPATH)/usr/local/share/tz/latest_tzdata.tar.gz)
+ endif
endif
+$(info # RC_EMBEDDEDPROJECT_DIR=$(RC_EMBEDDEDPROJECT_DIR))
$(info # TZDATA=$(TZDATA))
APPLE_INTERNAL_DIR=/AppleInternal
DATA_LOOKUP_DIR_BUILDHOST=/usr/share/icu/
# Timezone data file(s)
-# ICU will look for /var/db/icutz/icutz44l.dat
+# ICU will look for /var/db/timezone/icutz/icutz44l.dat
# If directory or file is not present, the timesone data in
# current data file e.g. /usr/share/icu/icudt56l.dat will be used.
# Currently we are not conditionalizing the definition of
# TZDATA_LOOKUP_DIR as in
# ifeq "$(BUILD_TYPE)" "DEVICE"
-# TZDATA_LOOKUP_DIR = /var/db/icutz
+# TZDATA_LOOKUP_DIR = /var/db/timezone/icutz
# else
# ...
# since the code stats the path for TZDATA_LOOKUP_DIR and does
# as TZDATA_LOOKUP_DIR = /usr/share/icutz when not needed...
# TZDATA_LOOKUP_DIR is passed to compiler as U_TIMEZONE_FILES_DIR
# TZDATA_PACKAGE is passed to compiler as U_TIMEZONE_PACKAGE
-TZDATA_LOOKUP_DIR = /var/db/icutz
+TZDATA_LOOKUP_DIR = /var/db/timezone/icutz
TZDATA_PACKAGE = icutz44l
TZDATA_FORMAT_STRING = "44l"
TZDATA_FORMAT_FILE = icutzformat.txt
INFOTOOL = icuinfo
INFOTOOL_OBJS = ./tools/icuinfo/icuinfo.o ./tools/toolutil/udbgutil.o ./tools/toolutil/uoptions.o
+ICUZDUMPTOOL = icuzdump
+ifeq "$(ICU_FOR_EMBEDDED_TRAINS)" "YES"
+ ICUZDUMPTOOL_OBJS = ./tools/tzcode/icuzdump.o $(IO_OBJ)
+else
+ ICUZDUMPTOOL_OBJS = ./tools/tzcode/icuzdump.o
+endif
+
TOOLSLIB_NAME = icutu
TOOLS_DYLIB = libicutu.$(DYLIB_SUFF)
TOOLS_DYLIB_OBJS = ./tools/toolutil/*.o
-# The following version enables the tz toools to be used on systems with ICU 55 or later
-TOOLS_DYLIB_OBJS_FORSDK = ./tools/toolutil/collationinfo.o ./tools/toolutil/filestrm.o \
+
+# The following modified version enables the tz toools to be used on systems with ICU 55 or later.
+# It is used with the toolchain tools below.
+TOOLSLIB_NAME_FORTOOLS = icutux
+TOOLS_DYLIB_FORTOOLS = libicutux.$(DYLIB_SUFF)
+TOOLS_DYLIB_OBJS_FORTOOLS = ./tools/toolutil/collationinfo.o ./tools/toolutil/filestrm.o \
./tools/toolutil/package.o ./tools/toolutil/pkg_icu.o ./tools/toolutil/pkgitems.o \
./tools/toolutil/swapimpl.o ./tools/toolutil/toolutil.o ./tools/toolutil/ucbuf.o \
./tools/toolutil/unewdata.o ./tools/toolutil/uoptions.o ./tools/toolutil/uparse.o \
TZ2ICUTOOL = tz2icu
TZ2ICUTOOL_OBJS = ./tools/tzcode/tz2icu.o
-ICUZDUMPTOOL = icuzdump
-ifeq "$(ICU_FOR_EMBEDDED_TRAINS)" "YES"
- ICUZDUMPTOOL_OBJS = ./tools/tzcode/icuzdump.o $(IO_OBJ)
-else
- ICUZDUMPTOOL_OBJS = ./tools/tzcode/icuzdump.o
-endif
+GENBRKTOOL = icugenbrk
+GENBRKTOOL_OBJS = ./tools/genbrk/genbrk.o
#################################
# CLDR file(s)
);
# For the install-icutztoolsforsdk target, SDKROOT will always be an OSX SDK root.
+# If the sources were installed using the minimalpatchconfig.txt patch, then
# we need to patch using crosshostpatchconfig.txt as for $(CROSSHOST_OBJROOT)/Makefile
+# (otherwise we ignore the patch in crosshostpatchconfig.txt, using -N)
icutztoolsforsdk : $(OBJROOT_CURRENT)/Makefile
echo "# make icutztoolsforsdk";
(cd $(OBJROOT_CURRENT); \
- if test ! -d $(SRCROOT)/.git ; then patch -p1 <$(SRCROOT)/crosshostpatchconfig.txt; fi; \
+ if test ! -d $(SRCROOT)/.git ; then patch -N -p1 <$(SRCROOT)/crosshostpatchconfig.txt; fi; \
$(MAKE) $($(ENV)); \
- echo '# build' $(TOOLS_DYLIB) 'linked against' $(LIB_NAME) ; \
+ echo '# build' $(TOOLS_DYLIB_FORTOOLS) 'linked against' $(LIB_NAME) ; \
$($(ENV)) $(CXX) -current_version $(ICU_VERS).$(ICU_SUBVERS) -compatibility_version 1 -dynamiclib -dynamic \
-g -Os -fno-exceptions -fvisibility=hidden -fvisibility-inlines-hidden $(ISYSROOT) \
$(CXXFLAGS) $(LDFLAGS) -single_module \
- -install_name $(locallibdir)$(TOOLS_DYLIB) -o ./$(TOOLS_DYLIB) $(TOOLS_DYLIB_OBJS_FORSDK) -L./ -l$(LIB_NAME) ; \
- echo '# build' $(ZICTOOL) 'linked against' $(TOOLSLIB_NAME) ; \
+ -install_name $(locallibdir)$(TOOLS_DYLIB_FORTOOLS) -o ./$(TOOLS_DYLIB_FORTOOLS) $(TOOLS_DYLIB_OBJS_FORTOOLS) -L./ -l$(LIB_NAME) ; \
+ echo '# build' $(ZICTOOL) 'linked against' $(TOOLSLIB_NAME_FORTOOLS) ; \
$($(ENV_BUILDHOST)) $(CXX) -g -Os -isysroot $(HOSTSDKPATH) \
- $(LDFLAGS) -dead_strip -o ./$(ZICTOOL) $(ZICTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME) ; \
- echo '# build' $(RESTOOL) 'linked against' $(TOOLSLIB_NAME) $(LIB_NAME) ; \
+ $(LDFLAGS) -dead_strip -o ./$(ZICTOOL) $(ZICTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME_FORTOOLS) ; \
+ echo '# build' $(RESTOOL) 'linked against' $(TOOLSLIB_NAME_FORTOOLS) $(LIB_NAME) ; \
$($(ENV_BUILDHOST)) $(CXX) -g -Os -isysroot $(HOSTSDKPATH) \
- $(LDFLAGS) -dead_strip -o ./$(RESTOOL) $(RESTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME) -l$(LIB_NAME) ; \
- echo '# build' $(PKGTOOL) 'linked against' $(TOOLSLIB_NAME) ; \
+ $(LDFLAGS) -dead_strip -o ./$(RESTOOL) $(RESTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME_FORTOOLS) -l$(LIB_NAME) ; \
+ echo '# build' $(PKGTOOL) 'linked against' $(TOOLSLIB_NAME_FORTOOLS) ; \
$($(ENV_BUILDHOST)) $(CXX) -g -Os -isysroot $(HOSTSDKPATH) \
- $(LDFLAGS) -dead_strip -o ./$(PKGTOOL) $(PKGTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME) ; \
- echo '# build' $(TZ2ICUTOOL) 'linked against' $(TOOLSLIB_NAME) ; \
+ $(LDFLAGS) -dead_strip -o ./$(PKGTOOL) $(PKGTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME_FORTOOLS) ; \
+ echo '# build' $(TZ2ICUTOOL) 'linked against' $(TOOLSLIB_NAME_FORTOOLS) ; \
$($(ENV_BUILDHOST)) $(CXX) -g -Os -isysroot $(HOSTSDKPATH) \
- $(LDFLAGS) -dead_strip -o ./$(TZ2ICUTOOL) $(TZ2ICUTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME) ; \
+ $(LDFLAGS) -dead_strip -o ./$(TZ2ICUTOOL) $(TZ2ICUTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME_FORTOOLS) ; \
+ echo '# build' $(GENBRKTOOL) 'linked against' $(TOOLSLIB_NAME_FORTOOLS) ; \
+ $($(ENV_BUILDHOST)) $(CXX) -g -Os -isysroot $(HOSTSDKPATH) \
+ $(LDFLAGS) -dead_strip -o ./$(GENBRKTOOL) $(GENBRKTOOL_OBJS) -L./ -l$(TOOLSLIB_NAME_FORTOOLS) ; \
);
check : icu
if test ! -d $(DSTROOT)$(locallibdir)/; then \
$(INSTALL) -d -m 0755 $(DSTROOT)$(locallibdir)/; \
fi;
- if test -f $(OBJROOT_CURRENT)/$(TOOLS_DYLIB); then \
- echo '# install' $(TOOLS_DYLIB) 'to' $(DSTROOT)$(locallibdir)$(TOOLS_DYLIB) ; \
- $(INSTALL) -b -m 0755 $(OBJROOT_CURRENT)/$(TOOLS_DYLIB) $(DSTROOT)$(locallibdir)$(TOOLS_DYLIB); \
+ if test -f $(OBJROOT_CURRENT)/$(TOOLS_DYLIB_FORTOOLS); then \
+ echo '# install' $(TOOLS_DYLIB_FORTOOLS) 'to' $(DSTROOT)$(locallibdir)$(TOOLS_DYLIB_FORTOOLS) ; \
+ $(INSTALL) -b -m 0755 $(OBJROOT_CURRENT)/$(TOOLS_DYLIB_FORTOOLS) $(DSTROOT)$(locallibdir)$(TOOLS_DYLIB_FORTOOLS); \
fi;
if test -f $(OBJROOT_CURRENT)/$(ZICTOOL); then \
echo '# install' $(ZICTOOL) 'to' $(DSTROOT)$(localtooldir)$(ZICTOOL) ; \
echo '# install' $(TZ2ICUTOOL) 'to' $(DSTROOT)$(localtooldir)$(TZ2ICUTOOL) ; \
$(INSTALL) -b -m 0755 $(OBJROOT_CURRENT)/$(TZ2ICUTOOL) $(DSTROOT)$(localtooldir)$(TZ2ICUTOOL); \
fi;
+ if test -f $(OBJROOT_CURRENT)/$(GENBRKTOOL); then \
+ echo '# install' $(GENBRKTOOL) 'to' $(DSTROOT)$(localtooldir)$(GENBRKTOOL) ; \
+ $(INSTALL) -b -m 0755 $(OBJROOT_CURRENT)/$(GENBRKTOOL) $(DSTROOT)$(localtooldir)$(GENBRKTOOL); \
+ fi;