author | ihse |
Thu, 14 Nov 2013 11:19:32 +0100 | |
changeset 21805 | c7d7946239de |
parent 20549 | jdk/makefiles/gensrc/GensrcProperties.gmk@815df0732142 |
child 23010 | 6dadb192ad81 |
permissions | -rw-r--r-- |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
1 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
2 |
# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
4 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
5 |
# This code is free software; you can redistribute it and/or modify it |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
7 |
# published by the Free Software Foundation. Oracle designates this |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
8 |
# particular file as subject to the "Classpath" exception as provided |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
9 |
# by Oracle in the LICENSE file that accompanied this code. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
10 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
15 |
# accompanied this code). |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
16 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
17 |
# You should have received a copy of the GNU General Public License version |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
20 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
22 |
# or visit www.oracle.com if you need additional information or have any |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
23 |
# questions. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
24 |
# |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
25 |
|
15126
bceb690ccf35
8005540: build-infra: Improve incremental build speed on windows by caching find results
erikj
parents:
14231
diff
changeset
|
26 |
# Prepare the find cache. This is only used on windows. |
20547 | 27 |
$(eval $(call FillCacheFind, $(JDK_TOPDIR)/src/share/classes $(JDK_TOPDIR)/src/windows/classes)) |
15126
bceb690ccf35
8005540: build-infra: Improve incremental build speed on windows by caching find results
erikj
parents:
14231
diff
changeset
|
28 |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
29 |
# All .properties files to be compiled are appended to this variable. |
20547 | 30 |
ALL_COMPILED_PROPSOURCES := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
31 |
# All generated .java files from compilation are appended to this variable. |
20547 | 32 |
ALL_COMPILED_PROPJAVAS := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
33 |
# The (very long) command line for compilation, stored in a file, prior to use. |
20547 | 34 |
COMPILE_PROPCMDLINE := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
35 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
36 |
# All .properties files to be cleaned are appended to this variable. |
20547 | 37 |
ALL_CLEANED_PROPSOURCES := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
38 |
# All generated cleaned .properties files from cleaning are appended to this variable. |
20547 | 39 |
ALL_CLEANED_PROPOUTPUT := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
40 |
# The (very long) command line for cleaning, stored in a file, prior to use. |
20547 | 41 |
CLEAN_PROPCMDLINE := |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
42 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
43 |
define add_properties_to_compile |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
44 |
# $1 is the name of the properties group |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
45 |
# $2 is the files belonging to this group |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
46 |
# $3 is the super class for the generated java file. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
47 |
# $4 is a from pattern for translating stripped name from source to target |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
48 |
# $5 is the to pattern replacing $3 in the target |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
49 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
50 |
# Strip away prefix and suffix, |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
51 |
# leaving for example: sun/util/resources/CurrencyNames_sv |
20547 | 52 |
$1_PROPPATHS := $$(patsubst $(JDK_TOPDIR)/src/windows/classes/%.properties, %, \ |
53 |
$$(patsubst $(JDK_TOPDIR)/src/macosx/classes/%.properties, %, \ |
|
54 |
$$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties, %, $2))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
55 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
56 |
# Apply optional name transformation, example: hz_TW -> hz_HK |
20547 | 57 |
$(if $4, $1_PROPPATHS := $$(patsubst $4, $5, $$($1_PROPPATHS))) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
58 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
59 |
# Accumulate all found properties files. |
20547 | 60 |
ALL_COMPILED_PROPSOURCES += $2 |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
61 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
62 |
# Generate the list of to be created java files. |
20547 | 63 |
ALL_COMPILED_PROPJAVAS += $$(patsubst %, $(JDK_OUTPUTDIR)/gensrc/%.java, $$($1_PROPPATHS)) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
64 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
65 |
# Now generate a sequence of "-compile ...CurrencyNames_sv.properties ...CurrencyNames_sv.java ListResourceBundle" |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
66 |
# suitable to be fed into the CompileProperties command. |
20547 | 67 |
COMPILE_PROPCMDLINE += $$(subst _SPACE_,$(SPACE),$$(join $$(addprefix -compile_SPACE_, $2), \ |
68 |
$$(addsuffix _SPACE_$(strip $3), \ |
|
69 |
$$(addprefix _SPACE_$(JDK_OUTPUTDIR)/gensrc/, \ |
|
70 |
$$(addsuffix .java, $$($1_PROPPATHS)))))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
71 |
endef |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
72 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
73 |
define add_properties_to_clean |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
74 |
# $1 is the name of the properties group |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
75 |
# $2 is the files belonging to this group |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
76 |
# $3 is a from pattern for translating stripped name from source to target |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
77 |
# $4 is the to pattern replacing $3 in the target |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
78 |
# $5 optional name of extra directory to put properties files in (ex: resources) |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
79 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
80 |
# Strip away prefix and suffix, |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
81 |
# leaving for example: sun/util/resources/CurrencyNames_sv |
20547 | 82 |
$1_PROPPATHS := $$(patsubst $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/classes/%.properties, %, \ |
83 |
$$(patsubst $(JDK_TOPDIR)/src/share/classes/%.properties, %, $2)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
84 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
85 |
# Apply optional name transformation, example: hz_TW -> hz_HK |
20547 | 86 |
$(if $3, $1_PROPPATHS := $$(patsubst $3, $4, $$($1_PROPPATHS))) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
87 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
88 |
# Accumulate all found properties files. |
20547 | 89 |
ALL_CLEANED_PROPSOURCES += $2 |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
90 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
91 |
# Generate the list of to be created java files. |
20547 | 92 |
$1_PROPOUTPUT := $$(patsubst %, $(JDK_OUTPUTDIR)/classes/%.properties, $$($1_PROPPATHS)) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
93 |
# If the properties target file isn't in a "resources" dir, add one. |
20547 | 94 |
ifneq ($5, ) |
95 |
$1_PROPOUTPUT := $$(foreach p, $$($1_PROPOUTPUT), $$(dir $$p)$5/$$(notdir $$p)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
96 |
endif |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
97 |
|
20547 | 98 |
ALL_CLEANED_PROPOUTPUT += $$($1_PROPOUTPUT) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
99 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
100 |
# Now generate a sequence of "-clean ...[src]...CurrencyNames_sv.properties ...[build]...CurrencyNames_sv.properties" |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
101 |
# suitable to be fed into the StripProperties command. |
20547 | 102 |
CLEAN_PROPCMDLINE += $$(subst _SPACE_,$(SPACE),$$(join $$(addprefix -clean_SPACE_,$2), \ |
103 |
$$(addprefix _SPACE_, $$($1_PROPOUTPUT)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
104 |
endef |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
105 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
106 |
# Some packages contain pregenerated java files instead of properties files. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
107 |
# But unfortunately not all properties should be converted, some should be |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
108 |
# copied....argggghhh. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
109 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
110 |
# For example: |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
111 |
# sun/applet/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
112 |
# sun/misc/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
113 |
# sun/text/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
114 |
# sun/tools/jconsole/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
115 |
# sun/tools/native2ascii/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
116 |
# sun/util/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
117 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
118 |
# Some packages have properties that need to be converted to java source files. |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
119 |
|
13702 | 120 |
#com/apple/laf/resources |
20547 | 121 |
ifeq ($(OPENJDK_TARGET_OS), macosx) |
122 |
$(eval $(call add_properties_to_compile,COM_APPLE_LAF, \ |
|
123 |
$(filter %.properties, \ |
|
124 |
$(call CacheFind, $(JDK_TOPDIR)/src/macosx/classes/com/apple/laf/resources)), \ |
|
125 |
ListResourceBundle)) |
|
13702 | 126 |
endif |
127 |
||
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
128 |
#com/sun/accessibility/internal/resources |
20547 | 129 |
$(eval $(call add_properties_to_compile,COM_SUN_ACCESSIBILITY, \ |
130 |
$(filter %.properties, \ |
|
131 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/accessibility/internal/resources)), \ |
|
132 |
ListResourceBundle)) |
|
133 |
$(eval $(call add_properties_to_compile,COM_SUN_ACCESSIBILITY_HK, \ |
|
134 |
$(filter %.properties, \ |
|
135 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/accessibility/internal/resources)), \ |
|
136 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
137 |
#com/sun/imageio/plugins/common |
20547 | 138 |
$(eval $(call add_properties_to_clean,COM_SUN_IMAGEIO, \ |
139 |
$(filter %.properties, \ |
|
140 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/imageio)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
141 |
#com/sun/java/swing/plaf/gtk/resources |
13164 | 142 |
ifneq ($(OPENJDK_TARGET_OS), windows) |
20547 | 143 |
# Only compile GTK resource bundles on Solaris/Linux |
144 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_GTK, \ |
|
145 |
$(filter %.properties, \ |
|
146 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/gtk/resources)), \ |
|
147 |
ListResourceBundle)) |
|
148 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_GTK_HK, \ |
|
149 |
$(filter %.properties, \ |
|
150 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/gtk/resources)), \ |
|
151 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12892 | 152 |
endif |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
153 |
#com/sun/java/swing/plaf/motif/resources |
20547 | 154 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_MOTIF, \ |
155 |
$(filter %.properties, \ |
|
156 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/motif/resources)), \ |
|
157 |
ListResourceBundle)) |
|
158 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_MOTIF_HK, \ |
|
159 |
$(filter %.properties, \ |
|
160 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/motif/resources)), \ |
|
161 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
162 |
#com/sun/java/swing/plaf/windows/resources |
20547 | 163 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_WINDOWS, \ |
164 |
$(filter %.properties, \ |
|
165 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/windows/resources)), \ |
|
166 |
ListResourceBundle)) |
|
167 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_WINDOWS_HK, \ |
|
168 |
$(filter %.properties, \ |
|
169 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/java/swing/plaf/windows/resources)), \ |
|
170 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
171 |
#com/sun/java/util/jar/pack |
20547 | 172 |
$(eval $(call add_properties_to_clean,JNDI_COSNAMING, \ |
173 |
$(JDK_TOPDIR)/src/share/classes/com/sun/java/util/jar/pack/intrinsic.properties)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
174 |
#com/sun/jndi/cosnaming |
20547 | 175 |
$(eval $(call add_properties_to_clean,JNDI_COSNAMING, \ |
176 |
$(JDK_TOPDIR)/src/share/classes/com/sun/jndi/cosnaming/jndiprovider.properties)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
177 |
#com/sun/jndi/ldap |
20547 | 178 |
$(eval $(call add_properties_to_clean,JNDI_COSNAMING, \ |
179 |
$(JDK_TOPDIR)/src/share/classes/com/sun/jndi/ldap/jndiprovider.properties)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
180 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
181 |
#com/sun/org/apache/xml/internal/security/resource |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
182 |
#FIXME: The "xmlsecurity*.properties" pattern is not ideal; we might want to find |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
183 |
#a better way to select the properties files that are needed. |
20547 | 184 |
$(eval $(call add_properties_to_clean,XML_SECURITY, \ |
185 |
$(filter $(JDK_TOPDIR)/src/share/classes/com/sun/org/apache/xml/internal/security/resource/xmlsecurity%.properties, \ |
|
186 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/org/apache/xml/internal/security/resource)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
187 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
188 |
#com/sun/rowset |
20547 | 189 |
$(eval $(call add_properties_to_clean,COM_SUN_ROWSET, \ |
190 |
$(filter %.properties, \ |
|
191 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/rowset)))) |
|
192 |
$(eval $(call add_properties_to_clean,COM_SUN_ROWSET_HK, \ |
|
193 |
$(filter %zh_TW.properties, \ |
|
194 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/rowset)), \ |
|
195 |
%zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
196 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
197 |
#com/sun/swing/internal/plaf/basic/resources |
20547 | 198 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_BASIC, \ |
199 |
$(filter %.properties, \ |
|
200 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/basic/resources)), \ |
|
201 |
ListResourceBundle)) |
|
202 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_BASIC_HK, \ |
|
203 |
$(filter %.properties, \ |
|
204 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/basic/resources)), \ |
|
205 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
206 |
#com/sun/swing/internal/plaf/metal/resources |
20547 | 207 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_METAL, \ |
208 |
$(filter %.properties, \ |
|
209 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/metal/resources)), \ |
|
210 |
ListResourceBundle)) |
|
211 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_METAL_HK, \ |
|
212 |
$(filter %.properties, $(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/metal/resources)), \ |
|
213 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
214 |
#com/sun/swing/internal/plaf/synth/resources |
20547 | 215 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_SYNTH, \ |
216 |
$(filter %.properties, \ |
|
217 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/synth/resources)), \ |
|
218 |
ListResourceBundle)) |
|
219 |
$(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_SYNTH_HK, \ |
|
220 |
$(filter %.properties, \ |
|
221 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/swing/internal/plaf/synth/resources)), \ |
|
222 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
223 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
224 |
#com/sun/tools/jdi/resources |
20547 | 225 |
$(eval $(call add_properties_to_compile,COM_SUN_TOOLS_JDI, \ |
226 |
$(filter %.properties, \ |
|
227 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/com/sun/tools/jdi/resources)), \ |
|
228 |
ListResourceBundle)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
229 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
230 |
#com/sun/tools/script/shell |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
231 |
#java/util |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
232 |
#javax/sql/rowset |
20547 | 233 |
$(eval $(call add_properties_to_clean,JAVAX_SQL_ROWSET, \ |
234 |
$(filter %.properties, \ |
|
235 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/javax/sql/rowset)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
236 |
#sun/awt/resources |
20547 | 237 |
$(eval $(call add_properties_to_compile,SUN_AWT, \ |
238 |
$(filter %.properties, \ |
|
239 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/awt/resources)), \ |
|
240 |
ListResourceBundle)) |
|
241 |
$(eval $(call add_properties_to_compile,SUN_AWT_HK, \ |
|
242 |
$(filter %.properties, \ |
|
243 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/awt/resources)), \ |
|
244 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
13702 | 245 |
#sun/awt/windows/ |
20547 | 246 |
ifeq ($(OPENJDK_TARGET_OS), windows) |
247 |
$(eval $(call add_properties_to_compile,SUN_AWT, \ |
|
248 |
$(filter $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows/awtLocalization%.properties, \ |
|
249 |
$(call CacheFind, $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows)), \ |
|
250 |
ListResourceBundle)) |
|
251 |
$(eval $(call add_properties_to_compile,SUN_AWT_HK, \ |
|
252 |
$(filter $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows/awtLocalization%.properties, \ |
|
253 |
$(call CacheFind, $(JDK_TOPDIR)/src/windows/classes/sun/awt/windows)), \ |
|
254 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
13702 | 255 |
endif |
20147
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
256 |
# os x specific awt properties |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
257 |
ifeq ($(OPENJDK_TARGET_OS),macosx) |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
258 |
$(eval $(call add_properties_to_compile,SUN_AWT,\ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
259 |
$(filter $(JDK_TOPDIR)/src/macosx/classes/sun/awt/resources/%.properties,\ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
260 |
$(call CacheFind,$(JDK_TOPDIR)/src/macosx/classes/sun/awt/resources)),\ |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
261 |
ListResourceBundle)) |
78e51d8fcb92
7129133: [macosx] Accelerators are displayed as Meta instead of the Command symbol
leonidr
parents:
16507
diff
changeset
|
262 |
endif |
13702 | 263 |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
264 |
#sun/launcher/resources |
20547 | 265 |
$(eval $(call add_properties_to_compile,SUN_LAUNCHER, \ |
266 |
$(filter %.properties, \ |
|
267 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/launcher/resources)), \ |
|
268 |
ListResourceBundle)) |
|
269 |
$(eval $(call add_properties_to_compile,SUN_LAUNCHER_HK, \ |
|
270 |
$(filter %.properties, \ |
|
271 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/launcher/resources)), \ |
|
272 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
273 |
#sun/management/resources |
20547 | 274 |
$(eval $(call add_properties_to_compile,SUN_MANAGEMENT, \ |
275 |
$(filter %.properties, \ |
|
276 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/management/resources)), \ |
|
277 |
ListResourceBundle)) |
|
278 |
$(eval $(call add_properties_to_compile,SUN_MANAGEMENT_KH, \ |
|
279 |
$(filter %.properties, \ |
|
280 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/management/resources)), \ |
|
281 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
282 |
#sun/print |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
283 |
#sun/print/resources |
20547 | 284 |
$(eval $(call add_properties_to_compile,SUN_PRINT, \ |
285 |
$(filter %.properties, \ |
|
286 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/print/resources)), \ |
|
287 |
ListResourceBundle)) |
|
288 |
$(eval $(call add_properties_to_compile,SUN_PRINT_HK, \ |
|
289 |
$(filter %.properties, \ |
|
290 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/print/resources)), \ |
|
291 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
292 |
#sun/rmi/registry/resources |
20547 | 293 |
$(eval $(call add_properties_to_clean,SUN_RMI_REGISTRY, \ |
294 |
$(filter %.properties, \ |
|
295 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/rmi/registry/resources)))) |
|
296 |
$(eval $(call add_properties_to_clean,SUN_RMI_REGISTRY_HK, \ |
|
297 |
$(filter %zh_TW.properties, \ |
|
298 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/rmi/registry/resources)), \ |
|
299 |
%zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
300 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
301 |
#sun/rmi/rmic/resources |
20547 | 302 |
$(eval $(call add_properties_to_clean,SUN_RMI_RMIC, \ |
303 |
$(filter %.properties, \ |
|
304 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/rmi/rmic/resources)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
305 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
306 |
#sun/rmi/server/resources |
20547 | 307 |
$(eval $(call add_properties_to_clean,SUN_RMI_SERVER, \ |
308 |
$(filter %.properties, \ |
|
309 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/rmi/server/resources)))) |
|
310 |
$(eval $(call add_properties_to_clean,SUN_RMI_SERVER_HK, \ |
|
311 |
$(filter %zh_TW.properties, \ |
|
312 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/rmi/server/resources)), \ |
|
313 |
%zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
314 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
315 |
# sun/tools/jar/resources |
20547 | 316 |
$(eval $(call add_properties_to_compile,SUN_TOOLS_JAR, \ |
317 |
$(filter %.properties, \ |
|
318 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/tools/jar/resources)), \ |
|
319 |
ListResourceBundle)) |
|
320 |
$(eval $(call add_properties_to_compile,SUN_TOOLS_JAR_HK, \ |
|
321 |
$(filter %.properties, \ |
|
322 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/tools/jar/resources)), \ |
|
323 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
324 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
325 |
#sun/tools/javac/resources |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
326 |
# It's unclear if the other localized property files here are supposed to be copied or not |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
327 |
# but the old build system didn't copy them. |
20547 | 328 |
$(eval $(call add_properties_to_clean,SUN_TOOLS_SERIALVER, \ |
329 |
$(filter %javac.properties, \ |
|
330 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/tools/javac/resources)))) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
331 |
|
13164 | 332 |
#sun/tools/jconsole/resources |
20547 | 333 |
$(eval $(call add_properties_to_clean,SUN_TOOLS_JCONSOLE, \ |
334 |
$(filter %.properties, \ |
|
335 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/tools/jconsole/resources)))) |
|
13164 | 336 |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
337 |
#sun/tools/serialver |
20547 | 338 |
$(eval $(call add_properties_to_clean,SUN_TOOLS_SERIALVER, \ |
339 |
$(filter %.properties, \ |
|
340 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/tools/serialver)), , ,resources)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
341 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
342 |
#sun/util/logging/resources |
20547 | 343 |
$(eval $(call add_properties_to_compile,SUN_UTIL_LOGGING, \ |
344 |
$(filter %.properties, \ |
|
345 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/util/logging/resources)), \ |
|
346 |
ListResourceBundle)) |
|
347 |
$(eval $(call add_properties_to_compile,SUN_UTIL_LOGGING_HK, \ |
|
348 |
$(filter %.properties, \ |
|
349 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/util/logging/resources)), \ |
|
350 |
ListResourceBundle, %zh_TW, %zh_HK)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
351 |
# sun/util/resources |
20547 | 352 |
$(eval $(call add_properties_to_compile,SUN_UTIL, \ |
353 |
$(filter %.properties, \ |
|
354 |
$(call CacheFind, $(JDK_TOPDIR)/src/share/classes/sun/util/resources)), \ |
|
355 |
sun.util.resources.LocaleNamesBundle)) |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
356 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
357 |
# Now setup the rule for the generation of the resource bundles. |
20547 | 358 |
$(JDK_OUTPUTDIR)/gensrc/_the.compiled_properties: $(ALL_COMPILED_PROPSOURCES) $(BUILD_TOOLS) |
359 |
# Generate all output directories in advance since the build tool does not do that... |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
360 |
$(MKDIR) -p $(sort $(dir $(ALL_COMPILED_PROPJAVAS))) |
12892 | 361 |
$(ECHO) Compiling $(words $(ALL_COMPILED_PROPSOURCES)) properties into resource bundles |
14231 | 362 |
$(call ListPathsSafely,COMPILE_PROPCMDLINE,\n, >> $(JDK_OUTPUTDIR)/gensrc/_the.cmdline) |
363 |
$(TOOL_COMPILEPROPERTIES) -quiet @$(JDK_OUTPUTDIR)/gensrc/_the.cmdline |
|
12892 | 364 |
$(TOUCH) $@ |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
365 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
366 |
# Now setup the rule for the generation of the cleaned properties. |
20547 | 367 |
# FIXME: We currently don't handle removed properties incrementally. |
368 |
$(JDK_OUTPUTDIR)/classes/_the.cleaned_properties: $(ALL_CLEANED_PROPSOURCES) $(BUILD_TOOLS) |
|
13702 | 369 |
$(RM) $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties.cmdline |
20547 | 370 |
# Generate all output directories in advance since the build tool does not do that... |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
371 |
$(MKDIR) -p $(sort $(dir $(ALL_CLEANED_PROPOUTPUT))) |
20547 | 372 |
$(ECHO) Copying and cleaning $(words $(ALL_CLEANED_PROPSOURCES)) properties |
12892 | 373 |
$(call ListPathsSafely,CLEAN_PROPCMDLINE,\n, >> $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties.cmdline) |
374 |
$(TOOL_STRIPPROPERTIES) @$(JDK_OUTPUTDIR)/classes/_the.cleaned_properties.cmdline |
|
375 |
$(TOUCH) $@ |
|
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
376 |
|
20547 | 377 |
$(ALL_COMPILED_PROPJAVAS): $(JDK_OUTPUTDIR)/gensrc/_the.compiled_properties |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
378 |
|
20547 | 379 |
$(ALL_CLEANED_PROPOUTPUT): $(JDK_OUTPUTDIR)/classes/_the.cleaned_properties |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
380 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
381 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
382 |
# Some zh_HK resources are just copied of zh_TW |
14231 | 383 |
$(JDK_OUTPUTDIR)/gensrc/%_zh_HK.java: $(JDK_TOPDIR)/src/share/classes/%_zh_TW.java |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
384 |
$(MKDIR) -p $(@D) |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
385 |
$(CAT) $< | $(SED) -e '/class/s/_zh_TW/_zh_HK/' > $@ |
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
386 |
|
20547 | 387 |
ZH_HK_JAVA := sun/applet/resources/MsgAppletViewer_zh_HK.java \ |
388 |
sun/misc/resources/Messages_zh_HK.java \ |
|
389 |
sun/security/util/AuthResources_zh_HK.java \ |
|
390 |
sun/security/util/Resources_zh_HK.java |
|
12892 | 391 |
|
20547 | 392 |
ZH_HK_JAVA_FILES := $(addprefix $(JDK_OUTPUTDIR)/gensrc/, $(ZH_HK_JAVA)) |
12317
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
393 |
|
9670c1610c53
7074397: Build infrastructure changes (makefile re-write)
ohair
parents:
diff
changeset
|
394 |
|
20547 | 395 |
GENSRC_PROPERTIES := $(ALL_COMPILED_PROPJAVAS) $(ALL_CLEANED_PROPOUTPUT) $(ZH_HK_JAVA_FILES) |