diff --git a/make/launchers/Makefile b/make/launchers/Makefile index be16512e478a69920406fb607f0fc2b20a65b5cc..476451587938060e0b14fe54856373c9cd180c69 100644 --- a/make/launchers/Makefile +++ b/make/launchers/Makefile @@ -77,6 +77,7 @@ $(call make-launcher, jmap, sun.tools.jmap.JMap, \ -J-Dsun.jvm.hotspot.debugger.useWindbgDebugger, ) $(call make-launcher, jps, sun.tools.jps.Jps, , ) $(call make-launcher, jrunscript, com.sun.tools.script.shell.Main, , ) +$(call make-launcher, jjs, jdk.nashorn.tools.Shell, , ) $(call make-launcher, jsadebugd, sun.jvm.hotspot.jdi.SADebugServer, , ) $(call make-launcher, jstack, sun.tools.jstack.JStack, \ -J-Dsun.jvm.hotspot.debugger.useProcDebugger \ diff --git a/make/tools/src/build/tools/deps/refs.allowed b/make/tools/src/build/tools/deps/refs.allowed index 91605d535febd4b246ab1aa9a8f2991e14379526..ad9d5271199032d6ad507198a76ec42eaf4426eb 100644 --- a/make/tools/src/build/tools/deps/refs.allowed +++ b/make/tools/src/build/tools/deps/refs.allowed @@ -33,8 +33,3 @@ sun.security.krb5.Realm=sun.security.ssl.krb5.KerberosClientKeyExchangeImpl,comp # java.beans.PropertyChangeListener=java.util.logging.LogManager,sun.org.mozilla.javascript.internal.Context,compact1,compact2,compact3 java.beans.PropertyChangeEvent=sun.org.mozilla.javascript.internal.Context,compact3 - -# JFR traces even in builds with JFR disabled -com.oracle.jrockit.jfr.FlightRecorder: com.sun.management.MissionControl, compact3 -com.oracle.jrockit.jfr.management.FlightRecorderMBean: com.sun.management.MissionControl, compact3 - diff --git a/makefiles/CompileLaunchers.gmk b/makefiles/CompileLaunchers.gmk index 170dc164ec4061cab7fc7071a9ff3be12faee3d6..501c986082e2c977a7690ad447d1ae2751860aa8 100644 --- a/makefiles/CompileLaunchers.gmk +++ b/makefiles/CompileLaunchers.gmk @@ -311,6 +311,9 @@ $(eval $(call SetupLauncher,jps,\ $(eval $(call SetupLauncher,jrunscript,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "com.sun.tools.script.shell.Main"$(COMMA) }')) +$(eval $(call SetupLauncher,jjs,\ + -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "jdk.nashorn.tools.Shell"$(COMMA) }')) + $(eval $(call SetupLauncher,jsadebugd,\ -DJAVA_ARGS='{ "-J-ms8m"$(COMMA) "sun.jvm.hotspot.jdi.SADebugServer"$(COMMA) }' \ -DAPP_CLASSPATH='{ "/lib/tools.jar"$(COMMA) "/lib/sa-jdi.jar"$(COMMA) "/classes" }' \ diff --git a/makefiles/CreateJars.gmk b/makefiles/CreateJars.gmk index 7e33790d299d184fccd830744c9a3f0cda9c694e..857e0d5e9a4ea9ee9a8e8421c7f78c07d8cc67d9 100644 --- a/makefiles/CreateJars.gmk +++ b/makefiles/CreateJars.gmk @@ -1119,6 +1119,14 @@ endif ########################################################################################## +# Import nashorn.jar from nashorn dist dir. +$(IMAGES_OUTPUTDIR)/lib/ext/nashorn.jar: $(NASHORN_DIST)/nashorn.jar + $(install-file) + +JARS += $(IMAGES_OUTPUTDIR)/lib/ext/nashorn.jar + +########################################################################################## + -include $(CUSTOM_MAKE_DIR)/CreateJars.gmk ########################################################################################## diff --git a/src/share/classes/java/lang/Deprecated.java b/src/share/classes/java/lang/Deprecated.java index 2b1546bc64b2e208dfd1c3a5bdcbde725100115f..58a0691f0540b01f776b23c6fe9de10125f55d5f 100644 --- a/src/share/classes/java/lang/Deprecated.java +++ b/src/share/classes/java/lang/Deprecated.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, 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 @@ -36,6 +36,7 @@ import static java.lang.annotation.ElementType.*; * * @author Neal Gafter * @since 1.5 + * @jls 9.6.3.6 @Deprecated */ @Documented @Retention(RetentionPolicy.RUNTIME) diff --git a/src/share/classes/java/lang/Override.java b/src/share/classes/java/lang/Override.java index ea6e54a151e48f43efb71d65061951a1ff200d30..bf77344296cb6f07b940fc132e5a6a3963c4650a 100644 --- a/src/share/classes/java/lang/Override.java +++ b/src/share/classes/java/lang/Override.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, 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 @@ -43,7 +43,7 @@ import java.lang.annotation.*; * * @author Peter von der Ahé * @author Joshua Bloch - * @jls 9.6.1.4 Override + * @jls 9.6.1.4 @Override * @since 1.5 */ @Target(ElementType.METHOD) diff --git a/src/share/classes/java/lang/SafeVarargs.java b/src/share/classes/java/lang/SafeVarargs.java index cb14134ffbe35dfa8f69c31b0a3b352c863f5917..6fcd48e97d7ab512045dad793d11dd397c0c821a 100644 --- a/src/share/classes/java/lang/SafeVarargs.java +++ b/src/share/classes/java/lang/SafeVarargs.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2010, 2013, 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 @@ -85,6 +85,7 @@ import java.lang.annotation.*; * @since 1.7 * @jls 4.7 Reifiable Types * @jls 8.4.1 Formal Parameters + * @jls 9.6.3.7 @SafeVarargs */ @Documented @Retention(RetentionPolicy.RUNTIME) diff --git a/src/share/classes/java/lang/SuppressWarnings.java b/src/share/classes/java/lang/SuppressWarnings.java index babb060396a5be0da5ebb550497c86f3736c39cc..22895dc7b2cef9fe39c3c32900280bf083183663 100644 --- a/src/share/classes/java/lang/SuppressWarnings.java +++ b/src/share/classes/java/lang/SuppressWarnings.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2004, 2013, 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 @@ -41,8 +41,13 @@ import static java.lang.annotation.ElementType.*; * suppress a warning in a particular method, you should annotate that * method rather than its class. * - * @since 1.5 * @author Josh Bloch + * @since 1.5 + * @jls 4.8 Raw Types + * @jls 4.12.2 Variables of Reference Type + * @jls 5.1.9 Unchecked Conversion + * @jls 5.5.2 Checked Casts and Unchecked Casts + * @jls 9.6.3.5 @SuppressWarnings */ @Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE}) @Retention(RetentionPolicy.SOURCE) @@ -56,9 +61,11 @@ public @interface SuppressWarnings { * free to emit a warning if an annotation contains an unrecognized * warning name. * - *

Compiler vendors should document the warning names they support in - * conjunction with this annotation type. They are encouraged to cooperate - * to ensure that the same names work across multiple compilers. + *

The string {@code "unchecked"} is used to suppress + * unchecked warnings. Compiler vendors should document the + * additional warning names they support in conjunction with this + * annotation type. They are encouraged to cooperate to ensure + * that the same names work across multiple compilers. */ String[] value(); } diff --git a/src/share/classes/java/lang/annotation/Inherited.java b/src/share/classes/java/lang/annotation/Inherited.java index a7efa6b41d2477de3043f503d708a535c197052f..83391e29eac4b93cbc48b927142ee7e4251a8731 100644 --- a/src/share/classes/java/lang/annotation/Inherited.java +++ b/src/share/classes/java/lang/annotation/Inherited.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, 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 @@ -44,6 +44,7 @@ package java.lang.annotation; * * @author Joshua Bloch * @since 1.5 + * @jls 9.6.3.3 @Inherited */ @Documented @Retention(RetentionPolicy.RUNTIME) diff --git a/src/share/classes/java/lang/annotation/Retention.java b/src/share/classes/java/lang/annotation/Retention.java index df04a31db90ab521b74ce47ca6cf53d9c8b02dd1..1c27ca0871eb0723acdd16145ba47a5b2b39d98b 100644 --- a/src/share/classes/java/lang/annotation/Retention.java +++ b/src/share/classes/java/lang/annotation/Retention.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2006, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, 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 @@ -38,6 +38,7 @@ package java.lang.annotation; * * @author Joshua Bloch * @since 1.5 + * @jls 9.6.3.2 @Retention */ @Documented @Retention(RetentionPolicy.RUNTIME) diff --git a/src/share/classes/java/lang/annotation/Target.java b/src/share/classes/java/lang/annotation/Target.java index dc67de3f071077ad77c1333c66132f378d2b3079..cdf4a748ae5aae3a5a94592165de32bfb22a86f9 100644 --- a/src/share/classes/java/lang/annotation/Target.java +++ b/src/share/classes/java/lang/annotation/Target.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2003, 2004, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2003, 2013, 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 @@ -59,6 +59,9 @@ package java.lang.annotation; * ... * } * + * + * @since 1.5 + * @jls 9.6.3.1 @Target */ @Documented @Retention(RetentionPolicy.RUNTIME) diff --git a/test/ProblemList.txt b/test/ProblemList.txt index 7c621e00884dba5dd56393f1e31c30cb35d703e0..7adc6d2c660bc3127bfcddb8c80716a3304ab084 100644 --- a/test/ProblemList.txt +++ b/test/ProblemList.txt @@ -327,9 +327,6 @@ tools/pack200/Pack200Test.java solaris-all, mac # 7150569 tools/launcher/UnicodeTest.java macosx-all -# 8006039 -tools/launcher/I18NJarTest.java macosx-all - # 8007410 tools/launcher/FXLauncherTest.java linux-all diff --git a/test/tools/launcher/I18NJarTest.java b/test/tools/launcher/I18NJarTest.java index 9c033b47f8f507a8e279d0d46712d4e17fa68828..ad94abcce64fe711801418592fd9ce3f433f4a82 100644 --- a/test/tools/launcher/I18NJarTest.java +++ b/test/tools/launcher/I18NJarTest.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2013, 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 @@ -52,6 +52,8 @@ public class I18NJarTest extends TestHelper { private static final File cwd = new File("."); private static final File dir = new File("\uFF66\uFF67\uFF68\uFF69"); private static final String encoding = System.getProperty("sun.jnu.encoding", ""); + private static final String LANG = System.getenv("LANG"); + private static final String LC_ALL = System.getenv("LC_ALL"); public static void main(String... args) throws Exception { boolean localeAvailable = false; @@ -63,7 +65,16 @@ public class I18NJarTest extends TestHelper { } if (!localeAvailable) { System.out.println("Warning: locale: " + Locale.JAPAN - + " not found, test passes vacuosly"); + + " not found, test passes vacuously"); + return; + } + if ("C".equals(LC_ALL) || "C".equals(LANG)) { + System.out.println("Warning: The LANG and/or LC_ALL env vars are " + + "set to \"C\":\n" + + " LANG=" + LANG + "\n" + + " LC_ALL=" + LC_ALL + "\n" + + "This test requires support for multi-byte filenames.\n" + + "Test passes vacuously."); return; } if (encoding.equals("MS932") || encoding.equals("UTF-8")) { @@ -73,7 +84,7 @@ public class I18NJarTest extends TestHelper { } else { System.out.println("Warning: current encoding is " + encoding + "this test requires MS932 or UTF-8," + - " test passes vacuosly"); + " test passes vacuously"); return; } dir.mkdir(); diff --git a/test/tools/launcher/VersionCheck.java b/test/tools/launcher/VersionCheck.java index 11f65cb2e9a07ca00b7b455580e9a7d4fec8d378..64f0e6adfb84016d03cdd4016aa4c7f52488cb8b 100644 --- a/test/tools/launcher/VersionCheck.java +++ b/test/tools/launcher/VersionCheck.java @@ -74,6 +74,7 @@ public class VersionCheck extends TestHelper { "jmap", "jps", "jrunscript", + "jjs", "jsadebugd", "jstack", "jstat",