# HG changeset patch # User amurillo # Date 1446490049 28800 # Node ID 22282d943f3a170f4bd45da3b1c665f36dc97064 # Parent 3fadd7701c2fd33c0523d9990a53b0a6c36f67e1# Parent 3429cce328396ce7285562963a85779f5039d9b2 Merge diff -r 3fadd7701c2f -r 22282d943f3a jdk/src/java.base/share/classes/java/util/spi/LocaleServiceProvider.java --- a/jdk/src/java.base/share/classes/java/util/spi/LocaleServiceProvider.java Fri Oct 30 12:03:09 2015 -0700 +++ b/jdk/src/java.base/share/classes/java/util/spi/LocaleServiceProvider.java Mon Nov 02 10:47:29 2015 -0800 @@ -123,25 +123,27 @@ *
* For example, if the following is specified in the property: *
- * java.locale.providers=SPI,CLDR,JRE + * java.locale.providers=SPI,CLDR,COMPAT ** the locale sensitive services in the SPI providers are looked up first. If the * desired locale sensitive service is not available, then the runtime looks for CLDR, - * JRE in that order. + * COMPAT in that order. *
- * The default order for looking up the preferred locale providers is "CLDR,JRE", - * so specifying "CLDR,JRE" is identical to the default behavior. Applications which + * The default order for looking up the preferred locale providers is "CLDR,COMPAT", + * so specifying "CLDR,COMPAT" is identical to the default behavior. Applications which * require implementations of the locale sensitive services must explicitly specify * "SPI" in order for the Java runtime to load them from the classpath. * diff -r 3fadd7701c2f -r 22282d943f3a jdk/src/java.base/share/classes/sun/util/locale/provider/LocaleProviderAdapter.java --- a/jdk/src/java.base/share/classes/sun/util/locale/provider/LocaleProviderAdapter.java Fri Oct 30 12:03:09 2015 -0700 +++ b/jdk/src/java.base/share/classes/sun/util/locale/provider/LocaleProviderAdapter.java Mon Nov 02 10:47:29 2015 -0800 @@ -124,6 +124,10 @@ if (order != null && order.length() != 0) { String[] types = order.split(","); for (String type : types) { + type = type.trim().toUpperCase(Locale.ROOT); + if (type.equals("COMPAT")) { + type = "JRE"; + } try { Type aType = Type.valueOf(type.trim().toUpperCase(Locale.ROOT)); if (!typeList.contains(aType)) { diff -r 3fadd7701c2f -r 22282d943f3a jdk/test/java/util/Locale/LocaleProviders.sh --- a/jdk/test/java/util/Locale/LocaleProviders.sh Fri Oct 30 12:03:09 2015 -0700 +++ b/jdk/test/java/util/Locale/LocaleProviders.sh Mon Nov 02 10:47:29 2015 -0800 @@ -1,6 +1,6 @@ #!/bin/sh # -# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved. # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. # # This code is free software; you can redistribute it and/or modify it @@ -24,7 +24,7 @@ # # @test # @bug 6336885 7196799 7197573 7198834 8000245 8000615 8001440 8008577 -# 8010666 8013086 8013233 8013903 8015960 8028771 +# 8010666 8013086 8013233 8013903 8015960 8028771 8062006 # @summary tests for "java.locale.providers" system property # @compile -XDignore.symbol.file LocaleProviders.java # @run shell/timeout=600 LocaleProviders.sh @@ -182,7 +182,7 @@ if [ "${DEFLANG}" != "en" ] && [ "${DEFFMTLANG}" != "en" ]; then PARAM2=en PARAM3=US -elif [ "${DEFLANG}" != "ja" ] && [ "${DEFFMTLANG}" != "ja" ]; then +elif [ "${DEFLANG}" != "ja" ] && [ "${DEFFMTLANG}" != "ja" ]; then PARAM2=ja PARAM3=JP else @@ -200,6 +200,8 @@ PARAM3=US SPICLASSES= runTest +PREFLIST=SPI,COMPAT +runTest # testing the order, variaton #1. This assumes en_GB DateFormat data are available both in JRE & CLDR METHODNAME=adapterTest @@ -209,6 +211,8 @@ PARAM3=GB SPICLASSES= runTest +PREFLIST=CLDR,COMPAT +runTest # testing the order, variaton #2. This assumes en_GB DateFormat data are available both in JRE & CLDR METHODNAME=adapterTest @@ -218,6 +222,8 @@ PARAM3=GB SPICLASSES= runTest +PREFLIST=COMPAT,CLDR +runTest # testing the order, variaton #3 for non-existent locale in JRE assuming "haw" is not in JRE. METHODNAME=adapterTest @@ -227,6 +233,8 @@ PARAM3= SPICLASSES= runTest +PREFLIST=COMPAT,CLDR +runTest # testing the order, variaton #4 for the bug 7196799. CLDR's "zh" data should be used in "zh_CN" METHODNAME=adapterTest @@ -275,6 +283,8 @@ PARAM3= SPICLASSES=${SPIDIR} runTest +PREFLIST=COMPAT +runTest # testing 8000615 fix. METHODNAME=tzNameTest @@ -284,6 +294,8 @@ PARAM3= SPICLASSES=${SPIDIR} runTest +PREFLIST=COMPAT +runTest # testing 8001440 fix. METHODNAME=bug8001440Test @@ -314,6 +326,8 @@ PARAM3= SPICLASSES=${SPIDIR} runTest +PREFLIST=COMPAT,SPI +runTest # testing 8013903 fix. (Windows only) METHODNAME=bug8013903Test @@ -323,12 +337,9 @@ PARAM3= SPICLASSES= runTest -METHODNAME=bug8013903Test PREFLIST=HOST -PARAM1= -PARAM2= -PARAM3= -SPICLASSES= +runTest +PREFLIST=HOST,COMPAT runTest # testing 8027289 fix, if the platform format default is zh_CN @@ -342,12 +353,10 @@ PARAM3= SPICLASSES= runTest - METHODNAME=bug8027289Test + PREFLIST=COMPAT,HOST + runTest PREFLIST=HOST PARAM1=00A5 - PARAM2= - PARAM3= - SPICLASSES= runTest fi diff -r 3fadd7701c2f -r 22282d943f3a jdk/test/sun/security/pkcs11/PKCS11Test.java --- a/jdk/test/sun/security/pkcs11/PKCS11Test.java Fri Oct 30 12:03:09 2015 -0700 +++ b/jdk/test/sun/security/pkcs11/PKCS11Test.java Mon Nov 02 10:47:29 2015 -0800 @@ -539,6 +539,7 @@ osMap.put("Linux-amd64-64", new String[]{ "/usr/lib/x86_64-linux-gnu/", "/usr/lib/x86_64-linux-gnu/nss/", "/usr/lib64/"}); + osMap.put("Linux-ppc64-64", new String[]{"/usr/lib64/"}); osMap.put("Windows-x86-32", new String[]{ PKCS11_BASE + "/nss/lib/windows-i586/".replace('/', SEP)}); osMap.put("Windows-amd64-64", new String[]{