diff options
author | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
---|---|---|
committer | Matt A. Tobin <mattatobin@localhost.localdomain> | 2018-02-02 04:16:08 -0500 |
commit | 5f8de423f190bbb79a62f804151bc24824fa32d8 (patch) | |
tree | 10027f336435511475e392454359edea8e25895d /intl/icu/source/config | |
parent | 49ee0794b5d912db1f95dce6eb52d781dc210db5 (diff) | |
download | UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.gz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.lz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.tar.xz UXP-5f8de423f190bbb79a62f804151bc24824fa32d8.zip |
Add m-esr52 at 52.6.0
Diffstat (limited to 'intl/icu/source/config')
39 files changed, 4478 insertions, 0 deletions
diff --git a/intl/icu/source/config/Makefile.inc.in b/intl/icu/source/config/Makefile.inc.in new file mode 100644 index 000000000..83da082ab --- /dev/null +++ b/intl/icu/source/config/Makefile.inc.in @@ -0,0 +1,292 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +## -*-makefile-*- +#****************************************************************************** +# Copyright (C) 1999-2014, International Business Machines +# Corporation and others. All Rights Reserved. +#****************************************************************************** +# This Makefile.inc is designed to be included into projects which make use +# of the ICU. + +# CONTENTS OF THIS FILE +# 1). Base configuration information and linkage +# 2). Variables giving access to ICU tools +# 3). Host information +# 4). Compiler flags and settings +# 5). Data Packaging directives +# 6). Include of platform make fragment (mh-* file) + +################################################################## +################################################################## +# +# *1* base configuration information and linkage +# +################################################################## +# The PREFIX is the base of where ICU is installed. +# Inside this directory you should find bin, lib, include/unicode, +# etc. If ICU is not installed in this directory, you must change the +# following line. There should exist $(prefix)/include/unicode/utypes.h +# for example. +prefix = @prefix@ +exec_prefix = @exec_prefix@ +libdir = @libdir@ +libexecdir = @libexecdir@ +bindir = @bindir@ +datarootdir = @datarootdir@ +datadir = @datadir@ +sbindir = @sbindir@ + +# about the ICU version +VERSION = @VERSION@ +UNICODE_VERSION = @UNICODE_VERSION@ + +# The prefix for ICU libraries, normally 'icu' +ICUPREFIX = icu +PACKAGE = @PACKAGE@ +LIBICU = lib$(ICUPREFIX) + +# Static library prefix and file extension +STATIC_PREFIX = s +LIBSICU = lib$(STATIC_PREFIX)$(ICUPREFIX) +A = a + +# Suffix at the end of libraries. Usually empty. +ICULIBSUFFIX = @ICULIBSUFFIX@ +# ICULIBSUFFIX_VERSION is non-empty if it is to contain a library +# version. For example, if it is 21, it means libraries are named +# libicuuc21.so for example. + +# rpath links a library search path right into the binaries. +## mh-files MUST NOT override RPATHLDFLAGS unless they provide +## equivalent '#SH#' lines for icu-config fixup +ENABLE_RPATH = @ENABLE_RPATH@ +ifeq ($(ENABLE_RPATH),YES) +RPATHLDFLAGS = $(LD_RPATH)$(LD_RPATH_PRE)$(libdir) +endif + +#SH## icu-config version of above 'if': +#SH#case "x$ENABLE_RPATH" in +#SH# x[yY]*) +#SH# ENABLE_RPATH=YES +#SH# RPATHLDFLAGS="${LD_RPATH}${LD_RPATH_PRE}${libdir}" +#SH# ;; +#SH# +#SH# x[nN]*) +#SH# ENABLE_RPATH=NO +#SH# RPATHLDFLAGS="" +#SH# ;; +#SH# +#SH# x) +#SH# ENABLE_RPATH=NO +#SH# RPATHLDFLAGS="" +#SH# ;; +#SH# +#SH# *) +#SH# echo $0: Unknown --enable-rpath value ${ENABLE_RPATH} 1>&2 +#SH# exit 3 +#SH# ;; +#SH#esac + +# Name flexibility for the library naming scheme. Any modifications should +# be made in the mh- file for the specific platform. +DATA_STUBNAME = data +COMMON_STUBNAME = uc +I18N_STUBNAME = i18n +LAYOUTEX_STUBNAME = lx +IO_STUBNAME = io +TOOLUTIL_STUBNAME = tu +CTESTFW_STUBNAME = test + + + +### To link your application with ICU: +# 1. use LDFLAGS, CFLAGS, etc from above +# 2. link with $(ICULIBS) +# 3. optionally, add one or more of: +# - $(ICULIBS_I18N) - i18n library, formatting, etc. +# - $(ICULIBS_ICUIO) - ICU stdio equivalent library + +ICULIBS_COMMON = -l$(ICUPREFIX)uc$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_DATA = -l$(ICUPREFIX)$(DATA_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_I18N = -l$(ICUPREFIX)$(I18N_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_TOOLUTIL = -l$(ICUPREFIX)tu$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_CTESTFW = -l$(ICUPREFIX)ctestfw$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_ICUIO = -l$(ICUPREFIX)io$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_OBSOLETE = -l$(ICUPREFIX)obsolete$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_LAYOUTEX = -l$(ICUPREFIX)lx$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION) +ICULIBS_BASE = -L$(libdir) + +# for icu-config to test with +ICULIBS_COMMON_LIB_NAME = ${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}.${SO} +ICULIBS_COMMON_LIB_NAME_A = ${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}.${A} + +# ICULIBS is the set of libraries your application should link +# with usually. Many applications will want to add $(ICULIBS_I18N) as well. +ICULIBS = $(ICULIBS_BASE) $(ICULIBS_I18N) $(ICULIBS_COMMON) $(ICULIBS_DATA) + +# Proper echo newline handling is needed in icu-config +ECHO_N=@ICU_ECHO_N@ +ECHO_C=@ICU_ECHO_C@ +# Not currently being used but good to have for proper tab handling +ECHO_T=@ICU_ECHO_T@ + +################################################################## +################################################################## +# +# *2* access to ICU tools +# +################################################################## +# Environment variable to set a runtime search path +# (Overridden when necessary in -mh files) +LDLIBRARYPATH_ENVVAR = LD_LIBRARY_PATH + +# Versioned target for a shared library +FINAL_SO_TARGET = $(SO_TARGET).$(SO_TARGET_VERSION) +MIDDLE_SO_TARGET = $(SO_TARGET).$(SO_TARGET_VERSION_MAJOR) + +# Access to important ICU tools. +# Use as follows: $(INVOKE) $(GENRB) arguments .. +INVOKE = $(LDLIBRARYPATH_ENVVAR)=$(libdir):$$$(LDLIBRARYPATH_ENVVAR) $(LEAK_CHECKER) +GENCCODE = $(sbindir)/genccode +ICUPKG = $(sbindir)/icupkg +GENCMN = $(sbindir)/gencmn +GENRB = $(bindir)/genrb +PKGDATA = $(bindir)/pkgdata + +# moved here because of dependencies +pkgdatadir = $(datadir)/$(PACKAGE)$(ICULIBSUFFIX)/$(VERSION) +pkglibdir = $(libdir)/$(PACKAGE)$(ICULIBSUFFIX)/$(VERSION) + +################################################################## +################################################################## +# +# *3* Information about the host +# +################################################################## + +# Information about the host that 'configure' was run on. +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_vendor = @host_vendor@ +host_os = @host_os@ +# Our platform canonical name (as determined by configure) +# this is a #define value (i.e. U_XXXX or XXXX) +platform = @platform@ + +################################################################## +################################################################## +# +# *4* compiler flags and misc. options +# +################################################################## +AR = @AR@ +# initial tab keeps it out of the shell version. + ARFLAGS := @ARFLAGS@ $(ARFLAGS) +#SH#ARFLAGS="@ARFLAGS@ ${ARFLAGS}" +CC = @CC@ +CPP = @CPP@ +CFLAGS = @UCONFIG_CFLAGS@ +CPPFLAGS = @UCONFIG_CPPFLAGS@ -I$(prefix)/include +CXXFLAGS = @UCONFIG_CXXFLAGS@ +CXX = @CXX@ +DEFAULT_MODE = @DATA_PACKAGING_MODE@ +DEFS = @DEFS@ +# use a consistent INSTALL +INSTALL = $(SHELL) $(pkgdatadir)/install-sh -c +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +LDFLAGS = $(RPATHLDFLAGS) +LIBS = @LIBS@ +LIB_M = @LIB_M@ +LIB_VERSION = @LIB_VERSION@ +LIB_VERSION_MAJOR = @LIB_VERSION_MAJOR@ +MKINSTALLDIRS = $(SHELL) $(pkgdatadir)/mkinstalldirs +RANLIB = @RANLIB@ +RMV = rm -rf +SHELL = @SHELL@ +SHLIB.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -shared +SHLIB.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -shared +U_IS_BIG_ENDIAN = @U_IS_BIG_ENDIAN@ +includedir = @includedir@ +infodir = @infodir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +oldincludedir = @oldincludedir@ +program_transform_name = @program_transform_name@ +sharedstatedir = @sharedstatedir@ +sysconfdir = @sysconfdir@ +INSTALL-L = ${INSTALL_DATA} + +# for derivative builds - don't bother with VERBOSE/NONVERBOSE SILENT_COMPILE +SILENT_COMPILE=$(1) #M# +ICU_MSG=@echo " $(1) " #M# + +################################################################## +################################################################## +# +# *5* packaging options and directories +# +################################################################## + + +# The basename of the ICU data file (i.e. icudt21b ) +ICUDATA_CHAR = @ICUDATA_CHAR@ +ICUDATA_NAME = icudt@LIB_VERSION_MAJOR@@ICUDATA_CHAR@ + +# Defaults for pkgdata's mode and directories +# The default data dir changes depending on what packaging mode +# is being used +ifeq ($(strip $(PKGDATA_MODE)),) +#SH# if [ "x$PKGDATA_MODE" = "x" ]; +#SH# then +PKGDATA_MODE=@DATA_PACKAGING_MODE@ +#SH# fi +endif + +#SH# case "$PKGDATA_MODE" in +ifeq ($(PKGDATA_MODE),common) +#SH# common) +ICUDATA_DIR = $(pkgdatadir) +ICUPKGDATA_DIR = $(ICUDATA_DIR) +#SH# ;; +else +ifeq ($(PKGDATA_MODE),dll) +#SH# dll) +ICUDATA_DIR = $(pkgdatadir) +ICUPKGDATA_DIR = $(libdir) +#SH# ;; +else +#SH# *) +ICUDATA_DIR = $(pkgdatadir) +ICUPKGDATA_DIR = $(ICUDATA_DIR) +#SH# ;; +endif +endif + +#SH# esac + +GENCCODE_ASSEMBLY = @GENCCODE_ASSEMBLY@ + +################################################################## +################################################################## +# +# *6* Inclusion of platform make fragment (mh-* file) +# +################################################################## +# The mh- file ("make fragment") for the platform is included here. +# It may override the above settings. +# It is put last so that the mh-file can override anything. +# The selfcheck is just a sanity check that this makefile is +# parseable. The mh fragment is only included if this does not occur. + +ifeq (selfcheck,$(MAKECMDGOALS)) #M# +selfcheck: #M# + @echo passed #M# +else #M# +include $(pkgdatadir)/config/@platform_make_fragment_name@ +endif #M# + diff --git a/intl/icu/source/config/dist.mk b/intl/icu/source/config/dist.mk new file mode 100644 index 000000000..442782bf7 --- /dev/null +++ b/intl/icu/source/config/dist.mk @@ -0,0 +1,86 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +#****************************************************************************** +# +# Copyright (C) 2010-2011, International Business Machines Corporation and others. All Rights Reserved. +# +#****************************************************************************** +# This is to be called from ../Makefile.in +# +# This will only work if subversion is installed. + +top_builddir = . + +include $(top_builddir)/icudefs.mk + + +DISTY_TMP=dist/tmp +DISTY_ICU=$(DISTY_TMP)/icu +DISTY_DATA=$(DISTY_ICU)/source/data +DISTY_RMV=brkitr coll curr lang locales mappings rbnf region translit xml zone +DISTY_RMDIR=$(DISTY_RMV:%=$(DISTY_DATA)/%) +DISTY_IN=$(DISTY_DATA)/in +DOCZIP=icu-docs.zip + +SVNTOP=$(top_srcdir)/.. +SVNDOT=$(SVNTOP)/.svn +SVNVER=$(shell svnversion $(SVNTOP) | cut -d: -f1 | tr -cd 'a-zA-Z0-9') +SVNURL=$(shell svn info $(SVNTOP) | grep '^URL:' | cut -d: -f2-) +DISTY_VER=$(shell echo $(VERSION) | tr '.' '_' ) +DISTY_PREFIX=icu4c +DISTY_FILE_DIR=$(shell pwd)/$(DISTY_DIR) +DISTY_FILE_TGZ=$(DISTY_FILE_DIR)/$(DISTY_PREFIX)-src-$(DISTY_VER)-r$(SVNVER).tgz +DISTY_FILE_ZIP=$(DISTY_FILE_DIR)/$(DISTY_PREFIX)-src-$(DISTY_VER)-r$(SVNVER).zip +DISTY_DOC_ZIP=$(DISTY_FILE_DIR)/$(DISTY_PREFIX)-docs-$(DISTY_VER)-r$(SVNVER).zip +DISTY_DATA_ZIP=$(DISTY_FILE_DIR)/$(DISTY_PREFIX)-data-$(DISTY_VER)-r$(SVNVER).zip +DISTY_DAT=$(firstword $(wildcard data/out/tmp/icudt$(SO_TARGET_VERSION_MAJOR)*.dat)) + +DISTY_FILES_SRC=$(DISTY_FILE_TGZ) $(DISTY_FILE_ZIP) +DISTY_FILES=$(DISTY_FILES_SRC) $(DISTY_DOC_ZIP) + +$(SVNDOT): + @echo "ERROR: 'dist' will not work unless the parent of the top_srcdir ( $(SVNTOP) ) is checked out from svn, and svn is installed." + false + +$(DISTY_FILE_DIR): + $(MKINSTALLDIRS) $(DISTY_FILE_DIR) + +$(DISTY_TMP): + $(MKINSTALLDIRS) $(DISTY_TMP) + +$(DISTY_DOC_ZIP): $(SVNDOT) $(DOCZIP) $(DISTY_FILE_DIR) + cp $(DOCZIP) $(DISTY_DOC_ZIP) + +$(DISTY_DAT): + echo Missing $@ + /bin/false + +$(DOCZIP): + $(MAKE) -C . srcdir="$(srcdir)" top_srcdir="$(top_srcdir)" builddir=. $@ + +$(DISTY_FILE_TGZ) $(DISTY_FILE_ZIP) $(DISTY_DATA_ZIP): $(SVNDOT) $(DISTY_DAT) $(DISTY_TMP) + @echo "svnversion of $(SVNTOP) is as follows (if this fails, make sure svn is installed..)" + svnversion $(SVNTOP) + -$(RMV) $(DISTY_FILE) $(DISTY_TMP) + $(MKINSTALLDIRS) $(DISTY_TMP) + svn export -r $(shell echo $(SVNVER) | tr -d 'a-zA-Z' ) $(SVNURL) "$(DISTY_TMP)/icu" + ( cd $(DISTY_TMP)/icu/source ; zip -rlq $(DISTY_DATA_ZIP) data ) + $(RMV) $(DISTY_RMDIR) + $(MKINSTALLDIRS) $(DISTY_IN) + cp $(DISTY_DAT) $(DISTY_IN) + ( cd $(DISTY_TMP)/icu ; python as_is/bomlist.py > as_is/bomlist.txt || rm -f as_is/bomlist.txt ) + ( cd $(DISTY_TMP) ; tar cfpz $(DISTY_FILE_TGZ) icu ) + ( cd $(DISTY_TMP) ; zip -rlq $(DISTY_FILE_ZIP) icu ) + ls -l $(DISTY_FILE) + +dist-local: $(DISTY_FILES) + +distcheck: distcheck-tgz + +DISTY_CHECK=$(DISTY_TMP)/check + +distcheck-tgz: $(DISTY_FILE_TGZ) + @echo Checking $(DISTY_FILE_TGZ) + @-$(RMV) $(DISTY_CHECK) + @$(MKINSTALLDIRS) $(DISTY_CHECK) + @(cd $(DISTY_CHECK) && tar xfpz $(DISTY_FILE_TGZ) && cd icu/source && $(SHELL) ./configure $(DISTCHECK_CONFIG_OPTIONS) && $(MAKE) check $(DISTCHECK_MAKE_OPTIONS) ) && (echo "!!! PASS: $(DISTY_FILE_TGZ)" ) diff --git a/intl/icu/source/config/gmakever.mk b/intl/icu/source/config/gmakever.mk new file mode 100644 index 000000000..6035e6a1a --- /dev/null +++ b/intl/icu/source/config/gmakever.mk @@ -0,0 +1,31 @@ +## -*-makefile-*- +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +#****************************************************************************** +# Copyright (C) 2008-2011, International Business Machines +# Corporation and others. All Rights Reserved. +#****************************************************************************** +# Make sure we have the right version of Make. + +at_least=3.80 +ifeq ($(MACHTYPE),i370-ibm-mvs) +at_least=3.79.1 +endif +ifeq ($(PLATFORM),OS390) +at_least=3.79.1 +endif +ifeq ($(MACHTYPE),powerpc-ibm-os400) +at_least=3.77 +endif + +latest_a=$(firstword $(sort $(MAKE_VERSION) $(at_least))) + +ifneq ($(at_least),$(latest_a)) +err: + @echo "ERROR: $(MAKE_VERSION) - too old, please upgrade to at least $(at_least)" + @false +else +ok: + @echo "$(MAKE_VERSION) (we wanted at least $(at_least))" +endif + diff --git a/intl/icu/source/config/icu-config-bottom b/intl/icu/source/config/icu-config-bottom new file mode 100644 index 000000000..20d0cdd8b --- /dev/null +++ b/intl/icu/source/config/icu-config-bottom @@ -0,0 +1,413 @@ +## -*-sh-*- +## BEGIN of icu-config-bottom. +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2002-2013, International Business Machines Corporation and +## others. All Rights Reserved. + +ICUUC_FILE="${libdir}/${ICULIBS_COMMON_LIB_NAME}" +ICUUC_FILE_A="${libdir}/${ICULIBS_COMMON_LIB_NAME_A}" + +# echo ENABLE RPATH $ENABLE_RPATH and RPATHLDFLAGS=${RPATH_LDFLAGS} +if [ "x$PKGDATA_MODE" = "x" ]; then + PKGDATA_MODE=dll +fi + +} + +## The actual code of icu-config goes here. + +ME=`basename "$0"` + +allflags() +{ + echo " --noverify Don't verify that ICU is actually installed." + echo " --bindir Print binary directory path (bin)" + echo " --cc Print C compiler used [CC]" + echo " --cflags Print C compiler flags [CFLAGS]" + echo " --cflags-dynamic Print additional C flags for" + echo " building shared libraries." + echo " --cppflags Print C Preprocessor flags [CPPFLAGS]" + echo " --cppflags-dynamic Print additional C Preprocessor flags for" + echo " building shared libraries." + echo " --cppflags-searchpath Print only -I include directives (-Iinclude)" + echo " --cxx Print C++ compiler used [CXX]" + echo " --cxxflags Print C++ compiler flags [CXXFLAGS]" + echo " --cxxflags-dynamic Print additional C++ flags for" + echo " building shared libraries." + echo " --detect-prefix Attempt to detect prefix based on PATH" + echo " --exec-prefix Print prefix for executables (/bin)" + echo " --exists Return with 0 status if ICU exists else fail" + echo " --help, -?, --usage Print this message" + echo " --icudata Print shortname of ICU data file (icudt21l)" + echo " --icudata-install-dir Print path to install data to - use as --install option to pkgdata(1)" + echo " --icudata-mode Print default ICU pkgdata mode (dll) - use as --mode option to pkgdata(1)." + echo " --icudatadir Print path to packaged archive data. Can set as [ICU_DATA]" + echo " --invoke Print commands to invoke an ICU program" + echo " --invoke=<prog> Print commands to invoke an ICU program named <prog> (ex: genrb)" + echo " --ldflags Print -L search path and -l libraries to link with ICU [LDFLAGS]. This is for the data, uc (common), and i18n libraries only. " + echo " --ldflags-libsonly Same as --ldflags, but only the -l directives" + echo " --ldflags-searchpath Print only -L (search path) directive" + echo " --ldflags-system Print only system libs ICU links with (-lpthread, -lm)" + echo " --ldflags-icuio Print ICU icuio link directive. Use in addition to --ldflags " + echo " --ldflags-obsolete Print ICU obsolete link directive. Use in addition to --ldflags. (requires icuapps/obsolete to be built and installed.) " + echo " --mandir Print manpage (man) path" + echo " --prefix Print PREFIX to icu install (/usr/local)" + echo " --prefix=XXX Set prefix to XXX for remainder of command" + echo " --sbindir Print system binary path (sbin) " + echo " --shared-datadir Print shared data (share) path. This is NOT the ICU data dir." + echo " --shlib-c Print the command to compile and build C shared libraries with ICU" + echo " --shlib-cc Print the command to compile and build C++ shared libraries with ICU" + echo " --sysconfdir Print system config (etc) path" + echo " --unicode-version Print version of Unicode data used in ICU ($UNICODE_VERSION)" + echo " --version Print ICU version ($VERSION)" + echo " --incfile Print path to Makefile.inc" + echo " --incpkgdatafile Print path to pkgdata.inc (for -O option of pkgdata)" + echo " --install Print path to install-sh" + echo " --mkinstalldirs Print path to mkinstalldirs" +} + +## Print the normal usage message +shortusage() +{ + echo "usage: ${ME} " `allflags | cut -c-25 | sed -e 's%.*%[ & ]%'` +} + + +usage() +{ + echo "${ME}: icu-config: ICU configuration helper script" + echo + echo "The most commonly used options will be --cflags, --cxxflags, --cppflags, and --ldflags." + echo 'Example (in make): CPFLAGS=$(shell icu-config --cppflags)' + echo ' LDFLAGS=$(shell icu-config --ldflags)' + echo " (etc).." + echo + echo "Usage:" + allflags + + echo + echo " [Brackets] show MAKE variable equivalents, (parenthesis) show example output" + echo + echo "Copyright (c) 2002-2013, International Business Machines Corporation and others. All Rights Reserved." + echo + echo "NOTE: Please consider using the pkg-config (.pc) files instead of icu-config." + echo " See: <http://userguide.icu-project.org/howtouseicu#TOC-pkg-config> " +} + +## Check the sanity of current variables +sanity() +{ + if [ ! -f "${ICUUC_FILE}" -a ! -f "${ICUUC_FILE_A}" ] && [ ${IGNORE_ICUUC_FILE_CHECK} = "no" ] && [ ${SANITY} = "sane" ]; + then + echo "### $ME: Can't find ${ICUUC_FILE} - ICU prefix is wrong." 1>&2 + echo "### Try the --prefix= option " 1>&2 + echo "### or --detect-prefix" 1>&2 + echo "### (If you want to disable this check, use the --noverify option)" 1>&2 + echo "### $ME: Exitting." 1>&2 + exit 2 + fi +} + +## Main starts here. + +if [ $# -lt 1 ]; then + shortusage + exit 1 +fi + +# For certain options (e.g. --detect-prefix) don't check for icuuc library file. + +IGNORE_ICUUC_FILE_CHECK="no"; + +SANITY="sane" + +case "$1" in +--noverify) + SANITY="nosanity" + shift + ;; +esac + +case "$1" in +*prefix*) + IGNORE_ICUUC_FILE_CHECK="yes" + ;; +esac + +# Load our variables from autoconf +# ALWAYS load twice because of dependencies +loaddefs +loaddefs + +if [ $# -gt 0 -a $1 = "--selfcheck" ]; +then + echo "passed" + exit + # EXIT for self check +fi + +sanity + +while [ $# -gt 0 ]; +do + arg="$1" + var=`echo $arg | sed -e 's/^[^=]*=//'` +# echo "### processing $arg" 1>&2 + case "$arg" in + + # undocumented. + --debug) + set -x + ;; + + --noverify) + echo "### $ME: Error: --noverify must be the first argument." 1>&2 + exit 1 + ;; + + --so) + echo $SO + ;; + + --bindir) + echo $bindir + ;; + + --libdir) + echo $libdir + ;; + + --exists) + sanity + ;; + + --sbindir) + echo $sbindir + ;; + + --mkinstalldirs) + echo ${MKINSTALLDIRS} + ;; + + --install) + echo ${INSTALL} + ;; + + --invoke=*) + QUOT="\"" + CMD="${var}" + + # If it's not a locally executable command (1st choice) then + # search for it in the ICU directories. + if [ ! -x ${CMD} ]; then + if [ -x ${bindir}/${var} ]; then + CMD="${bindir}/${var}" + fi + if [ -x ${sbindir}/${var} ]; then + CMD="${sbindir}/${var}" + fi + fi + + echo "env ${QUOT}${LDLIBRARYPATH_ENVVAR}=${libdir}:"'${'"${LDLIBRARYPATH_ENVVAR}"'}'${QUOT} ${CMD} + ;; + + --invoke) + QUOT="\"" + echo "env ${QUOT}${LDLIBRARYPATH_ENVVAR}=${libdir}:"'${'"${LDLIBRARYPATH_ENVVAR}"'}'${QUOT} + ;; + + --cflags) + echo $ECHO_N "${CFLAGS} ${ECHO_C}" + ;; + + --cc) + echo $ECHO_N "${CC} ${ECHO_C}" + ;; + + --cxx) + echo $ECHO_N "${CXX} ${ECHO_C}" + ;; + + --cxxflags) + echo $ECHO_N "${CXXFLAGS} ${ECHO_C}" + ;; + + --cppflags) + # Don't echo the -I. - it's unneeded. + echo $ECHO_N "${CPPFLAGS} ${ECHO_C}" | sed -e 's/-I. //' + ;; + + --cppflags-searchpath) + echo $ECHO_N "-I${prefix}/include ${ECHO_C}" + ;; + + --cppflags-dynamic) + echo $ECHO_N "${SHAREDLIBCPPFLAGS} ${ECHO_C}" + ;; + + --cxxflags-dynamic) + echo $ECHO_N "${SHAREDLIBCXXFLAGS} ${ECHO_C}" + ;; + + --cflags-dynamic) + echo $ECHO_N "${SHAREDLIBCFLAGS} ${ECHO_C}" + ;; + + --ldflags-system) + echo $ECHO_N "${LIBS} ${ECHO_C}" + ;; + + --ldflags) + echo $ECHO_N "${LDFLAGS} ${ICULIBS} ${ECHO_C}" +# $RPATH_LDFLAGS + ;; + + --ldflags-libsonly) + echo $ECHO_N "${ICULIBS_I18N} ${ICULIBS_COMMON} ${ICULIBS_DATA} ${ECHO_C}" + ;; + + --ldflags-icuio) + echo $ECHO_N " ${ICULIBS_ICUIO} ${ECHO_C}" + ;; + + --ldflags-obsolete) + echo $ECHO_N "${ICULIBS_OBSOLETE} ${ECHO_C}" + ;; + + --ldflags-toolutil) + echo $ECHO_N " ${ICULIBS_TOOLUTIL} ${ECHO_C}" + ;; + + --ldflags-layout) + echo ${ME}: ERROR: the old layout engine has been removed. use HarfBuzz. + exit 1 + ;; + + --ldflags-searchpath) + echo $ECHO_N "-L${libdir} ${ECHO_C}" + ;; + + --detect-prefix) + HERE=`echo $0 | sed -e "s/$ME//g"` + if [ -f "${HERE}/../lib/${ICULIBS_COMMON_LIB_NAME}" -o -f "${HERE}/../lib/${ICULIBS_COMMON_LIB_NAME_A}" ]; then + prefix="${HERE}/.." + echo "## Using --prefix=${prefix}" 1>&2 + fi + loaddefs + loaddefs + ;; + + --exec-prefix) + echo $exec_prefix + ;; + + --prefix) + echo $prefix + ;; + + --prefix=*) + prefix=$var + loaddefs + loaddefs + ;; + + --sysconfdir) + echo $sysconfdir + ;; + + --mandir) + echo $mandir + ;; + + --shared-datadir) + echo $ECHO_N "${datadir} ${ECHO_C}" + ;; + + --incfile) + echo $ECHO_N "${pkglibdir}/Makefile.inc ${ECHO_C}" + ;; + + --incpkgdatafile) + echo $ECHO_N "${pkglibdir}/pkgdata.inc ${ECHO_C}" + ;; + + --icudata) + echo $ECHO_N "${ICUDATA_NAME} ${ECHO_C}" + ;; + + --icudata-mode) + echo $ECHO_N "${PKGDATA_MODE} ${ECHO_C}" + ;; + + --icudata-install-dir) + echo $ECHO_N "${ICUPKGDATA_DIR} ${ECHO_C}" + ;; + + --icudatadir) + echo $ECHO_N "${ICUDATA_DIR} ${ECHO_C}" + ;; + + --shlib-c) + echo $ECHO_N "${SHLIB_c} ${ECHO_C}" + ;; + + --shlib-cc) + echo $ECHO_N "${SHLIB_cc} ${ECHO_C}" + ;; + + --version) + echo $ECHO_N $VERSION + ;; + + --unicode-version) + echo $ECHO_N $UNICODE_VERSION + ;; + + --host) + echo $host + exit 0 + ;; + + --help) + usage + exit 0 + ;; + + --usage) + usage + exit 0 + ;; + +# --enable-rpath=*) +# ENABLE_RPATH=$var +# loaddefs +# ;; + + -?) + usage + exit 0 + ;; + + *) + echo ${ME}: ERROR Unknown Option $arg 1>&2 + echo 1>&2 + shortusage 1>&2 + echo "### $ME: Exitting." 1>&2 + exit 1; + ;; + esac + shift + + # Reset the ignore icuuc file check flag + if [ $IGNORE_ICUUC_FILE_CHECK = "yes" ]; then + IGNORE_ICUUC_FILE_CHECK="no" + sanity + fi +done +echo +# Check once before we quit (will check last used prefix) +sanity +## END of icu-config-bottom + +exit 0 diff --git a/intl/icu/source/config/icu-config-top b/intl/icu/source/config/icu-config-top new file mode 100644 index 000000000..589385e1b --- /dev/null +++ b/intl/icu/source/config/icu-config-top @@ -0,0 +1,26 @@ +#!/bin/sh +## -*-sh-*- +#set -x +# BEGIN of icu-config-top +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +#****************************************************************************** +# Copyright (C) 1999-2013, International Business Machines +# Corporation and others. All Rights Reserved. +#****************************************************************************** +# This script is designed to aid configuration of ICU. +# rpath links a library search path right into the binaries. +# +# Note: it's preferred to use the .pc files rather than icu-config. +# + +### END of icu-config-top + +## Zero out prefix. +execprefix= +prefix= + + +loaddefs() +{ + diff --git a/intl/icu/source/config/icu-config.1.in b/intl/icu/source/config/icu-config.1.in new file mode 100644 index 000000000..55b8e3f31 --- /dev/null +++ b/intl/icu/source/config/icu-config.1.in @@ -0,0 +1,287 @@ +.\" Hey, Emacs! This is -*-nroff-*- you know... +.\" +.\" icu-config.1: manual page for the icu-config utility +.\" +.\" Copyright (C) 2016 and later: Unicode, Inc. and others. +.\" License & terms of use: http://www.unicode.org/copyright.html +.\" Copyright (C) 2002-2008 IBM, Inc. and others. +.\" +.\" Based on Yves Arrouye's pkgdata page <yves@arrouye.net> +.\" Modified by Steven R. Loomis <srl@jtcsv.com>. +.\" With help from http://www.igpm.rwth-aachen.de/~albrecht/manpage.html + +.TH ICU-CONFIG 1 "17 May 2004" "ICU MANPAGE" "ICU @VERSION@ Manual" +.\".Dd "17 May 2004" +.\".Dt ICU-CONFIG 1 +.\".Os + +.SH NAME +.B icu-config +\- output ICU build options +.SH SYNOPSIS +.B icu-config +[ +.BI "\-\-bindir" +] +[ +.BI "\-\-cc" +] +[ +.BI "\-\-cflags" +] +[ +.BI "\-\-cppflags" +] +[ +.BI "\-\-cppflags\-searchpath" +] +[ +.BI "\-\-cxx" +] +[ +.BI "\-\-cxxflags" +] +[ +.BI "\-\-detect\-prefix" +] +[ +.BI "\-\-exec\-prefix" +] +[ +.BI "\-\-exists" +] +[ +.BI "\-\-help\fP, \fB\-?\fP,\fB" +.BI "\-\-usage" +] +[ +.BI "\-\-icudata" +] +[ +.BI "\-\-icudata\-install\-dir" +] +[ +.BI "\-\-icudata\-mode" +] +[ +.BI "\-\-icudatadir" +] +[ +.BI "\-\-invoke" +] +[ +.BI "\-\-invoke=" "prog" +] +[ +.BI "\-\-ldflags" +] +[ +.BI "\-\-ldflags\-libsonly" +] +[ +.BI "\-\-ldflags\-searchpath" +] +[ +.BI "\-\-ldflags\-system" +] +[ +.BI "\-\-ldflags\-icuio" +] +[ +.BI "\-\-mandir" +] +[ +.BI "\-\-prefix" +] +[ +.BI "\-\-prefix=" "prefix" +] +[ +.BI "\-\-sbindir" +] +[ +.BI "\-\-shared\-datadir" +] +[ +.BI "\-\-sysconfdir" +] +[ +.BI "\-\-unicode\-version" +] +[ +.BI "\-\-version" +] +[ +.BI "\-\-incfile" +] + + + +.SH DESCRIPTION +.B icu-config +simplifies the task of building and linking against ICU as compared to +manually configuring user makefiles or equivalent. Because +.B icu-config +is an executable script, it also solves the problem of locating the ICU +libraries and headers, by allowing the system PATH to locate it. +.SH EXAMPLES +.B icu-config +can be used without a makefile. The command line below is sufficient for +building a single-file c++ program against ICU. (For example, \fBicu/source/samples/props/props.cpp\fR) +.PP +.RS +`icu-config --cxx --cxxflags --cppflags --ldflags` -o props props.cpp +.RE +.PP +More commonly, +.B icu-config +will be called from within a makefile, and used to set up variables. The +following example also builds the \fIprops\fR example. +.PP +.RS +CC=$(shell icu-config --cc) + +CXX=$(shell icu-config --cxx) + +CPPFLAGS=$(shell icu-config --cppflags) + +CXXFLAGS=$(shell icu-config --cxxflags) + +LDFLAGS =$(shell icu-config --ldflags) + +all: props + +props.o: props.cpp +.RE +.PP +make(1) will automatically use the above variables. +.SH OPTIONS +.TP +.BI "\-\-bindir" +Prints the binary (executable) directory path. Normally equivalent to 'bin'. +ICU user-executable applications and scripts are found here. +.TP +.BI "\-\-cc" +Print the C compiler used. Equivalent to the $(CC) Makefile variable. +.TP +.BI "\-\-cflags" +Print the C compiler flags. Equivalent to the $(CFLAGS) Makefile variable. +Does NOT include preprocessor directives such as include path or defined symbols. Examples include debugging (\-g) and optimization flags +.TP +.BI "\-\-cppflags" +Print the C preprocessor flags. Equivalent to the $(CPPFLAGS) Makefile variable. Examples are \-I include paths and \-D define directives. +.TP +.BI "\-\-cppflags\-searchpath" +Print the C preprocessor flags, as above but only \-I search paths. +.TP +.BI "\-\-cxx" +Print the C++ compiler. Equivalent to the $(CXX) Makefile variable. +.TP +.BI "\-\-cxxflags" +Print the C++ compiler flags. Equivalent to the $(CXXFLAGS) Makefile variable. +.TP +.BI "\-\-detect\-prefix" +If ICU has been moved from its installed location, prepending this flag to +other +.B icu-config +calls will attempt to locate ICU relative to where the +.B icu-config +script has been located. Can be used as a last-chance effort if the ICU +install has been damaged. +.TP +.BI "\-\-exec\-prefix" +Print the prefix used for executable program directories (such as bin, sbin, etc). Normally the same as the prefix. +.TP +.BI "\-\-exists" +Script will return with a successful (0) status if ICU seems to be installed +and located correctly, otherwise an error message and nonzero status will +be displayed. +.TP +.BI "\-\-help\fP, \fB\-?\fP,\fB\-\-usage" +Print a help and usage message. +.TP +.BI "\-\-icudata" +Print the \fIshortname\fP of the ICU data file. This does not include any suffix such as .dat, .dll, .so, .lib, .a, etc nor does it include prefixes such as 'lib'. It may be in the form \fBicudt21b\fP +.TP +.BI "\-\-icudata\-install\-dir" +Print the directory where ICU packaged data should +be installed. Can use as pkgdata(1)'s --install option. +.TP +.BI "\-\-icudata\-mode" +Print the default ICU pkgdata mode, such as dll or common. Can use as pkgdata(1)'s --mode option. +.TP +.BI "\-\-icudatadir" +Print the path to packaged archive data. (should be where $ICU_DATA +or equivalent default path points.) Will NOT point to the libdir. +.TP +.BI "\-\-invoke" +If ICU is not installed in a location where the operating system will locate +its shared libraries, this option will print out commands so as to set the +appropriate environment variables to load ICU's shared libraries. For example, +on many systems a variable named LD_LIBRARY_PATH or equivalent must be set. +.TP +.BI "\-\-invoke=" "prog" +Same as the \fB\-\-invoke\fP option, except includes options for invoking +a program named \fIprog\fP. If \fIprog\fP is the name of an ICU tool, +such as genrb(1), then \fBicu-config\fP will also include the full path +to that tool. +.TP +.BI "\-\-ldflags" +Print any flags which should be passed to the linker. These may include +-L for library search paths, and -l for including ICU libraries. By default, +this option will attempt to link in the "common" (libicuuc) and "i18n" +(libicui18n) libraries, as well as the data library. If additional libraries +are required, any of the following two flags may be added in conjunction with this one, +for example "\-\-ldflags \-\-ldflags-icuio" if the icuio library is required +in addition to the standard ICU libraries. +Equivalent to the $(LDFLAGS) Makefile variable. +.TP +.BI "\-\-ldflags\-layout" +Prints the link option for the ICU layout library. +.TP +.BI "\-\-ldflags\-icuio" +Prints the link option to add the ICU I/O package +.TP +.BI "\-\-ldflags\-libsonly" +Similar to \fI\-\-ldflags\fP but only includes the \-l options. +.TP +.BI "\-\-ldflags\-searchpath" +Similar to \fI\-\-ldflags\fP but only includes the \-L search path options. +.TP +.BI "\-\-ldflags\-system" +Similar to \fI\-\-ldflags\fP but only includes system libraries (such as pthreads) +.BI "\-\-mandir" +Prints the location of the installed ICU man pages. Normally (man) +.TP +.BI "\-\-prefix" +Prints the prefix (base directory) under which the installed ICU resides. +.TP +.BI "\-\-prefix=" "prefix" +Sets the ICU prefix to \fIprefix\fP for the remainder of this command line. +Does test whether the new prefix is valid. +.TP +.BI "\-\-sbindir" +Prints the location of ICU system binaries, normally (sbin) +.TP +.BI "\-\-shared\-datadir" +Prints the location of ICU shared data, normally (share) +.TP +.BI "\-\-sysconfdir" +Prints the location of ICU system configuration data, normally (etc) +.TP +.BI "\-\-unicode\-version" +Prints the Version of the Unicode Standard which the current ICU uses. +.TP +.BI "\-\-version" +Prints the current version of ICU. +.TP +.BI "\-\-incfile" +Prints the 'Makefile.inc' path, suitable for use with pkgdata(1)'s \-O option. +.PP +.SH AUTHORS +Steven Loomis +.SH VERSION +@VERSION@ +.SH COPYRIGHT +Copyright (C) 2002-2004 IBM, Inc. and others. + diff --git a/intl/icu/source/config/icu.pc.in b/intl/icu/source/config/icu.pc.in new file mode 100644 index 000000000..4d8db206c --- /dev/null +++ b/intl/icu/source/config/icu.pc.in @@ -0,0 +1,36 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +# Copyright (C) 2010-2013, International Business Machines Corporation. All Rights Reserved. + +# CFLAGS contains only anything end users should set +CFLAGS = @UCONFIG_CFLAGS@ +# CXXFLAGS contains only anything end users should set +CXXFLAGS = @UCONFIG_CXXFLAGS@ +# DEFS only contains those UCONFIG_CPPFLAGS which are not auto-set by platform.h +DEFS = @UCONFIG_CPPFLAGS@ +prefix = @prefix@ +exec_prefix = @exec_prefix@ +#bindir = @bindir@ +libdir = @libdir@ +includedir = @includedir@ +baselibs = @LIBS@ +#datarootdir = @datarootdir@ +#datadir = @datadir@ +#sbindir = @sbindir@ +#mandir = @mandir@ +#sysconfdir = @sysconfdir@ +UNICODE_VERSION=@UNICODE_VERSION@ +ICUPREFIX=icu +ICULIBSUFFIX=@ICULIBSUFFIX@ +LIBICU=lib${ICUPREFIX} +#SHAREDLIBCFLAGS=-fPIC +pkglibdir=${libdir}/@PACKAGE@${ICULIBSUFFIX}/@VERSION@ +#pkgdatadir=${datadir}/@PACKAGE@${ICULIBSUFFIX}/@VERSION@ +ICUDATA_NAME = icudt@LIB_VERSION_MAJOR@@ICUDATA_CHAR@ +#ICUPKGDATA_DIR=@libdir@ +#ICUDATA_DIR=${pkgdatadir} +ICUDESC=International Components for Unicode + +Version: @VERSION@ +Cflags: -I${includedir} +# end of icu.pc.in diff --git a/intl/icu/source/config/m4/icu-conditional.m4 b/intl/icu/source/config/m4/icu-conditional.m4 new file mode 100644 index 000000000..85dffb619 --- /dev/null +++ b/intl/icu/source/config/m4/icu-conditional.m4 @@ -0,0 +1,18 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +# Copyright (c) 1999-2015, International Business Machines Corporation and +# others. All Rights Reserved. + +# moved here from ../../acinclude.m4 + +# ICU_CONDITIONAL - similar example taken from Automake 1.4 +AC_DEFUN([ICU_CONDITIONAL], +[AC_SUBST($1_TRUE) +AC_SUBST(U_HAVE_$1) +if $2; then + $1_TRUE= + U_HAVE_$1=1 +else + $1_TRUE='#' + U_HAVE_$1=0 +fi]) diff --git a/intl/icu/source/config/make2sh.sed b/intl/icu/source/config/make2sh.sed new file mode 100644 index 000000000..df53e4e52 --- /dev/null +++ b/intl/icu/source/config/make2sh.sed @@ -0,0 +1,20 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +# Copyright (C) 1999-2011, International Business Machines Corporation and others. All Rights Reserved. +s%^\([a-zA-Z0-9\._-]*\)[ ]*+=%\1=$(\1) % +s%^[A-Z]*_SO_TARG*%## &% +s%^SHARED_OBJECT.*%## &% +s%^LD_SONAME.*%## &% +s%$(\([^\)]*\))%${\1}%g +s%^ %#M# % +s@^[a-zA-Z%$.][^=]*$@#M#&@ +s@^\([a-zA-Z][-.a-zA-Z_0-9-]*\)[ ]*=[ ]*\(.*\)@\1="\2"@ +s@^\([a-zA-Z][-a-zA-Z_0-9-]*\)\.\([a-zA-Z_0-9-]*\)[ ]*=[ ]*\(.*\)@\1_\2=\3@ +s@^\([a-zA-Z][-a-zA-Z_0-9-]*\)\-\([a-zA-Z_0-9-]*\)[ ]*=[ ]*\(.*\)@\1_\2=\3@ +s@\${\([a-zA-Z][-a-zA-Z_0-9-]*\)\.\([a-zA-Z_0-9-]*\)}@${\1_\2}@g +s@^\(prefix\)=\(.*\)@default_\1=\2\ +if [ "x${\1}" = "x" ]; then \1="$default_\1"; fi@ +s@^\(ENABLE_RPATH\)=\(.*\)@default_\1=\2\ +if [ "x${\1}" = "x" ]; then \1="$default_\1"; fi@ +s%^#SH#[ ]*%% +s%'\$\$'%\\\$\\\$%g diff --git a/intl/icu/source/config/mh-aix-gcc b/intl/icu/source/config/mh-aix-gcc new file mode 100644 index 000000000..62692bb74 --- /dev/null +++ b/intl/icu/source/config/mh-aix-gcc @@ -0,0 +1,138 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2003-2015 IBM, Ken Foskey, and others. All rights reserved. +## +## Aix-specific setup (for gcc) +## +## Please note: AIX does NOT have library versioning per se (there is no 'SONAME' capability). +## So, we are using 'windows' style library names, that is, libicuuc20.1.so instead of libicuuc.so.20.1 + +# When building stubdata, special considerations need to be made when building on AIX with GCC +BUILD_HOST_ICU=AIX_GCC + +# Certain files don't compile in -ansi mode (e.g. umutex.c, toolutil.c, and cdatatst.c) +CFLAGS += -D_ALL_SOURCE + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Commands to link +## We need to use the C++ linker, even when linking C programs, since +## our libraries contain C++ code (C++ static init not called) +LINK.c= $(AIX_PREDELETE) $(CXX) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(AIX_PREDELETE) $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +LD_SOOPTIONS= -Wl,-bsymbolic + +## Commands to make a shared library +SHLIB.c= $(AIX_PREDELETE) $(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-bexpall $(LD_SOOPTIONS) +SHLIB.cc= $(AIX_PREDELETE) $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared -Wl,-bexpall $(LD_SOOPTIONS) + +## Compiler switch to embed a runtime search path +LD_RPATH= -I +LD_RPATH_PRE= + +## enable the shared lib loader +LDFLAGS += -Wl,-bbigtoc + +## These are the library specific LDFLAGS +LDFLAGSICUDT=-nodefaultlibs -nostdlib + +## We need to delete things prior to linking, or else we'll get +## SEVERE ERROR: output file in use .. on AIX. +## But, shell script version should NOT delete target as we don't +## have $@ in that context. (SH = only shell script, icu-config) +AIX_PREDELETE=rm -f $@ ; +#SH# AIX_PREDELETE= + +## Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = LIBPATH + +## Override Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +MIDDLE_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +SHARED_OBJECT = $(notdir $(FINAL_SO_TARGET:.$(SO)=.$(SOBJ))) +SHARED_OBJECT_NO_VERSION = $(basename $(SO_TARGET)).$(SOBJ) + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +# this one is for icudefs.mk's use +ifeq ($(ENABLE_SHARED),YES) +SO_TARGET_VERSION_SUFFIX = $(SO_TARGET_VERSION_MAJOR) +endif + +## Compiler switch to embed a library name. Not present on AIX. +LD_SONAME = + +## The type of assembly needed when pkgdata is used for generating shared libraries. +GENCCODE_ASSEMBLY=-a xlc + +## Shared object suffix +SOBJ= so +# without the -brtl option, the library names use .a. AIX is funny that way. +SO= a +A= a + +## Non-shared intermediate object suffix +STATIC_O = o + +## Special AIX rules + +## Build archive from shared object +%.a : %.so + ln -f $< $(SHARED_OBJECT_NO_VERSION) + $(AR) $(ARFLAGS) $@ $(SHARED_OBJECT_NO_VERSION) + rm -f $(SHARED_OBJECT_NO_VERSION) +$(LIBDIR)/%.a : %.so + ln -f $< $(SHARED_OBJECT_NO_VERSION) + $(AR) $(ARFLAGS) $@ $(SHARED_OBJECT_NO_VERSION) + rm -f $(SHARED_OBJECT_NO_VERSION) + +## Build import list from export list +%.e : %.exp + @echo "Building an import list for $<" + @$(SHELL) -ec "echo '#! $*.a($*.so)' | cat - $< > $@" + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules +%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ +%.$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ + + +## BIR - bind with internal references [so app data and icu data doesn't collide] +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-bE:$(NAME).map,-bnoexpall + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= $(NAME).map + diff --git a/intl/icu/source/config/mh-aix-va b/intl/icu/source/config/mh-aix-va new file mode 100644 index 000000000..e1b423658 --- /dev/null +++ b/intl/icu/source/config/mh-aix-va @@ -0,0 +1,140 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Aix-specific setup (for Visual Age 5+) +## Copyright (c) 1999-2010, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -M $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -M $(DEFS) $(CPPFLAGS) + +# -qroconst make the strings readonly, which is usually the default. +# This helps in the data library, +# -qproto assumes all functions are prototyped (for optimization) +# -qrtti turns on compiler RTTI, required beginning with ICU 4.6 +CFLAGS += -qproto -qroconst +CXXFLAGS += -qproto -qroconst -qrtti + +# If you readd this line, you must change the SO value +#LDFLAGS += -brtl + +ifeq ($(UCLN_NO_AUTO_CLEANUP),0) +# set up init point. +UCLN_FINI = ucln_fini$(TARGET_STUBNAME)_$(SO_TARGET_VERSION_MAJOR)$(ICULIBSUFFIXCNAME) +CPPFLAGS_FINI = -DUCLN_FINI=$(UCLN_FINI) +LDFLAGS_FINI = -binitfini::$(UCLN_FINI) + +CPPFLAGSICUUC += $(CPPFLAGS_FINI) +LDFLAGSICUUC += $(LDFLAGS_FINI) +CPPFLAGSICUIO += $(CPPFLAGS_FINI) +LDFLAGSICUIO += $(LDFLAGS_FINI) +CPPFLAGSICUI18N += $(CPPFLAGS_FINI) +LDFLAGSICUI18N += $(LDFLAGS_FINI) +CPPFLAGSCTESTFW += $(CPPFLAGS_FINI) +LDFLAGSCTESTFW += $(LDFLAGS_FINI) + +# ICUUC, ICUIO, ICUI18N, CTESTFW +endif + +## We need to delete things prior to linking, or else we'll get +## SEVERE ERROR: output file in use .. on AIX. +## But, shell script version should NOT delete target as we don't +## have $@ in that context. (SH = only shell script, icu-config) +AIX_PREDELETE=rm -f $@ ; +#SH# AIX_PREDELETE= + +## Commands to link +## We need to use the C++ linker, even when linking C programs, since +## our libraries contain C++ code (C++ static init not called) +LINK.c= $(AIX_PREDELETE) $(CXX) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(AIX_PREDELETE) $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Commands to make a shared library +## -G means -berok -brtl -bnortllib -bnosymbolic -bnoautoexp +## -bh:8 means halt on errors or worse. We don't display warnings about +## duplicate inline symbols. +SHLIB.c= $(AIX_PREDELETE) $(CXX) -qmkshrobj -G $(LDFLAGS) +SHLIB.cc= $(AIX_PREDELETE) $(CXX) -qmkshrobj -G $(LDFLAGS) + +## Compiler switch to embed a runtime search path +LD_RPATH= -I +LD_RPATH_PRE= + +## Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = LIBPATH + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +# this one is for icudefs.mk's use +ifeq ($(ENABLE_SHARED),YES) +SO_TARGET_VERSION_SUFFIX = $(SO_TARGET_VERSION_MAJOR) +endif + +LD_SONAME = + +## The type of assembly needed when pkgdata is used for generating shared libraries. +GENCCODE_ASSEMBLY=-a xlc + +## Shared object suffix +SOBJ= so +# without the -brtl option, the library names use .a. AIX is funny that way. +SO= a +## Non-shared intermediate object suffix +STATIC_O = o + +## Override Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +MIDDLE_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +SHARED_OBJECT = $(notdir $(FINAL_SO_TARGET:.$(SO)=.$(SOBJ))) +SHARED_OBJECT_NO_VERSION= $(basename $(SO_TARGET)).$(SOBJ) + +## Build archive from shared object +%.a : %.so + ln -f $< $(SHARED_OBJECT_NO_VERSION) + $(AIX_PREDELETE) $(AR) $(ARFLAGS) $@ $(SHARED_OBJECT_NO_VERSION) + rm -f $(SHARED_OBJECT_NO_VERSION) +$(LIBDIR)/%.a : %.so + ln -f $< $(SHARED_OBJECT_NO_VERSION) + $(AIX_PREDELETE) $(AR) $(ARFLAGS) $@ $(SHARED_OBJECT_NO_VERSION) + rm -f $(SHARED_OBJECT_NO_VERSION) + +## Build import list from export list +%.e : %.exp + @echo "Building an import list for $<" + @$(SHELL) -ec "echo '#! $*.a($*.so)' | cat - $< > $@" + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : %.u + @$(SHELL) -ec 'cat $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@ ; rm -f $<' + +%.u : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > /dev/null + +%.u : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > /dev/null + +## Versioned libraries rules +%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ +%.$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ + +## End Aix-specific setup diff --git a/intl/icu/source/config/mh-alpha-linux-cc b/intl/icu/source/config/mh-alpha-linux-cc new file mode 100644 index 000000000..b3476b64a --- /dev/null +++ b/intl/icu/source/config/mh-alpha-linux-cc @@ -0,0 +1,87 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Alpha-Linux-specific setup +## Copyright (c) 1999-2006, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +#GEN_DEPS.c= $(CC) $(DEFS) $(CPPFLAGS) -MD -c -msg_quiet +#GEN_DEPS.cc= $(CXX) $(DEFS) $(CPPFLAGS) -D__USE_STD_IOSTREAM -c -MD -msg_quiet + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +# The tests need complete IEEE floating point support +CFLAGS += -ieee +CXXFLAGS += -ieee + +## Commands to compile +COMPILE.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -c -signed -accept nogccinline +COMPILE.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) -c -signed -D__USE_STD_IOSTREAM -accept nogcc_inline + + +## Commands to link +LINK.c= $(CC) -call_shared $(CFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) -call_shared $(CXXFLAGS) $(LDFLAGS) + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +#%.d: $(srcdir)/%.c +# @echo "generating dependency information for $<" +# @$(SHELL) -ec '$(GEN_DEPS.c) $< \ +# | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ +# [ -s $@ ] || rm -f $@' + +#%.d: $(srcdir)/%.cpp +# @echo "generating dependency information for $<" +# @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ +# | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ +# [ -s $@ ] || rm -f $@' +# +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## End Linux-specific setup + diff --git a/intl/icu/source/config/mh-alpha-linux-gcc b/intl/icu/source/config/mh-alpha-linux-gcc new file mode 100644 index 000000000..a3531d271 --- /dev/null +++ b/intl/icu/source/config/mh-alpha-linux-gcc @@ -0,0 +1,85 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Linux-specific setup +## Copyright (c) 1999-2009, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +# The tests need complete IEEE floating point support +CFLAGS += -mieee +CXXFLAGS += -mieee + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +# The type of assembly to write for generating an object file +GENCCODE_ASSEMBLY=-a gcc + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## End Linux-specific setup + diff --git a/intl/icu/source/config/mh-alpha-osf b/intl/icu/source/config/mh-alpha-osf new file mode 100644 index 000000000..27d73cf93 --- /dev/null +++ b/intl/icu/source/config/mh-alpha-osf @@ -0,0 +1,87 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Alpha-OSF-specific setup +## Copyright (c) 1999-2006, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +#GEN_DEPS.c= $(CC) $(DEFS) $(CPPFLAGS) -MD -c -msg_quiet +#GEN_DEPS.cc= $(CXX) $(DEFS) $(CPPFLAGS) -D__USE_STD_IOSTREAM -c -MD -msg_quiet + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT -pthread +LIBCPPFLAGS = + +# The tests need complete IEEE floating point support +CFLAGS += -ieee +CXXFLAGS += -ieee + +## Commands to compile +COMPILE.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -c +COMPILE.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) -c -D__USE_STD_IOSTREAM + + +## Commands to link +LINK.c= $(CC) -call_shared $(CFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) -call_shared $(CXXFLAGS) $(LDFLAGS) + +## Compiler switch to embed a runtime search path +LD_RPATH= $(LD_RPATH)$(LD_RPATH_PRE)path1 +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +#%.d: $(srcdir)/%.c +# @echo "generating dependency information for $<" +# @$(SHELL) -ec '$(GEN_DEPS.c) $< \ +# | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ +# [ -s $@ ] || rm -f $@' + +#%.d: $(srcdir)/%.cpp +# @echo "generating dependency information for $<" +# @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ +# | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ +# [ -s $@ ] || rm -f $@' +# +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## End Tru64 5.1 specific setup + diff --git a/intl/icu/source/config/mh-beos b/intl/icu/source/config/mh-beos new file mode 100644 index 000000000..3e9af8e53 --- /dev/null +++ b/intl/icu/source/config/mh-beos @@ -0,0 +1,108 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## BeOS-specific setup +## Copyright (c) 2003-2006, International Business Machines Corporation and +## others. All Rights Reserved. +## +## Original author: Andrew Bachmann + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +# Safe optimizations +#OPTIMIZATIONS= -fdefault-inline -fdefer-pop -fforce-mem -fforce-addr \ +# -finline -finline-functions \ +# -fkeep-inline-functions -fkeep-static-consts -fbranch-count-reg \ +# -ffunction-cse -fstrength-reduce -fthread-jumps -fcse-follow-jumps \ +# -fcse-skip-blocks -frerun-cse-after-loop -frerun-loop-opt \ +# -fexpensive-optimizations -foptimize-register-move -fregmove \ +# -fschedule-insns -fschedule-insns2 -ffloat-store -funroll-loops \ +# -fmove-all-movables -freduce-all-givs -fpeephole \ +# -funroll-all-loops -ffunction-sections -fdata-sections + +# BeOS gccs (geekgadgets + 2.95.3) have this old bug: +# after this: const wchar_t x[] = L"foo"; +# x[2] is "optimized" into: (wchar_t)((char *)x)[2] (== 0) +# +# see also: http://gcc.gnu.org/ml/gcc-patches/2000-09/msg00454.html +# +# Unfortunately this behavior isn't controlled by a flag so we can't +# use any O optimizations at all. (the behavior kicks in at -O1) + +# Optimizations aren't currently defined in the mh files. +# So Don't override any flags set by the user or runConfigureICU. +#CFLAGS += $(OPTIMIZATIONS) +#CXXFLAGS += $(OPTIMIZATIONS) + +# Use -nostart instead of -shared +SHLIB.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -nostart +SHLIB.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -nostart + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +LIBCPPFLAGS = +THREADSCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE = -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +# Use LIBRARY_PATH instead of LD_LIBRARY_PATH +LDLIBRARYPATH_ENVVAR= LIBRARY_PATH + +## End BeOS-specific setup + diff --git a/intl/icu/source/config/mh-bsd-gcc b/intl/icu/source/config/mh-bsd-gcc new file mode 100644 index 000000000..9dc525f1f --- /dev/null +++ b/intl/icu/source/config/mh-bsd-gcc @@ -0,0 +1,82 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## BSD-specific setup (FreeBSD, OpenBSD, NetBSD, *BSD) +## Copyright (c) 1999-2013, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End BSD-specific setup + + diff --git a/intl/icu/source/config/mh-cygwin b/intl/icu/source/config/mh-cygwin new file mode 100644 index 000000000..1cc2d74c3 --- /dev/null +++ b/intl/icu/source/config/mh-cygwin @@ -0,0 +1,143 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Cygwin-specific setup +## Copyright (c) 2001-2010, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +# Commands to link. Link with C++ in case static libraries are used. +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +#LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Commands to make a shared library +# $(subst) won't work in shell script. #M# at the end omits these +# lines from the shell script (Make only) +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(subst cyg,lib,$@).$(A)#M# +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(subst cyg,lib,$@).$(A)#M# +# the #SH# lines don't go through further postprocessing. +# so, they must be valid shell script starting from column 4 +#SH#SHLIB_c="$(CC) $(CFLAGS) $(LDFLAGS) -shared " +#SH#SHLIB_cc="$(CXX) $(CXXFLAGS) $(LDFLAGS) -shared " + + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao +LIBICU = cyg$(ICUPREFIX) +## To have an import library is better on Cygwin +IMPORT_LIB_EXT = .dll.a + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.c) $< >> $@ || (rm -f $@ && FALSE) + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.cc) $< >> $@ || (rm -f $@ && FALSE) + +## Versioned target for a shared library. +## Since symbolic links don't work the same way on Windows, +## we only use the version major number. +#FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +IMPORT_LIB = $(subst cyg,lib,$(FINAL_SO_TARGET)).$(A)#M# +MIDDLE_IMPORT_LIB = $(subst cyg,lib,$(basename $(SO_TARGET)))$(SO_TARGET_VERSION_MAJOR).$(SO).$(A)#M# +FINAL_IMPORT_LIB = $(IMPORT_LIB)#M# + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + $(RM) $(subst cyg,lib,$@).$(A) && ln -s $(subst cyg,lib,${<F}).$(A) $(subst cyg,lib,$@).$(A) + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# The type of assembly to write for generating an object file +GENCCODE_ASSEMBLY=-a gcc-cygwin + +# put this here again so it gets cyguc... + +#SH#ICULIBS_COMMON_LIB_NAME="${LIBICU}uc${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}.${SO}" + +# for icu-config + +#SH### copied from Makefile.inc +#SH#ICULIBS_COMMON="-l${LIBICU}uc${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_DATA="-l${LIBICU}${DATA_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_I18N="-l${LIBICU}${I18N_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_TOOLUTIL="-l${LIBICU}tu${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_CTESTFW="-l${LIBICU}ctestfw${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_ICUIO="-l${LIBICU}io${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_OBSOLETE="-l${LIBICU}obsolete${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_LAYOUT="-l${LIBICU}le${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_LAYOUTEX="-l${LIBICU}lx${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_BASE="${LIBS} -L${libdir}" +#SH#ICULIBS="${ICULIBS_BASE} ${ICULIBS_I18N} ${ICULIBS_COMMON} ${ICULIBS_DATA}" + +## End Cygwin-specific setup + diff --git a/intl/icu/source/config/mh-cygwin-msvc b/intl/icu/source/config/mh-cygwin-msvc new file mode 100644 index 000000000..01003acfd --- /dev/null +++ b/intl/icu/source/config/mh-cygwin-msvc @@ -0,0 +1,230 @@ +## Cygwin with Microsoft Visual C++ compiler specific setup +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2001-2013, International Business Machines Corporation and +## others. All Rights Reserved. + +# We install sbin tools into the same bin directory because +# pkgdata needs some of the tools in sbin, and we can't always depend on +# icu-config working on Windows. +sbindir=$(bindir) + +## Commands to generate dependency files +GEN_DEPS.c= : +GEN_DEPS.cc= : +#GEN_DEPS.c= $(COMPILE.c) -E +#GEN_DEPS.cc= $(COMPILE.cc) -E + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION#M# +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = + +## Additional flags when building libraries and with threads +LIBCPPFLAGS = + +ifeq ($(ENABLE_RELEASE),1) +# Make sure that assertions are disabled +CPPFLAGS+=-DU_RELEASE=1#M# +endif + +ifeq ($(ENABLE_DEBUG),1) +# Pass debugging flag through +CPPFLAGS+=-D_DEBUG=1#M# +ICULIBSUFFIX:=$(ICULIBSUFFIX)d#M# +endif + +# /GF pools strings and places them into read-only memory +# /EHsc enables exception handling +# /Zc:wchar_t makes wchar_t a native type. Required for C++ ABI compatibility. +# -D_CRT_SECURE_NO_DEPRECATE is needed to quiet warnings about using standard C functions. +CFLAGS+=-GF -nologo +CXXFLAGS+=-GF -nologo -EHsc -Zc:wchar_t +CPPFLAGS+=-D_CRT_SECURE_NO_DEPRECATE +DEFS+=-DWIN32 -DCYGWINMSVC +LDFLAGS+=-nologo + +# Commands to compile +COMPILE.c= $(CC) $(CPPFLAGS) $(DEFS) $(CFLAGS) -c +COMPILE.cc= $(CXX) $(CPPFLAGS) $(DEFS) $(CXXFLAGS) -c + +# Commands to link +LINK.c= LINK.EXE -subsystem:console $(LDFLAGS) +LINK.cc= LINK.EXE -subsystem:console $(LDFLAGS) + +## Commands to make a shared library +SHLIB.c= LINK.EXE -DLL $(LDFLAGS) +SHLIB.cc= LINK.EXE -DLL $(LDFLAGS) + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= + +## Compiler switch to embed a library name +LD_SONAME = -IMPLIB:$(SO_TARGET:.dll=.lib) + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao +# OUTOPT is for creating a specific output name +OUTOPT = -out: + +# Static library prefix and file extension +LIBSICU = $(STATIC_PREFIX)$(ICUPREFIX) +A = lib + +# Cygwin's ar can't handle Win64 right now. So we use Microsoft's tool instead. +AR = LIB.EXE#M# +ARFLAGS := -nologo $(ARFLAGS:r=)#M# +RANLIB = ls -s#M# +AR_OUTOPT = -OUT:#M# + +## An import library is needed for z/OS, MSVC and Cygwin +IMPORT_LIB_EXT = .lib + +LIBPREFIX= +DEFAULT_LIBS = advapi32.lib + +# Change the stubnames so that poorly working FAT disks and installation programs can work. +# This is also for backwards compatibility. +DATA_STUBNAME = dt +I18N_STUBNAME = in +LIBICU = $(STATIC_PREFIX_WHEN_USED)$(ICUPREFIX) + +## Link commands to link to ICU libs +ifeq ($(wildcard $(LIBDIR)/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib),) +LIBICUDT= $(top_builddir)/stubdata/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib +else +LIBICUDT= $(LIBDIR)/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib +endif +LIBICUUC= $(LIBDIR)/$(LIBICU)$(COMMON_STUBNAME)$(ICULIBSUFFIX).lib $(LIBICUDT) +LIBICUI18N= $(LIBDIR)/$(LIBICU)$(I18N_STUBNAME)$(ICULIBSUFFIX).lib +LIBICULE= $(LIBDIR)/$(LIBICU)$(LAYOUT_STUBNAME)$(ICULIBSUFFIX).lib +LIBICULX= $(LIBDIR)/$(LIBICU)$(LAYOUTEX_STUBNAME)$(ICULIBSUFFIX).lib +LIBICUIO= $(LIBDIR)/$(LIBICU)$(IO_STUBNAME)$(ICULIBSUFFIX).lib +LIBCTESTFW= $(top_builddir)/tools/ctestfw/$(LIBICU)$(CTESTFW_STUBNAME)$(ICULIBSUFFIX).lib +LIBICUTOOLUTIL= $(LIBDIR)/$(LIBICU)$(TOOLUTIL_STUBNAME)$(ICULIBSUFFIX).lib + +## These are the library specific LDFLAGS +LDFLAGSICUDT+= -base:"0x4ad00000" -NOENTRY# The NOENTRY option is required for creating a resource-only DLL. +LDFLAGSICUUC= -base:"0x4a800000"# in-uc = 1MB +LDFLAGSICUI18N= -base:"0x4a900000"# io-in = 2MB +LDFLAGSICUIO= -base:"0x4ab00000"# le-io = 1MB +LDFLAGSICULX= -base:"0x4ac80000" +LDFLAGSCTESTFW=# Unused for now. +LDFLAGSICUTOOLUTIL= -base:"0x4ac00000"# Same as layout. Layout and tools probably won't mix. + +# The #M# is used to delete lines for icu-config +# Current full path directory. +CURR_FULL_DIR?=$(subst \,/,$(shell cygpath -da .))#M# -m isn't used because it doesn't work on Win98 +# Current full path directory for use in source code in a -D compiler option. +CURR_SRCCODE_FULL_DIR=$(subst \,\\,$(shell cygpath -da .))#M# + +ifeq ($(srcdir),.) +SOURCE_FILE=$< +else +SOURCE_FILE=$(shell cygpath -dma $<)#M# +endif + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -Fo$@ $(SOURCE_FILE) +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -Fo$@ $(SOURCE_FILE) + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -Fo$@ $(SOURCE_FILE) +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -Fo$@ $(SOURCE_FILE) + + +## Dependency rules +## This is a start to how depdendencies could work +# The commented out rules may not properly delete the file when ^C is pressed +# or the compiler fails. +# make currently doesn't like rules with C:\\PROGRA~1\\.. in the depedency. +# So system headers are ignored by ignoring \\ +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > $@ +# @echo -n "generating dependency information for " +# @echo -n "$@ $(basename $<).o : " > $@ +# @$(SHELL) -ec '$(GEN_DEPS.c) $< \ +# | grep "#line 1 " | grep -v \\\\ | cut -d " " -f 3 \ +# | /usr/bin/sort -u | sed s/\"$$/\\\\/ | sed s/^\"/\ / >> $@ \ +# || (rm -f $@ && echo $@ && false)' + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > $@ +# @echo -n "generating dependency information for " +# @echo -n "$@ $(basename $<).o : " > $@ +# @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ +# | grep "#line 1 " | grep -v \\\\ | cut -d " " -f 3 \ +# | /usr/bin/sort -u | sed s/\"$$/\\\\/ | sed s/^\"/\ / >> $@ \ +# || (rm -f $@ && echo $@ && false)' + +## Compile a Windows resource file +%.res : $(srcdir)/%.rc + rc.exe -fo$@ $(CPPFLAGS) $(SOURCE_FILE) + +## Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +## Starting in MSVC 2005, manifest files are required. This reduces the obnoxiousness of this feature. + POST_SO_BUILD_STEP = @([ -e $<.manifest ] && \ + ( echo Embedding manifest into $< && mt.exe -nologo -manifest $<.manifest -outputresource:"$<;2" && rm -rf $<.manifest )) \ + || true + POST_BUILD_STEP = @([ -e $@.manifest ] && \ + ( echo Embedding manifest into $@ && mt.exe -nologo -manifest $@.manifest -outputresource:"$@;1" && rm -rf $@.manifest )) \ + || true + +## Special pkgdata information that is needed +PKGDATA_VERSIONING = -r $(SO_TARGET_VERSION_MAJOR) +ICUPKGDATA_INSTALL_DIR = $(shell mkdir -p $(DESTDIR)$(ICUPKGDATA_DIR) ; cygpath -dma $(DESTDIR)$(ICUPKGDATA_DIR))#M# +ICUPKGDATA_INSTALL_LIBDIR = $(shell mkdir -p $(DESTDIR)$(libdir) ; cygpath -dma $(DESTDIR)$(libdir))#M# + +## Versioned import library names. The library names are versioned, +## but the import libraries do not need versioning. +IMPORT_LIB = $(basename $(SO_TARGET))$(IMPORT_LIB_EXT)#M# +MIDDLE_IMPORT_LIB = $(IMPORT_LIB)#M# +FINAL_IMPORT_LIB = $(MIDDLE_IMPORT_LIB)#M# + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ + +# The following rule is sometimes a no op. +# We only want to do a post-build step when a manifest file doesn't exist. +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + @echo -n + $(POST_SO_BUILD_STEP) + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# These are needed to allow the pkgdata nmake files to work +PKGDATA_INVOKE_OPTS = MAKEFLAGS= + +# Include the version information in the shared library +ENABLE_SO_VERSION_DATA=1 + +## End Cygwin-specific setup + diff --git a/intl/icu/source/config/mh-cygwin64 b/intl/icu/source/config/mh-cygwin64 new file mode 100644 index 000000000..0af0c88a9 --- /dev/null +++ b/intl/icu/source/config/mh-cygwin64 @@ -0,0 +1,143 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Cygwin64-specific setup +## Copyright (c) 2014, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +# Commands to link. Link with C++ in case static libraries are used. +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +#LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Commands to make a shared library +# $(subst) won't work in shell script. #M# at the end omits these +# lines from the shell script (Make only) +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(subst cyg,lib,$@).$(A)#M# +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(subst cyg,lib,$@).$(A)#M# +# the #SH# lines don't go through further postprocessing. +# so, they must be valid shell script starting from column 4 +#SH#SHLIB_c="$(CC) $(CFLAGS) $(LDFLAGS) -shared " +#SH#SHLIB_cc="$(CXX) $(CXXFLAGS) $(LDFLAGS) -shared " + + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao +LIBICU = cyg$(ICUPREFIX) +## To have an import library is better on Cygwin +IMPORT_LIB_EXT = .dll.a + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.c) $< >> $@ || (rm -f $@ && FALSE) + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.cc) $< >> $@ || (rm -f $@ && FALSE) + +## Versioned target for a shared library. +## Since symbolic links don't work the same way on Windows, +## we only use the version major number. +#FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +IMPORT_LIB = $(subst cyg,lib,$(FINAL_SO_TARGET)).$(A)#M# +MIDDLE_IMPORT_LIB = $(subst cyg,lib,$(basename $(SO_TARGET)))$(SO_TARGET_VERSION_MAJOR).$(SO).$(A)#M# +FINAL_IMPORT_LIB = $(IMPORT_LIB)#M# + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + $(RM) $(subst cyg,lib,$@).$(A) && ln -s $(subst cyg,lib,${<F}).$(A) $(subst cyg,lib,$@).$(A) + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# The type of assembly to write for generating an object file +GENCCODE_ASSEMBLY=-a gcc-mingw64 + +# put this here again so it gets cyguc... + +#SH#ICULIBS_COMMON_LIB_NAME="${LIBICU}uc${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}.${SO}" + +# for icu-config + +#SH### copied from Makefile.inc +#SH#ICULIBS_COMMON="-l${LIBICU}uc${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_DATA="-l${LIBICU}${DATA_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_I18N="-l${LIBICU}${I18N_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_TOOLUTIL="-l${LIBICU}tu${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_CTESTFW="-l${LIBICU}ctestfw${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_ICUIO="-l${LIBICU}io${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_OBSOLETE="-l${LIBICU}obsolete${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_LAYOUT="-l${LIBICU}le${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_LAYOUTEX="-l${LIBICU}lx${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}" +#SH#ICULIBS_BASE="${LIBS} -L${libdir}" +#SH#ICULIBS="${ICULIBS_BASE} ${ICULIBS_I18N} ${ICULIBS_COMMON} ${ICULIBS_DATA}" + +## End Cygwin-specific setup + diff --git a/intl/icu/source/config/mh-darwin b/intl/icu/source/config/mh-darwin new file mode 100644 index 000000000..fdab05192 --- /dev/null +++ b/intl/icu/source/config/mh-darwin @@ -0,0 +1,81 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Darwin-specific setup (Darwin is the Mac OS X developer preview, successor +## to Rhapsody, aka Mac OS X Server) +## Copyright (c) 1999-2012 International Business Machines Corporation and +## others. All Rights Reserved. + +## Flags for position independent code +SHAREDLIBCFLAGS = -dynamic +SHAREDLIBCXXFLAGS = -dynamic +SHAREDLIBCPPFLAGS = + +# Do not export internal methods by default +LIBCFLAGS += -fvisibility=hidden +LIBCXXFLAGS += -fvisibility=hidden + +# Pad out the paths to the maximum possible length +LD_FLAGS += -headerpad_max_install_names + +# We do not need to see the stderr message that the archive was made. +ARFLAGS += -c + +## Commands to compile +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 +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 + +GENCCODE_ASSEMBLY=-a gcc-darwin + +## Shared object suffix +SO= dylib +## Non-shared intermediate object suffix +STATIC_O = ao + +## Override Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET)).$(SO_TARGET_VERSION).$(SO) +MIDDLE_SO_TARGET= $(basename $(SO_TARGET)).$(SO_TARGET_VERSION_MAJOR).$(SO) + +## Compilation and dependency rules +%.$(STATIC_O): $(srcdir)/%.c + $(call SILENT_COMPILE,$(strip $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS)) -MMD -MT "$*.d $*.o $*.$(STATIC_O)" -o $@ $<) +%.o: $(srcdir)/%.c + $(call SILENT_COMPILE,$(strip $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS)) -MMD -MT "$*.d $*.o $*.$(STATIC_O)" -o $@ $<) + +%.$(STATIC_O): $(srcdir)/%.cpp + $(call SILENT_COMPILE,$(strip $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS)) -MMD -MT "$*.d $*.o $*.$(STATIC_O)" -o $@ $<) +%.o: $(srcdir)/%.cpp + $(call SILENT_COMPILE,$(strip $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS)) -MMD -MT "$*.d $*.o $*.$(STATIC_O)" -o $@ $<) + +## Versioned libraries rules + +%.$(SO_TARGET_VERSION_MAJOR).$(SO): %.$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO_TARGET_VERSION_MAJOR).$(SO) + $(RM) $@ && ln -s ${*F}.$(SO_TARGET_VERSION).$(SO) $@ + +# tzcode option +TZORIG_EXTRA_CFLAGS=-DSTD_INSPIRED + +# genren opts +GENREN_PL_OPTS=-x Mach-O -n '-g' -p '| c++filt' + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End Darwin-specific setup diff --git a/intl/icu/source/config/mh-haiku b/intl/icu/source/config/mh-haiku new file mode 100644 index 000000000..bb814cdd4 --- /dev/null +++ b/intl/icu/source/config/mh-haiku @@ -0,0 +1,80 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## haiku-specific setup +## Copyright (c) 2010-2012, International Business Machines Corporation and +## others. All Rights Reserved. +## + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +LIBCPPFLAGS = +THREADSCPPFLAGS = + +# +CPPFLAGS += -D__STDC_ISO_10646__ -DU_CHARSET_IS_UTF8=1 + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE = -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +# Use LIBRARY_PATH instead of LD_LIBRARY_PATH +LDLIBRARYPATH_ENVVAR= LIBRARY_PATH + +## End haiku-specific setup diff --git a/intl/icu/source/config/mh-hpux-acc b/intl/icu/source/config/mh-hpux-acc new file mode 100644 index 000000000..87f2b505c --- /dev/null +++ b/intl/icu/source/config/mh-hpux-acc @@ -0,0 +1,138 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## HP/UX-specific setup using aCC +## Copyright (c) 1999-2012, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= : +GEN_DEPS.cc= : + +## Flags for position independent code +SHAREDLIBCFLAGS = +Z +SHAREDLIBCXXFLAGS = +Z + +## Additional flags when building libraries with threads +## We use this instead of -mt, which isn't available in all versions of aCC +## Our tools won't compile with -D_POSIX_C_SOURCE=199506L +THREADSCPPFLAGS = -D_REENTRANT -D_THREAD_SAFE + +# Use Extended ANSI mode, which is useful for 64-bit numbers +# +W ignores some warnings +# 740 Unsafe cast between pointers/references to incomplete classes... +# 749 This operation is non-portable and potentially unsafe. +# (Ironically the solution to fix this warning is non-portable) +# 823 Redundant preprocessing concatenation operation results in two valid +# preprocessing tokens. This comes from INT64_C in <inttypes.h> +# 4232 conversion to a more strictly aligned type may cause misaligned access. +CFLAGS += -Ae +Olit=all +CXXFLAGS += -AA -Wc,-ansi_for_scope,on +W740 +W749 +W823 +W4232 + +ifeq ($(UCLN_NO_AUTO_CLEANUP),0) +# set up init point. +UCLN_FINI = ucln_fini$(TARGET_STUBNAME)_$(SO_TARGET_VERSION_MAJOR)$(ICULIBSUFFIXCNAME) +CPPFLAGS_FINI = -DUCLN_FINI=$(UCLN_FINI) +LDFLAGS_FINI = -Wl,+fini,$(UCLN_FINI) + +CPPFLAGSICUUC += $(CPPFLAGS_FINI) +LDFLAGSICUUC += $(LDFLAGS_FINI) +CPPFLAGSICUIO += $(CPPFLAGS_FINI) +LDFLAGSICUIO += $(LDFLAGS_FINI) +CPPFLAGSICUI18N += $(CPPFLAGS_FINI) +LDFLAGSICUI18N += $(LDFLAGS_FINI) +CPPFLAGSCTESTFW += $(CPPFLAGS_FINI) +LDFLAGSCTESTFW += $(LDFLAGS_FINI) + +# ICUUC, ICUIO, ICUI18N, CTESTFW +endif + +# -Bhidden_def Hides all symbols defined in the module. +#LIBCFLAGS = -Bhidden_def +#LIBCXXFLAGS = -Bhidden_def + +## Commands to compile +COMPILE.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -c +COMPILE.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) -c + +## Common 'default' path to ensure the sanity of users. Search the current +## directory, at least. +LD_DEFAULTPATH= -Wl,+b,'$$'ORIGIN/ + +# Use SHLIB_PATH and LD_LIBRARY_PATH to locate shared libraries +LDFLAGS += -Wl,+s $(LD_DEFAULTPATH) + +## Commands to link +## For aCC, use the C++ linker so that __shlinit gets defined +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +## HPUX PA-risc does not recognize -Bprotected_def aC++ option. +## Use linker option -Wl,-B,symbolic instead. +ifeq ($(shell uname -m),ia64) +LD_SOOPTIONS= -Bprotected_def +else +LD_SOOPTIONS= -Wl,-B,symbolic +endif + +## Commands to make a shared library +#SHLIB.c= $(LD) $(LDFLAGS) -b +SHLIB.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) -b $(LD_SOOPTIONS) +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -b $(LD_SOOPTIONS) + +## Compiler switch to embed a runtime search path +LD_RPATH= -Wl,+b, +LD_RPATH_PRE= + +## Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = SHLIB_PATH + +## Compiler switch to embed a library name +LD_SONAME = -Wl,+h,$(notdir $(MIDDLE_SO_TARGET)) + +## The type of assembly needed when pkgdata is used for generating shared libraries. +# Commented out for now because the hp1 test machine runs out of memory. +#GENCCODE_ASSEMBLY=-a aCC-parisc + +## Shared object suffix +SO= sl +## Non-shared intermediate object suffix +STATIC_O = o + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > $@ + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > $@ + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End HP/UX-specific setup diff --git a/intl/icu/source/config/mh-hpux-gcc b/intl/icu/source/config/mh-hpux-gcc new file mode 100644 index 000000000..c2e91227e --- /dev/null +++ b/intl/icu/source/config/mh-hpux-gcc @@ -0,0 +1,92 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## HPUX/gcc specific setup +## Copyright (c) 1999-2012, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Common 'default' path to ensure the sanity of users. Search the current +## directory, at least. +LD_DEFAULTPATH= -Wl,+b,.:'$$'ORIGIN/ + +# Need to override this or we will get unworking assembly +#GENCCODE_ASSEMBLY=-a gcc +GENCCODE_ASSEMBLY= + +# Get some handy functions defined properly +DEFS += -D_HPUX_SOURCE -D_POSIX_C_SOURCE=199506L + +## Commands to link +## For aCC, use the C++ linker so that __shlinit gets defined +LINK.c= $(CXX) $(DEFS) $(LDFLAGS) -Wl,+s $(LD_DEFAULTPATH) +LINK.cc= $(CXX) $(DEFS) $(LDFLAGS) -Wl,+s $(LD_DEFAULTPATH) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Commands to make a shared library +SHLIB.c= $(CC) $(DEFS) $(CFLAGS) $(LDFLAGS) $(SHAREDLIBCXXFLAGS) -shared -Wl,+s $(LD_DEFAULTPATH) $(LD_SOOPTIONS) +SHLIB.cc= $(CXX) $(DEFS) $(CXXFLAGS) $(LDFLAGS) $(SHAREDLIBCXXFLAGS) -shared -Wl,+s $(LD_DEFAULTPATH) $(LD_SOOPTIONS) + +## Compiler switch to embed a runtime search path +LD_RPATH= -Wl,+b, +LD_RPATH_PRE= + +## Compiler switch to embed a library name +LD_SONAME = -Wl,+h,$(notdir $(MIDDLE_SO_TARGET)) + +## Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = SHLIB_PATH + +## Shared object suffix +SO= sl +## Non-shared intermediate object suffix +STATIC_O = o + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "Generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d : $(srcdir)/%.cpp + @echo "Generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End HPUX/gcc specific setup + diff --git a/intl/icu/source/config/mh-irix b/intl/icu/source/config/mh-irix new file mode 100644 index 000000000..e8904fa17 --- /dev/null +++ b/intl/icu/source/config/mh-irix @@ -0,0 +1,76 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## IRIX-specific setup (for CC) +## Copyright (c) 1999-2006, International Business Machines Corporation and +## others. All Rights Reserved. + +## Flags for position independent code +SHAREDLIBCFLAGS = -shared +SHAREDLIBCXXFLAGS = -shared +SHAREDLIBCPPFLAGS = + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -M $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -M $(DEFS) $(CPPFLAGS) + +## Commands to link +## We need to use the C++ linker, even when linking C programs, since +## our libraries contain C++ code (C++ static init not called) +#LINK.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) +LINK.c= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) + +## Commands to make a shared library +SHLIB.c= $(CC) -shared $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) +SHLIB.cc= $(CXX) -shared $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) + +## Additional flags when building libraries with thread safety +THREADSCPPFLAGS = -D_REENTRANT -D_PTHREADS +LIBCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO= so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## End IRIX-specific setup diff --git a/intl/icu/source/config/mh-linux b/intl/icu/source/config/mh-linux new file mode 100644 index 000000000..53d6780d6 --- /dev/null +++ b/intl/icu/source/config/mh-linux @@ -0,0 +1,87 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Linux-specific setup +## Copyright (c) 1999-2013, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) $(CXXFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= -Wl,-zorigin,-rpath,'$$'ORIGIN +LD_RPATH_PRE = -Wl,-rpath, + +## These are the library specific LDFLAGS +LDFLAGSICUDT=-nodefaultlibs -nostdlib + +## Compiler switch to embed a library name +# The initial tab in the next line is to prevent icu-config from reading it. + LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) +#SH# # We can't depend on MIDDLE_SO_TARGET being set. +#SH# LD_SONAME= + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(call SILENT_COMPILE,$(strip $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS)) -o $@ $<) +%.o: $(srcdir)/%.c + $(call SILENT_COMPILE,$(strip $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS)) -o $@ $<) + +%.$(STATIC_O): $(srcdir)/%.cpp + $(call SILENT_COMPILE,$(strip $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS)) -o $@ $<) +%.o: $(srcdir)/%.cpp + $(call SILENT_COMPILE,$(strip $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS)) -o $@ $<) + + +## Dependency rules +%.d: $(srcdir)/%.c + $(call ICU_MSG,(deps)) $< + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + $(call ICU_MSG,(deps)) $< + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End Linux-specific setup + diff --git a/intl/icu/source/config/mh-linux-va b/intl/icu/source/config/mh-linux-va new file mode 100644 index 000000000..c1acad6bb --- /dev/null +++ b/intl/icu/source/config/mh-linux-va @@ -0,0 +1,79 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Linux-specific setup for Visual Age +## Copyright (c) 2003-2010, International Business Machines Corporation and +## others. All Rights Reserved. + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +# -qroconst make the strings readonly, which is usually the default. +# This helps in the data library, +# -qproto assumes all functions are prototyped (for optimization) +CFLAGS += -qproto -qroconst +CXXFLAGS += -qproto -qroconst + +GENCCODE_ASSEMBLY=-a gcc +## Flags for position independent code +SHAREDLIBCFLAGS = -qpic=large +SHAREDLIBCXXFLAGS = -qpic=large +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT +LIBCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= -Wl,-zorigin,-rpath,'$$'ORIGIN +#LD_RPATH_PRE = -Wl,-rpath, + +## Compiler switch to embed a library name +# The initial tab in the next line is to prevent icu-config from reading it. + LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) +#SH# # We can't depend on MIDDLE_SO_TARGET being set. +#SH# LD_SONAME= + +## The type of assembly needed when pkgdata is used for generating shared libraries. +GENCCODE_ASSEMBLY=-a gcc + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Override the default mechanism for building shared objects +SHLIB.c= $(CC) $(CFLAGS) -qmkshrobj -qpic=large -G $(LDFLAGS) +SHLIB.cc= $(CXX) $(CXXFLAGS) -qmkshrobj -qpic=large -G $(LDFLAGS) + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< > /dev/null' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< > /dev/null' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## End Linux-specific setup + diff --git a/intl/icu/source/config/mh-mingw b/intl/icu/source/config/mh-mingw new file mode 100644 index 000000000..b8d2ee058 --- /dev/null +++ b/intl/icu/source/config/mh-mingw @@ -0,0 +1,160 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Cygwin/MinGW specific setup +## Copyright (c) 2001-2014, International Business Machines Corporation and +## others. All Rights Reserved. + +# TODO: Finish the rest of this port. This platform port is incomplete. + +# This file is similar to mh-mingw64 +# Any changes made here may also need to be made in mh-mingw64 + +# We install sbin tools into the same bin directory because +# pkgdata needs some of the tools in sbin, and we can't always depend on +# icu-config working on Windows. +sbindir=$(bindir) + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCFLAGS = -mthreads +THREADSCXXFLAGS = -mthreads +LIBCPPFLAGS = + +# Commands to link. Link with C++ in case static libraries are used. +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +#LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Commands to make a shared library +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(dir $@)lib$(notdir $(@:$(SO_TARGET_VERSION_MAJOR).$(SO)=))$(IMPORT_LIB_EXT)#M# +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(dir $@)lib$(notdir $(@:$(SO_TARGET_VERSION_MAJOR).$(SO)=))$(IMPORT_LIB_EXT)#M# + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao + +ifeq ($(ENABLE_SHARED),YES) +SO_TARGET_VERSION_SUFFIX = $(SO_TARGET_VERSION_MAJOR) +else +SO_TARGET_VERSION_SUFFIX = +endif + +# Static library prefix and file extension +LIBSICU = $(LIBPREFIX)$(STATIC_PREFIX)$(ICUPREFIX) +A = a + +## An import library is needed for z/OS and MSVC +IMPORT_LIB_EXT = .dll.a + +LIBPREFIX=lib + +# Change the stubnames so that poorly working FAT disks and installation programs can work. +# This is also for backwards compatibility. +DATA_STUBNAME = dt +I18N_STUBNAME = in +LIBICU = $(STATIC_PREFIX_WHEN_USED)$(ICUPREFIX) + +#SH### copied from Makefile.inc +#SH## for icu-config to test with +#SH#ICULIBS_COMMON_LIB_NAME="${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}.${SO}" +#SH#ICULIBS_COMMON_LIB_NAME_A="${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}.${A}" + +#SH#ICULIBS_DATA="-l$(ICUPREFIX)$(DATA_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION)" +#SH#ICULIBS_I18N="-l$(ICUPREFIX)$(I18N_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION)" +#SH# +#SH## ICULIBS is the set of libraries your application should link +#SH## with usually. Many applications will want to add ${ICULIBS_I18N} as well. +#SH#ICULIBS="${ICULIBS_BASE} ${ICULIBS_I18N} ${ICULIBS_COMMON} ${ICULIBS_DATA} " + +# The #M# is used to delete lines for icu-config +# Current full path directory. +#CURR_FULL_DIR=$(shell pwd -W)#M# for MSYS +CURR_FULL_DIR?=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell +# Current full path directory for use in source code in a -D compiler option. +#CURR_SRCCODE_FULL_DIR=$(subst /,\\\\,$(shell pwd -W))#M# for MSYS +CURR_SRCCODE_FULL_DIR=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.c) $< >> $@ || (rm -f $@ && FALSE) + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.cc) $< >> $@ || (rm -f $@ && FALSE) + +## Versioned target for a shared library. +## Since symbolic links don't work the same way on Windows, +## we only use the version major number. +#FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +FINAL_IMPORT_LIB = $(dir $(SO_TARGET))lib$(notdir $(basename $(SO_TARGET)))$(IMPORT_LIB_EXT)#M# +IMPORT_LIB = $(FINAL_IMPORT_LIB)#M# +MIDDLE_IMPORT_LIB = $(FINAL_IMPORT_LIB)#M# + +## Special pkgdata information that is needed +PKGDATA_VERSIONING = -r $(SO_TARGET_VERSION_MAJOR) +#ICUPKGDATA_INSTALL_DIR = $(shell cygpath -dma $(DESTDIR)$(ICUPKGDATA_DIR))#M# +#ICUPKGDATA_INSTALL_LIBDIR = $(shell cygpath -dma $(DESTDIR)$(libdir))#M# + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + @echo -n + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# The type of assembly to write for generating an object file +GENCCODE_ASSEMBLY=-a gcc-cygwin + +# These are needed to allow the pkgdata GNU make files to work +PKGDATA_DEFS = -DU_MAKE=\"$(MAKE)\" + +## End Cygwin/MinGW specific setup + diff --git a/intl/icu/source/config/mh-mingw64 b/intl/icu/source/config/mh-mingw64 new file mode 100644 index 000000000..188d2aa74 --- /dev/null +++ b/intl/icu/source/config/mh-mingw64 @@ -0,0 +1,160 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Cygwin64/MinGW64 specific setup +## Copyright (c) 2012-2014, International Business Machines Corporation and +## others. All Rights Reserved. + +# TODO: Finish the rest of this port. This platform port is incomplete. + +# This file is similar to mh-mingw +# Any changes made here may also need to be made in mh-mingw + +# We install sbin tools into the same bin directory because +# pkgdata needs some of the tools in sbin, and we can't always depend on +# icu-config working on Windows. +sbindir=$(bindir) + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = -DPIC + +## Additional flags when building libraries and with threads +THREADSCFLAGS = -mthreads +THREADSCXXFLAGS = -mthreads +LIBCPPFLAGS = + +# Commands to link. Link with C++ in case static libraries are used. +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +#LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## Commands to make a shared library +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(dir $@)lib$(notdir $(@:$(SO_TARGET_VERSION_MAJOR).$(SO)=))$(IMPORT_LIB_EXT)#M# +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -shared $(LD_SOOPTIONS) -Wl,--enable-auto-import -Wl,--out-implib=$(dir $@)lib$(notdir $(@:$(SO_TARGET_VERSION_MAJOR).$(SO)=))$(IMPORT_LIB_EXT)#M# + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao + +ifeq ($(ENABLE_SHARED),YES) +SO_TARGET_VERSION_SUFFIX = $(SO_TARGET_VERSION_MAJOR) +else +SO_TARGET_VERSION_SUFFIX = +endif + +# Static library prefix and file extension +LIBSICU = lib$(LIBPREFIX)$(STATIC_PREFIX)$(ICUPREFIX) +A = a + +## An import library is needed for z/OS and MSVC +IMPORT_LIB_EXT = .dll.a + +LIBPREFIX= + +# Change the stubnames so that poorly working FAT disks and installation programs can work. +# This is also for backwards compatibility. +DATA_STUBNAME = dt +I18N_STUBNAME = in +LIBICU = $(STATIC_PREFIX_WHEN_USED)$(ICUPREFIX) + +#SH### copied from Makefile.inc +#SH## for icu-config to test with +#SH#ICULIBS_COMMON_LIB_NAME="${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}${ICULIBSUFFIX_VERSION}.${SO}" +#SH#ICULIBS_COMMON_LIB_NAME_A="${LIBICU}${COMMON_STUBNAME}${ICULIBSUFFIX}.${A}" + +#SH#ICULIBS_DATA="-l$(ICUPREFIX)$(DATA_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION)" +#SH#ICULIBS_I18N="-l$(ICUPREFIX)$(I18N_STUBNAME)$(ICULIBSUFFIX)$(ICULIBSUFFIX_VERSION)" +#SH# +#SH## ICULIBS is the set of libraries your application should link +#SH## with usually. Many applications will want to add ${ICULIBS_I18N} as well. +#SH#ICULIBS="${ICULIBS_BASE} ${ICULIBS_I18N} ${ICULIBS_COMMON} ${ICULIBS_DATA} " + +# The #M# is used to delete lines for icu-config +# Current full path directory. +#CURR_FULL_DIR=$(shell pwd -W)#M# for MSYS +CURR_FULL_DIR?=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell +# Current full path directory for use in source code in a -D compiler option. +#CURR_SRCCODE_FULL_DIR=$(subst /,\\\\,$(shell pwd -W))#M# for MSYS +CURR_SRCCODE_FULL_DIR=$(subst \,/,$(shell cmd /c cd))#M# for Cygwin shell + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.c) $< >> $@ || (rm -f $@ && FALSE) + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @echo -n "$@ " > $@ + @$(GEN_DEPS.cc) $< >> $@ || (rm -f $@ && FALSE) + +## Versioned target for a shared library. +## Since symbolic links don't work the same way on Windows, +## we only use the version major number. +#FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +FINAL_SO_TARGET=$(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +FINAL_IMPORT_LIB = $(dir $(SO_TARGET))lib$(notdir $(basename $(SO_TARGET)))$(IMPORT_LIB_EXT)#M# +IMPORT_LIB = $(FINAL_IMPORT_LIB)#M# +MIDDLE_IMPORT_LIB = $(FINAL_IMPORT_LIB)#M# + +## Special pkgdata information that is needed +PKGDATA_VERSIONING = -r $(SO_TARGET_VERSION_MAJOR) +#ICUPKGDATA_INSTALL_DIR = $(shell cygpath -dma $(DESTDIR)$(ICUPKGDATA_DIR))#M# +#ICUPKGDATA_INSTALL_LIBDIR = $(shell cygpath -dma $(DESTDIR)$(libdir))#M# + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + @echo -n + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# The type of assembly to write for generating an object file +GENCCODE_ASSEMBLY=-a gcc-mingw64 + +# These are needed to allow the pkgdata GNU make files to work +PKGDATA_DEFS = -DU_MAKE=\"$(MAKE)\" + +## End Cygwin64/MinGW64 specific setup + diff --git a/intl/icu/source/config/mh-mpras b/intl/icu/source/config/mh-mpras new file mode 100644 index 000000000..b1b8bf6d8 --- /dev/null +++ b/intl/icu/source/config/mh-mpras @@ -0,0 +1,66 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## MP-RAS specific setup +## Copyright (c) 2003-2004, International Business Machines Corporation and +## others. All Rights Reserved. +## +## Original contributer: Jason Gordon from NCR + +## Flags for position independent code +SHAREDLIBCFLAGS = -K PIC +SHAREDLIBCXXFLAGS = -K PIC +SHAREDLIBCPPFLAGS = -DPIC + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -Hnocopyr -I/usr/include -Hcpplvl=3 -Xa -Hmake $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -Hnocopyr -I/usr/include -Hcpplvl=3 -Xa -Hmake $(DEFS) $(CPPFLAGS) + +## Commands to link +LINK.c= $(CC) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Commands to make a shared library +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -G +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -G + +## Compiler switch to embed a runtime search path +LD_RPATH= -YP, +LD_RPATH_PRE= + +## Compiler switch to embed a library name +LD_SONAME = -h $(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO= so +## Non-shared intermediate object suffix +STATIC_O = o + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > $@ + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > $@ + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + diff --git a/intl/icu/source/config/mh-msys-msvc b/intl/icu/source/config/mh-msys-msvc new file mode 100644 index 000000000..6b57c2692 --- /dev/null +++ b/intl/icu/source/config/mh-msys-msvc @@ -0,0 +1,222 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## MSYS with Microsoft Visual C++ compiler specific setup +## Copyright (c) 2014, International Business Machines Corporation and +## others. All Rights Reserved. + +# We install sbin tools into the same bin directory because +# pkgdata needs some of the tools in sbin, and we can't always depend on +# icu-config working on Windows. +sbindir=$(bindir) + +# Need this option to use / instead of - when specifying options for the +# rc.exe command +MSYS_RC_MODE=1 + +## Commands to generate dependency files +GEN_DEPS.c= : +GEN_DEPS.cc= : +#GEN_DEPS.c= $(COMPILE.c) -E +#GEN_DEPS.cc= $(COMPILE.cc) -E + +## Flags to create/use a static library +ifneq ($(ENABLE_SHARED),YES) +## Make sure that the static libraries can be built and used +CPPFLAGS += -DU_STATIC_IMPLEMENTATION#M# +else +## Make sure that the static libraries can be built +STATICCPPFLAGS = -DU_STATIC_IMPLEMENTATION +endif + +## Flags for position independent code +SHAREDLIBCFLAGS = +SHAREDLIBCXXFLAGS = +SHAREDLIBCPPFLAGS = + +## Additional flags when building libraries and with threads +LIBCPPFLAGS = + +ifeq ($(ENABLE_RELEASE),1) +# Make sure that assertions are disabled +CPPFLAGS+=-DU_RELEASE=1#M# +endif + +ifeq ($(ENABLE_DEBUG),1) +# Pass debugging flag through +CPPFLAGS+=-D_DEBUG=1#M# +ICULIBSUFFIX:=$(ICULIBSUFFIX)d#M# +endif + +# -GF pools strings and places them into read-only memory +# -EHsc enables exception handling +# -Zc:wchar_t makes wchar_t a native type. Required for C++ ABI compatibility. +# -D_CRT_SECURE_NO_DEPRECATE is needed to quiet warnings about using standard C functions. +CFLAGS+=-GF -nologo +CXXFLAGS+=-GF -nologo -EHsc -Zc:wchar_t +CPPFLAGS+=-D_CRT_SECURE_NO_DEPRECATE +DEFS+=-DWIN32 -DCYGWINMSVC +LDFLAGS+=-nologo + +# Commands to compile +COMPILE.c= $(CC) $(CPPFLAGS) $(DEFS) $(CFLAGS) -c +COMPILE.cc= $(CXX) $(CPPFLAGS) $(DEFS) $(CXXFLAGS) -c + +# Commands to link +LINK.c= LINK.EXE -subsystem:console $(LDFLAGS) +LINK.cc= LINK.EXE -subsystem:console $(LDFLAGS) + +## Commands to make a shared library +SHLIB.c= LINK.EXE -DLL $(LDFLAGS) +SHLIB.cc= LINK.EXE -DLL $(LDFLAGS) + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE= + +## Compiler switch to embed a library name +LD_SONAME = -IMPLIB:$(SO_TARGET:.dll=.lib) + +## Shared object suffix +SO = dll +## Non-shared intermediate object suffix +STATIC_O = ao +# OUTOPT is for creating a specific output name +OUTOPT = -out: + +# Static library prefix and file extension +LIBSICU = $(STATIC_PREFIX)$(ICUPREFIX) +A = lib + +# Cygwin's ar can't handle Win64 right now. So we use Microsoft's tool instead. +AR = LIB.EXE#M# +ARFLAGS := -nologo $(ARFLAGS:r=)#M# +RANLIB = ls -s#M# +AR_OUTOPT = -OUT:#M# + +## An import library is needed for z-OS, MSVC and Cygwin +IMPORT_LIB_EXT = .lib + +LIBPREFIX= +DEFAULT_LIBS = advapi32.lib + +# Change the stubnames so that poorly working FAT disks and installation programs can work. +# This is also for backwards compatibility. +DATA_STUBNAME = dt +I18N_STUBNAME = in +LIBICU = $(STATIC_PREFIX_WHEN_USED)$(ICUPREFIX) + +## Link commands to link to ICU libs +ifeq ($(wildcard $(LIBDIR)/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib),) +LIBICUDT= $(top_builddir)/stubdata/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib +else +LIBICUDT= $(LIBDIR)/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).lib +endif +LIBICUUC= $(LIBDIR)/$(LIBICU)$(COMMON_STUBNAME)$(ICULIBSUFFIX).lib $(LIBICUDT) +LIBICUI18N= $(LIBDIR)/$(LIBICU)$(I18N_STUBNAME)$(ICULIBSUFFIX).lib +LIBICULE= $(LIBDIR)/$(LIBICU)$(LAYOUT_STUBNAME)$(ICULIBSUFFIX).lib +LIBICULX= $(LIBDIR)/$(LIBICU)$(LAYOUTEX_STUBNAME)$(ICULIBSUFFIX).lib +LIBICUIO= $(LIBDIR)/$(LIBICU)$(IO_STUBNAME)$(ICULIBSUFFIX).lib +LIBCTESTFW= $(top_builddir)/tools/ctestfw/$(LIBICU)$(CTESTFW_STUBNAME)$(ICULIBSUFFIX).lib +LIBICUTOOLUTIL= $(LIBDIR)/$(LIBICU)$(TOOLUTIL_STUBNAME)$(ICULIBSUFFIX).lib + +## These are the library specific LDFLAGS +LDFLAGSICUDT+= -base:"0x4ad00000" -NOENTRY# The NOENTRY option is required for creating a resource-only DLL. +LDFLAGSICUUC= -base:"0x4a800000"# in-uc = 1MB +LDFLAGSICUI18N= -base:"0x4a900000"# io-in = 2MB +LDFLAGSICUIO= -base:"0x4ab00000"# le-io = 1MB +LDFLAGSICULX= -base:"0x4ac80000" +LDFLAGSCTESTFW=# Unused for now. +LDFLAGSICUTOOLUTIL= -base:"0x4ac00000"# Same as layout. Layout and tools probably won't mix. + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -Fo$@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -Fo$@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -Fo$@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -Fo$@ $< + + +## Dependency rules +## This is a start to how depdendencies could work +# The commented out rules may not properly delete the file when ^C is pressed +# or the compiler fails. +# make currently doesn't like rules with C:\\PROGRA~1\\.. in the depedency. +# So system headers are ignored by ignoring \\ +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > $@ +# @echo -n "generating dependency information for " +# @echo -n "$@ $(basename $<).o : " > $@ +# @$(SHELL) -ec '$(GEN_DEPS.c) $< \ +# | grep "#line 1 " | grep -v \\\\ | cut -d " " -f 3 \ +# | /usr/bin/sort -u | sed s/\"$$/\\\\/ | sed s/^\"/\ / >> $@ \ +# || (rm -f $@ && echo $@ && false)' + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > $@ +# @echo -n "generating dependency information for " +# @echo -n "$@ $(basename $<).o : " > $@ +# @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ +# | grep "#line 1 " | grep -v \\\\ | cut -d " " -f 3 \ +# | /usr/bin/sort -u | sed s/\"$$/\\\\/ | sed s/^\"/\ / >> $@ \ +# || (rm -f $@ && echo $@ && false)' + +## Compile a Windows resource file +%.res : $(srcdir)/%.rc + rc.exe -fo$@ $(CPPFLAGS) $< + +## Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) +MIDDLE_SO_TARGET=$(FINAL_SO_TARGET) + +## Starting in MSVC 2005, manifest files are required. This reduces the obnoxiousness of this feature. + POST_SO_BUILD_STEP = @([ -e $<.manifest ] && \ + ( echo Embedding manifest into $< && mt.exe -nologo -manifest $<.manifest -outputresource:"$<;2" && rm -rf $<.manifest )) \ + || true + POST_BUILD_STEP = @([ -e $@.manifest ] && \ + ( echo Embedding manifest into $@ && mt.exe -nologo -manifest $@.manifest -outputresource:"$@;1" && rm -rf $@.manifest )) \ + || true + +## Special pkgdata information that is needed +PKGDATA_VERSIONING = -r $(SO_TARGET_VERSION_MAJOR) +ICUPKGDATA_INSTALL_DIR = $(shell mkdir -p $(DESTDIR)$(ICUPKGDATA_DIR) ; echo $(DESTDIR)$(ICUPKGDATA_DIR))#M# +ICUPKGDATA_INSTALL_LIBDIR = $(shell mkdir -p $(DESTDIR)$(libdir) ; echo $(DESTDIR)$(libdir))#M# + +## Versioned import library names. The library names are versioned, +## but the import libraries do not need versioning. +IMPORT_LIB = $(basename $(SO_TARGET))$(IMPORT_LIB_EXT)#M# +MIDDLE_IMPORT_LIB = $(IMPORT_LIB)#M# +FINAL_IMPORT_LIB = $(MIDDLE_IMPORT_LIB)#M# + +# The following is for Makefile.inc's use. +ICULIBSUFFIX_VERSION = $(LIB_VERSION_MAJOR) + +## Versioned libraries rules +#%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) +# $(RM) $@ && cp ${<F} $@ + +# The following rule is sometimes a no op. +# We only want to do a post-build step when a manifest file doesn't exist. +%.$(SO): %$(SO_TARGET_VERSION_MAJOR).$(SO) + @echo -n + $(POST_SO_BUILD_STEP) + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +# Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = PATH + +# These are needed to allow the pkgdata nmake files to work +PKGDATA_INVOKE_OPTS = MAKEFLAGS= + +# Include the version information in the shared library +ENABLE_SO_VERSION_DATA=1 + +## End MSYS-specific setup diff --git a/intl/icu/source/config/mh-os390 b/intl/icu/source/config/mh-os390 new file mode 100644 index 000000000..dbc3a3a5a --- /dev/null +++ b/intl/icu/source/config/mh-os390 @@ -0,0 +1,241 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## os/390, z/OS specific setup +## Copyright (c) 1999-2014, International Business Machines Corporation and +## others. All Rights Reserved. + +################################################################### +# IMPORTANT NOTE # +################################################################### +# Before you try to run the Makefile, make sure you have the # +# environment variables set. # +# # +# If you are going to do the OS390BATCH build, make sure you have # +# the OS390BATCH environment variable set. # +# # +# export OS390BATCH=1 # +# # +# To build a version of ICU that does not use IEEE Floating point # +# # +# export IEEE390=0 # +# # +# To build a version of ICU which uses a two data libraries # +# where the smaller one is loaded first, use OS390_STUBDATA. # +# USAGE OF THIS OPTION IS DEPRECATED. You should look into using # +# Link Pack Area (LPA), library lookaside facility (LLA) or other # +# z/OS options that enable page fault based loading of read-only # +# code/data instead of this option. # +# This option will be removed in a future version of ICU. # +# # +# export OS390_STUBDATA=1 # +# # +# To build a version of ICU which exploits the C/C++ compiler # +# and runtime Extra Performance Linkage (XPLINK), specify # +# # +# export OS390_XPLINK=1 # +# # +################################################################### + +# TODO: Fix this configuration so that icu-config will work! +# If statements don't work well when icu-config is generated. +ifeq (${IEEE390},) +IEEE390=1#M# +endif + +ifeq (${IEEE390}, 1) +ICU_IEEE = -Wc,'FLOAT(IEEE)' -DIEEE_754=0#M# +else +ICU_IEEE =#M# +endif + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_OPEN_THREADS=3 + +# For a dynamically called DLL module to share access to the POSIX external +# variables, with its caller, the DLL module must define these _SHR_* macros. +SHAREDLIBCPPFLAGS = -D_SHR_TZNAME -D_SHR_TIMEZONE + +# -Wc,expo is used to export all functions +SHAREDLIBCFLAGS = -Wc,expo +SHAREDLIBCXXFLAGS = -Wc,expo + +# TODO: Consider using -Wc,roc,ros for making the data and strings readonly +# -Wc,"ros" seems to work, but not the "roc" +# The RENT option makes the program reentrant. This may not really have the same +# meaning as normal reentrancy on other platforms. See the z/OS documentation +# for details. This is the default for C++, but not C. +# The DLL option must be used by the callee and caller code when using shared libraries. +# NOCSECT might be used as an optimization option. +# -+ means accept any file extension as a C++ file. By default only .C is accepted. +CFLAGS += -Wc,DLL,ROS,RENT,'ARCH(7)','LOC(POSIX)',NOANSIALIAS,'LANGLVL(EXTENDED)' $(ICU_IEEE) +CXXFLAGS += -Wc,DLL,ROS,RTTI,'ARCH(7)','LOC(POSIX)',NOANSIALIAS,'LANGLVL(EXTENDED)' $(ICU_IEEE) -+ +ARFLAGS = -cr + +# _MSE_PROTOS usually interacts with _XOPEN_SOURCE. It affects some standard +# C functions that use wchar_t, and it selects behavior for +# multibyte extension support (MSE) functions. +#DEFS += -D_MSE_PROTOS + +ifeq (${OS390_XPLINK}, 1) +#SH# if [ "x$OS390_XPLINK" = "x1" ]; then +# These lines must be the last options specified. +# GOFF is is the strategic object module format for S/390. It is required for XPLINK. +# NOTEMPINC could be used if ICU starts using templates. +ICU_XPLINK_C = -Wc,'xplink(backchain,storeargs),goff' +ICU_XPLINK_CXX = -Wc,'xplink(backchain,storeargs),goff' -Wc,'NOTEMPINC' +ICU_XPLINK_L = -Wl,xplink +#SH# fi +endif + +## OS390BATCH +ifeq (${OS390BATCH},1) +DEFS += -DOS390BATCH#M# +endif + +## Commands to generate dependency files +GEN_DEPS.c= makedep +GEN_DEPS.cc= makedep + +## Commands to compile +# _CXX_STEPS="-1" is a prelink step when compiling C and C++, and +# it's only needed for long function names +COMPILE.c = $(COMPILE_LINK_ENVVAR) $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) $(ICU_XPLINK_C) -c +COMPILE.cc = $(COMPILE_LINK_ENVVAR) $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) $(ICU_XPLINK_CXX) -c + +# Commands to link +LINK.c= $(COMPILE_LINK_ENVVAR) $(CC) $(CFLAGS) -Wl,dll $(LDFLAGS) $(ICU_XPLINK_L) +LINK.cc= $(COMPILE_LINK_ENVVAR) $(CXX) $(CXXFLAGS) -Wl,dll $(LDFLAGS) $(ICU_XPLINK_L) + +## Commands for shared library (dll) +SHLIB.c= $(LINK.c) +SHLIB.cc= $(LINK.cc) + +## Compiler switch to embed a runtime search path +LD_RPATH= -I + +## Environment variable to set a runtime search path +LDLIBRARYPATH_ENVVAR = LIBPATH + +## An import library (a.k.a. sidedeck) is needed for z/OS and MSVC +IMPORT_LIB_EXT = .x + +## Versioned target for a shared library. +FINAL_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION).$(SO) +MIDDLE_SO_TARGET= $(basename $(SO_TARGET))$(SO_TARGET_VERSION_MAJOR).$(SO) + +## Versioned import library names. +IMPORT_LIB = $(basename $(notdir $(SO_TARGET)))$(IMPORT_LIB_EXT)#M# +MIDDLE_IMPORT_LIB = $(basename $(notdir $(MIDDLE_SO_TARGET)))$(IMPORT_LIB_EXT)#M# +FINAL_IMPORT_LIB = $(basename $(notdir $(FINAL_SO_TARGET)))$(IMPORT_LIB_EXT)#M# + +## Non-shared intermediate object suffix +STATIC_O = o + +ifeq ($(OS390_STUBDATA),1) +## Suffix of the subset data library for dual common library support +STUB_SUFFIX=_stub#M# +DEFS += -DOS390_STUBDATA -DU_LIBICUDATA_NAME=\"$(ICUPREFIX)$(DATA_STUBNAME)$(ICULIBSUFFIX)\"#M# +endif + +ifeq ($(OS390BATCH),1) +## PDS_NAME_PREFIX sets the prefix of the PDS dataset name while keeping the ICU version number. +## To use custom names set ICU_PDS_NAME and ICU_PDS_NAME_SUFFIX +## IXM is used as a name prefix for XML Toolkit, default value +ifeq ($(PDS_NAME_PREFIX),) +PDS_NAME_PREFIX= IXMI +endif +ifeq ($(ICU_PDS_NAME),) +PDS_FULL_NAME=${PDS_NAME_PREFIX}${SO_TARGET_VERSION_MAJOR} +else +PDS_FULL_NAME=${ICU_PDS_NAME} +endif +ifeq ($(OS390_STUBDATA),1) +BATCH_STUB_TARGET= "//'${LOADMOD}(${PDS_FULL_NAME}D1${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICUDT= "//'${LOADEXP}(${PDS_FULL_NAME}D1${ICU_PDS_NAME_SUFFIX})'" +else +BATCH_STUB_TARGET= "//'${LOADMOD}(${PDS_FULL_NAME}DA${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICUDT= "//'${LOADEXP}(${PDS_FULL_NAME}DA${ICU_PDS_NAME_SUFFIX})'" +PKGDATA_DEFS += -DU_LIBICUDATA_NAME=\"$(ICUPREFIX)$(DATA_STUBNAME)$(ICULIBSUFFIX)\" +endif + +BATCH_COMMON_TARGET="//'${LOADMOD}(${PDS_FULL_NAME}UC${ICU_PDS_NAME_SUFFIX})'" +BATCH_I18N_TARGET="//'${LOADMOD}(${PDS_FULL_NAME}IN${ICU_PDS_NAME_SUFFIX})'" +BATCH_IO_TARGET="//'${LOADMOD}(${PDS_FULL_NAME}IO${ICU_PDS_NAME_SUFFIX})'" +BATCH_LAYOUT_TARGET="//'${LOADMOD}(${PDS_FULL_NAME}LE${ICU_PDS_NAME_SUFFIX})'" +BATCH_LAYOUTEX_TARGET="//'${LOADMOD}(${PDS_FULL_NAME}LX${ICU_PDS_NAME_SUFFIX})'" + +BATCH_LIBICUUC= "//'${LOADEXP}(${PDS_FULL_NAME}UC${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICUI18N= "//'${LOADEXP}(${PDS_FULL_NAME}IN${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICUIO= "//'${LOADEXP}(${PDS_FULL_NAME}IO${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICULE= "//'${LOADEXP}(${PDS_FULL_NAME}LE${ICU_PDS_NAME_SUFFIX})'" +BATCH_LIBICULX= "//'${LOADEXP}(${PDS_FULL_NAME}LX${ICU_PDS_NAME_SUFFIX})'" +endif + + +## Link commands to link to ICU libs +LIBICUDT= $(top_builddir)/stubdata/$(LIBICU)data$(ICULIBSUFFIX)$(STUB_SUFFIX)$(SO_TARGET_VERSION).x +LIBICUUC= $(top_builddir)/common/$(LIBICU)uc$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x +LIBICUI18N= $(top_builddir)/i18n/$(LIBICU)i18n$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x +LIBICULX= $(top_builddir)/layoutex/$(LIBICU)lx$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x +LIBICUIO= $(top_builddir)/io/$(LIBICU)io$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x +LIBCTESTFW= $(top_builddir)/tools/ctestfw/$(LIBICU)test$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x +LIBICUTOOLUTIL= $(top_builddir)/tools/toolutil/$(LIBICU)tu$(ICULIBSUFFIX)$(SO_TARGET_VERSION).x + +ifneq (${ICUDATA_CHAR},e) +#SH# if [ "$ICUDATA_CHAR" != "e" ]; then +## We're in ASCII mode. +CFLAGS += -Wc,'ascii' +CXXFLAGS += -Wc,'ascii' +SO = so +else +#SH# else +## We're in EBCDIC mode. +## Shared object suffix +SO = dll +endif +#SH# fi + +## Special 390 rules + +## Build archive from object +%.a : $(OBJECTS) + $(AR) $(ARFLAGS) $@ $(OBJECTS) + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + +## Dependency rules +%.d : %.u + @$(SHELL) -ec 'cat $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@ ; rm -f $<' + +%.u : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec 'touch $*.u > /dev/null 2>&1' + @$(SHELL) -ec '$(GEN_DEPS.c) -f $*.u $< > /dev/null 2>&1' + +%.u : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec 'touch $*.u > /dev/null 2>&1' + @$(SHELL) -ec '$(GEN_DEPS.cc) -f $*.u $< > /dev/null 2>&1' + +## Versioned libraries rules +%$(SO_TARGET_VERSION_MAJOR).$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ +%.$(SO): %$(SO_TARGET_VERSION).$(SO) + $(RM) $@ && ln -s ${*F}$(SO_TARGET_VERSION).$(SO) $@ + +## Install libraries as executable +INSTALL-L=$(INSTALL_PROGRAM) + +## End 390-specific setup diff --git a/intl/icu/source/config/mh-os400 b/intl/icu/source/config/mh-os400 new file mode 100644 index 000000000..82d7b500f --- /dev/null +++ b/intl/icu/source/config/mh-os400 @@ -0,0 +1,141 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## OS400-specific setup (for cross build) +## Copyright (c) 1999-2013, International Business Machines Corporation and +## others. All Rights Reserved. + +# This otherwise breaks on OS400 - can't find "shell" +CURR_FULL_DIR=. +CURR_SRCCODE_FULL_DIR=. + +GEN_DEPS.c= $(CC1) -E -M $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX1) -E -M $(DEFS) $(CPPFLAGS) + +THREADSCPPFLAGS = -D_MULTI_THREADED + +# put this in the environment to get threading +THREADSENVFLAGS = QIBM_MULTI_THREADED=Y ; + +## Commands to compile +# -qTERASPACE: large pointers +# -qPFROPT=*STRDONLY: Strings are read-only +COMPILE.c= $(CC) $(DEFS) $(CPPFLAGS) $(CFLAGS) -c -qTERASPACE=*YES -qSTGMDL=*INHERIT -qPFROPT=*STRDONLY +COMPILE.cc= $(CXX) $(DEFS) $(CPPFLAGS) $(CXXFLAGS) -c -qTERASPACE=*YES -qSTGMDL=*INHERIT -qPFROPT=*STRDONLY -qRTTIALL + +## ICULD program - run bldiculd.sh in icu/as_is/os400/ to build it +ICULD=/qsys.lib/$(OUTPUTDIR).lib/iculd.pgm + +## Commands to link +## We need to use the C++ linker, even when linking C programs, since +## our libraries contain C++ code (C++ static init not called) +LINK.c= $(ICULD) $(CXXFLAGS) $(LDFLAGS) -qOPTION='*DUPPROC *DUPVAR' +LINK.cc= $(ICULD) $(CXXFLAGS) $(LDFLAGS) -qOPTION='*DUPPROC *DUPVAR' + +## Commands to make a shared library +# -qALWLIBUPD: It allows the compiled service program to have dependencies on +# service programs in a different library than that specified originally +# by CRTSRVPGM after having used the UPDSRVPGM command. +# Similar to -fPIC and -install_name on other compilers, but different. +SHLIB.c= ld -v -qOPTION='*DUPPROC *DUPVAR' -qALWLIBUPD=*YES +SHLIB.cc= ld -v -qOPTION='*DUPPROC *DUPVAR' -qALWLIBUPD=*YES +AR = qar +ARFLAGS = -cuv + +## Compiler switch to embed a runtime search path +LD_RPATH= -I +LD_RPATH_PRE= -I + +## Make target to rebind the common library +## to the actual data versus the stub data +POST_DATA_BUILD = os400-data-rebind + +# The stubdata directory is the same directory as the normal data library. +STUBDATA_LIBDIR = $(LIBDIR)/ + +## Versioned target for a shared library. +FINAL_SO_TARGET = $(SO_TARGET) +MIDDLE_SO_TARGET = + +# this one is for icudefs.mk's use +ifeq ($(ENABLE_SHARED),YES) +SO_TARGET_VERSION_SUFFIX = $(SO_TARGET_VERSION_MAJOR) +endif + +# this one is for the individual make files and linking +ICULIBSUFFIX = $(SO_TARGET_VERSION_SUFFIX) + +## object suffix +TO= o + +## Shared object suffix +SO= so +## Non-shared intermediate object suffix +STATIC_O = o + +## Platform command to remove or move executable target +RMV = del +## Platform commands to remove or move executable and library targets +INSTALL-S = cp -fph +INSTALL-L = $(INSTALL-S) + +# Stub name overrides for iSeries +DATA_STUBNAME = dt +I18N_STUBNAME = in +CTESTFW_STUBNAME = tf + +## Link commands to link to ICU service programs +LIBICUDT = $(LIBDIR)/$(LIBICU)$(DATA_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICUUC = $(LIBDIR)/$(LIBICU)$(COMMON_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICUI18N = $(LIBDIR)/$(LIBICU)$(I18N_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICULE = $(LIBDIR)/$(LIBICU)$(LAYOUT_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICULX = $(LIBDIR)/$(LIBICU)$(LAYOUTEX_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBCTESTFW = $(top_builddir)/tools/ctestfw/$(LIBICU)$(CTESTFW_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICUTOOLUTIL = $(LIBDIR)/$(LIBICU)$(TOOLUTIL_STUBNAME)$(ICULIBSUFFIX).$(SO) +LIBICUIO= $(LIBDIR)/$(LIBICU)$(IO_STUBNAME)$(ICULIBSUFFIX).$(SO) + +## Special OS400 rules + +## Build archive from shared object +%.a : %.o + $(AR) $(ARFLAGS) $@ $< + +## Build import list from export list +%.e : %.exp + @echo "Building an import list for $<" + @$(SHELL) -ec "echo '#! $*.a($*.so)' | cat - $< > $@" + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + +%.qwobj : $(srcdir)/%.c + $(COMPILE.c) -o $@ $< + +%.qwobj : $(srcdir)/%.cpp + $(COMPILE.cc) -o $@ $< + +## Dependency rules +%.d : %.u +# @$(SHELL) -ec 'cat $< \ +# | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ +# [ -s $@ ] || rm -f $@ ; rm -f $<' + +%.u : $(srcdir)/%.c + @echo "generating dependency information for $<" +# @$(SHELL) -ec 'touch $*.u > /dev/null 2>&1' +# @$(SHELL) -ec '$(GEN_DEPS.c) -f $*.u $< > /dev/null 2>&1' + +%.u : $(srcdir)/%.cpp + @echo "generating dependency information for $<" +# @$(SHELL) -ec 'touch $*.u > /dev/null 2>&1' +# @$(SHELL) -ec '$(GEN_DEPS.cc) -f $*.u $< > /dev/null 2>&1' + +## End OS400-specific setup diff --git a/intl/icu/source/config/mh-qnx b/intl/icu/source/config/mh-qnx new file mode 100644 index 000000000..06c404880 --- /dev/null +++ b/intl/icu/source/config/mh-qnx @@ -0,0 +1,94 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## QNX-specific setup +## Copyright (c) 1999-2006, International Business Machines Corporation and +## others. All Rights Reserved. +## +## Provided By: Chris McKillop <cdm@qnx.com> + + +# +# Create shared libs that "work" properly. +# + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -Wp,-MM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -E -Wp,-MM $(DEFS) $(CPPFLAGS) + +## Flags for position independent code +SHAREDLIBCFLAGS = -shared +SHAREDLIBCXXFLAGS = -shared +# SHAREDLIBCPPFLAGS = -shared + +# +# Always generatate PIC code. +# +#CPPFLAGS+=-shared + +## Additional flags when building libraries and with threads +LIBCPPFLAGS = +THREADSCPPFLAGS = + +## Compiler switch to embed a runtime search path +LD_RPATH= +LD_RPATH_PRE = -Wl,-rpath, + +## Compiler switch to embed a library name +LD_SONAME = -Wl,-soname -Wl,$(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO = so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d: $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d: $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s%\($*\)\.o[ :]*%\1.o $@ : %g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules +## +## QNX wants the SONAME in the shared lib to match the final "real" filename. +## (to ease in packaging with QNX's native package format) +## +MIDDLE_SO_TARGET = $(SO_TARGET).$(SO_TARGET_VERSION_MAJOR) +FINAL_SO_TARGET = $(MIDDLE_SO_TARGET) + +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION_MAJOR) $@ +#%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) +# $(RM) $@ && ln -s ${<F} $@ +#%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) +# $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Bind internal references + +# LDflags that pkgdata will use +BIR_LDFLAGS= -Wl,-Bsymbolic + +# Dependencies [i.e. map files] for the final library +BIR_DEPS= + +## End QNX-specific setup + diff --git a/intl/icu/source/config/mh-solaris b/intl/icu/source/config/mh-solaris new file mode 100644 index 000000000..469b2100f --- /dev/null +++ b/intl/icu/source/config/mh-solaris @@ -0,0 +1,100 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Solaris-specific setup using Sun's compilers +## Copyright (c) 1999-2010, International Business Machines Corporation and +## others. All Rights Reserved. + +## Flags for position independent code +SHAREDLIBCFLAGS = -KPIC +SHAREDLIBCXXFLAGS = -KPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -xM $(DEFS) $(CPPFLAGS) +GEN_DEPS.cc= $(CXX) -xM $(DEFS) $(CPPFLAGS) + +ifeq ($(UCLN_NO_AUTO_CLEANUP),0) +# set up init point. +UCLN_FINI = ucln_fini$(TARGET_STUBNAME)_$(SO_TARGET_VERSION_MAJOR)$(ICULIBSUFFIXCNAME) +CPPFLAGS_FINI = -DUCLN_FINI=$(UCLN_FINI) +LDFLAGS_FINI = -zfiniarray=$(UCLN_FINI) + +CPPFLAGSICUUC += $(CPPFLAGS_FINI) +LDFLAGSICUUC += $(LDFLAGS_FINI) +CPPFLAGSICUIO += $(CPPFLAGS_FINI) +LDFLAGSICUIO += $(LDFLAGS_FINI) +CPPFLAGSICUI18N += $(CPPFLAGS_FINI) +LDFLAGSICUI18N += $(LDFLAGS_FINI) +CPPFLAGSCTESTFW += $(CPPFLAGS_FINI) +LDFLAGSCTESTFW += $(LDFLAGS_FINI) + +# ICUUC, ICUIO, ICUI18N, CTESTFW +endif + +# -mt means 'compiles and links a multithreaded program' +THREADSCFLAGS += -mt +THREADSCXXFLAGS += -mt + +## Commands to link +## For Sun Workshop, use CC to link to bring in C++ runtime +LINK.c= $(CXX) $(CXXFLAGS) $(LDFLAGS) +LINK.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) + +## Commands to make a shared library +SHLIB.c= $(CC) $(CFLAGS) $(LDFLAGS) -G +SHLIB.cc= $(CXX) $(CXXFLAGS) $(LDFLAGS) -G + +## Compiler switch to embed a runtime search path +LD_RPATH= -R'$$'ORIGIN +LD_RPATH_PRE= -R + +#LIBRARY_PATH_PREFIX=/usr/lib/lwp: + +## Compiler switch to embed a library name +LD_SONAME = -h $(notdir $(MIDDLE_SO_TARGET)) + +## Shared object suffix +SO= so +## Non-shared intermediate object suffix +STATIC_O = o + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(GEN_DEPS.c) $< > $@ + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(GEN_DEPS.cc) $< > $@ + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +# +ifeq (strip $(GENCCODE_ASSEMBLY),) +BIR_LDFLAGS= -Wl,-M,$(NAME).map -Wl,-B,symbolic -Wl,-B,eliminate +BIR_DEPS= $(NAME).map +endif + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End Solaris-specific setup diff --git a/intl/icu/source/config/mh-solaris-gcc b/intl/icu/source/config/mh-solaris-gcc new file mode 100644 index 000000000..63db4f028 --- /dev/null +++ b/intl/icu/source/config/mh-solaris-gcc @@ -0,0 +1,80 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Solaris-specific setup using gcc +## Copyright (c) 1999-2014, International Business Machines Corporation and +## others. All Rights Reserved. + +## Flags for position independent code +SHAREDLIBCFLAGS = -fPIC +SHAREDLIBCXXFLAGS = -fPIC +SHAREDLIBCPPFLAGS = -DPIC + +## Commands to generate dependency files +GEN_DEPS.c= $(CC) -E -MM $(DEFS) $(CPPFLAGS) $(CFLAGS) +GEN_DEPS.cc= $(CXX) -E -MM $(DEFS) $(CPPFLAGS) $(CXXFLAGS) + +## These are the library specific LDFLAGS +LDFLAGSICUDT=-nodefaultlibs -nostdlib + +## Additional flags when building libraries and with threads +THREADSCPPFLAGS = -D_REENTRANT + +## Compiler switch to embed a runtime search path +LD_RPATH= -R'$$'ORIGIN +LD_RPATH_PRE= -R + +## Compiler switch to embed a library name +LD_SONAME = -h $(notdir $(MIDDLE_SO_TARGET)) + +## Shared library options +LD_SOOPTIONS= -Wl,-Bsymbolic + +## The type of assembly needed when pkgdata is used for generating shared libraries. +## Only use this when not on x86 Solaris. +ifeq (strip $(GENCCODE_ASSEMBLY),) +GENCCODE_ASSEMBLY=-a sun +endif + +## Shared object suffix +SO= so +## Non-shared intermediate object suffix +STATIC_O = ao + +## Compilation rules +%.$(STATIC_O): $(srcdir)/%.c + $(COMPILE.c) $(STATICCPPFLAGS) $(STATICCFLAGS) -o $@ $< +%.o: $(srcdir)/%.c + $(COMPILE.c) $(DYNAMICCPPFLAGS) $(DYNAMICCFLAGS) -o $@ $< + +%.$(STATIC_O): $(srcdir)/%.cpp + $(COMPILE.cc) $(STATICCPPFLAGS) $(STATICCXXFLAGS) -o $@ $< +%.o: $(srcdir)/%.cpp + $(COMPILE.cc) $(DYNAMICCPPFLAGS) $(DYNAMICCXXFLAGS) -o $@ $< + + +## Dependency rules +%.d : $(srcdir)/%.c + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.c) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +%.d : $(srcdir)/%.cpp + @echo "generating dependency information for $<" + @$(SHELL) -ec '$(GEN_DEPS.cc) $< \ + | sed '\''s/\($*\)\.o[ :]*/\1.o $@ : /g'\'' > $@; \ + [ -s $@ ] || rm -f $@' + +## Versioned libraries rules + +%.$(SO).$(SO_TARGET_VERSION_MAJOR): %.$(SO).$(SO_TARGET_VERSION) + $(RM) $@ && ln -s ${<F} $@ +%.$(SO): %.$(SO).$(SO_TARGET_VERSION_MAJOR) + $(RM) $@ && ln -s ${*F}.$(SO).$(SO_TARGET_VERSION) $@ + +## Remove shared library 's' +STATIC_PREFIX_WHEN_USED = +STATIC_PREFIX = + +## End Solaris-specific setup diff --git a/intl/icu/source/config/mh-unknown b/intl/icu/source/config/mh-unknown new file mode 100644 index 000000000..deff8583a --- /dev/null +++ b/intl/icu/source/config/mh-unknown @@ -0,0 +1,29 @@ +## -*-makefile-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2003, International Business Machines Corporation and +## others. All Rights Reserved. +## + +# Note, this is not a real mh- file. You got here because configure +# (specifically, aclocal.m4) could not determine a suitable mh- file. +# +# Perhaps your platform wasn't detected- try changing aclocal.m4 and +# re-running autoconf. +# +# If your platform is truly new/different: +# As a start, try copying mh-linux (which is fairly generic) over this +# file, and re-run config.status. + +%.$(STATIC_O) %.o %.$(STATIC_O) %.o ../data/%.o %.d %.d %.$(SO).$(SO_TARGET_VERSION_MAJOR) %.$(SO): + @echo + @echo + @echo "*** ERROR - configure could not detect your platform" + @echo "*** see the readme.html" + @echo "*** or, try copying icu/source/config/mh-linux to mh-unknown" + @echo "*** and editing it." + @echo + @echo + exit 1 + + diff --git a/intl/icu/source/config/pkgdataMakefile.in b/intl/icu/source/config/pkgdataMakefile.in new file mode 100644 index 000000000..7bf24cc6b --- /dev/null +++ b/intl/icu/source/config/pkgdataMakefile.in @@ -0,0 +1,42 @@ +## pkgdataMakefile.in for ICU data +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2008-2012, International Business Machines Corporation and +## others. All Rights Reserved. + +## Source directory information +srcdir = @srcdir@ +top_srcdir = @top_srcdir@ + +# So that you have $(top_builddir)/config.status +top_builddir = .. + +## All the flags and other definitions are included here. +include $(top_builddir)/icudefs.mk + +OUTPUTFILE=pkgdata.inc +MIDDLE_SO_TARGET= + +all : clean + @echo GENCCODE_ASSEMBLY_TYPE=$(GENCCODE_ASSEMBLY) >> $(OUTPUTFILE) + @echo SO=$(SO) >> $(OUTPUTFILE) + @echo SOBJ=$(SOBJ) >> $(OUTPUTFILE) + @echo A=$(A) >> $(OUTPUTFILE) + @echo LIBPREFIX=$(LIBPREFIX)$(STATIC_PREFIX_WHEN_USED) >> $(OUTPUTFILE) + @echo LIB_EXT_ORDER=$(FINAL_SO_TARGET) >> $(OUTPUTFILE) + @echo COMPILE="$(COMPILE.c)" >> $(OUTPUTFILE) + @echo LIBFLAGS="-I$(prefix)/include $(SHAREDLIBCPPFLAGS) $(SHAREDLIBCFLAGS)" >> $(OUTPUTFILE) + @echo GENLIB="$(SHLIB.c)" >> $(OUTPUTFILE) + @echo LDICUDTFLAGS=$(LDFLAGSICUDT) >> $(OUTPUTFILE) + @echo LD_SONAME=$(LD_SONAME) >> $(OUTPUTFILE) + @echo RPATH_FLAGS=$(RPATH_FLAGS) >> $(OUTPUTFILE) + @echo BIR_LDFLAGS=$(BIR_LDFLAGS) >> $(OUTPUTFILE) + @echo AR=$(AR) >> $(OUTPUTFILE) + @echo ARFLAGS=$(ARFLAGS) >> $(OUTPUTFILE) + @echo RANLIB=$(RANLIB) >> $(OUTPUTFILE) + @echo INSTALL_CMD=$(INSTALL-L) >> $(OUTPUTFILE) + + +clean : + $(RMV) $(OUTPUTFILE) + diff --git a/intl/icu/source/config/test-icu-config.sh b/intl/icu/source/config/test-icu-config.sh new file mode 100755 index 000000000..0f22484e1 --- /dev/null +++ b/intl/icu/source/config/test-icu-config.sh @@ -0,0 +1,50 @@ +#!/bin/sh +## -*-sh-*- +## Copyright (C) 2016 and later: Unicode, Inc. and others. +## License & terms of use: http://www.unicode.org/copyright.html +## Copyright (c) 2002, International Business Machines Corporation and +## others. All Rights Reserved. +# +# Just a script to test out icu-config. +# + +set -x +which icu-config +icu-config +icu-config -? +icu-config --BAD ARGUMENT +icu-config --bindir +icu-config --cflags +icu-config --cxx +icu-config --cc +icu-config --cxxflags +icu-config --cppflags +icu-config --cppflags-searchpath +icu-config --incpath +icu-config --invoke +icu-config --invoke=genrb +icu-config --invoke=./myapp +icu-config --invoke=/path/to/myapp +icu-config --ldflags +icu-config --ldflags-searchpath +icu-config --ldflags-libsonly +icu-config --ldflags-system +icu-config --ldflags-ustdio +icu-config --exec-prefix +icu-config --prefix +icu-config --sbindir +icu-config --sysconfdir +icu-config --mandir +icu-config --icudata +icu-config --icudatadir +icu-config --icudata-mode +icu-config --icudata-install-dir +icu-config --shared-datadir +icu-config --unicode-version +icu-config --version +# should fail +icu-config --prefix=/tmp --bindir +# following needs to point to an alternate path that will work +icu-config --prefix=/Users/srl/II --cflags +icu-config --detect-prefix --ldflags + diff --git a/intl/icu/source/config/windows-update.sed.in b/intl/icu/source/config/windows-update.sed.in new file mode 100644 index 000000000..23473a757 --- /dev/null +++ b/intl/icu/source/config/windows-update.sed.in @@ -0,0 +1,8 @@ +# Copyright (C) 2016 and later: Unicode, Inc. and others. +# License & terms of use: http://www.unicode.org/copyright.html +# Copyright (C) 2010 IBM Corporation and Others. All Rights Reserved +# sed script for updating windows .mak and .vcproj files +s%^U_ICUDATA_NAME=.*%U_ICUDATA_NAME=icudt@LIB_VERSION_MAJOR@% +s%^UNICODE_VERSION=.*%UNICODE_VERSION=@UNICODE_VERSION@% +s%\(icu[a-zA-Z]*\)[0-9][0-9]\(d\.dll\)%\1@LIB_VERSION_MAJOR@\2%g +s%\(icu[a-zA-Z]*\)[0-9][0-9]\(\.dll\)%\1@LIB_VERSION_MAJOR@\2%g |