From 5f8de423f190bbb79a62f804151bc24824fa32d8 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 2 Feb 2018 04:16:08 -0500 Subject: Add m-esr52 at 52.6.0 --- intl/icu/source/config/Makefile.inc.in | 292 +++++++++++++++++++ intl/icu/source/config/dist.mk | 86 ++++++ intl/icu/source/config/gmakever.mk | 31 ++ intl/icu/source/config/icu-config-bottom | 413 +++++++++++++++++++++++++++ intl/icu/source/config/icu-config-top | 26 ++ intl/icu/source/config/icu-config.1.in | 287 +++++++++++++++++++ intl/icu/source/config/icu.pc.in | 36 +++ intl/icu/source/config/m4/icu-conditional.m4 | 18 ++ intl/icu/source/config/make2sh.sed | 20 ++ intl/icu/source/config/mh-aix-gcc | 138 +++++++++ intl/icu/source/config/mh-aix-va | 140 +++++++++ intl/icu/source/config/mh-alpha-linux-cc | 87 ++++++ intl/icu/source/config/mh-alpha-linux-gcc | 85 ++++++ intl/icu/source/config/mh-alpha-osf | 87 ++++++ intl/icu/source/config/mh-beos | 108 +++++++ intl/icu/source/config/mh-bsd-gcc | 82 ++++++ intl/icu/source/config/mh-cygwin | 143 ++++++++++ intl/icu/source/config/mh-cygwin-msvc | 230 +++++++++++++++ intl/icu/source/config/mh-cygwin64 | 143 ++++++++++ intl/icu/source/config/mh-darwin | 81 ++++++ intl/icu/source/config/mh-haiku | 80 ++++++ intl/icu/source/config/mh-hpux-acc | 138 +++++++++ intl/icu/source/config/mh-hpux-gcc | 92 ++++++ intl/icu/source/config/mh-irix | 76 +++++ intl/icu/source/config/mh-linux | 87 ++++++ intl/icu/source/config/mh-linux-va | 79 +++++ intl/icu/source/config/mh-mingw | 160 +++++++++++ intl/icu/source/config/mh-mingw64 | 160 +++++++++++ intl/icu/source/config/mh-mpras | 66 +++++ intl/icu/source/config/mh-msys-msvc | 222 ++++++++++++++ intl/icu/source/config/mh-os390 | 241 ++++++++++++++++ intl/icu/source/config/mh-os400 | 141 +++++++++ intl/icu/source/config/mh-qnx | 94 ++++++ intl/icu/source/config/mh-solaris | 100 +++++++ intl/icu/source/config/mh-solaris-gcc | 80 ++++++ intl/icu/source/config/mh-unknown | 29 ++ intl/icu/source/config/pkgdataMakefile.in | 42 +++ intl/icu/source/config/test-icu-config.sh | 50 ++++ intl/icu/source/config/windows-update.sed.in | 8 + 39 files changed, 4478 insertions(+) create mode 100644 intl/icu/source/config/Makefile.inc.in create mode 100644 intl/icu/source/config/dist.mk create mode 100644 intl/icu/source/config/gmakever.mk create mode 100644 intl/icu/source/config/icu-config-bottom create mode 100644 intl/icu/source/config/icu-config-top create mode 100644 intl/icu/source/config/icu-config.1.in create mode 100644 intl/icu/source/config/icu.pc.in create mode 100644 intl/icu/source/config/m4/icu-conditional.m4 create mode 100644 intl/icu/source/config/make2sh.sed create mode 100644 intl/icu/source/config/mh-aix-gcc create mode 100644 intl/icu/source/config/mh-aix-va create mode 100644 intl/icu/source/config/mh-alpha-linux-cc create mode 100644 intl/icu/source/config/mh-alpha-linux-gcc create mode 100644 intl/icu/source/config/mh-alpha-osf create mode 100644 intl/icu/source/config/mh-beos create mode 100644 intl/icu/source/config/mh-bsd-gcc create mode 100644 intl/icu/source/config/mh-cygwin create mode 100644 intl/icu/source/config/mh-cygwin-msvc create mode 100644 intl/icu/source/config/mh-cygwin64 create mode 100644 intl/icu/source/config/mh-darwin create mode 100644 intl/icu/source/config/mh-haiku create mode 100644 intl/icu/source/config/mh-hpux-acc create mode 100644 intl/icu/source/config/mh-hpux-gcc create mode 100644 intl/icu/source/config/mh-irix create mode 100644 intl/icu/source/config/mh-linux create mode 100644 intl/icu/source/config/mh-linux-va create mode 100644 intl/icu/source/config/mh-mingw create mode 100644 intl/icu/source/config/mh-mingw64 create mode 100644 intl/icu/source/config/mh-mpras create mode 100644 intl/icu/source/config/mh-msys-msvc create mode 100644 intl/icu/source/config/mh-os390 create mode 100644 intl/icu/source/config/mh-os400 create mode 100644 intl/icu/source/config/mh-qnx create mode 100644 intl/icu/source/config/mh-solaris create mode 100644 intl/icu/source/config/mh-solaris-gcc create mode 100644 intl/icu/source/config/mh-unknown create mode 100644 intl/icu/source/config/pkgdataMakefile.in create mode 100755 intl/icu/source/config/test-icu-config.sh create mode 100644 intl/icu/source/config/windows-update.sed.in (limited to 'intl/icu/source/config') 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= Print commands to invoke an ICU program named (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: " +} + +## 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 +.\" Modified by Steven R. Loomis . +.\" 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 ${ $@; \ + [ -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 ${ $@; \ +# [ -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 ${ $@; \ + [ -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 ${ $@; \ + [ -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 ${ $@ + @$(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 ${ $@ +# @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 ${ $@ + @$(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 ${ $@; \ + [ -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 ${ +# 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 ${ $@; \ + [ -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 ${ $@; \ + [ -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 ${ $@; \ + [ -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 ${ /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 ${ $@ + @$(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 ${ $@ + @$(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 ${ $@ + +%.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 ${ $@ +# @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 ${ $@; \ + [ -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 + + +# +# 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 ${ $@ + +%.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 ${ $@; \ + [ -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 ${> $(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 -- cgit v1.2.3