annotate makefiles/GensrcProperties.gmk @ 7280:a4f32e60635c

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