Makefile
author jenda
Thu, 19 May 2011 11:33:20 +0200
changeset 134 455f05a692fc
parent 133 65086617f925
child 138 dff2e32f3bca
permissions -rw-r--r--
7040301 Uncomplete LC_CTYPE information after migration to CLDR 1.9 & Unicode 6.0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     1
#
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     2
# CDDL HEADER START
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     3
#
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
111
33aaab5040ad 6900712 [PSARC/2009/528] Remove obsolete short-form locales
hnhn
parents: 109
diff changeset
     5
# Common Development and Distribution License (the "License").
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     7
#
29
1db559ddf29a add and/or fix CDDL headers
jenda
parents: 26
diff changeset
     8
# You can obtain a copy of the license at OPENSOLARIS.LICENSE
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    10
# See the License for the specific language governing permissions
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    11
# and limitations under the License.
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    12
#
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
29
1db559ddf29a add and/or fix CDDL headers
jenda
parents: 26
diff changeset
    14
# file and include the License file at OPENSOLARIS.LICENSE.
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    18
#
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    19
# CDDL HEADER END
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    20
#
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
    21
# Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
29
1db559ddf29a add and/or fix CDDL headers
jenda
parents: 26
diff changeset
    22
#
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
    23
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    24
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    25
# common applications
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    26
JAVA		?= java
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    27
ANT		?= ant
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    28
LOCALEDEF	?= localedef
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    29
WGET		?= wget
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    30
GNU_PATCH	?= gpatch
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    31
UNZIP		?= unzip
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    32
ZIP		?= zip
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    33
PERL		?= perl
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
    34
GNU_TAR		?= gtar
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    35
CC		= /opt/SUNWspro/bin/cc
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    36
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    37
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    38
# internal applications
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    39
GEN_CHARMAP	= $(JAVA) $(CLDR_JAVAFLAGS) -cp $(call classpath) org.unicode.cldr.posix.GenerateCharmap 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    40
GEN_POSIX	= $(JAVA) $(CLDR_JAVAFLAGS) -cp $(call classpath) org.unicode.cldr.posix.GeneratePOSIX 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    41
GEN_DESCRIPTION	= $(JAVA) $(CLDR_JAVAFLAGS) -cp $(call classpath) org.unicode.cldr.tool.LocaleDescription
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    42
XMLVALIDATOR	= $(JAVA) $(CLDR_JAVAFLAGS) -cp $(call classpath) org.unicode.cldr.util.XMLValidator
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    43
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    44
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    45
# software versions
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
    46
CLDR_VERSION		:= 1.9.0
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
    47
ICU4J_VERSION		:= 4.6.1
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    48
XALAN_VERSION		:= 2.7.1
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    49
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    50
CLDR_CORE_SOURCE	:= core_$(subst .,_,$(CLDR_VERSION)).zip
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    51
CLDR_CORE_SITE		:= http://unicode.org/Public/cldr/$(CLDR_VERSION)/core.zip
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    52
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    53
CLDR_TOOLS_SOURCE	:= tools_$(subst .,_,$(CLDR_VERSION)).zip
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    54
CLDR_TOOLS_SITE		:= http://unicode.org/Public/cldr/$(CLDR_VERSION)/tools.zip
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    55
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
    56
ICU4J_SOURCE		:= icu4j-$(subst .,_,$(ICU4J_VERSION)).tgz
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    57
ICU4J_SITE		:= http://download.icu-project.org/files/icu4j/$(ICU4J_VERSION)/$(ICU4J_SOURCE)
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    59
XALAN_SOURCE		:= xalan-j_$(subst .,_,$(XALAN_VERSION))-bin.zip
127
e53aeef086b3 update proxy and xalan mirror
pavel heimlich - Sun Microsystems - Prague Czech Republic <Pavel.Heimlich@Sun.COM>
parents: 126
diff changeset
    60
XALAN_SITE		:= http://apache.mirrors.airband.net/xml/xalan-j/$(XALAN_SOURCE)
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    61
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    62
CLDR_DTD_SOURCE		:= cldr_dtd.$(subst .,_,$(CLDR_VERSION)).zip
58
629fd75208e1 define downloaded software versions in config.mk
jenda
parents: 57
diff changeset
    63
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    64
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    65
# architecture
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    66
MACH		:= $(shell uname -p)
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    67
MACH64_sparc	= sparcv9
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    68
MACH64_i386	= amd64
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    69
MACH64		= $(MACH64_$(MACH))
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    70
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    71
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    72
# compile flags
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    73
#
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    74
#	CFLAGS_*:	flags for both (32/64bit) targets
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    75
#	CFLAGS32_*:	flags for 32bit target
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    76
#	CFLAGS64_*:	flags for 64bit target
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    77
#	CFLAGS*_common:	flags for both (i386/sparc) architectures
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    78
#	CFLAGS*_sparc:	flags for sparc architecture only
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    79
#	CFLAGS*_i386:	flags for i386 architecture only
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    80
CFLAGS_common	= -xO3 -Xa -xildoff -xc99=%none -v -K pic -D PIC -G -I. -z defs -z text -z ignore -D_REENTRANT
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    81
CFLAGS32_common	= -m32
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    82
CFLAGS64_common	= -m64
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    83
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    84
CFLAGS_sparc	= -xarch=sparc -xspace -W0\,-Lt -W2\,-Rcond_elim -Wd\,-xsafe=unboundsym -xregs=no%appl
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    85
CFLAGS64_sparc	= -dalign -v  -Wc\,-Qiselect-regsym=0
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    86
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    87
CFLAGS32_i386	= -xspace
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    88
CFLAGS64_i386	= -xarch=sse2 -Ui386 -U__i386  
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    89
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    90
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    91
# java flags
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    92
# for cldr posix locale generator
134
455f05a692fc 7040301 Uncomplete LC_CTYPE information after migration to CLDR 1.9 & Unicode 6.0
jenda
parents: 133
diff changeset
    93
JAVAFLAGS	= -Xmx512m
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    94
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    95
# misc
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    96
DOWNLOADS	?= .
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
    97
FILEROOT	= proto/$(MACH)/fileroot
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    98
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
    99
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
   100
# ==== END OF CONFIGURATION ====
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
   101
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   102
# To put more focus on warnings, be less verbose as default
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   103
# Use 'make V=1' to see the full commands
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   104
ifeq ($(V),1)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   105
  M=@\#
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   106
  Q=
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   107
else
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   108
  M=@echo ' '  
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   109
  Q=@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   110
endif
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   111
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   112
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
   113
# list of all locales
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
   114
LOCALES = $(basename $(notdir $(wildcard locale/*.spec)))
30
a1878e39c19f aesthetic adjustments in makefiles
jenda
parents: 29
diff changeset
   115
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   116
# C flags
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   117
CFLAGS32	?= $(CFLAGS_common) $(CFLAGS32_common) $(CFLAGS_$(MACH)) $(CFLAGS32_$(MACH))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   118
CFLAGS64	?= $(CFLAGS_common) $(CFLAGS64_common) $(CFLAGS_$(MACH)) $(CFLAGS64_$(MACH))
26
cade4546c172 migrate from g11n-oso to standalone ws and from ccs/make to gnu make
jenda
parents: 24
diff changeset
   119
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   120
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   121
# java flags for cldr posix locale generator
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   122
#	'-DCLDR_DTD_CACHE=.dtd_cache':		cache dir for temporary files
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   123
#	'-Dhttp.proxyHost=webcache.sfbay -Dhttp.proxyPort=8080:		default web proxy
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   124
CLDR_JAVAFLAGS	= $(JAVAFLAGS) -Dhttp.proxyHost=emeacache.uk.oracle.com -Dhttp.proxyPort=80 -DCLDR_DTD_CACHE=build/.dtd_cache -DCLDR_DIR=build/cldr_core
5
63aec4025526 locale_cldr: move list of generated locales (and variants) from Makefile to locale.list
jenda
parents: 4
diff changeset
   125
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   126
# locale name parsing functions
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   127
locale_xxYY = $(firstword $(subst ., ,$(1)))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   128
charmap = $(firstword $(subst @, ,$(lastword $(subst ., ,$(1)))))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   129
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   130
# misrc
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   131
#   CLDR uses different names for some charmaps 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   132
cldr_charmap = $(subst ANSI1251,ansi-1251,$(call charmap,$(1)))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   133
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   134
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   135
# ************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   136
# ==== Public targets ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   137
# ************************
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
   138
133
65086617f925 remove obsolete and broken SVR4 prototype creation tasks from Makefile
jenda
parents: 132
diff changeset
   139
.PHONY: all install doc build_tools clean
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
   140
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   141
all: build/pkgs.d build/cldr.d locale_objects
8
44f8eb36a5e1 locele_cldr: fix minor makefile bugs
jenda
parents: 6
diff changeset
   142
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   143
install: install_ips
31
4494cec780b5 add install target to Makefile
jenda
parents: 30
diff changeset
   144
73
db0f94907036 add diff.html report
jenda
parents: 70
diff changeset
   145
doc: build/report_diff.html
61
aa074266466f fix default value of key 'manifest'
jenda
parents: 60
diff changeset
   146
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   147
build_tools: build/icu4j.jar build/xalan.jar build/xml-apis.jar build/utilities.jar build/cldr.jar build/cldr_core/.src
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   148
57
706a08680440 reorder and simplify makefiles, build all code in ./build dir
jenda
parents: 39
diff changeset
   149
clean: 
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   150
	$(M)CLEAN
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   151
	$(Q)rm -Rf build pkgmaps proto
0
ab8dc3de97cd extension of locale data build process - build locale data from CLDR directly
jenda
parents:
diff changeset
   152
38
ea0937345b04 add 'make ips' target
jenda
parents: 36
diff changeset
   153
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   154
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   155
# ****************************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   156
# ==== generate makefile depend files ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   157
# ****************************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   158
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   159
-include build/pkgs.d
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   160
-include build/cldr.d
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   161
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   162
.PHONY: $(PKGS)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   163
115
e6a10d95ac6f remove SUNWlocaledefsrc (obsolete pkg) building rules from Makefile
jenda
parents: 113
diff changeset
   164
# little woo-doo: %pkg is hash of arrays, key is pkg_name, values are locales; 
e6a10d95ac6f remove SUNWlocaledefsrc (obsolete pkg) building rules from Makefile
jenda
parents: 113
diff changeset
   165
# ... look to the generated 'build/pkgs.d'
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   166
build/pkgs.d: $(LOCALES:%=build/%/pkg_name) build/.dir
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   167
	$(M)GENERATE $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   168
	$(Q)$(PERL) -e 'push @{$$pkg{substr(`cat $$_`,0,-1)}},m!build/(.*)/pkg_name! foreach (glob "build/*/pkg_name"); \
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   169
		 print "PKGS ?= SUNWlocaledefsrc " . join(" ", keys %pkg) . "\n"; \
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   170
		 print "build/$$_/.installed: " . join(" ", map { "build/$$_/.installed" } @{$$pkg{$$_}}) ."\n" foreach (keys %pkg); \
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   171
		 print "build/$$_/manifest: " . join(" ", map { "build/$$_/manifest" } @{$$pkg{$$_}}) ."\n" foreach (keys %pkg); ' > $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   172
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   173
build/cldr.d: $(LOCALES:%=build/%/cldr_variant) build/.dir
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   174
	$(M)GENERATE $@
132
7e8834a94d06 7011510 CLDR 1.9 ... - fix LC_CTYPE category: generate ctype from cldr/unicode
jenda
parents: 130
diff changeset
   175
	$(Q)$(PERL) -e 'my %loc = map { m!build/(.*)/cldr_variant! => m!build/.+\.([^@]+).*/cldr_variant! } qw($^); \
7e8834a94d06 7011510 CLDR 1.9 ... - fix LC_CTYPE category: generate ctype from cldr/unicode
jenda
parents: 130
diff changeset
   176
		print "CHARMAPS ?= " . join(" ", grep { ! $$seen1{$$_}++ } values %loc) . "\n"; \
7e8834a94d06 7011510 CLDR 1.9 ... - fix LC_CTYPE category: generate ctype from cldr/unicode
jenda
parents: 130
diff changeset
   177
		print "build/$$k/32bit.so.3 build/$$k/64bit.so.3: build/$$v.cm misc/$$v.x\n" while(($$k,$$v) = each %loc);'  > $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   178
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   179
build/SUNWlocaledefsrc/manifest: misc/templates/manifest/header_localedefsrc $(LOCALES:%=build/%/manifest_src) $(CHARMAPS:%=build/manifest_charmap_%)
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   180
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   181
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   182
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   183
# ************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   184
# ==== Locale Objects ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   185
# ************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   186
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   187
.PHONY: posix locale_objects
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   188
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   189
locale_objects: $(LOCALES:%=build/%/32bit.so.3) $(LOCALES:%=build/%/64bit.so.3)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   190
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   191
# all jars that CldrTools needs
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   192
CLDR_TOOLS_DEPS	= build/icu4j.jar build/xalan.jar build/xml-apis.jar build/utilities.jar build/cldr.jar build/cldr_core/.src
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   193
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   194
posix: $(LOCALES:%=build/%/posix.src)
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   195
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   196
$(LOCALES:%=build/%/posix.src): build/%/posix.src: build/%/cldr_variant $(CLDR_TOOLS_DEPS) build/.dtd_cache/.src
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   197
	$(M)GENERATE $@
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   198
	$(Q)$(GEN_POSIX) -d $(@D) -o $(@F) -c $(call cldr_charmap,$*) -m $(shell cat $<) 
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   199
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   200
$(LOCALES:%=build/%/32bit.so.3): build/%/32bit.so.3: build/%/posix.src build/%/32bit/.methods_so
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   201
	$(M)LOCALEDEF $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   202
	$(Q)cd $(@D)/32bit; $(LOCALEDEF) $(if $(Q),,-v) -P $(dir $(CC)) -W cc,"$(CFLAGS32)" -L "-R\\\$$ORIGIN" -x ../../../misc/$(call charmap, $*).x -f ../../$(call charmap, $*).cm -i ../posix.src $*; mv $*.so.3 ../32bit.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   203
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   204
# localedef reads the 32bit library for function definitions
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   205
# and then links against the 64bit library, so we need both 32bit and 64bit versions
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   206
$(LOCALES:%=build/%/64bit.so.3): build/%/64bit.so.3: build/%/posix.src build/%/64bit/.methods_so build/%/64bit/$(MACH64)/.methods_so
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   207
	$(M)LOCALEDEF $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   208
	$(Q)cd $(@D)/64bit; $(LOCALEDEF) $(if $(Q),,-v) -P $(dir $(CC)) -W cc,"$(CFLAGS64)" -L "-R\\\$$ORIGIN" -m lp64 -x ../../../misc/$(call charmap, $*).x -f ../../$(call charmap, $*).cm -i ../posix.src $*; mv $*.so.3 ../64bit.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   209
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   210
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   211
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   212
# ******************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   213
# ==== Charmaps ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   214
# ******************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   215
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   216
$(CHARMAPS:%=build/%.cm): build/%.cm: $(CLDR_TOOLS_DEPS) build/.dir build/.dtd_cache/.src
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   217
	$(M)GENERATE $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   218
	$(Q)$(GEN_CHARMAP) -d $(@D) -c $(call cldr_charmap,$*)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   219
	$(Q)[ "$(call charmap,$*)" = "$(call cldr_charmap,$*)" ] || mv build/$(call cldr_charmap,$*).cm $@
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   220
	# Note: 0x07 and 0x1f514 chars have the same name (<BELL>) - Unicode 6.0 bug?
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   221
	$(Q)perl -i -ne 'print unless /^<BELL>(\s+\\x07)$$/' $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   222
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   223
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   224
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   225
# *****************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   226
# ==== Other package files ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   227
# *****************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   228
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   229
# manifest
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   230
$(PKGS:%=build/%/manifest): build/%/manifest: build/%/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   231
	$(M)GENERATE $@
122
8ff29aae866c fix weak regular expressions (if one key was prefix of another key, the key can be misinterpreted)
jenda
parents: 121
diff changeset
   232
	$(Q)cat $^ | $(PERL) -ne 'print unless $$a{$$_}++' > $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   233
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   234
# copyright
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   235
$(FILEROOT)/copyright.cddl+unicode: misc/copyright.cddl+unicode
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   236
	$(Q)[ -d $(@D) ] || mkdir -p $(@D)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   237
	$(Q)cp $< $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   238
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   239
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   240
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   241
# **********************************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   242
# ==== Read params from locale/*.spec files ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   243
# **********************************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   244
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   245
# FIXME: this section is a bit too tricky ... probably will be rewritten as scripts
132
7e8834a94d06 7011510 CLDR 1.9 ... - fix LC_CTYPE category: generate ctype from cldr/unicode
jenda
parents: 130
diff changeset
   246
cldr_variant = $(call add_platform,$(call add_yesno,$(1)))
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   247
sep = $(call contains,$(1),@,$(comma),@)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   248
add_platform = $(1)$(call contains,$(1),platform=,,$(call sep,$(1))platform=solaris)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   249
add_yesno = $(1)$(call contains,$(1),yesno=,,$(call sep,$(1))yesno=solaris)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   250
122
8ff29aae866c fix weak regular expressions (if one key was prefix of another key, the key can be misinterpreted)
jenda
parents: 121
diff changeset
   251
spec_key = $(if $(shell $(PERL) -ne 'print 1 if /^$(1)\s/' $<),$(shell $(PERL) -ne 'print if s/^$(1)\s+(.*)/\1/' $<),$(2))
8ff29aae866c fix weak regular expressions (if one key was prefix of another key, the key can be misinterpreted)
jenda
parents: 121
diff changeset
   252
spec_key_is_set = $(if $(shell $(PERL) -ne 'print 1 if /^$(1)\s/' $<),\# $(1) is set,)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   253
spec_fkey = $(addprefix misc/templates/$(1)/,$(spec_key))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   254
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   255
# if $(1) contains $(2), return $(3) else $(4)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   256
contains = $(if $(filter-out xx,x$(subst $(1),,$(subst $(2),=-=,$(1))x)),$(3),$(4))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   257
comma := ,
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   258
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   259
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   260
EXPAND_ENV = LOC=$* \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   261
	     MACH=$(MACH) \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   262
	     MACH64=$(MACH64) \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   263
	     CHARMAP='$(call charmap,$*)' \
111
33aaab5040ad 6900712 [PSARC/2009/528] Remove obsolete short-form locales
hnhn
parents: 109
diff changeset
   264
	     LCMESSAGES='$(call spec_key,lc_messages,default)' \
33aaab5040ad 6900712 [PSARC/2009/528] Remove obsolete short-form locales
hnhn
parents: 109
diff changeset
   265
	     LCTIME='$(call spec_key,lc_time,default)' \
33aaab5040ad 6900712 [PSARC/2009/528] Remove obsolete short-form locales
hnhn
parents: 109
diff changeset
   266
	     IS_SET_LC_MESSAGES='$(call spec_key_is_set,lc_messages)' \
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   267
	     IS_SET_LC_TIME='$(call spec_key_is_set,lc_time)' \
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   268
	     DESCRIPTION='$(shell cat build/$*/pkg_description)'
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   269
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   270
$(LOCALES:%=build/%/pkg_name): build/%/pkg_name: locale/%.spec build/%/.dir
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   271
	$(M)GENERATE $@
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   272
	$(Q)echo "$(call spec_key,pkg_name,SUNWlang-$(firstword $(subst _, ,$*)))" >$@
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   273
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   274
$(LOCALES:%=build/%/cldr_variant): build/%/cldr_variant: locale/%.spec build/%/.dir
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   275
	$(M)GENERATE $@
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   276
	$(Q)echo "$(call cldr_variant,$(call spec_key,cldr_variant,$(call locale_xxYY,$*)))" > $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   277
126
fad75fecd632 fix packages description
jenda
parents: 125
diff changeset
   278
$(LOCALES:%=build/%/pkg_description): build/%/pkg_description: locale/%.spec build/%/locale_description build/%/.dir
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   279
	$(M)GENERATE $@
126
fad75fecd632 fix packages description
jenda
parents: 125
diff changeset
   280
	$(Q)echo '$(call spec_key,pkg_desc,$(shell $(PERL) -pe "s/,.*/ language support/" build/$*/locale_description))' > $@
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   281
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   282
$(LOCALES:%=build/%/locale_map): build/%/locale_map: locale/%.spec build/%/pkg_description
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   283
	$(M)GENERATE $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   284
	$(Q)for src in $(call spec_fkey,locale_map,default); do \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   285
		$(EXPAND_ENV) bash -c 'while read l; do eval "echo \"$$l\""; done' < $$src; \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   286
	done > $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   287
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   288
$(LOCALES:%=build/%/locale_description): build/%/locale_description: locale/%.spec $(CLDR_TOOLS_DEPS) build/%/cldr_variant build/.dtd_cache/.src
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   289
	$(M)GENERATE $@
122
8ff29aae866c fix weak regular expressions (if one key was prefix of another key, the key can be misinterpreted)
jenda
parents: 121
diff changeset
   290
	$(Q)(if [ -z "$(shell $(PERL) -ne 'print if s/^locale_desc\s+(.*)/\1/' $<)" ] ; then \
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   291
			$(GEN_DESCRIPTION) build/cldr_core $(shell cat build/$*/cldr_variant); \
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   292
			echo " ($(call charmap,$*))"; \
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   293
		else \
122
8ff29aae866c fix weak regular expressions (if one key was prefix of another key, the key can be misinterpreted)
jenda
parents: 121
diff changeset
   294
			echo "$(shell $(PERL) -ne 'print if s/^locale_desc\s+(.*)/\1/' $<)"; \
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   295
		fi) > $@
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   296
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   297
$(LOCALES:%=build/%/manifest): build/%/manifest: locale/%.spec build/%/pkg_description
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   298
	$(M)GENERATE $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   299
	$(Q)for src in $(call spec_fkey,manifest,header_lang utf8); do \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   300
		$(EXPAND_ENV) bash -c 'while read l; do eval "echo \"$$l\""; done' < $$src; \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   301
	done > $@
125
0e6428cfa223 add legacy entry to manifests
jenda
parents: 123
diff changeset
   302
	$(Q)$(PERL) -ne 'print if s/^manifest_raw\s+(.*)/\1/' $< >> $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   303
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   304
$(LOCALES:%=build/%/manifest_src): build/%/manifest_src: misc/templates/manifest/src locale/%.spec build/%/pkg_description
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   305
	$(M)GENERATE $@
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   306
	$(Q)$(EXPAND_ENV) bash -c 'while read l; do eval "echo \"$$l\""; done' < $< > $@
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   307
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   308
$(CHARMAPS:%=build/manifest_charmap_%): build/manifest_charmap_%: misc/templates/manifest/src_charmap locale/*.spec 
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   309
	$(M)GENERATE $@
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   310
	$(Q)CHARMAP=$* bash -c 'while read l; do eval "echo \"$$l\""; done' < $< >$@
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   311
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   312
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   313
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   314
# ********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   315
# ==== Install/Build packages ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   316
# ********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   317
133
65086617f925 remove obsolete and broken SVR4 prototype creation tasks from Makefile
jenda
parents: 132
diff changeset
   318
.PHONY: install_ips
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   319
117
fbb3551be55e make ips generates manifests with the same list of files as svr4 prototypes
jenda
parents: 116
diff changeset
   320
install_ips: build/pkgs.d $(PKGS:%=build/%/.installed_ips)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   321
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   322
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   323
$(LOCALES:%=build/%/.installed): build/%/.installed: build/%/.installed_locale_object_32 build/%/.installed_locale_object_64 build/%/.installed_locale_description build/%/.installed_locale_map build/%/.installed_locale_src
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   324
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   325
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   326
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   327
$(LOCALES:%=build/%/.installed_locale_object_32): build/%/.installed_locale_object_32: build/%/32bit.so.3 $(FILEROOT)/usr/lib/locale/%/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   328
	$(M)INSTALL $*.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   329
	$(Q)cp build/$*/32bit.so.3 $(FILEROOT)/usr/lib/locale/$*/$*.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   330
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   331
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   332
$(LOCALES:%=build/%/.installed_locale_object_64): build/%/.installed_locale_object_64: build/%/64bit.so.3 $(FILEROOT)/usr/lib/locale/%/$(MACH64)/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   333
	$(M)INSTALL $(MACH64)/$*.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   334
	$(Q)cp build/$*/64bit.so.3 $(FILEROOT)/usr/lib/locale/$*/$(MACH64)/$*.so.3
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   335
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   336
109
320c2bdeb88b Makefile: fix typo in .installed_locale_description and .installed_locale_map targets
jenda
parents: 108
diff changeset
   337
$(LOCALES:%=build/%/.installed_locale_description): build/%/.installed_locale_description: build/%/locale_description $(FILEROOT)/usr/lib/locale/%/.dir
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   338
	$(M)INSTALL $*/locale_description
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   339
	$(Q)cp build/$*/locale_description $(FILEROOT)/usr/lib/locale/$*/
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   340
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   341
	
109
320c2bdeb88b Makefile: fix typo in .installed_locale_description and .installed_locale_map targets
jenda
parents: 108
diff changeset
   342
$(LOCALES:%=build/%/.installed_locale_map): build/%/.installed_locale_map: build/%/locale_map $(FILEROOT)/usr/lib/locale/%/.dir
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   343
	$(M)INSTALL $*/locale_map
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   344
	$(Q)cp build/$*/locale_map $(FILEROOT)/usr/lib/locale/$*/
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   345
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   346
	
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   347
$(LOCALES:%=build/%/.installed_locale_src): build/%/.installed_locale_src: build/%/posix.src $(FILEROOT)/usr/lib/localedef/src/locales/.dir
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   348
	$(M)INSTALL $*/locale_src
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   349
	$(Q)cp $< $(FILEROOT)/usr/lib/localedef/src/locales/$*.src
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   350
	$(Q)touch $@
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   351
133
65086617f925 remove obsolete and broken SVR4 prototype creation tasks from Makefile
jenda
parents: 132
diff changeset
   352
$(PKGS:%=build/%/.installed_ips): build/%/.installed_ips: build/%/manifest build/%/.installed $(FILEROOT)/copyright.cddl+unicode pkgmaps/.dir
118
686cb5e09cd5 "ips" and "install_ips" targets copy files and manifests only, new target "pkgsend" publishes pkgs to ips
jenda
parents: 117
diff changeset
   353
	$(M)INSTALL $*/manifest
133
65086617f925 remove obsolete and broken SVR4 prototype creation tasks from Makefile
jenda
parents: 132
diff changeset
   354
	$(Q)cp $< pkgmaps/manifest.$(subst SUNW,,$*)
118
686cb5e09cd5 "ips" and "install_ips" targets copy files and manifests only, new target "pkgsend" publishes pkgs to ips
jenda
parents: 117
diff changeset
   355
	$(Q)touch $@
686cb5e09cd5 "ips" and "install_ips" targets copy files and manifests only, new target "pkgsend" publishes pkgs to ips
jenda
parents: 117
diff changeset
   356
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   357
$(CHARMAPS:%=build/.installed_charmap_%): build/.installed_charmap_%: build/%.cm $(FILEROOT)/usr/lib/localedef/src/charmaps/.dir
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   358
	$(M)INSTALL charmap $*
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   359
	$(Q)cp $< $(FILEROOT)/usr/lib/localedef/src/charmaps/$*.charmap
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   360
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   361
128
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   362
build/.installed_extensions: $(FILEROOT)/usr/lib/localedef/src/extensions/.dir
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   363
	$(M)INSTALL extensions
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   364
	$(Q)cp misc/*.x $(FILEROOT)/usr/lib/localedef/src/extensions/
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   365
05d36addbcc9 7020024 reintroduce SUNWlocaledefsrc
pavel heimlich - Oracle - Prague Czech Republic <Pavel.Heimlich@Oracle.COM>
parents: 127
diff changeset
   366
build/SUNWlocaledefsrc/.installed: $(LOCALES:%=build/%/.installed_locale_src) $(CHARMAPS:%=build/.installed_charmap_%) build/.installed_extensions
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   367
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   368
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   369
# *********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   370
# ==== Compile the build tools ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   371
# *********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   372
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   373
classpath = $(subst $() $(),:,$(filter %.jar,$^))
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   374
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   375
# xalan
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   376
build/xalan/.src: downloads/$(XALAN_SOURCE)
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   377
	$(M)UNPACK $(@D)
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   378
	$(Q)rm -Rf $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   379
	$(Q)$(UNZIP) -u $(if $(Q),-q) -d $(@D) $<
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   380
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   381
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   382
build/xalan.jar: build/xalan/.src
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   383
	$(M)INSTALL $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   384
	$(Q)cp build/xalan/xalan-j_2_7_1/xalan.jar $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   385
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   386
build/xml-apis.jar: build/xalan/.src
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   387
	$(M)INSTALL $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   388
	$(Q)cp build/xalan/xalan-j_2_7_1/xml-apis.jar $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   389
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   390
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   391
# icu4j
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   392
build/icu4j/.src: downloads/$(ICU4J_SOURCE) $(wildcard misc/patches/icu4j/*.patch)
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   393
	$(M)UNPACK $(@D)
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   394
	$(Q)rm -Rf $(@D)
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   395
	$(Q)mkdir $(@D)
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   396
	$(Q)(cd $(@D);  $(GNU_TAR) x$(if $(Q),,v)zf ../../$<)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   397
	$(M)PATCH icu4j
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   398
	$(Q)for a in $(filter %.patch, $(sort $^)); do \
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   399
		echo "   $$a"; \
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   400
		(cd $(@D); $(GNU_PATCH) -p1 $(if $(Q),-s)) < $$a; \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   401
	done
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   402
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   403
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   404
build/icu4j/.compiled: build/icu4j/.src
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   405
	$(M)COMPILE $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   406
	$(Q)cd $(@D); $(ANT) $(if $(Q),-q) jar cldrUtil
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   407
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   408
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   409
build/utilities.jar: build/icu4j/.compiled
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   410
	$(M)INSTALL $@
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   411
	$(Q)cp build/icu4j/out/cldr_util/lib/utilities.jar $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   412
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   413
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   414
build/icu4j.jar: build/icu4j/.compiled 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   415
	$(M)INSTALL $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   416
	$(Q)cp build/icu4j/icu4j.jar $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   417
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   418
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   419
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   420
# cldr_tools
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   421
build/cldr_tools/.src: downloads/$(CLDR_TOOLS_SOURCE) $(wildcard misc/patches/cldr_tools/*.patch)
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   422
	$(M)UNPACK $(@D)
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   423
	$(Q)rm -Rf $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   424
	$(Q)$(UNZIP) -u $(if $(Q),-q) -d $(@D) $<
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   425
	$(M)PATCH $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   426
	$(Q)find $(@D) -type f -exec perl -pi -e 's,\r$$,,' {} \;
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   427
	$(Q)for a in $(filter %.patch, $(sort $^)); do  \
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   428
		echo "   $$a"; \
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   429
		(cd $(@D); $(GNU_PATCH) -p1 $(if $(Q),-s)) < $$a; \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   430
	done
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   431
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   432
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   433
build/cldr_tools/.compiled: build/icu4j.jar build/utilities.jar build/xalan.jar build/xml-apis.jar build/cldr_tools/.src
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   434
	$(M)COMPILE $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   435
	$(Q)cd $(@D)/tools/java; ICU4J_JAR=../../../icu4j.jar UTILITIES_JAR=../../../utilities.jar CLDR_JAR=../../../xalan.jar XML_APIS_JAR=../../../xml-apis.jar $(ANT) $(if $(Q),-q) jar
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   436
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   437
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   438
build/cldr.jar: build/cldr_tools/.compiled 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   439
	$(M)INSTALL $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   440
	$(Q)cp build/cldr_tools/tools/java/cldr.jar $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   441
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   442
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   443
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   444
# cldr_core
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   445
build/cldr_core/.src: downloads/$(CLDR_CORE_SOURCE) $(wildcard misc/patches/cldr_core/*.patch)
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   446
	$(M)UNPACK $(@D)
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   447
	$(Q)rm -Rf $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   448
	$(Q)$(UNZIP) -u $(if $(Q),-q) -d $(@D) $<
116
54bc75ad88c9 minor Makefile reorder and fix small typos in buildlog messages
jenda
parents: 115
diff changeset
   449
	$(M)PATCH $(@D)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   450
	$(Q)find $(@D) -type f -exec perl -pi -e 's,\r$$,,' {} \;
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   451
	$(Q)for a in $(filter %.patch, $(sort $^)); do  \
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   452
		echo "   $$a"; \
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   453
		(cd $(@D); $(GNU_PATCH) -p1 $(if $(Q),-s)) < $$a; \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   454
	done
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   455
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   456
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   457
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   458
# ldump and cmprint 
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   459
build/cmap.c: tools/cmap.pl $(CHARMAPS:%=build/%.cm)
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   460
	$(M)GENERATE $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   461
	$(Q)tools/cmap.pl $(filter %.cm,$^) > $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   462
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   463
build/cmap.o: build/cmap.c
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   464
	$(M)CC $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   465
	$(Q)$(CC) -c -o $@ $<
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   466
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   467
build/%.o: tools/%.c
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   468
	$(M)CC $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   469
	$(Q)$(CC) -c -o $@ $<
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   470
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   471
build/ldump: build/ldump.o build/cmap.o
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   472
	$(M)BUILD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   473
	$(Q)$(CC) -o $@ $^
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   474
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   475
build/cmprint: build/cmprint.o build/cmap.o
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   476
	$(M)BUILD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   477
	$(Q)$(CC) -o $@ $^
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   478
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   479
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   480
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   481
# *************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   482
# ==== Pack and Unpack ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   483
# *************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   484
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   485
build/.dtd_cache/.src: downloads/$(CLDR_DTD_SOURCE) build/.dtd_cache/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   486
	$(M)UNPACK $<
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   487
	$(Q)$(UNZIP) -u $(if $(Q),-q) -d $(@D) $<
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   488
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   489
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   490
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   491
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   492
# ***********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   493
# ==== Download sources from net ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   494
# ***********************************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   495
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   496
downloads/$(CLDR_CORE_SOURCE): downloads/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   497
	$(M)DOWNLOAD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   498
	$(Q)if [ -f $(DOWNLOADS)/$(@F) ]; then \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   499
		cp $(DOWNLOADS)/$(@F) $(@D); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   500
	else \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   501
		$(WGET) $(if $(Q),-q) -O $@ $(CLDR_CORE_SITE); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   502
	fi
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   503
	$(Q)touch -c $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   504
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   505
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   506
downloads/$(CLDR_TOOLS_SOURCE): downloads/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   507
	$(M)DOWNLOAD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   508
	$(Q)if [ -f $(DOWNLOADS)/$(@F) ]; then \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   509
		cp $(DOWNLOADS)/$(@F) $(@D); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   510
	else \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   511
		$(WGET) $(if $(Q),-q) -O $@ $(CLDR_TOOLS_SITE); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   512
	fi
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   513
	$(Q)touch -c $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   514
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   515
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   516
downloads/$(ICU4J_SOURCE): downloads/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   517
	$(M)DOWNLOAD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   518
	$(Q)if [ -f $(DOWNLOADS)/$(@F) ]; then \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   519
		cp $(DOWNLOADS)/$(@F) $(@D); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   520
	else \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   521
		$(WGET) $(if $(Q),-q) -O $@ $(ICU4J_SITE); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   522
	fi
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   523
	$(Q)touch -c $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   524
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   525
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   526
downloads/$(XALAN_SOURCE): downloads/.dir
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   527
	$(M)DOWNLOAD $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   528
	$(Q)if [ -f $(DOWNLOADS)/$(@F) ]; then \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   529
		cp $(DOWNLOADS)/$(@F) $(@D); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   530
	else \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   531
		$(WGET) $(if $(Q),-q) -O $@ $(XALAN_SITE); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   532
	fi
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   533
	$(Q)touch -c $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   534
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   535
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   536
# workaround for race condition in org.unicode.cldr.util.CachingEntityResolver
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   537
# - if more than one process use build/.dtd_cache dir, the second process could
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   538
# receive uncomplete dtd and parallel build could fail
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   539
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   540
downloads/$(CLDR_DTD_SOURCE): downloads/.dir $(CLDR_TOOLS_DEPS)
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   541
	$(M)DOWNLOAD DTDs
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   542
	$(Q)if [ -f $(DOWNLOADS)/$(@F) ]; then \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   543
		cp $(DOWNLOADS)/$(@F) $(@D); \
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   544
	else \
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   545
		mkdir -p build/.dtd_cache; \
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   546
		$(XMLVALIDATOR) build/cldr_core/common/main/en.xml > /dev/null; \
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   547
		$(XMLVALIDATOR) build/cldr_core/common/supplemental/supplementalData.xml > /dev/null; \
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   548
		(cd build/.dtd_cache/; $(ZIP) $(if $(Q),-q) -o ../../$@ *.dtd); \
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   549
	fi
130
66e398a2332f 7011510 CLDR 1.9 locale data integration
jenda
parents: 129
diff changeset
   550
	$(Q)touch $@
108
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   551
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   552
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   553
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   554
# **************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   555
# ==== Misc ====
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   556
# **************
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   557
%/.dir:
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   558
	$(Q)mkdir -p "$*"
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   559
	$(Q)touch $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   560
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   561
build/report_diff.html: all build/ldump tools/report_diff.pl
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   562
	$(M)GENERATE $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   563
	$(Q)tools/report_diff.pl $(LOCALES) > $@
bdf1f0a15884 re-order and simplify Makefiles - less internal functions, no includes, ...
jenda
parents: 95
diff changeset
   564
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   565
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   566
METHODS_SO = methods_unicode.so.3
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   567
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   568
build/.methods_so: build/32bit/.dir build/64bit/.dir
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   569
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   570
ifeq ($(wildcard $(FILEROOT)/usr/lib/locale/common/$(METHODS_SO)),)
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   571
build/.methods_so:
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   572
	$(M)COPY_SYSTEM $(METHODS_SO)
119
ee584b50490d re-make could fail to copy methods_unicode.so, fixed
jenda
parents: 118
diff changeset
   573
	$(Q)cp -f /usr/lib/locale/common/$(METHODS_SO) build/32bit/
ee584b50490d re-make could fail to copy methods_unicode.so, fixed
jenda
parents: 118
diff changeset
   574
	$(Q)cp -f /usr/lib/locale/common/$(MACH64)/$(METHODS_SO) build/64bit/
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   575
	$(Q)touch $@
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   576
else
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   577
build/.methods_so: $(FILEROOT)/usr/lib/locale/common/$(METHODS_SO) $(FILEROOT)/usr/lib/locale/common/$(MACH64)/$(METHODS_SO)
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   578
	$(M)COPY $(METHODS_SO)
119
ee584b50490d re-make could fail to copy methods_unicode.so, fixed
jenda
parents: 118
diff changeset
   579
	$(Q)cp -f $(FILEROOT)/usr/lib/locale/common/$(METHODS_SO) build/32bit/
ee584b50490d re-make could fail to copy methods_unicode.so, fixed
jenda
parents: 118
diff changeset
   580
	$(Q)cp -f $(FILEROOT)/usr/lib/locale/common/$(MACH64)/$(METHODS_SO) build/64bit/
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   581
	$(Q)touch $@
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   582
endif
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   583
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   584
$(LOCALES:%=build/%/32bit/.methods_so) $(LOCALES:%=build/%/64bit/.methods_so): build/%/.methods_so: build/.methods_so build/%/.dir
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   585
	$(M)LINK $(@D)/$(METHODS_SO)
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   586
	$(Q)rm -f build/$*/$(METHODS_SO)
121
1ef1a0fe5f25 %/.dir target does not work well in parallel build
jenda
parents: 119
diff changeset
   587
	$(Q)cp build/32bit/$(METHODS_SO) build/$*/$(METHODS_SO)
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   588
	$(Q)touch $@
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   589
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   590
$(LOCALES:%=build/%/64bit/$(MACH64)/.methods_so): build/%/.methods_so: build/.methods_so build/%/.dir
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   591
	$(M)LINK $(@D)/$(METHODS_SO)
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   592
	$(Q)rm -f build/$*/$(METHODS_SO)
121
1ef1a0fe5f25 %/.dir target does not work well in parallel build
jenda
parents: 119
diff changeset
   593
	$(Q)cp build/64bit/$(METHODS_SO) build/$*/$(METHODS_SO)
113
68608e19b3f8 6972031 build locales against built methods*so, not system's methods*so
hnhn
parents: 111
diff changeset
   594
	$(Q)touch $@