8207243: Fix translation filtering to also support zh_HK and zh_TW

Reviewed-by: tbell
This commit is contained in:
Erik Joelsson 2018-07-19 14:25:42 -07:00
parent 67d90233b1
commit 9d7fc64c38
4 changed files with 12 additions and 7 deletions

View File

@ -621,9 +621,14 @@ $(JDK_OUTPUTDIR)/modules/%_zh_HK.properties: $(JDK_OUTPUTDIR)/modules/%_zh_TW.pr
$(install-file) $(install-file)
CreateHkTargets = \ CreateHkTargets = \
$(patsubst $(TOPDIR)/src/%, $(JDK_OUTPUTDIR)/modules/%, \ $(call FilterExcludedTranslations, \
$(subst /share/classes,, \ $(patsubst $(TOPDIR)/src/%, $(JDK_OUTPUTDIR)/modules/%, \
$(subst _zh_TW,_zh_HK, $(filter %_zh_TW.properties, $1)))) $(subst /share/classes,, \
$(subst _zh_TW,_zh_HK, $(filter %_zh_TW.properties, $1)) \
) \
), \
.properties \
)
ifeq ($(MODULE), java.sql.rowset) ifeq ($(MODULE), java.sql.rowset)
TARGETS += $(call CreateHkTargets, $(java.sql.rowset_CLEAN_FILES)) TARGETS += $(call CreateHkTargets, $(java.sql.rowset_CLEAN_FILES))

View File

@ -242,7 +242,7 @@ var getJibProfilesCommon = function (input, data) {
dependencies: ["boot_jdk", "gnumake", "jtreg", "jib", "autoconf"], dependencies: ["boot_jdk", "gnumake", "jtreg", "jib", "autoconf"],
default_make_targets: ["product-bundles", "test-bundles"], default_make_targets: ["product-bundles", "test-bundles"],
configure_args: concat(["--enable-jtreg-failure-handler"], configure_args: concat(["--enable-jtreg-failure-handler"],
"--with-exclude-translations=de,es,fr,it,ko,pt_BR,sv,ca,tr,cs,sk,ja_JP_A,ja_JP_HA,ja_JP_HI,ja_JP_I", "--with-exclude-translations=de,es,fr,it,ko,pt_BR,sv,ca,tr,cs,sk,ja_JP_A,ja_JP_HA,ja_JP_HI,ja_JP_I,zh_TW,zh_HK",
versionArgs(input, common)) versionArgs(input, common))
}; };
// Extra settings for debug profiles // Extra settings for debug profiles

View File

@ -45,7 +45,7 @@ public class VerifyTranslations {
* The set of translations we want to see in an Oracle built image * The set of translations we want to see in an Oracle built image
*/ */
private static final Set<String> VALID_TRANSLATION_SUFFIXES = Set.of( private static final Set<String> VALID_TRANSLATION_SUFFIXES = Set.of(
"_en", "_en_US", "_en_US_POSIX", "_ja", "_zh_CN", "_zh_TW", "_zh_HK" "_en", "_en_US", "_en_US_POSIX", "_ja", "_zh_CN"
); );
/** /**

View File

@ -37,8 +37,8 @@ public class LocalizedLevelName {
"SEVERE", Locale.ENGLISH, "Severe", Level.SEVERE, "SEVERE", Locale.ENGLISH, "Severe", Level.SEVERE,
"WARNING", Locale.JAPANESE, "\u8B66\u544A", Level.WARNING, "WARNING", Locale.JAPANESE, "\u8B66\u544A", Level.WARNING,
"INFO", Locale.SIMPLIFIED_CHINESE, "\u4FE1\u606F", Level.INFO, "INFO", Locale.SIMPLIFIED_CHINESE, "\u4FE1\u606F", Level.INFO,
"SEVERE", Locale.TRADITIONAL_CHINESE, "\u56B4\u91CD", Level.SEVERE, "SEVERE", Locale.SIMPLIFIED_CHINESE, "\u4E25\u91CD", Level.SEVERE,
"CONFIG", Locale.forLanguageTag("zh-HK"), "\u7D44\u614B", Level.CONFIG, "CONFIG", Locale.forLanguageTag("zh-CN"), "\u914D\u7F6E", Level.CONFIG,
"ALL", Locale.ROOT, "All", Level.ALL, "ALL", Locale.ROOT, "All", Level.ALL,
"SEVERE", Locale.ROOT, "Severe", Level.SEVERE, "SEVERE", Locale.ROOT, "Severe", Level.SEVERE,
"WARNING", Locale.ROOT, "Warning", Level.WARNING, "WARNING", Locale.ROOT, "Warning", Level.WARNING,