changeset 8071:a195f50617fa

retain only vestigal randomSeed.
author mduigou
date Mon, 08 Apr 2013 15:57:12 -0700
parents 973a4c9b9935 7b4721e4edb4
children cc55bc49dda8
files .hgtags make/com/sun/servicetag/Makefile make/common/Release.gmk make/java/java/FILES_java.gmk make/java/nio/Makefile make/netbeans/common/java-data-no-native.ent make/netbeans/common/shared.xml make/tools/javazic/Makefile make/tools/src/build/tools/javazic/BackEnd.java make/tools/src/build/tools/javazic/Checksum.java make/tools/src/build/tools/javazic/DayOfWeek.java make/tools/src/build/tools/javazic/Gen.java make/tools/src/build/tools/javazic/GenDoc.java make/tools/src/build/tools/javazic/Main.java make/tools/src/build/tools/javazic/Mappings.java make/tools/src/build/tools/javazic/Month.java make/tools/src/build/tools/javazic/Rule.java make/tools/src/build/tools/javazic/RuleDay.java make/tools/src/build/tools/javazic/RuleRec.java make/tools/src/build/tools/javazic/Simple.java make/tools/src/build/tools/javazic/Time.java make/tools/src/build/tools/javazic/Timezone.java make/tools/src/build/tools/javazic/Zone.java make/tools/src/build/tools/javazic/ZoneRec.java make/tools/src/build/tools/javazic/Zoneinfo.java src/macosx/native/sun/osxapp/NSApplicationAWT.m src/share/classes/com/sun/servicetag/BrowserSupport.java src/share/classes/com/sun/servicetag/Installer.java src/share/classes/com/sun/servicetag/LinuxSystemEnvironment.java src/share/classes/com/sun/servicetag/RegistrationData.java src/share/classes/com/sun/servicetag/RegistrationDocument.java src/share/classes/com/sun/servicetag/Registry.java src/share/classes/com/sun/servicetag/ServiceTag.java src/share/classes/com/sun/servicetag/SolarisServiceTag.java src/share/classes/com/sun/servicetag/SolarisSystemEnvironment.java src/share/classes/com/sun/servicetag/SunConnection.java src/share/classes/com/sun/servicetag/SystemEnvironment.java src/share/classes/com/sun/servicetag/UnauthorizedAccessException.java src/share/classes/com/sun/servicetag/Util.java src/share/classes/com/sun/servicetag/WindowsSystemEnvironment.java src/share/classes/com/sun/servicetag/package.html src/share/classes/com/sun/servicetag/resources/Putback-Notes.txt src/share/classes/com/sun/servicetag/resources/javase_5_swordfish.properties src/share/classes/com/sun/servicetag/resources/javase_6_swordfish.properties src/share/classes/com/sun/servicetag/resources/javase_7_swordfish.properties src/share/classes/com/sun/servicetag/resources/javase_servicetag.properties src/share/classes/com/sun/servicetag/resources/jdk_header.png src/share/classes/com/sun/servicetag/resources/product_registration.xsd src/share/classes/com/sun/servicetag/resources/register.html src/share/classes/com/sun/servicetag/resources/register_ja.html src/share/classes/com/sun/servicetag/resources/register_zh_CN.html src/share/classes/java/lang/annotation/InvalidContainerAnnotationError.java src/share/classes/java/lang/invoke/AbstractValidatingLambdaMetafactory.java src/share/classes/java/lang/invoke/InnerClassLambdaMetafactory.java src/share/classes/java/lang/invoke/LambdaMetafactory.java src/share/classes/java/lang/invoke/MethodHandleImpl.java src/share/classes/java/lang/invoke/MethodHandleInfo.java src/share/classes/java/lang/invoke/MethodHandleProxies.java src/share/classes/java/lang/invoke/SerializedLambda.java src/share/classes/java/lang/invoke/TypeConvertingMethodAdapter.java src/share/classes/java/nio/file/Files.java src/share/classes/java/util/Collections.java src/share/classes/java/util/Comparator.java src/share/classes/java/util/Comparators.java src/share/classes/java/util/Hashtable.java src/share/classes/java/util/IdentityHashMap.java src/share/classes/java/util/Map.java src/share/classes/java/util/Optional.java src/share/classes/java/util/OptionalDouble.java src/share/classes/java/util/OptionalInt.java src/share/classes/java/util/OptionalLong.java src/share/classes/java/util/concurrent/ForkJoinPool.java src/share/classes/java/util/concurrent/ForkJoinTask.java src/share/classes/java/util/concurrent/ThreadLocalRandom.java src/share/classes/java/util/concurrent/ThreadPoolExecutor.java src/share/classes/java/util/concurrent/atomic/AtomicInteger.java src/share/classes/java/util/concurrent/atomic/AtomicIntegerFieldUpdater.java src/share/classes/java/util/concurrent/atomic/AtomicLong.java src/share/classes/java/util/concurrent/atomic/AtomicLongFieldUpdater.java src/share/classes/java/util/concurrent/atomic/AtomicReference.java src/share/classes/java/util/concurrent/atomic/AtomicReferenceFieldUpdater.java src/share/classes/java/util/function/BiConsumer.java src/share/classes/java/util/function/BiFunction.java src/share/classes/java/util/function/BiPredicate.java src/share/classes/java/util/function/BinaryOperator.java src/share/classes/java/util/function/BooleanSupplier.java src/share/classes/java/util/function/Consumer.java src/share/classes/java/util/function/DoubleBinaryOperator.java src/share/classes/java/util/function/DoubleConsumer.java src/share/classes/java/util/function/DoubleFunction.java src/share/classes/java/util/function/DoublePredicate.java src/share/classes/java/util/function/DoubleSupplier.java src/share/classes/java/util/function/DoubleUnaryOperator.java src/share/classes/java/util/function/Function.java src/share/classes/java/util/function/IntBinaryOperator.java src/share/classes/java/util/function/IntConsumer.java src/share/classes/java/util/function/IntFunction.java src/share/classes/java/util/function/IntPredicate.java src/share/classes/java/util/function/IntSupplier.java src/share/classes/java/util/function/IntUnaryOperator.java src/share/classes/java/util/function/LongBinaryOperator.java src/share/classes/java/util/function/LongConsumer.java src/share/classes/java/util/function/LongFunction.java src/share/classes/java/util/function/LongPredicate.java src/share/classes/java/util/function/LongSupplier.java src/share/classes/java/util/function/LongUnaryOperator.java src/share/classes/java/util/function/ObjDoubleConsumer.java src/share/classes/java/util/function/ObjIntConsumer.java src/share/classes/java/util/function/ObjLongConsumer.java src/share/classes/java/util/function/Predicate.java src/share/classes/java/util/function/ToDoubleBiFunction.java src/share/classes/java/util/function/ToDoubleFunction.java src/share/classes/java/util/function/ToIntBiFunction.java src/share/classes/java/util/function/ToIntFunction.java src/share/classes/java/util/function/ToLongBiFunction.java src/share/classes/java/util/function/ToLongFunction.java src/share/classes/java/util/function/UnaryOperator.java src/share/classes/java/util/function/package-info.java src/share/classes/java/util/logging/Logger.java src/share/classes/sun/awt/datatransfer/DataTransferer.java src/share/classes/sun/misc/Hashing.java src/share/classes/sun/reflect/Reflection.java src/share/classes/sun/security/util/KeyLength.java src/share/native/common/check_code.c src/share/native/java/lang/System.c src/solaris/native/java/lang/java_props_md.c test/Makefile test/com/sun/servicetag/DeleteServiceTag.java test/com/sun/servicetag/DuplicateNotFound.java test/com/sun/servicetag/FindServiceTags.java test/com/sun/servicetag/InstanceUrnCheck.java test/com/sun/servicetag/InvalidRegistrationData.java test/com/sun/servicetag/InvalidServiceTag.java test/com/sun/servicetag/JavaServiceTagTest.java test/com/sun/servicetag/JavaServiceTagTest1.java test/com/sun/servicetag/NewRegistrationData.java test/com/sun/servicetag/SvcTagClient.java test/com/sun/servicetag/SystemRegistryTest.java test/com/sun/servicetag/TestLoadFromXML.java test/com/sun/servicetag/UpdateServiceTagTest.java test/com/sun/servicetag/Util.java test/com/sun/servicetag/ValidRegistrationData.java test/com/sun/servicetag/environ.properties test/com/sun/servicetag/missing-environ-field.xml test/com/sun/servicetag/newer-registry-version.xml test/com/sun/servicetag/registration.xml test/com/sun/servicetag/servicetag1.properties test/com/sun/servicetag/servicetag2.properties test/com/sun/servicetag/servicetag3.properties test/com/sun/servicetag/servicetag4.properties test/com/sun/servicetag/servicetag5.properties test/java/lang/PrimitiveSumMinMaxTest.java test/java/lang/invoke/lambda/LambdaAccessControlTest.java test/java/lang/invoke/lambda/LambdaSerialization.java test/java/util/Optional/Basic.java test/java/util/Optional/BasicDouble.java test/java/util/Optional/BasicInt.java test/java/util/Optional/BasicLong.java test/javax/script/RhinoExceptionTest.java test/sun/tools/jstat/gcPermCapacityOutput1.awk test/sun/tools/jstat/jstatGcPermCapacityOutput1.sh
diffstat 563 files changed, 14413 insertions(+), 17711 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Thu Apr 04 11:33:40 2013 -0700
+++ b/.hgtags	Mon Apr 08 15:57:12 2013 -0700
@@ -206,3 +206,6 @@
 00b7535d743f83eda763c10b3c9ea19ba4b67f55 jdk8-b78
 c933505d75c2a0a671f06d6dac5d2237a9228d2d jdk8-b79
 dfb40f066c6ce129822f0f5dc2ac89173808781a jdk8-b80
+c0f8022eba536dcdc8aae659005b33f3982b9368 jdk8-b81
+624bcb4800065c6656171948e31ebb2925f25c7a jdk8-b82
+ac519af51769e92c51b597a730974e8607357709 jdk8-b83
--- a/make/com/sun/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/com/sun/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -45,7 +45,7 @@
 SUBDIRS_desktop    = image
 SUBDIRS_enterprise = crypto/provider jndi \
                      org rowset net/httpserver
-SUBDIRS_misc       = $(SCRIPT_SUBDIR) tracing servicetag nio demo
+SUBDIRS_misc       = $(SCRIPT_SUBDIR) tracing nio demo
 
 SUBDIRS_tools      = tools
 
--- a/make/com/sun/org/apache/xml/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/com/sun/org/apache/xml/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -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
@@ -34,6 +34,8 @@
 JAVAC_WARNINGS_FATAL = true
 include $(BUILDDIR)/common/Defs.gmk
 
+JAVAC_LINT_OPTIONS += -Xlint:-overrides
+
 #
 # Files to compile
 #
--- a/make/com/sun/servicetag/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,80 +0,0 @@
-# Copyright (c) 2008, 2011, 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
-# under the terms of the GNU General Public License version 2 only, as
-# published by the Free Software Foundation.  Oracle designates this
-# particular file as subject to the "Classpath" exception as provided
-# by Oracle in the LICENSE file that accompanied this code.
-#
-# This code is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
-# version 2 for more details (a copy is included in the LICENSE file that
-# accompanied this code).
-#
-# You should have received a copy of the GNU General Public License version
-# 2 along with this work; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
-# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
-# or visit www.oracle.com if you need additional information or have any
-# questions.
-
-BUILDDIR = ../../..
-PACKAGE = com.sun.servicetag
-PRODUCT = sun
-include $(BUILDDIR)/common/Defs.gmk
-
-#
-# Files to compile
-#
-AUTO_FILES_JAVA_DIRS = com/sun/servicetag
-
-#
-# Rules
-#
-include $(BUILDDIR)/common/Classes.gmk
-
-SERVICETAG_LIBDIR = $(LIBDIR)/servicetag
-SERVICETAG_RESOURCES_DIR = $(CLASSDESTDIR)/com/sun/servicetag/resources
-FILES_copy = $(SERVICETAG_RESOURCES_DIR)/product_registration.xsd \
-             $(SERVICETAG_RESOURCES_DIR)/register.html \
-             $(SERVICETAG_RESOURCES_DIR)/register_ja.html \
-             $(SERVICETAG_RESOURCES_DIR)/register_zh_CN.html \
-             $(SERVICETAG_LIBDIR)/jdk_header.png
-
-# Add all properties files to the FILES_copy list
-SWORDFISH_properties := $(shell \
-       $(CD) $(SHARE_SRC)/classes/com/sun/servicetag/resources; \
-       $(FIND) . -name 'javase_*.properties' -print ; \
-    )
-FILES_copy += $(shell \
-   for f in $(SWORDFISH_properties) ; do \
-       echo $(SERVICETAG_RESOURCES_DIR)/$$f ; \
-   done \
-)
-
-
-#
-#OTHER_JAVACFLAGS += -Xlint:unchecked
-
-build: install-servicetag-lib copy-files
-
-copy-files: $(FILES_copy)
-
-$(CLASSBINDIR)/%: $(SHARE_SRC)/classes/%
-	$(install-file)
-
-$(SERVICETAG_LIBDIR)/jdk_header.png: $(SHARE_SRC)/classes/com/sun/servicetag/resources/jdk_header.png
-	$(install-file)
-	$(call chmod-file, 444)
-
-install-servicetag-lib:
-	@$(RM) -rf $(SERVICETAG_LIBDIR)
-	$(MKDIR) $(SERVICETAG_LIBDIR)
-
-clean clobber::
-	@$(RM) $(FILES_copy)
-
-.PHONY: copy-files
--- a/make/common/Release.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/common/Release.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -59,8 +59,7 @@
 # This is an interim solution until the ct.sym is replaced
 # with a new module system (being discussed for JDK 8).
 #
-EXPORTED_PRIVATE_PKGS = com.sun.servicetag \
-                        com.oracle.net \
+EXPORTED_PRIVATE_PKGS = com.oracle.net \
                         com.oracle.nio
 
 # 64-bit solaris has a few special cases. We define the variable
@@ -348,7 +347,6 @@
 	sun/tools/serialver	\
 	sun/tools/tree		\
 	sun/tools/util		\
-	sun/security/tools/jarsigner/JarBASE64Encoder.class \
 	sun/security/tools/jarsigner/Main.class \
 	sun/security/tools/jarsigner/JarSignerParameters.class \
 	sun/security/tools/jarsigner/Resources.class \
@@ -576,7 +574,6 @@
 	$(ECHO) "sun/tools/serialver/" >> $@
 	$(ECHO) "sun/tools/tree/" >> $@
 	$(ECHO) "sun/tools/util/" >> $@
-	$(ECHO) "sun/security/tools/jarsigner/JarBASE64Encoder.class" >> $@
 	$(ECHO) "sun/security/tools/jarsigner/Main.class" >> $@
 	$(ECHO) "sun/security/tools/jarsigner/JarSignerParameters.class" >> $@
 	$(ECHO) "sun/security/tools/jarsigner/Resources.class" >> $@
--- a/make/common/shared/Defs-utils.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/common/shared/Defs-utils.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -74,24 +74,24 @@
   UTILS_DEVTOOL_PATH=$(DEVTOOLS_PATH)
 endif
 
-# Utilities
-ifdef CROSS_COMPILE_ARCH
-  AR             = $(COMPILER_PATH)ar
-  AS             = $(COMPILER_PATH)as
-  LD             = $(COMPILER_PATH)ld
-  MCS            = $(COMPILER_PATH)mcs
-  NM             = $(COMPILER_PATH)nm
-  STRIP          = $(COMPILER_PATH)strip
-endif
-
-ifeq ($(PLATFORM),solaris)
-  AR             = $(UTILS_CCS_BIN_PATH)ar
-  AS             = $(UTILS_CCS_BIN_PATH)as
-  LD             = $(UTILS_CCS_BIN_PATH)ld
-  MCS            = $(UTILS_CCS_BIN_PATH)mcs
-  NM             = $(UTILS_CCS_BIN_PATH)nm
-  STRIP          = $(UTILS_CCS_BIN_PATH)strip
-endif
+ifndef CONFIGURE_BUILD
+  # Utilities
+  ifdef CROSS_COMPILE_ARCH
+    AR             = $(COMPILER_PATH)ar
+    AS             = $(COMPILER_PATH)as
+    LD             = $(COMPILER_PATH)ld
+    MCS            = $(COMPILER_PATH)mcs
+    NM             = $(COMPILER_PATH)nm
+    STRIP          = $(COMPILER_PATH)strip
+  else
+    AR             = $(UTILS_CCS_BIN_PATH)ar
+    AS             = $(UTILS_CCS_BIN_PATH)as
+    LD             = $(UTILS_CCS_BIN_PATH)ld
+    MCS            = $(UTILS_CCS_BIN_PATH)mcs
+    NM             = $(UTILS_CCS_BIN_PATH)nm
+    STRIP          = $(UTILS_CCS_BIN_PATH)strip
+  endif
+endif # CONFIGURE_BUILD
 
 ADB            = $(UTILS_COMMAND_PATH)adb
 BASENAME       = $(UTILS_COMMAND_PATH)basename
--- a/make/java/java/FILES_java.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/java/java/FILES_java.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -209,6 +209,7 @@
             sun/util/locale/provider/CalendarDataProviderImpl.java \
             sun/util/locale/provider/CalendarDataUtility.java \
             sun/util/locale/provider/CalendarNameProviderImpl.java \
+            sun/util/locale/provider/CalendarProviderImpl.java \
             sun/util/locale/provider/CollationRules.java \
             sun/util/locale/provider/CollatorProviderImpl.java \
             sun/util/locale/provider/CurrencyNameProviderImpl.java \
@@ -232,6 +233,7 @@
             sun/util/locale/provider/SPILocaleProviderAdapter.java \
             sun/util/locale/provider/TimeZoneNameProviderImpl.java \
             sun/util/locale/provider/TimeZoneNameUtility.java \
+	sun/util/spi/CalendarProvider.java \
     java/util/LocaleISOData.java \
         sun/util/cldr/CLDRLocaleProviderAdapter.java \
     java/util/MissingResourceException.java \
@@ -257,6 +259,7 @@
         sun/util/calendar/ZoneInfoFile.java \
     java/util/TooManyListenersException.java \
     java/util/Comparator.java \
+    java/util/Comparators.java \
     java/util/Collections.java \
     java/util/Iterator.java \
     java/util/ListIterator.java \
--- a/make/java/java/mapfile-vers	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/java/java/mapfile-vers	Mon Apr 08 15:57:12 2013 -0700
@@ -133,6 +133,7 @@
 		Java_java_lang_ClassLoader_00024NativeLibrary_find;
 		Java_java_lang_ClassLoader_00024NativeLibrary_load;
 		Java_java_lang_ClassLoader_00024NativeLibrary_unload;
+		Java_java_lang_ClassLoader_00024NativeLibrary_findBuiltinLib;
 		Java_java_lang_ClassLoader_getCaller; 
 		Java_java_lang_ClassLoader_registerNatives;
 		Java_java_lang_Compiler_registerNatives;
--- a/make/java/nio/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/java/nio/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2000, 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
@@ -384,9 +384,7 @@
 ifeq ($(PLATFORM),windows)
   OTHER_LDLIBS += $(JVMLIB) ws2_32.lib \
      -libpath:$(LIBDIR) java.lib \
-     $(OBJDIR)/../../../../sun/java.net/net/$(OBJDIRNAME)/net.lib \
-     $(OBJDIR)/../../../java.lang/java/$(OBJDIRNAME)/io_util.obj \
-     $(OBJDIR)/../../../java.lang/java/$(OBJDIRNAME)/FileDescriptor_md.obj
+     $(OBJDIR)/../../../../sun/java.net/net/$(OBJDIRNAME)/net.lib
 endif
 ifeq ($(PLATFORM), linux)
 OTHER_LDLIBS += -L$(LIBDIR)/$(LIBARCH) -ljava -lnet -lpthread $(LIBDL)
--- a/make/java/zip/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/java/zip/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -68,6 +68,16 @@
     FILES_reorder += reorder-$(ARCH)
   endif
 endif
+
+#
+# Use mapfile unconditionally (even with fastdebug).
+# JDK's internal zlib is incompatible with stock zlib, because the
+# size of struct z_stream has been changed, so internal zlib
+# implementation must not be allowed to leak outside of libzip.so,
+# else you get hard to debug failures with fastdebug jdk when user
+# native code includes stock zlib.
+#
+FILES_m = mapfile-vers
 include $(BUILDDIR)/common/Mapfile-vers.gmk
 include $(BUILDDIR)/common/Library.gmk
 
--- a/make/javax/others/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/javax/others/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 1998, 2011, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 1998, 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
@@ -33,6 +33,8 @@
 
 include $(BUILDDIR)/common/Defs.gmk
 
+JAVAC_LINT_OPTIONS += -Xlint:-deprecation
+
 #
 # Files to compile
 #
--- a/make/launchers/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/launchers/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -77,6 +77,7 @@
   -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 \
--- a/make/netbeans/common/java-data-no-native.ent	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/netbeans/common/java-data-no-native.ent	Mon Apr 08 15:57:12 2013 -0700
@@ -43,5 +43,6 @@
         <package-root>${root}/test</package-root>
         <unit-tests/>
         <source-level>1.8</source-level>
+        <classpath mode="compile">${jtreg.home}/lib/testng.jar</classpath>
     </compilation-unit>
 </java-data>
--- a/make/netbeans/common/shared.xml	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/netbeans/common/shared.xml	Mon Apr 08 15:57:12 2013 -0700
@@ -338,7 +338,7 @@
         <!-- Note: even with this default value, includes/excludes
          from share.src.dir get javadoc'd; see packageset below -->
         <property name="javadoc.packagenames" value="none"/> <!-- default, can be overridden per user or per project -->
-        <javadoc destdir="${javadoc.dir}" source="1.7"
+        <javadoc destdir="${javadoc.dir}" source="1.8"
             windowtitle="UNOFFICIAL" failonerror="true" use="true"
             author="false" version="false"
             packagenames="${javadoc.packagenames}">
--- a/make/sun/cmm/lcms/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/sun/cmm/lcms/Makefile	Mon Apr 08 15:57:12 2013 -0700
@@ -28,6 +28,9 @@
 LIBRARY = lcms
 PRODUCT = sun
 
+# Use highest level of optimization on this library
+OPTIMIZATION_LEVEL = HIGHEST
+
 include $(BUILDDIR)/common/Defs.gmk
 
 #
--- a/make/sun/cmm/lcms/mapfile-vers	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/sun/cmm/lcms/mapfile-vers	Mon Apr 08 15:57:12 2013 -0700
@@ -27,13 +27,12 @@
 
 SUNWprivate_1.1 {
 	global:
-        Java_sun_java2d_cmm_lcms_LCMS_loadProfile;
-        Java_sun_java2d_cmm_lcms_LCMS_freeProfile;
+        Java_sun_java2d_cmm_lcms_LCMS_loadProfileNative;
+        Java_sun_java2d_cmm_lcms_LCMS_freeProfileNative;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileSize;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileData;
-        Java_sun_java2d_cmm_lcms_LCMS_getTagSize;
-        Java_sun_java2d_cmm_lcms_LCMS_getTagData;
-        Java_sun_java2d_cmm_lcms_LCMS_setTagData;
+        Java_sun_java2d_cmm_lcms_LCMS_getTagNative;
+        Java_sun_java2d_cmm_lcms_LCMS_setTagDataNative;
         Java_sun_java2d_cmm_lcms_LCMS_colorConvert;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileID;
         Java_sun_java2d_cmm_lcms_LCMS_initLCMS;
--- a/make/sun/xawt/FILES_c_unix.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/sun/xawt/FILES_c_unix.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2002, 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
@@ -76,6 +76,7 @@
 	debug_trace.c \
 	debug_util.c \
 	awt_Plugin.c \
+        gnome_interface.c \
 	gtk2_interface.c \
         swing_GTKEngine.c \
         swing_GTKStyle.c \
--- a/make/tools/javazic/Makefile	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,43 +0,0 @@
-#
-# Copyright (c) 1998, 2005, 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
-# under the terms of the GNU General Public License version 2 only, as
-# published by the Free Software Foundation.  Oracle designates this
-# particular file as subject to the "Classpath" exception as provided
-# by Oracle in the LICENSE file that accompanied this code.
-#
-# This code is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
-# version 2 for more details (a copy is included in the LICENSE file that
-# accompanied this code).
-#
-# You should have received a copy of the GNU General Public License version
-# 2 along with this work; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
-# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
-# or visit www.oracle.com if you need additional information or have any
-# questions.
-#
-
-#
-# Makefile for building the javazic tool
-#
-
-BUILDDIR = ../..
-PACKAGE = build.tools.javazic
-PRODUCT = javazic
-PROGRAM = javazic
-include $(BUILDDIR)/common/Defs.gmk
-
-BUILDTOOL_SOURCE_ROOT = $(BUILDDIR)/tools/src
-BUILDTOOL_MAIN        = $(PKGDIR)/Main.java
-
-#
-# Build tool jar rules.
-#
-include $(BUILDDIR)/common/BuildToolJar.gmk
-
--- a/make/tools/src/build/tools/deps/refs.allowed	Thu Apr 04 11:33:40 2013 -0700
+++ b/make/tools/src/build/tools/deps/refs.allowed	Mon Apr 08 15:57:12 2013 -0700
@@ -33,8 +33,3 @@
 #
 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
-
--- a/make/tools/src/build/tools/javazic/BackEnd.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,70 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-/**
- * <code>BackEnd</code> is an abstract base class for a back-end of compiling
- * Olson's zoneinfo database and generating Java zoneinfo database.
- *
- * @since 1.4
- */
-abstract class BackEnd {
-
-    /**
-     * Receives each zone's TimeZone information which was created by
-     * {@link Zoneinfo#parse} in class <code>Zoneinfo</code>,
-     * and processes it.
-     *
-     * @param tz Timezone object for each zone
-     * @return 0 if no error occurred, otherwise 1.
-     */
-    abstract int processZoneinfo(Timezone tz);
-
-    /**
-     * Receives whole information which is generated by JavaZic's front-end
-     * in the form of Mapping object and generates all Java zone information
-     * files.
-     *
-     * @param m Mappings object which is generated by
-     *          {@link Main#compile() Main.compile()}.
-     * @return 0 if no error occurred, otherwise 1.
-     */
-    abstract int generateSrc(Mappings m);
-
-    /**
-     * Decides which backend class should be used and returns its instance.
-     * @return an instance of backend class
-     */
-    static BackEnd getBackEnd() {
-        if (Zoneinfo.isYearForTimeZoneDataSpecified) {
-            return new Simple();
-        } else if (Main.outputDoc) {
-            return new GenDoc();
-        } else {
-            return new Gen();
-        }
-    }
-}
--- a/make/tools/src/build/tools/javazic/Checksum.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,69 +0,0 @@
-/*
- * Copyright (c) 2000, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.zip.CRC32;
-
-/**
- * Checksum provides methods for calculating a CRC32 value for a
- * transitions table.
- *
- * @since 1.4
- */
-public class Checksum extends CRC32
-{
-    /**
-     * Updates the CRC32 value from each byte of the given int
-     * value. The bytes are used in the big endian order.
-     * @param val the int value
-     */
-    public void update(int val) {
-        byte[] b = new byte[4];
-        b[0] = (byte)((val >>> 24) & 0xff);
-        b[1] = (byte)((val >>> 16) & 0xff);
-        b[2] = (byte)((val >>> 8) & 0xff);
-        b[3] = (byte)(val & 0xff);
-        update(b);
-    }
-
-    /**
-     * Updates the CRC32 value from each byte of the given long
-     * value. The bytes are used in the big endian order.
-     * @param val the long value
-     */
-    void update(long val) {
-        byte[] b = new byte[8];
-        b[0] = (byte)((val >>> 56) & 0xff);
-        b[1] = (byte)((val >>> 48) & 0xff);
-        b[2] = (byte)((val >>> 40) & 0xff);
-        b[3] = (byte)((val >>> 32) & 0xff);
-        b[4] = (byte)((val >>> 24) & 0xff);
-        b[5] = (byte)((val >>> 16) & 0xff);
-        b[6] = (byte)((val >>> 8) & 0xff);
-        b[7] = (byte)(val & 0xff);
-        update(b);
-    }
-}
--- a/make/tools/src/build/tools/javazic/DayOfWeek.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,56 +0,0 @@
-/*
- * Copyright (c) 2004, 2006, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-/**
- * Day of week enum.
- *
- * @since 1.6
- */
-
-enum DayOfWeek {
-    SUNDAY("Sun"),
-    MONDAY("Mon"),
-    TUESDAY("Tue"),
-    WEDNESDAY("Wed"),
-    THURSDAY("Thu"),
-    FRIDAY("Fri"),
-    SATURDAY("Sat");
-
-    private final String abbr;
-
-    private DayOfWeek(String abbr) {
-        this.abbr = abbr;
-    }
-
-    String getAbbr() {
-        return abbr;
-    }
-
-    int value() {
-        return ordinal() + 1;
-    }
-}
--- a/make/tools/src/build/tools/javazic/Gen.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,347 +0,0 @@
-/*
- * Copyright (c) 2000, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import  java.io.IOException;
-import  java.io.File;
-import  java.io.FileOutputStream;
-import  java.io.DataOutputStream;
-import  java.io.RandomAccessFile;
-import  java.util.List;
-import  java.util.Map;
-import  java.util.Set;
-import  sun.util.calendar.ZoneInfoFile;
-
-/**
- * <code>Gen</code> is one of back-end classes of javazic, and generates
- * ZoneInfoMappings and zone-specific file for each zone.
- */
-class Gen extends BackEnd {
-
-    /**
-     * Generates datafile in binary TLV format for each time zone.
-     * Regarding contents of output files, see {@link ZoneInfoFile}.
-     *
-     * @param Timezone
-     * @return 0 if no errors, or 1 if error occurred.
-     */
-    int processZoneinfo(Timezone tz) {
-        try {
-            int size;
-            String outputDir = Main.getOutputDir();
-            String zonefile = ZoneInfoFile.getFileName(tz.getName());
-
-            /* If outputDir doesn't end with file-separator, adds it. */
-            if (!outputDir.endsWith(File.separator)) {
-                outputDir += File.separatorChar;
-            }
-
-            /* If zonefile includes file-separator, it's treated as part of
-             * pathname. And make directory if necessary.
-             */
-            int index = zonefile.lastIndexOf(File.separatorChar);
-            if (index != -1) {
-                outputDir += zonefile.substring(0, index+1);
-            }
-            File outD = new File(outputDir);
-            outD.mkdirs();
-
-            FileOutputStream fos =
-                new FileOutputStream(outputDir + zonefile.substring(index+1));
-            DataOutputStream dos = new DataOutputStream(fos);
-
-            /* Output Label */
-            dos.write(ZoneInfoFile.JAVAZI_LABEL, 0,
-                      ZoneInfoFile.JAVAZI_LABEL.length);
-
-            /* Output Version of ZoneInfoFile */
-            dos.writeByte(ZoneInfoFile.JAVAZI_VERSION);
-
-            List<Long> transitions = tz.getTransitions();
-            if (transitions != null) {
-                List<Integer> dstOffsets = tz.getDstOffsets();
-                List<Integer> offsets = tz.getOffsets();
-
-                if ((dstOffsets == null && offsets != null) ||
-                    (dstOffsets != null && offsets == null)) {
-                    Main.panic("Data not exist. (dstOffsets or offsets)");
-                    return 1;
-                }
-
-                /* Output Transition records */
-                dos.writeByte(ZoneInfoFile.TAG_Transition);
-                size = transitions.size();
-                dos.writeShort((size * 8) & 0xFFFF);
-                int dstoffset;
-                for (int i = 0; i < size; i++) {
-                    /* if DST offset is 0, this means DST isn't used.
-                     * (NOT: offset's index is 0.)
-                     */
-                    if ((dstoffset = dstOffsets.get(i).intValue()) == -1) {
-                        dstoffset = 0;
-                    }
-
-                    dos.writeLong((transitions.get(i).longValue() << 12)
-                                  | (dstoffset << 4)
-                                  | offsets.get(i).intValue());
-
-                }
-
-                /* Output data for GMTOffset */
-                List<Integer> gmtoffset = tz.getGmtOffsets();
-                dos.writeByte(ZoneInfoFile.TAG_Offset);
-                size = gmtoffset.size();
-                dos.writeShort((size * 4) & 0xFFFF);
-                for (int i = 0; i < size; i++) {
-                    dos.writeInt(gmtoffset.get(i));
-                }
-            }
-
-            /* Output data for SimpleTimeZone */
-            List<RuleRec> stz = tz.getLastRules();
-            if (stz != null) {
-                RuleRec[] rr = new RuleRec[2];
-                boolean wall = true;
-
-                rr[0] = stz.get(0);
-                rr[1] = stz.get(1);
-
-                dos.writeByte(ZoneInfoFile.TAG_SimpleTimeZone);
-                wall = rr[0].getTime().isWall() && rr[1].getTime().isWall();
-                if (wall) {
-                    dos.writeShort(32);
-                } else {
-                    dos.writeShort(40);
-                }
-
-                for (int i = 0; i < 2; i++) {
-                    dos.writeInt(rr[i].getMonthNum() - 1); // 0-based month number
-                    dos.writeInt(rr[i].getDay().getDayForSimpleTimeZone());
-                    dos.writeInt(rr[i].getDay().getDayOfWeekForSimpleTimeZoneInt());
-                    dos.writeInt((int)rr[i].getTime().getTime());
-                    if (!wall) {
-                        dos.writeInt((rr[i].getTime().getType() & 0xFF) - 1);
-                    }
-                }
-            }
-
-            /* Output RawOffset */
-            dos.writeByte(ZoneInfoFile.TAG_RawOffset);
-            dos.writeShort(4);
-            dos.writeInt(tz.getRawOffset());
-
-            /* Output willGMTOffsetChange flag */
-            if (tz.willGMTOffsetChange()) {
-                dos.writeByte(ZoneInfoFile.TAG_GMTOffsetWillChange);
-                dos.writeShort(1);
-                dos.writeByte(1);
-            }
-
-            /* Output LastDSTSaving */
-            dos.writeByte(ZoneInfoFile.TAG_LastDSTSaving);
-            dos.writeShort(2);
-            dos.writeShort(tz.getLastDSTSaving()/1000);
-
-            /* Output checksum */
-            dos.writeByte(ZoneInfoFile.TAG_CRC32);
-            dos.writeShort(4);
-            dos.writeInt(tz.getCRC32());
-
-            fos.close();
-            dos.close();
-        } catch(IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-            return 1;
-        }
-
-        return 0;
-    }
-
-    /**
-     * Generates ZoneInfoMappings in binary TLV format for each zone.
-     * Regarding contents of output files, see {@link ZoneInfoFile}.
-     *
-     * @param Mappings
-     * @return 0 if no errors, or 1 if error occurred.
-     */
-    int generateSrc(Mappings map) {
-        try {
-            int index;
-            int block_size;
-            int roi_size;
-            long fp;
-            String outputDir = Main.getOutputDir();
-
-            /* If outputDir doesn't end with file-separator, adds it. */
-            if (!outputDir.endsWith(File.separator)) {
-                outputDir += File.separatorChar;
-            }
-
-            File outD = new File(outputDir);
-            outD.mkdirs();
-
-            /* Open ZoneInfoMapping file to write. */
-            RandomAccessFile raf =
-                new RandomAccessFile(outputDir + ZoneInfoFile.JAVAZM_FILE_NAME, "rw");
-
-            /* Whether rawOffsetIndex list exists or not. */
-            List<Integer> roi = map.getRawOffsetsIndex();
-            if (roi == null) {
-                Main.panic("Data not exist. (rawOffsetsIndex)");
-                return 1;
-            }
-            roi_size = roi.size();
-
-            /* Whether rawOffsetIndexTable list exists or not. */
-            List<Set<String>> roit = map.getRawOffsetsIndexTable();
-            if (roit == null || roit.size() != roi_size) {
-                Main.panic("Data not exist. (rawOffsetsIndexTable) Otherwise, Invalid size");
-                return 1;
-            }
-
-            /* Output Label */
-            raf.write(ZoneInfoFile.JAVAZM_LABEL, 0,
-                      ZoneInfoFile.JAVAZM_LABEL.length);
-
-            /* Output Version */
-            raf.writeByte(ZoneInfoFile.JAVAZM_VERSION);
-
-            index = ZoneInfoFile.JAVAZM_LABEL.length + 2;
-
-            /* Output Version of Olson's tzdata */
-            byte[] b = Main.getVersionName().getBytes("UTF-8");
-            raf.writeByte(ZoneInfoFile.TAG_TZDataVersion);
-            raf.writeShort((b.length+1) & 0xFFFF);
-            raf.write(b);
-            raf.writeByte(0x00);
-            index += b.length + 4;
-
-            /* Output ID list. */
-            raf.writeByte(ZoneInfoFile.TAG_ZoneIDs);
-            block_size = 2;
-            raf.writeShort(block_size & 0xFFFF);
-            short nID = 0;
-            raf.writeShort(nID & 0xFFFF);
-            for (int i = 0; i < roi_size; i++) {
-                for (String key : roit.get(i)) {
-                    byte size = (byte)key.getBytes("UTF-8").length;
-                    raf.writeByte(size & 0xFF);
-                    raf.write(key.getBytes("UTF-8"), 0, size);
-                    block_size += 1 + size;
-                    nID++;
-                }
-            }
-            fp = raf.getFilePointer();
-            raf.seek(index);
-            raf.writeShort((block_size) & 0xFFFF);
-            raf.writeShort(nID & 0xFFFF);
-            raf.seek(fp);
-
-            /* Output sorted rawOffset list. */
-            raf.writeByte(ZoneInfoFile.TAG_RawOffsets);
-            index += 3 + block_size;
-            block_size = roi_size * 4;
-            raf.writeShort(block_size & 0xFFFF);
-            for (int i = 0; i < roi_size; i++) {
-                raf.writeInt(Integer.parseInt(roi.get(i).toString()));
-            }
-
-            /* Output sorted rawOffsetIndex list. */
-            raf.writeByte(ZoneInfoFile.TAG_RawOffsetIndices);
-            index += 3 + block_size;
-            block_size = 0;
-            raf.writeShort(block_size & 0xFFFF);
-            int num;
-            for (int i = 0; i < roi_size; i++) {
-                num = roit.get(i).size();
-                block_size += num;
-                for (int j = 0; j < num; j++) {
-                    raf.writeByte(i);
-                }
-            }
-            fp = raf.getFilePointer();
-            raf.seek(index);
-            raf.writeShort((block_size) & 0xFFFF);
-            raf.seek(fp);
-
-            /* Whether alias list exists or not. */
-            Map<String,String> a = map.getAliases();
-            if (a == null) {
-                Main.panic("Data not exist. (aliases)");
-                return 0;
-            }
-
-            /* Output ID list. */
-            raf.writeByte(ZoneInfoFile.TAG_ZoneAliases);
-            index += 3 + block_size;
-            block_size = 2;
-            raf.writeShort(block_size & 0xFFFF);
-            raf.writeShort(a.size() & 0xFFFF);
-            for (String key : a.keySet()) {
-                String alias = a.get(key);
-                byte key_size = (byte)key.length();
-                byte alias_size = (byte)alias.length();
-                raf.writeByte(key_size & 0xFF);
-                raf.write(key.getBytes("UTF-8"), 0, key_size);
-                raf.writeByte(alias_size & 0xFF);
-                raf.write(alias.getBytes("UTF-8"), 0, alias_size);
-                block_size += 2 + key_size + alias_size;
-            }
-            fp = raf.getFilePointer();
-            raf.seek(index);
-            raf.writeShort((block_size) & 0xFFFF);
-            raf.seek(fp);
-
-            /* Output the exclude list if it exists. */
-            List<String> excludedZones = map.getExcludeList();
-            if (excludedZones != null) {
-                raf.writeByte(ZoneInfoFile.TAG_ExcludedZones);
-                index += 3 + block_size;
-                block_size = 2;
-                raf.writeShort(block_size & 0xFFFF);  // place holder
-                raf.writeShort(excludedZones.size()); // the number of excluded zones
-                for (String name : excludedZones) {
-                    byte size = (byte) name.length();
-                    raf.writeByte(size);                 // byte length
-                    raf.write(name.getBytes("UTF-8"), 0, size); // zone name
-                    block_size += 1 + size;
-                }
-                fp = raf.getFilePointer();
-                raf.seek(index);
-                raf.writeShort(block_size & 0xFFFF);
-                raf.seek(fp);
-            }
-
-            /* Close ZoneInfoMapping file. */
-            raf.close();
-        } catch(IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-            return 1;
-        }
-
-        return 0;
-    }
-}
--- a/make/tools/src/build/tools/javazic/GenDoc.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,781 +0,0 @@
-/*
- * Copyright (c) 2001, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import  java.io.BufferedReader;
-import  java.io.BufferedWriter;
-import  java.io.File;
-import  java.io.FileReader;
-import  java.io.FileWriter;
-import  java.io.IOException;
-import  java.util.Date;
-import  java.util.HashMap;
-import  java.util.List;
-import  java.util.Map;
-import  java.util.Set;
-import  java.util.SortedMap;
-import  java.util.StringTokenizer;
-import  java.util.TreeMap;
-import  java.util.TreeSet;
-import  sun.util.calendar.ZoneInfoFile;
-
-/**
- * <code>GenDoc</code> is one of back-end classes of javazic, and generates
- * index.html and other html files which prints the detailed time zone
- * information for each zone.
- */
-class GenDoc extends BackEnd {
-
-    private static final String docDir = "doc";
-
-    private static final String header1 =
-        "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0 Frameset//EN\"" +
-        "\"http://www.w3.org/TR/REC-html40/frameset.dtd\">\n" +
-        "<HTML>\n<HEAD>\n<!-- Generated by javazic on ";
-    private static final String header2 =
-        "-->\n<TITLE>\n" +
-        "Java Platform, Standard Edition - TimeZone information based on ";
-    private static final String header3 =
-        "-->\n<TITLE>\n" +
-        "Java Platform, Standard Edition  TimeZone - ";
-    private static final String header4 =
-        "</TITLE>\n" +
-        "</HEAD>\n\n";
-
-    private static final String body1 =
-        "<BODY BGCOLOR=\"white\">\n";
-    private static final String body2 =
-        "</BODY>\n";
-
-    private static final String footer =
-        "</HTML>\n";
-
-
-    // list of time zone name and zonefile name/real time zone name
-    //   e.g.
-    //      key (String)       : value (String)
-    //      "America/Denver"   : "America/Denver.html" (real time zone)
-    //      "America/Shiprock" : "America/Denver"      (alias)
-    TreeMap<String,String> timezoneList = new TreeMap<String,String>();
-
-    // list of time zone's display name and time zone name
-    //   e.g.
-    //      key (String)                : value (String)
-    //      "Tokyo, Asia"               : "Asia/Tokyo"
-    //      "Marengo, Indiana, America" : "America/Indiana/Marengo"
-    //          (aliases included)
-    TreeMap<String,String> displayNameList = new TreeMap<String,String>();
-
-    // list of top level regions
-    //   e.g.
-    //      key (String) : value (String)
-    //      "America"    : "America.html"
-    //          (including entries in America/Indiana/, America/Kentucky/, ...)
-    TreeMap<String,String> regionList = new TreeMap<String,String>();
-
-    // mapping list from zone name to latitude & longitude
-    //   This list is generated from zone.tab.
-    //   e.g.
-    //      key (String) : value (LatitudeAndLongitude object)
-    //      "Asia/Tokyo" : latitude=35.3916, longitude=13.9444
-    //          (aliases not included)
-    HashMap<String,LatitudeAndLongitude> mapList = null;
-
-    // SortedMap of zone IDs sorted by their GMT offsets. If zone's GMT
-    // offset will change in the future, its last known offset is
-    // used.
-    SortedMap<Integer, Set<String>> zonesByOffset = new TreeMap<Integer, Set<String>>();
-
-    /**
-     * Generates HTML document for each zone.
-     * @param Timezone
-     * @return 0 if no errors, or 1 if error occurred.
-     */
-    int processZoneinfo(Timezone tz) {
-        try {
-            int size;
-            int index;
-            String outputDir = Main.getOutputDir();
-            String zonename = tz.getName();
-            String zonefile = ZoneInfoFile.getFileName(zonename) + ".html";
-            List<RuleRec> stz = tz.getLastRules();
-            timezoneList.put(zonename, zonefile);
-            displayNameList.put(transform(zonename), zonename);
-
-            // Populate zonesByOffset. (Zones that will change their
-            // GMT offsets are also added to zonesByOffset here.)
-            int lastKnownOffset = tz.getRawOffset();
-            Set<String> set = zonesByOffset.get(lastKnownOffset);
-            if (set == null) {
-                set = new TreeSet<String>();
-                zonesByOffset.put(lastKnownOffset, set);
-            }
-            set.add(zonename);
-
-            /* If outputDir doesn't end with file-separator, adds it. */
-            if (!outputDir.endsWith(File.separator)) {
-                outputDir += File.separatorChar;
-            }
-            outputDir += docDir + File.separatorChar;
-
-            index = zonename.indexOf('/');
-            if (index != -1) {
-                regionList.put(zonename.substring(0, index),
-                               zonename.substring(0, index) + ".html");
-            }
-
-            /* If zonefile includes file-separator, it's treated as part of
-             * pathname. And make directory if necessary.
-             */
-            index = zonefile.lastIndexOf('/');
-            if (index != -1) {
-                zonefile.replace('/', File.separatorChar);
-                outputDir += zonefile.substring(0, index+1);
-            }
-            File outD = new File(outputDir);
-            outD.mkdirs();
-
-            /* If mapfile is available, add a link to the appropriate map */
-            if ((mapList == null) && (Main.getMapFile() != null)) {
-                FileReader fr = new FileReader(Main.getMapFile());
-                BufferedReader in = new BufferedReader(fr);
-                mapList = new HashMap<String,LatitudeAndLongitude>();
-                String line;
-                while ((line = in.readLine()) != null) {
-                    // skip blank and comment lines
-                    if (line.length() == 0 || line.charAt(0) == '#') {
-                        continue;
-                    }
-                    StringTokenizer tokens = new StringTokenizer(line);
-                    String token = tokens.nextToken();  /* We don't use the first token. */
-                    token = tokens.nextToken();
-                    LatitudeAndLongitude location = new LatitudeAndLongitude(token);
-                    token = tokens.nextToken();
-                    mapList.put(token, location);
-                }
-                in.close();
-            }
-
-            /* Open zoneinfo file to write. */
-            FileWriter fw = new FileWriter(outputDir + zonefile.substring(index+1));
-            BufferedWriter out = new BufferedWriter(fw);
-
-            out.write(header1 + new Date() + header3 + zonename + header4);
-            out.write(body1 + "<FONT size=\"+2\"><B>" + zonename + "</B></FONT>");
-            LatitudeAndLongitude location = mapList.get(zonename);
-            if (location != null) {
-                int deg, min, sec;
-
-                deg = location.getLatDeg();
-                min = location.getLatMin();
-                sec = location.getLatSec();
-                if (deg < 0) {
-                    min = -min;
-                    sec = -sec;
-                } else if (min < 0) {
-                    sec = -sec;
-                }
-                out.write("&nbsp;&nbsp;&nbsp;" +
-                          "<A HREF=\"http://www.mapquest.com/maps/map.adp?" +
-                          "latlongtype=degrees" +
-                          "&latdeg=" + deg +
-                          "&latmin=" + min +
-                          "&latsec=" + sec);
-
-                deg = location.getLongDeg();
-                min = location.getLongMin();
-                sec = location.getLongSec();
-                if (deg < 0) {
-                    min = -min;
-                    sec = -sec;
-                } else if (min < 0) {
-                    sec = -sec;
-                }
-                out.write("&longdeg=" + deg +
-                          "&longmin=" + min +
-                          "&longsec=" + sec +
-                          "\" target=\"_blank\">[map]</A>");
-            }
-            out.write("\n<P>\n");
-
-            List<ZoneRec> zone = tz.getZones();
-            List<RuleRec> rule = tz.getRules();
-            if (rule != null && zone != null) {
-                out.write("<TABLE BORDER=\"0\" WIDTH=\"100%\" CELLPADDING=\"1\" CELLSPACING=\"0\">\n" +
-                          "<TR>\n" +
-                          "<TD BGCOLOR=\"#EEEEFF\" WIDTH=\"50%\" ALIGN=\"CENTER\"><BR>" +
-                          "<A HREF=\"#Rules\">Rules</A><BR></TD>\n" +
-                          "<TD BGCOLOR=\"#EEEEFF\" WIDTH=\"50%\" ALIGN=\"CENTER\">" +
-                          "<A HREF=\"#Zone\"><BR>Zone<BR></A></TD>\n" +
-                          "</TR>\n</TABLE>\n");
-            }
-
-            /* Output Rule records. */
-            if (rule != null) {
-                size = rule.size();
-                out.write("<P>\n<A NAME=\"Rules\">" +
-                          "<FONT SIZE=\"+1\"><B>Rules</B></FONT></A>\n" +
-                          "<TABLE BORDER=\"1\" WIDTH=\"100%\" CELLPADDING=\"3\" CELLSPACING=\"0\">\n" +
-                          "<TR BGCOLOR=\"#CCCCFF\">\n" +
-                          "<TD>NAME</TD><TD>FROM</TD><TD>TO</TD><TD>TYPE</TD>" +
-                          "<TD>IN</TD><TD>ON</TD><TD>AT</TD><TD>SAVE</TD>" +
-                          "<TD>LETTER/S</TD><TD>NOTES</TD>\n</TR>\n");
-                for (int i = 0; i < size; i++) {
-                    out.write("<TR BGCOLOR=\"#FFFFFF\">\n");
-                    StringTokenizer st = new StringTokenizer(rule.get(i).getLine());
-                    String s;
-                    if (st.hasMoreTokens()) {   /* RULE - truncated */
-                        st.nextToken();
-                    }
-                    if (st.hasMoreTokens()) {   /* NAME */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* FROM */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* TO */
-                        s = st.nextToken();
-                        if (s.equals("min") || s.equals("max")) {
-                            out.write("<TD><FONT COLOR=\"red\">" + s + "</FONT></TD>");
-                        } else {
-                            out.write("<TD>" + s + "</TD>");
-                        }
-                    }
-                    if (st.hasMoreTokens()) {   /* TYPE */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* IN */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* ON */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* AT */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* SAVE */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* LETTER/S */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* NOTES */
-                        s = st.nextToken();
-                        while (st.hasMoreTokens()) {
-                            s += " " + st.nextToken();
-                        }
-                        index = s.indexOf('#');
-                        out.write("<TD>" + s.substring(index+1) + "</TD>\n");
-                    } else {
-                        out.write("<TD>&nbsp;</TD>\n");
-                    }
-                    out.write("</TR>\n");
-                }
-                out.write("</TABLE>\n<P>&nbsp;<P>\n");
-            }
-
-            /* Output Zone records. */
-            if (zone != null) {
-                size = zone.size();
-                out.write("<P>\n<A NAME=\"Zone\">" +
-                          "<FONT SIZE=\"+1\"><B>Zone</B></FONT></A>\n" +
-                          "<TABLE BORDER=\"1\" WIDTH=\"100%\" CELLPADDING=\"3\" CELLSPACING=\"0\">\n" +
-                          "<TR BGCOLOR=\"#CCCCFF\">\n<TD>GMTOFF</TD>" +
-                          "<TD>RULES</TD><TD>FORMAT</TD><TD>UNTIL</TD>" +
-                          "<TD>NOTES</TD>\n</TR>\n");
-                for (int i = 0; i < size; i++) {
-                    out.write("<TR>\n");
-                    StringTokenizer st = new StringTokenizer(zone.get(i).getLine());
-                    String s = st.nextToken();
-                    if (s.equals("Zone")) {     /* NAME */
-                        s = st.nextToken();
-                        s = st.nextToken();
-                    }
-                    out.write("<TD>" + s + "</TD>");    /* GMTOFFSET */
-                    if (st.hasMoreTokens()) {   /* RULES */
-                        out.write("<TD>" + st.nextToken() + "</TD>");
-                    }
-                    if (st.hasMoreTokens()) {   /* FORMAT */
-                        s = st.nextToken();
-                        index = s.indexOf('#');
-                        if (index != -1) {
-                            if (index != 0) {
-                                out.write("<TD>" + s.substring(0, index-1) +
-                                          "</TD>");     /* FORMAT */
-                                s = s.substring(index+1);
-                            } else {
-                                out.write("<TD>&nbsp;</TD>");   /* FORMAT */
-                            }
-                            while (st.hasMoreTokens()) {
-                                s += " " + st.nextToken();
-                            }
-                            out.write("<TD>&nbsp;</TD>");       /* UNTIL */
-                            out.write("<TD>" + s + "</TD>\n</TR>\n");   /* NOTES */
-                            continue;
-                        } else {
-                            out.write("<TD>" + s + "</TD>");    /* FORMAT */
-                        }
-                    }
-
-                    if (st.hasMoreTokens()) {   /* UNTIL */
-                        s = st.nextToken();
-                        while (st.hasMoreTokens()) {
-                            s += " " + st.nextToken();
-                        }
-                        index = s.indexOf('#');
-                        if (index != -1) {
-                            if (index != 0) {
-                                out.write("<TD>" + s.substring(0, index-1) +
-                                          "</TD>");     /* UNTIL */
-                            } else {
-                                out.write("<TD>&nbsp;</TD>");   /* UNTIL */
-                            }
-                            out.write("<TD>" + s.substring(index+1) +
-                                      "</TD>\n");       /* NOTES */
-                        } else {
-                            out.write("<TD>" + s + "</TD>");    /* UNTIL */
-                            out.write("<TD>&nbsp;</TD>\n");     /* NOTES */
-                        }
-                    } else {
-                        out.write("<TD>&nbsp;</TD>");           /* UNTIL */
-                        out.write("<TD>&nbsp;</TD>\n");         /* NOTES */
-                    }
-                    out.write("</TR>\n");
-                }
-                out.write("</TABLE>\n");
-            }
-            out.write(body2 + footer);
-
-            out.close();
-            fw.close();
-        } catch(IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-            return 1;
-        }
-
-        return 0;
-    }
-
-    /**
-     * Generates index.html and other top-level frame files.
-     * @param Mappings
-     * @return 0 if no errors, or 1 if error occurred.
-     */
-    int generateSrc(Mappings map) {
-        try {
-            int len;
-            Object o[];
-            String outputDir = Main.getOutputDir();
-            FileWriter fw1, fw2;
-            BufferedWriter out1, out2;
-
-            /* Whether alias list exists or not. */
-            Map<String,String> a = map.getAliases();
-            if (a == null) {
-                Main.panic("Data not exist. (aliases)");
-                return 1;
-            }
-
-            timezoneList.putAll(a);
-
-            /* If outputDir doesn't end with file-separator, adds it. */
-            if (!outputDir.endsWith(File.separator)) {
-                outputDir += File.separatorChar;
-            }
-            outputDir += docDir + File.separatorChar;
-
-            File outD = new File(outputDir);
-            outD.mkdirs();
-
-            /* Creates index.html */
-            fw1 = new FileWriter(outputDir + "index.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 +
-                       "<FRAMESET cols=\"20%,80%\">\n" +
-                       "<FRAMESET rows=\"30%,70%\">\n" +
-                       "<FRAME src=\"overview-frame.html\" name=\"TimeZoneListFrame\">\n" +
-                       "<FRAME src=\"allTimeZone-frame1.html\" name=\"allTimeZoneFrame\">\n" +
-                       "</FRAMESET>" +
-                       "<FRAME src=\"overview-summary.html\" name=\"rightFrame\">\n" +
-                       "</FRAMESET>\n" +
-                       "<NOFRAMES>\n" +
-                       "<H2>\nFrame Alert\n</H2>\n\n" +
-                       "<P>\n\n" +
-                       "This document is designed to be viewed using the frames feature. If you see this\n" +
-                       "message, you are using a non-frame-capable web client.\n" +
-                       "<BR>\n" +
-                       "Link to<A HREF=\"overview-summary.html\">Non-frame version.</A>\n" +
-                       "</NOFRAMES>\n" + footer);
-
-            out1.close();
-            fw1.close();
-
-
-            /* Creates overview-frame.html */
-            fw1 = new FileWriter(outputDir + "overview-frame.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 + body1 +
-                       "<TABLE BORDER=\"0\" WIDTH=\"100%\">\n<TR>\n" +
-                       "<TD NOWRAP><FONT size=\"+1\">\n" +
-                       "<B>Java<sup><font size=-2>TM</font></sup>&nbsp;Platform<br>Standard&nbsp;Ed.</B></FONT></TD>\n" +
-                       "</TR>\n</TABLE>\n\n" +
-                       "<TABLE BORDER=\"0\" WIDTH=\"100%\">\n<TR>\n<TD NOWRAP>" +
-                       "<P>\n<FONT size=\"+1\">\nAll Time Zones Sorted By:</FONT>\n<BR>\n" +
-                       "&nbsp;&nbsp;<A HREF=\"allTimeZone-frame1.html\" TARGET=\"allTimeZoneFrame\">GMT offsets</A></FONT>\n<BR>\n" +
-                       "&nbsp;&nbsp;<A HREF=\"allTimeZone-frame2.html\" TARGET=\"allTimeZoneFrame\">Zone names</A></FONT>\n<BR>" +
-                       "&nbsp;&nbsp;<A HREF=\"allTimeZone-frame3.html\" TARGET=\"allTimeZoneFrame\">City names</A></FONT>\n" +
-                       "<P>\n<FONT size=\"+1\">\nContinents and Oceans</FONT>\n<BR>\n");
-
-            for (String regionKey : regionList.keySet()) {
-                out1.write("&nbsp;&nbsp;<A HREF=\"" + regionList.get(regionKey) +
-                           "\" TARGET=\"allTimeZoneFrame\">" + regionKey +
-                           "</A><BR>\n");
-
-                fw2 = new FileWriter(outputDir + regionList.get(regionKey),
-                                     false);
-                out2 = new BufferedWriter(fw2);
-
-                out2.write(header1 + new Date() + header3 + regionKey +
-                           header4 + body1 + "<FONT size=\"+1\"><B>" +
-                           regionKey + "</B></FONT>\n<BR>\n<TABLE>\n<TR>\n<TD>");
-
-                boolean found = false;
-                for (String timezoneKey : timezoneList.keySet()) {
-                    int regionIndex = timezoneKey.indexOf('/');
-                    if (regionIndex == -1 ||
-                        !regionKey.equals(timezoneKey.substring(0, regionIndex))) {
-                        if (found) {
-                            break;
-                        } else {
-                            continue;
-                        }
-                    }
-
-                    found = true;
-                    if (a.containsKey(timezoneKey)) {
-                        Object realName = a.get(timezoneKey);
-                        while (a.containsKey(realName)) {
-                            realName = a.get(realName);
-                        }
-                        out2.write(timezoneKey +
-                                   " (alias for " + "<A HREF=\"" +
-                                   timezoneList.get(realName) +
-                                   "\" TARGET=\"rightFrame\">" +
-                                   realName + "</A>)");
-                    } else {
-                        out2.write("<A HREF=\"" + timezoneList.get(timezoneKey) +
-                                   "\" TARGET=\"rightFrame\">" + timezoneKey +
-                                   "</A>");
-                    }
-                    out2.write("<BR>\n");
-                }
-                out2.write("</TD>\n</TR>\n</TABLE>\n" + body2 + footer);
-
-                out2.close();
-                fw2.close();
-            }
-            out1.write("</FONT></TD>\n</TR></TABLE>\n" + body2 + footer);
-
-            out1.close();
-            fw1.close();
-
-
-            /* Creates allTimeZone-frame1.html (Sorted by GMT offsets) */
-            fw1 = new FileWriter(outputDir + "allTimeZone-frame1.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 + body1 +
-                       "<FONT size=\"+1\"><B>Sorted by GMT offsets</B></FONT>\n" +
-                       "<BR>\n\n" + "<TABLE BORDER=\"0\" WIDTH=\"100%\">\n" +
-                       "<TR>\n<TD NOWRAP>\n");
-
-            List<Integer> roi = map.getRawOffsetsIndex();
-            List<Set<String>> roit = map.getRawOffsetsIndexTable();
-
-            int index = 0;
-            for (Integer offset : zonesByOffset.keySet()) {
-                int off = roi.get(index);
-                Set<String> perRO = zonesByOffset.get(offset);
-                if (offset == off) {
-                    // Merge aliases into zonesByOffset
-                    perRO.addAll(roit.get(index));
-                }
-                index++;
-
-                for (String timezoneKey : perRO) {
-                    out1.write("<TR>\n<TD><FONT SIZE=\"-1\">(" +
-                               Time.toGMTFormat(offset.toString()) +
-                               ")</FONT></TD>\n<TD>");
-
-                    if (a.containsKey(timezoneKey)) {
-                        Object realName = a.get(timezoneKey);
-                        while (a.containsKey(realName)) {
-                            realName = a.get(realName);
-                        }
-                        out1.write(timezoneKey +
-                                   " (alias for " + "<A HREF=\"" +
-                                   timezoneList.get(realName) +
-                                   "\" TARGET=\"rightFrame\">" + realName +
-                                   "</A>)");
-                    } else {
-                        out1.write("<A HREF=\"" + timezoneList.get(timezoneKey) +
-                                   "\" TARGET=\"rightFrame\">" + timezoneKey +
-                                   "</A>");
-                    }
-                    out1.write("</TD>\n</TR>\n");
-                }
-            }
-            out1.write("</FONT></TD>\n</TR>\n</TABLE>\n" + body2 + footer);
-
-            out1.close();
-            fw1.close();
-
-
-            /* Creates allTimeZone-frame2.html (Sorted by zone names) */
-            fw1 = new FileWriter(outputDir + "allTimeZone-frame2.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 + body1 +
-                       "<FONT size=\"+1\"><B>Sorted by zone names</B></FONT>\n" +
-                       "<BR>\n\n" + "<TABLE BORDER=\"0\" WIDTH=\"100%\">\n" +
-                       "<TR>\n<TD NOWRAP>\n");
-            o = timezoneList.keySet().toArray();
-            len = timezoneList.size();
-            for (int i = 0; i < len; i++) {
-                Object timezoneKey = o[i];
-                if (a.containsKey(timezoneKey)) {
-                    Object realName = a.get(timezoneKey);
-                    while (a.containsKey(realName)) {
-                        realName = a.get(realName);
-                    }
-                    out1.write(timezoneKey +
-                               " (alias for " +
-                               "<A HREF=\"" + timezoneList.get(realName) +
-                               "\" TARGET=\"rightFrame\">" + realName +
-                               "</A>)");
-                } else {
-                    out1.write("<A HREF=\"" + timezoneList.get(timezoneKey) +
-                               "\" TARGET=\"rightFrame\">" + timezoneKey +
-                               "</A>");
-                }
-                out1.write("<BR> \n");
-            }
-            out1.write("</FONT></TD>\n</TR>\n</TABLE>\n" + body2 + footer);
-
-            out1.close();
-            fw1.close();
-
-            /* Creates allTimeZone-frame3.html (Sorted by city names) */
-            fw1 = new FileWriter(outputDir + "allTimeZone-frame3.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 + body1 +
-                       "<FONT size=\"+1\"><B>Sorted by city names</B></FONT>\n" +
-                       "<BR>\n\n" + "<TABLE BORDER=\"0\" WIDTH=\"100%\">\n" +
-                       "<TR>\n<TD NOWRAP>\n");
-
-            Set<String> aliasSet = a.keySet();
-            len = aliasSet.size();
-            String aliasNames[] = aliasSet.toArray(new String[0]);
-            for (int i = 0; i < len; i++) {
-                displayNameList.put(transform(aliasNames[i]),
-                                    aliasNames[i]);
-            }
-
-            o = displayNameList.keySet().toArray();
-            len = displayNameList.size();
-            for (int i = 0; i < len; i++) {
-                Object displayName = o[i];
-                Object timezoneKey = displayNameList.get(o[i]);
-                if (a.containsKey(timezoneKey)) {
-                    Object realName = a.get(timezoneKey);
-                    while (a.containsKey(realName)) {
-                        realName = a.get(realName);
-                    }
-                    out1.write(displayName +
-                               " (alias for " +
-                               "<A HREF=\"" + timezoneList.get(realName) +
-                               "\" TARGET=\"rightFrame\">" + realName +
-                               "</A>)");
-                } else {
-                    out1.write("<A HREF=\"" + timezoneList.get(timezoneKey) +
-                               "\" TARGET=\"rightFrame\">" + displayName +
-                               "</A>");
-                }
-                out1.write("<BR> \n");
-            }
-
-            out1.write("</FONT></TD>\n</TR>\n</TABLE>\n" + body2 + footer);
-
-            out1.close();
-            fw1.close();
-
-            /* Creates overview-summary.html */
-            fw1 = new FileWriter(outputDir + "overview-summary.html", false);
-            out1 = new BufferedWriter(fw1);
-
-            out1.write(header1 + new Date() + header2 + Main.getVersionName() +
-                       header4 + body1 +
-                       "<p>This is the list of time zones generated from <B>" +
-                       Main.getVersionName() + "</B> for Java Platform, " +
-                       "Standard Edition. The source code can be obtained " +
-                       "from ftp site <a href=\"ftp://elsie.nci.nih.gov/pub/\">" +
-                       "ftp://elsie.nci.nih.gov/pub/</a>. A total of <B>" +
-                       len +
-                       "</B> time zones and aliases are supported " +
-                       "in this edition. For the " +
-                       "format of rules and zones, refer to the zic " +
-                       "(zoneinfo compiler) man page on " +
-                       "Solaris or Linux.</p>\n" +
-                       "<p>Note that the time zone data is not " +
-                       "a public interface of the Java Platform. No " +
-                       "applications should rely on the time zone data of " +
-                       "this document. Time zone names and data " +
-                       "may change without any prior notice.</p>\n" +
-                       body2 + footer);
-
-            out1.close();
-            fw1.close();
-        } catch(IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-            return 1;
-        }
-
-        return 0;
-    }
-
-    String transform(String s) {
-        int index = s.lastIndexOf("/");
-
-        /* If the string doesn't include any delimiter, return */
-        if (index == -1) {
-            return s;
-        }
-
-        int lastIndex = index;
-        String str = s.substring(index+1);
-        do {
-            index = s.substring(0, lastIndex).lastIndexOf('/');
-            str += ", " + s.substring(index+1, lastIndex);
-            lastIndex = index;
-        } while (index > -1);
-
-        return str;
-    }
-
-    static class LatitudeAndLongitude {
-
-        private int latDeg, latMin, latSec, longDeg, longMin, longSec;
-
-        LatitudeAndLongitude(String s) {
-            try {
-                // First of all, check the string has the correct format:
-                //    either +-DDMM+-DDDMM or +-DDMMSS+-DDDMMSS
-
-                if (!s.startsWith("+") && !s.startsWith("-")) {
-                    Main.warning("Wrong latitude&longitude data: " + s);
-                    return;
-                }
-                int index;
-                if (((index = s.lastIndexOf("+")) <= 0) &&
-                    ((index = s.lastIndexOf("-")) <= 0)) {
-                    Main.warning("Wrong latitude&longitude data: " + s);
-                    return;
-                }
-
-                if (index == 5) {
-                    latDeg = Integer.parseInt(s.substring(1, 3));
-                    latMin = Integer.parseInt(s.substring(3, 5));
-                    latSec = 0;
-                } else if (index == 7) {
-                    latDeg = Integer.parseInt(s.substring(1, 3));
-                    latMin = Integer.parseInt(s.substring(3, 5));
-                    latSec = Integer.parseInt(s.substring(5, 7));
-                } else {
-                    Main.warning("Wrong latitude&longitude data: " + s);
-                    return;
-                }
-                if (s.startsWith("-")){
-                        latDeg = -latDeg;
-                        latMin = -latMin;
-                        latSec = -latSec;
-                }
-
-                int len = s.length();
-                if (index == 5 && len == 11) {
-                    longDeg = Integer.parseInt(s.substring(index+1, index+4));
-                    longMin = Integer.parseInt(s.substring(index+4, index+6));
-                    longSec = 0;
-                } else if (index == 7 && len == 15) {
-                    longDeg = Integer.parseInt(s.substring(index+1, index+4));
-                    longMin = Integer.parseInt(s.substring(index+4, index+6));
-                    longSec = Integer.parseInt(s.substring(index+6, index+8));
-                } else {
-                    Main.warning("Wrong latitude&longitude data: " + s);
-                    return;
-                }
-                if (s.charAt(index) == '-'){
-                        longDeg = -longDeg;
-                        longMin = -longMin;
-                        longSec = -longSec;
-                }
-            } catch(Exception e) {
-                Main.warning("LatitudeAndLongitude() Parse error: " + s);
-            }
-        }
-
-        int getLatDeg() {
-            return latDeg;
-        }
-
-        int getLatMin() {
-            return latMin;
-        }
-
-        int getLatSec() {
-            return latSec;
-        }
-
-        int getLongDeg() {
-            return longDeg;
-        }
-
-        int getLongMin() {
-            return longMin;
-        }
-
-        int getLongSec() {
-            return longSec;
-        }
-    }
-}
--- a/make/tools/src/build/tools/javazic/Main.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,238 +0,0 @@
-/*
- * Copyright (c) 2000, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Main class for the javazic time zone data compiler.
- *
- * @since 1.4
- */
-public class Main {
-
-    private static boolean verbose = false;
-    static boolean outputDoc = false;
-
-    private List<String> ziFiles = new ArrayList<String>();
-    private static String zoneNamesFile = null;
-    private static String versionName = "unknown";
-    private static String outputDir = "zoneinfo";
-    private static String mapFile = null;
-
-    /**
-     * Parses the specified arguments and sets up the variables.
-     * @param argv the arguments
-     */
-    void processArgs(String[] argv) {
-        for (int i = 0; i < argv.length; i++) {
-            String arg = argv[i];
-            if (arg.startsWith("-h")) {
-                usage();
-                System.exit(0);
-            } else if (arg.equals("-d")) {
-                outputDir = argv[++i];
-            } else if (arg.equals("-v")) {
-                verbose = true;
-            } else if (arg.equals("-V")) {
-                versionName = argv[++i];
-            } else if (arg.equals("-doc")) {
-                outputDoc = true;
-            } else if (arg.equals("-map")) {
-                outputDoc = true;
-                mapFile = argv[++i];
-            } else if (arg.equals("-f")) {
-                zoneNamesFile = argv[++i];
-            } else if (arg.equals("-S")) {
-                try {
-                    Zoneinfo.setYear(Integer.parseInt(argv[++i]));
-                } catch (Exception e) {
-                    error("invalid year: " + argv[i]);
-                    usage();
-                    System.exit(1);
-                }
-            } else {
-                boolean isStartYear = arg.equals("-s");
-                if (isStartYear || arg.equals("-e")) {
-                    try {
-                        int year = Integer.parseInt(argv[++i]);
-                        if (isStartYear) {
-                            Zoneinfo.setStartYear(year);
-                        } else {
-                            Zoneinfo.setEndYear(year);
-                        }
-                    } catch (Exception e) {
-                        error("invalid year: " + argv[i]);
-                        usage();
-                        System.exit(1);
-                    }
-                } else {
-                    // the rest of args are zoneinfo source files
-                    while (i < argv.length) {
-                        ziFiles.add(argv[i++]);
-                    }
-                }
-            }
-        }
-    }
-
-    /**
-     * Parses zoneinfo source files
-     */
-    int compile() {
-        int nFiles = ziFiles.size();
-        int status = 0;
-        Mappings maps = new Mappings();
-        BackEnd backend = BackEnd.getBackEnd();
-
-        for (int i = 0; i < nFiles; i++) {
-            Zoneinfo frontend = Zoneinfo.parse(ziFiles.get(i));
-
-            for (String key : frontend.getZones().keySet()) {
-                info(key);
-
-                Timezone tz = frontend.phase2(key);
-                status |= backend.processZoneinfo(tz);
-            }
-
-            maps.add(frontend);
-        }
-
-        // special code for dealing with the conflicting name "MET"
-        Zone.addMET();
-
-        maps.resolve();
-
-        status |= backend.generateSrc(maps);
-
-        return status;
-    }
-
-    public static void main(String[] argv) {
-        Main zic = new Main();
-
-        /*
-         * Parse args
-         */
-        zic.processArgs(argv);
-
-        /*
-         * Read target zone names
-         */
-        if (zoneNamesFile != null) {
-            Zone.readZoneNames(zoneNamesFile);
-        }
-
-        int status = zic.compile();
-
-        System.exit(status);
-    }
-
-    void usage() {
-        System.err.println("Usage: javazic [options] file...\n"+
-                           "         -f namefile  file containing zone names\n"+
-                           "                      to be generated (ie, generating subset)\n"+
-                           "         -d dir       output directory\n"+
-                           "         -v           verbose\n"+
-                           "         -V datavers  specifies the tzdata version string\n"+
-                           "                      (eg, \"tzdata2000g\")"+
-                           "         -S year      output only SimleTimeZone data of that year\n"+
-                           "         -s year      start year (default: 1900)\n"+
-                           "         -e year      end year (default: 2037)\n"+
-                           "         -doc         generates HTML documents\n"+
-                           "         -map mapfile generates HTML documents with map information\n"+
-                           "         file...      zoneinfo source file(s)");
-    }
-
-    /**
-     * @return the output directory path name
-     */
-    static String getOutputDir() {
-        return outputDir;
-    }
-
-    /**
-     * @return the map file's path and name
-     */
-    static String getMapFile() {
-        return mapFile;
-    }
-
-    /**
-     * Returns the time zone data version string specified by the -V
-     * option. If it is not specified, "unknown" is returned.
-     * @return the time zone data version string
-     */
-    static String getVersionName() {
-        return versionName;
-    }
-
-    /**
-     * Prints out the specified fatal error message and calls {@link
-     * java.lang.System#exit System.exit(1)}.
-     * @param msg the fatal error message
-     */
-    static void panic(String msg) {
-        printMessage("fatal error", msg);
-        System.exit(1);
-    }
-
-    /**
-     * Prints out the specified error message.
-     * @param msg the error message
-     */
-    static void error(String msg) {
-        printMessage("error", msg);
-    }
-
-    /**
-     * Prints out the specified warning message.
-     * @param msg the warning message
-     */
-    static void warning(String msg) {
-        printMessage("warning", msg);
-    }
-
-    /**
-     * Prints out the informative message.
-     * @param msg the informative message
-     */
-    static void info(String msg) {
-        if (verbose) {
-            printMessage(null, msg);
-        }
-    }
-
-    private static void printMessage(String type, String msg) {
-        if (type != null) {
-            type += ": ";
-        } else {
-            type = "";
-        }
-        System.err.println("javazic: " + type + msg);
-    }
-}
--- a/make/tools/src/build/tools/javazic/Mappings.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,197 +0,0 @@
-/*
- * Copyright (c) 2000, 2012, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import  java.util.ArrayList;
-import  java.util.HashMap;
-import  java.util.LinkedList;
-import  java.util.List;
-import  java.util.Map;
-import  java.util.Set;
-import  java.util.TreeMap;
-import  java.util.TreeSet;
-
-/**
- * <code>Mappings</code> generates two Maps and a List which are used by
- * javazic BackEnd.
- *
- * @since 1.4
- */
-class Mappings {
-    // All aliases specified by Link statements. It's alias name to
-    // real name mappings.
-    private Map<String,String> aliases;
-
-    private List<Integer> rawOffsetsIndex;
-
-    private List<Set<String>> rawOffsetsIndexTable;
-
-    // Zone names to be excluded from rawOffset table. Those have GMT
-    // offsets to change some future time.
-    private List<String> excludeList;
-
-    /**
-     * Constructor creates some necessary instances.
-     */
-    Mappings() {
-        aliases = new TreeMap<String,String>();
-        rawOffsetsIndex = new LinkedList<Integer>();
-        rawOffsetsIndexTable = new LinkedList<Set<String>>();
-    }
-
-    /**
-     * Generates aliases and rawOffsets tables.
-     * @param zi a Zoneinfo containing Zones
-     */
-    void add(Zoneinfo zi) {
-        Map<String,Zone> zones = zi.getZones();
-
-        for (String zoneName : zones.keySet()) {
-            Zone zone = zones.get(zoneName);
-            String zonename = zone.getName();
-            int rawOffset = zone.get(zone.size()-1).getGmtOffset();
-
-            // If the GMT offset of this Zone will change in some
-            // future time, this Zone is added to the exclude list.
-            boolean isExcluded = false;
-            for (int i = 0; i < zone.size(); i++) {
-                ZoneRec zrec = zone.get(i);
-                if ((zrec.getGmtOffset() != rawOffset)
-                    && (zrec.getUntilTime(0) > Time.getCurrentTime())) {
-                    if (excludeList == null) {
-                        excludeList = new ArrayList<String>();
-                    }
-                    excludeList.add(zone.getName());
-                    isExcluded = true;
-                    break;
-                }
-            }
-
-            if (!rawOffsetsIndex.contains(new Integer(rawOffset))) {
-                // Find the index to insert this raw offset zones
-                int n = rawOffsetsIndex.size();
-                int i;
-                for (i = 0; i < n; i++) {
-                    if (rawOffsetsIndex.get(i) > rawOffset) {
-                        break;
-                    }
-                }
-                rawOffsetsIndex.add(i, rawOffset);
-
-                Set<String> perRawOffset = new TreeSet<String>();
-                if (!isExcluded) {
-                    perRawOffset.add(zonename);
-                }
-                rawOffsetsIndexTable.add(i, perRawOffset);
-            } else if (!isExcluded) {
-                int i = rawOffsetsIndex.indexOf(new Integer(rawOffset));
-                Set<String> perRawOffset = rawOffsetsIndexTable.get(i);
-                perRawOffset.add(zonename);
-            }
-        }
-
-        Map<String,String> a = zi.getAliases();
-        // If there are time zone names which refer to any of the
-        // excluded zones, add those names to the excluded list.
-        if (excludeList != null) {
-            for (String zoneName : a.keySet()) {
-                String realname = a.get(zoneName);
-                if (excludeList.contains(realname)) {
-                    excludeList.add(zoneName);
-                }
-            }
-        }
-        aliases.putAll(a);
-    }
-
-    /**
-     * Adds valid aliases to one of per-RawOffset table and removes
-     * invalid aliases from aliases List. Aliases referring to
-     * excluded zones are not added to a per-RawOffset table.
-     */
-    void resolve() {
-        int index = rawOffsetsIndexTable.size();
-        List<String> toBeRemoved = new ArrayList<String>();
-        for (String key : aliases.keySet()) {
-            boolean validname = false;
-            for (int j = 0; j < index; j++) {
-                Set<String> perRO = rawOffsetsIndexTable.get(j);
-                boolean isExcluded = (excludeList == null) ?
-                                        false : excludeList.contains(key);
-
-                if ((perRO.contains(aliases.get(key)) || isExcluded)
-                    && Zone.isTargetZone(key)) {
-                    validname = true;
-                    if (!isExcluded) {
-                        perRO.add(key);
-                        Main.info("Alias <"+key+"> added to the list.");
-                    }
-                    break;
-                }
-            }
-
-            if (!validname) {
-                Main.info("Alias <"+key+"> removed from the list.");
-                toBeRemoved.add(key);
-            }
-        }
-
-        // Remove zones, if any, from the list.
-        for (String key : toBeRemoved) {
-            aliases.remove(key);
-        }
-        // Eliminate any alias-to-alias mappings. For example, if
-        // there are A->B and B->C, A->B is changed to A->C.
-        Map<String, String> newMap = new HashMap<String, String>();
-        for (String key : aliases.keySet()) {
-            String realid = aliases.get(key);
-            String leaf = realid;
-            while (aliases.get(leaf) != null) {
-                leaf = aliases.get(leaf);
-            }
-            if (!realid.equals(leaf)) {
-                newMap.put(key, leaf);
-            }
-        }
-        aliases.putAll(newMap);
-    }
-
-    Map<String,String> getAliases() {
-        return(aliases);
-    }
-
-    List<Integer> getRawOffsetsIndex() {
-        return(rawOffsetsIndex);
-    }
-
-    List<Set<String>> getRawOffsetsIndexTable() {
-        return(rawOffsetsIndexTable);
-    }
-
-    List<String> getExcludeList() {
-        return excludeList;
-    }
-}
--- a/make/tools/src/build/tools/javazic/Month.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,94 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Month enum handles month related manipulation.
- *
- * @since 1.4
- */
-enum Month {
-    JANUARY("Jan"),
-    FEBRUARY("Feb"),
-    MARCH("Mar"),
-    APRIL("Apr"),
-    MAY("May"),
-    JUNE("Jun"),
-    JULY("Jul"),
-    AUGUST("Aug"),
-    SEPTEMBER("Sep"),
-    OCTOBER("Oct"),
-    NOVEMBER("Nov"),
-    DECEMBER("Dec");
-
-    private final String abbr;
-
-    private static final Map<String,Month> abbreviations
-                                = new HashMap<String,Month>(12);
-
-    static {
-        for (Month m : Month.values()) {
-            abbreviations.put(m.abbr, m);
-        }
-    }
-
-    private Month(String abbr) {
-        this.abbr = abbr;
-    }
-
-    int value() {
-        return ordinal() + 1;
-    }
-
-    /**
-     * Parses the specified string as a month abbreviation.
-     * @param name the month abbreviation
-     * @return the Month value
-     */
-    static Month parse(String name) {
-        Month m = abbreviations.get(name);
-        if (m != null) {
-            return m;
-        }
-        return null;
-    }
-
-    /**
-     * @param month the nunmth number (1-based)
-     * @return the month name in uppercase of the specified month
-     */
-    static String toString(int month) {
-        if (month >= JANUARY.value() && month <= DECEMBER.value()) {
-            return "Calendar." + Month.values()[month - 1];
-        }
-        throw new IllegalArgumentException("wrong month number: " + month);
-    }
-}
--- a/make/tools/src/build/tools/javazic/Rule.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,184 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.List;
-import java.util.StringTokenizer;
-
-/**
- * Rule manipulates Rule records.
- *
- * @since 1.4
- */
-class Rule {
-
-    private List<RuleRec> list;
-    private String name;
-
-    /**
-     * Constructs a Rule which consists of a Rule record list. The
-     * specified name is given to this Rule.
-     * @param name the Rule name
-     */
-    Rule(String name) {
-        this.name = name;
-        list = new ArrayList<RuleRec>();
-    }
-
-    /**
-     * Added a RuleRec to the Rule record list.
-     */
-    void add(RuleRec rec) {
-        list.add(rec);
-    }
-
-    /**
-     * @return the Rule name
-     */
-    String getName() {
-        return name;
-    }
-
-    /**
-     * Gets all rule records that cover the given year.
-     *
-     * @param year the year number for which the rule is applicable.
-     * @return rules in List that are collated in time. If no rule is found, an empty
-     * List is returned.
-     */
-    List<RuleRec> getRules(int year) {
-        List<RuleRec> rules = new ArrayList<RuleRec>(3);
-        for (RuleRec rec : list) {
-            if (year >= rec.getFromYear() && year <= rec.getToYear()) {
-                if ((rec.isOdd() && year % 2 == 0) || (rec.isEven() && year % 2 == 1))
-                    continue;
-                rules.add(rec);
-            }
-        }
-        int n = rules.size();
-        if (n <= 1) {
-            return rules;
-        }
-        if (n == 2) {
-            RuleRec rec1 = rules.get(0);
-            RuleRec rec2 = rules.get(1);
-            if (rec1.getMonthNum() > rec2.getMonthNum()) {
-                rules.set(0, rec2);
-                rules.set(1, rec1);
-            } else if (rec1.getMonthNum() == rec2.getMonthNum()) {
-                // TODO: it's not accurate to ignore time types (STD, WALL, UTC)
-                long t1 = Time.getLocalTime(year, rec1.getMonth(),
-                                            rec1.getDay(), rec1.getTime().getTime());
-                long t2 = Time.getLocalTime(year, rec2.getMonth(),
-                                            rec2.getDay(), rec2.getTime().getTime());
-                if (t1 > t2) {
-                    rules.set(0, rec2);
-                    rules.set(1, rec1);
-                }
-            }
-            return rules;
-        }
-
-        final int y = year;
-        RuleRec[] recs = new RuleRec[rules.size()];
-        rules.toArray(recs);
-        Arrays.sort(recs, new Comparator<RuleRec>() {
-                public int compare(RuleRec r1, RuleRec r2) {
-                    int n = r1.getMonthNum() - r2.getMonthNum();
-                    if (n != 0) {
-                        return n;
-                    }
-                    // TODO: it's not accurate to ignore time types (STD, WALL, UTC)
-                    long t1 = Time.getLocalTime(y, r1.getMonth(),
-                                                r1.getDay(), r1.getTime().getTime());
-                    long t2 = Time.getLocalTime(y, r2.getMonth(),
-                                                r2.getDay(), r2.getTime().getTime());
-                    return (int)(t1 - t2);
-                }
-                public boolean equals(Object o) {
-                    return this == o;
-                }
-            });
-        rules.clear();
-        for (int i = 0; i < n; i++) {
-            rules.add(recs[i]);
-        }
-        return rules;
-    }
-
-    /**
-     * Gets rule records that have either "max" or cover the endYear
-     * value in its DST schedule.
-     *
-     * @return rules that contain last DST schedule. An empty
-     * ArrayList is returned if no last rules are found.
-     */
-    List<RuleRec> getLastRules() {
-        RuleRec start = null;
-        RuleRec end = null;
-
-        for (int i = 0; i < list.size(); i++) {
-            RuleRec rec = list.get(i);
-            if (rec.isLastRule()) {
-                if (rec.getSave() > 0) {
-                    start = rec;
-                } else {
-                    end = rec;
-                }
-            }
-        }
-        if (start == null || end == null) {
-            int endYear = Zoneinfo.getEndYear();
-            for (int i  = 0; i < list.size(); i++) {
-                RuleRec rec = list.get(i);
-                if (endYear >= rec.getFromYear() && endYear <= rec.getToYear()) {
-                    if (start == null && rec.getSave() > 0) {
-                        start = rec;
-                    } else {
-                        if (end == null && rec.getSave() == 0) {
-                            end = rec;
-                        }
-                    }
-                }
-            }
-        }
-
-        List<RuleRec> r = new ArrayList<RuleRec>(2);
-        if (start == null || end == null) {
-            if (start != null || end != null) {
-                Main.warning("found last rules for "+name+" inconsistent.");
-            }
-            return r;
-        }
-
-        r.add(start);
-        r.add(end);
-        return r;
-    }
-}
--- a/make/tools/src/build/tools/javazic/RuleDay.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,190 +0,0 @@
-/*
- * Copyright (c) 2000, 2010, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * RuleDay class represents the value of the "ON" field.  The day of
- * week values start from 1 following the {@link java.util.Calendar}
- * convention.
- *
- * @since 1.4
- */
-class RuleDay {
-    private static final Map<String,DayOfWeek> abbreviations = new HashMap<String,DayOfWeek>(7);
-    static {
-        for (DayOfWeek day : DayOfWeek.values()) {
-            abbreviations.put(day.getAbbr(), day);
-        }
-    }
-
-    private String dayName = null;
-    private DayOfWeek dow;
-    private boolean lastOne = false;
-    private int soonerOrLater = 0;
-    private int thanDayOfMonth; // day of month (e.g., 8 for "Sun>=8")
-
-    RuleDay() {
-    }
-
-    RuleDay(int day) {
-        thanDayOfMonth = day;
-    }
-
-    int getDay() {
-        return thanDayOfMonth;
-    }
-
-    /**
-     * @return the day of week value (1-based)
-     */
-    int getDayOfWeekNum() {
-        return dow.value();
-    }
-
-    /**
-     * @return true if this rule day represents the last day of
-     * week. (e.g., lastSun).
-     */
-    boolean isLast() {
-        return lastOne;
-    }
-
-    /**
-     * @return true if this rule day represents the day of week on or
-     * later than (after) the {@link #getDay}. (e.g., Sun>=1)
-     */
-    boolean isLater() {
-        return soonerOrLater > 0;
-    }
-
-    /**
-     * @return true if this rule day represents the day of week on or
-     * earlier than (before) the {@link #getDay}. (e.g., Sun<=15)
-     */
-    boolean isEarlier() {
-        return soonerOrLater < 0;
-    }
-
-    /**
-     * @return true if this rule day represents an exact day.
-     */
-    boolean isExact() {
-        return soonerOrLater == 0;
-    }
-
-    /**
-     * Parses the "ON" field and constructs a RuleDay.
-     * @param day an "ON" field string (e.g., "Sun>=1")
-     * @return a RuleDay representing the given "ON" field
-     */
-    static RuleDay parse(String day) {
-        RuleDay d = new RuleDay();
-        if (day.startsWith("last")) {
-            d.lastOne = true;
-            d.dayName = day.substring(4);
-            d.dow = getDOW(d.dayName);
-        } else {
-            int index;
-            if ((index = day.indexOf(">=")) != -1) {
-                d.dayName = day.substring(0, index);
-                d.dow = getDOW(d.dayName);
-                d.soonerOrLater = 1; // greater or equal
-                d.thanDayOfMonth = Integer.parseInt(day.substring(index+2));
-            } else if ((index = day.indexOf("<=")) != -1) {
-                d.dayName = day.substring(0, index);
-                d.dow = getDOW(d.dayName);
-                d.soonerOrLater = -1; // less or equal
-                d.thanDayOfMonth = Integer.parseInt(day.substring(index+2));
-            } else {
-                // it should be an integer value.
-                d.thanDayOfMonth = Integer.parseInt(day);
-            }
-        }
-        return d;
-    }
-
-    /**
-     * Converts this RuleDay to the SimpleTimeZone day rule.
-     * @return the converted SimpleTimeZone day rule
-     */
-    int getDayForSimpleTimeZone() {
-        if (isLast()) {
-            return -1;
-        }
-        return isEarlier() ? -getDay() : getDay();
-    }
-
-    /**
-     * Converts this RuleDay to the SimpleTimeZone day-of-week rule.
-     * @return the SimpleTimeZone day-of-week rule value
-     */
-    int getDayOfWeekForSimpleTimeZoneInt() {
-        if (isEarlier() || isLater()) {
-            return -getDayOfWeekNum();
-        }
-        return isLast() ? getDayOfWeekNum() : 0;
-    }
-
-    /**
-     * @return the string representation of the {@link
-     * #getDayOfWeekForSimpleTimeZoneInt} value
-     */
-    String getDayOfWeekForSimpleTimeZone() {
-        int d = getDayOfWeekForSimpleTimeZoneInt();
-        if (d == 0) {
-            return "0";
-        }
-        String sign = "";
-        if (d < 0) {
-            sign = "-";
-            d = -d;
-        }
-        return sign + toString(d);
-    }
-
-    private static DayOfWeek getDOW(String abbr) {
-        return abbreviations.get(abbr);
-    }
-
-    /**
-     * Converts the specified day of week value to the day-of-week
-     * name defined in {@link java.util.Calenda}.
-     * @param dow 1-based day of week value
-     * @return the Calendar day of week name with "Calendar." prefix.
-     * @throws IllegalArgumentException if the specified dow value is out of range.
-     */
-    static String toString(int dow) {
-        if (dow >= DayOfWeek.SUNDAY.value() && dow <= DayOfWeek.SATURDAY.value()) {
-            return "Calendar." + DayOfWeek.values()[dow - 1];
-        }
-        throw new IllegalArgumentException("wrong Day_of_Week number: " + dow);
-    }
-}
--- a/make/tools/src/build/tools/javazic/RuleRec.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,232 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.StringTokenizer;
-
-/**
- * RuleRec class represents one record of the Rule set.
- *
- * @since 1.4
- */
-class RuleRec {
-    private int fromYear;
-    private int toYear;
-    private String type;
-    private Month inMonth;
-    private RuleDay onDay;
-    private Time atTime;
-    private int save;
-    private String letters;
-    private String line;
-    private boolean isLastRule;
-
-    int getFromYear() {
-        return fromYear;
-    }
-
-    int getToYear() {
-        return toYear;
-    }
-
-    Month getMonth() {
-        return inMonth;
-    }
-
-    int getMonthNum() {
-        return inMonth.value();
-    }
-
-    RuleDay getDay() {
-        return onDay;
-    }
-
-    Time getTime() {
-        return atTime;
-    }
-
-    int getSave() {
-        return save;
-    }
-
-    String getLine() {
-        return line;
-    }
-
-    /**
-     * Sets the line from the text file.
-     * @param line the text of the line
-     */
-    void setLine(String line) {
-        this.line = line;
-    }
-
-    /**
-     * @return true if the rule type is "odd".
-     */
-    boolean isOdd() {
-        return "odd".equals(type);
-    }
-
-    /**
-     * @return true if the rule type is "even".
-     */
-    boolean isEven() {
-        return "even".equals(type);
-    }
-
-    /**
-     * Determines if this rule record is the last DST schedule rule.
-     *
-     * @return true if this rule record has "max" as TO (year).
-     */
-    boolean isLastRule() {
-        return isLastRule;
-    }
-
-    /**
-     * Determines if the unadjusted until time of the specified ZoneRec
-     * is the same as the transition time of this rule in the same
-     * year as the ZoneRec until year.
-     *
-     * @param zrec ZoneRec to compare to
-     * @param save the amount of daylight saving in milliseconds
-     * @param gmtOffset the GMT offset value in milliseconds
-     * @return true if the unadjusted until time is the same as rule's
-     * transition time.
-     */
-    boolean isSameTransition(ZoneRec zrec, int save, int gmtOffset) {
-        long    until, transition;
-
-        if (zrec.getUntilTime().getType() != atTime.getType()) {
-            until = zrec.getLocalUntilTime(save, gmtOffset);
-            transition = Time.getLocalTime(zrec.getUntilYear(),
-                                           getMonth(),
-                                           getDay(),
-                                           save,
-                                           gmtOffset,
-                                           atTime);
-        } else {
-            until = zrec.getLocalUntilTime();
-            transition = Time.getLocalTime(zrec.getUntilYear(),
-                                           getMonth(),
-                                           getDay(),
-                                           atTime.getTime());
-        }
-
-        return until == transition;
-    }
-
-    /**
-     * Parses a Rule line and returns a RuleRec object.
-     *
-     * @param tokens a StringTokenizer object that should contain a
-     * token for the "FROM" field and the rest.
-     * @return a RuleRec object.
-     */
-    static RuleRec parse(StringTokenizer tokens) {
-        RuleRec rec = new RuleRec();
-        try {
-            // FROM
-            String token = tokens.nextToken();
-            try {
-                rec.fromYear = Integer.parseInt(token);
-            } catch (NumberFormatException e) {
-                // it's not integer
-                if ("min".equals(token) || "minimum".equals(token)) {
-                    rec.fromYear = Zoneinfo.getMinYear();
-                } else if ("max".equals(token) || "maximum".equals(token)) {
-                    rec.fromYear = Zoneinfo.getMaxYear();
-                } else {
-                    Main.panic("invalid year value: "+token);
-                }
-            }
-
-            // TO
-            token = tokens.nextToken();
-            rec.isLastRule = false;
-            try {
-                rec.toYear = Integer.parseInt(token);
-            } catch (NumberFormatException e) {
-                // it's not integer
-                if ("min".equals(token) || "minimum".equals(token)) {
-                    rec.fromYear = Zoneinfo.getMinYear();
-                } else if ("max".equals(token) || "maximum".equals(token)) {
-                    rec.toYear = Integer.MAX_VALUE;
-                    rec.isLastRule = true;
-                } else if ("only".equals(token)) {
-                    rec.toYear = rec.fromYear;
-                } else {
-                    Main.panic("invalid year value: "+token);
-                }
-            }
-
-            // TYPE
-            rec.type = tokens.nextToken();
-
-            // IN
-            rec.inMonth = Month.parse(tokens.nextToken());
-
-            // ON
-            rec.onDay = RuleDay.parse(tokens.nextToken());
-
-            // AT
-            rec.atTime = Time.parse(tokens.nextToken());
-
-            // SAVE
-            rec.save = (int) Time.parse(tokens.nextToken()).getTime();
-
-            // LETTER/S
-            rec.letters = tokens.nextToken();
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-        return rec;
-    }
-
-    /**
-     * Calculates the transition time of the given year under this rule.
-     * @param year the year value
-     * @param gmtOffset the GMT offset value in milliseconds
-     * @param save the amount of daylight save time
-     * @return the transition time in milliseconds of the given year in UTC.
-     */
-    long getTransitionTime(int year, int gmtOffset, int save) {
-        long time = Time.getLocalTime(year, getMonth(),
-                                      getDay(), atTime.getTime());
-        if (atTime.isSTD()) {
-            time -= gmtOffset;
-        } else if (atTime.isWall()) {
-            time -= gmtOffset + save;
-        }
-        return time;
-    }
-
-    private static int getInt(StringTokenizer tokens) {
-        String token = tokens.nextToken();
-        return Integer.parseInt(token);
-    }
-}
--- a/make/tools/src/build/tools/javazic/Simple.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,188 +0,0 @@
-/*
- * Copyright (c) 2000, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import  java.io.BufferedWriter;
-import  java.io.File;
-import  java.io.FileWriter;
-import  java.io.IOException;
-import  java.util.HashMap;
-import  java.util.List;
-import  java.util.Map;
-import  java.util.Set;
-import  java.util.SortedMap;
-import  java.util.TreeMap;
-import  java.util.TreeSet;
-
-/**
- * <code>Simple</code> generates TimeZoneData, which had been used as internal
- * data of TimeZone before J2SDK1.3.
- * Since J2SDK1.4 doesn't need TimeZoneData, this class is for maintenance
- * of old JDK release.
- */
-class Simple extends BackEnd {
-
-    /**
-     * Zone records which are applied for given year.
-     */
-    private static Map<String,ZoneRec> lastZoneRecs = new HashMap<>();
-
-    /**
-     * Rule records which are applied for given year.
-     */
-    private static Map<String,List<RuleRec>> lastRules = new TreeMap<>();
-
-    /**
-     * zone IDs sorted by their GMT offsets. If zone's GMT
-     * offset will change in the future, its last known offset is
-     * used.
-     */
-    private SortedMap<Integer, Set<String>> zonesByOffset = new TreeMap<>();
-
-    /**
-     * Sets last Rule records and Zone records for given timezone to
-     * each Map.
-     *
-     * @param tz Timezone object for each zone
-     * @return always 0
-     */
-    int processZoneinfo(Timezone tz) {
-        String zonename = tz.getName();
-
-        lastRules.put(zonename, tz.getLastRules());
-        lastZoneRecs.put(zonename, tz.getLastZoneRec());
-
-        // Populate zonesByOffset. (Zones that will change their
-        // GMT offsets are also added to zonesByOffset here.)
-        int lastKnownOffset = tz.getRawOffset();
-        Set<String> set = zonesByOffset.get(lastKnownOffset);
-        if (set == null) {
-            set = new TreeSet<>();
-            zonesByOffset.put(lastKnownOffset, set);
-        }
-        set.add(zonename);
-
-        return 0;
-    }
-
-    /**
-     * Generates TimeZoneData to output SimpleTimeZone data.
-     * @param map Mappings object which is generated by {@link Main#compile}.
-     * @return 0 if no error occurred, otherwise 1.
-     */
-    int generateSrc(Mappings map) {
-        try {
-            File outD = new File(Main.getOutputDir());
-            outD.mkdirs();
-
-            FileWriter fw =
-                new FileWriter(new File(outD, "TimeZoneData.java"), false);
-            BufferedWriter out = new BufferedWriter(fw);
-
-            out.write("import java.util.SimpleTimeZone;\n\n");
-            out.write("    static SimpleTimeZone zones[] = {\n");
-
-            Map<String,String> a = map.getAliases();
-            List<Integer> roi = map.getRawOffsetsIndex();
-            List<Set<String>> roit = map.getRawOffsetsIndexTable();
-
-            int index = 0;
-            for (int offset : zonesByOffset.keySet()) {
-                int o = roi.get(index);
-                Set<String> set = zonesByOffset.get(offset);
-                if (offset == o) {
-                    // Merge aliases into zonesByOffset
-                    set.addAll(roit.get(index));
-                }
-                index++;
-
-                for (String key : set) {
-                    ZoneRec zrec;
-                    String realname;
-                    List<RuleRec> stz;
-                    if ((realname = a.get(key)) != null) {
-                        // if this alias is not targeted, ignore it.
-                        if (!Zone.isTargetZone(key)) {
-                            continue;
-                        }
-                        stz = lastRules.get(realname);
-                        zrec = lastZoneRecs.get(realname);
-                    } else {
-                        stz = lastRules.get(key);
-                        zrec = lastZoneRecs.get(key);
-                    }
-
-                    out.write("\t//--------------------------------------------------------------------\n");
-                    String s = Time.toFormedString(offset);
-                    out.write("\tnew SimpleTimeZone(" +
-                        Time.toFormedString(offset) + ", \"" + key + "\"");
-                    if (realname != null) {
-                        out.write(" /* " + realname + " */");
-                    }
-
-                    if (stz == null) {
-                        out.write("),\n");
-                    } else {
-                        RuleRec rr0 = stz.get(0);
-                        RuleRec rr1 = stz.get(1);
-
-                        out.write(",\n\t  " + Month.toString(rr0.getMonthNum()) +
-                                  ", " + rr0.getDay().getDayForSimpleTimeZone() + ", " +
-                                  rr0.getDay().getDayOfWeekForSimpleTimeZone() + ", " +
-                                  Time.toFormedString((int)rr0.getTime().getTime()) + ", " +
-                                  rr0.getTime().getTypeForSimpleTimeZone() + ",\n" +
-
-                                  "\t  " + Month.toString(rr1.getMonthNum()) + ", " +
-                                  rr1.getDay().getDayForSimpleTimeZone() + ", " +
-                                  rr1.getDay().getDayOfWeekForSimpleTimeZone() + ", " +
-                                  Time.toFormedString((int)rr1.getTime().getTime())+ ", " +
-                                  rr1.getTime().getTypeForSimpleTimeZone() + ",\n" +
-
-                                  "\t  " + Time.toFormedString(rr0.getSave()) + "),\n");
-
-                        out.write("\t// " + rr0.getLine() + "\n");
-                        out.write("\t// " + rr1.getLine() + "\n");
-                    }
-
-                    String zline = zrec.getLine();
-                    if (zline.indexOf("Zone") == -1) {
-                        zline = "Zone " + key + "\t" + zline.trim();
-                    }
-                    out.write("\t// " + zline + "\n");
-                }
-            }
-            out.write("    };\n");
-
-            out.close();
-            fw.close();
-        } catch(IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-            return 1;
-        }
-
-        return 0;
-    }
-}
--- a/make/tools/src/build/tools/javazic/Time.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,343 +0,0 @@
-/*
- * Copyright (c) 2000, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.Locale;
-import sun.util.calendar.CalendarDate;
-import sun.util.calendar.CalendarSystem;
-import sun.util.calendar.Gregorian;
-
-/**
- * Time class represents the "AT" field and other time related information.
- *
- * @since 1.4
- */
-class Time {
-
-    static final Gregorian gcal = CalendarSystem.getGregorianCalendar();
-
-    // type is wall clock time
-    private static final int WALL = 1;
-
-    // type is standard time
-    private static final int STD = 2;
-
-    // type is UTC
-    private static final int UTC = 3;
-
-    // type of representing time
-    private int type;
-
-    /**
-     * Time from the EPOCH in milliseconds
-     */
-    private long time;
-
-    /**
-     * Current time in milliseconds
-     */
-    private static final long currentTime = System.currentTimeMillis();
-
-    Time() {
-        time = 0L;
-    }
-
-    Time(long time) {
-        this.time = time;
-    }
-
-    void setType(int type) {
-        this.type = type;
-    }
-
-    long getTime() {
-        return time;
-    }
-
-    int getType() {
-        return type;
-    }
-
-    static long getCurrentTime() {
-        return currentTime;
-    }
-
-    /**
-     * @return true if the time is represented in wall-clock time.
-     */
-    boolean isWall() {
-        return type == WALL;
-    }
-
-    /**
-     * @return true if the time is represented in standard time.
-     */
-    boolean isSTD() {
-        return type == STD;
-    }
-
-    /**
-     * @return true if the time is represented in UTC time.
-     */
-    boolean isUTC() {
-        return type == UTC;
-    }
-
-    /**
-     * Converts the type to a string that represents the type in the
-     * SimpleTimeZone time mode. (e.g., "SimpleTimeZone.WALL_TIME").
-     * @return the converted string or null if the type is undefined.
-     */
-    String getTypeForSimpleTimeZone() {
-        String  stz = "SimpleTimeZone.";
-        if (isWall()) {
-            return stz+"WALL_TIME";
-        }
-        else if (isSTD()) {
-            return stz+"STANDARD_TIME";
-        }
-        else if (isUTC()) {
-            return stz+"UTC_TIME";
-        }
-        else {
-            return null;
-        }
-    }
-
-    /**
-     * Converts the given Gregorian calendar field values to local time.
-     * Local time is represented by the amount of milliseconds from
-     * January 1, 1970 0:00 GMT.
-     * @param year the year value
-     * @param month the Month value
-     * @param day the day represented by {@link RuleDay}
-     * @param save the amount of daylight time in milliseconds
-     * @param gmtOffset the GMT offset in milliseconds
-     * @param time the time of the day represented by {@link Time}
-     * @return local time
-     */
-    static long getLocalTime(int year, Month month, RuleDay day, int save,
-                             int gmtOffset, Time time) {
-        long    t = time.getTime();
-
-        if (time.isSTD())
-            t = time.getTime() + save;
-        else if (time.isUTC())
-            t = time.getTime() + save + gmtOffset;
-
-        return getLocalTime(year, month, day, t);
-    }
-
-    /**
-     * Converts the given Gregorian calendar field values to local time.
-     * Local time is represented by the amount of milliseconds from
-     * January 1, 1970 0:00 GMT.
-     * @param year the year value
-     * @param month the Month value
-     * @param day the day value
-     * @param time the time of the day in milliseconds
-     * @return local time
-     */
-    static long getLocalTime(int year, Month month, int day, long time) {
-        CalendarDate date = gcal.newCalendarDate(null);
-        date.setDate(year, month.value(), day);
-        long millis = gcal.getTime(date);
-        return millis + time;
-    }
-
-    /**
-     * Equivalent to <code>getLocalTime(year, month, day, (long)time)</code>.
-     * @param year the year value
-     * @param month the Month value
-     * @param day the day value
-     * @param time the time of the day in milliseconds
-     * @return local time
-     */
-    static long getLocalTime(int year, Month month, int day, int time) {
-        return getLocalTime(year, month, day, (long)time);
-    }
-
-    /**
-     * Equivalent to {@link #getLocalTime(int, Month, RuleDay, int)
-     * getLocalTime(year, month, day, (int) time)}.
-     * @param year the year value
-     * @param month the Month value
-     * @param day the day represented by {@link RuleDay}
-     * @param time the time of the day represented by {@link Time}
-     * @return local time
-     */
-    static long getLocalTime(int year, Month month, RuleDay day, long time) {
-        return getLocalTime(year, month, day, (int) time);
-    }
-
-    /**
-     * Converts the given Gregorian calendar field values to local time.
-     * Local time is represented by the amount of milliseconds from
-     * January 1, 1970 0:00 GMT.
-     * @param year the year value
-     * @param month the Month value
-     * @param day the day represented by {@link RuleDay}
-     * @param time the time of the day represented by {@link Time}
-     * @return local time
-     */
-    static long getLocalTime(int year, Month month, RuleDay day, int time) {
-        CalendarDate cdate = gcal.newCalendarDate(null);
-        int monthValue = month.value();
-
-        if (day.isLast()) {     // e.g., "lastSun"
-            cdate.setDate(year, monthValue, 1);
-            cdate.setDayOfMonth(gcal.getMonthLength(cdate));
-            cdate = gcal.getNthDayOfWeek(-1, day.getDayOfWeekNum(), cdate);
-        } else if (day.isLater()) { // e.g., "Sun>=1"
-            cdate.setDate(year, monthValue, day.getDay());
-            cdate = gcal.getNthDayOfWeek(1, day.getDayOfWeekNum(), cdate);
-        } else if (day.isExact()) {
-            cdate.setDate(year, monthValue, day.getDay());
-        } else if (day.isEarlier()) {   // e.g., "Sun<=15"
-            cdate.setDate(year, monthValue, day.getDay());
-            cdate = gcal.getNthDayOfWeek(-1, day.getDayOfWeekNum(), cdate);
-        } else {
-            Main.panic("invalid day type: " + day);
-        }
-        return gcal.getTime(cdate) + time;
-    }
-
-    /**
-     * Parses the given "AT" field and constructs a Time object.
-     * @param the "AT" field string
-     * @return the Time object
-     */
-    static Time parse(String time) {
-        int sign;
-        int index = 0;
-        Time tm;
-
-        if (time.charAt(0) == '-') {
-            sign = -1;
-            index++;
-        } else {
-            sign = 1;
-        }
-        int val = 0;
-        int num = 0;
-        int countDelim = 0;
-        while (index < time.length()) {
-            char c = time.charAt(index++);
-            if (c == ':') {
-                val = val * 60 + num;
-                countDelim++;
-                num = 0;
-                continue;
-            }
-            int d = Character.digit(c, 10);
-            if (d == -1) {
-                --index;
-                break;
-            }
-            num = num * 10 + d;
-        }
-        val = val * 60 + num;
-        // convert val to second
-        for (; countDelim < 2; countDelim++) {
-            val *= 60;
-        }
-        tm = new Time((long)val * 1000 * sign);
-        if (index < time.length()) {
-            char c = time.charAt(index++);
-            if (c == 's') {
-                tm.setType(Time.STD);
-            } else if (c == 'u' || c == 'g' || c == 'z') {
-                tm.setType(Time.UTC);
-            } else if (c == 'w') {
-                tm.setType(Time.WALL);
-            } else {
-                Main.panic("unknown time mode: "+c);
-            }
-        } else {
-            tm.setType(Time.WALL);
-        }
-        return tm;
-    }
-
-    /**
-     * Converts the given milliseconds string to a "[+-]hh:mm" string.
-     * @param ms the milliseconds string
-     */
-    static String toGMTFormat(String ms) {
-        long sec = Long.parseLong(ms) / 1000;
-        char sign;
-        if (sec < 0) {
-            sign = '-';
-            sec = -sec;
-        } else {
-            sign = '+';
-        }
-        return String.format((Locale)null, "%c%02d:%02d",
-                             sign, sec/3600, (sec%3600)/60);
-    }
-
-    /**
-     * Converts the given millisecond value to a string for a
-     * SimpleTimeZone parameter.
-     * @param ms the millisecond value
-     * @return the string in a human readable form
-     */
-    static String toFormedString(int ms) {
-        StringBuilder s = new StringBuilder();
-        boolean minus = false;
-
-        if (ms < 0) {
-            s.append("-");
-            minus = true;
-            ms = -ms;
-        } else if (ms == 0) {
-            return "0";
-        }
-
-        int hour = ms / (60 * 60 * 1000);
-        ms %= (60 * 60 * 1000);
-        int minute = ms / (60 * 1000);
-
-        if (hour != 0) {
-            if (minus && minute != 0) {
-                s.append("(");
-            }
-            s.append(Integer.toString(hour) + "*ONE_HOUR");
-        }
-
-        if (minute != 0) {
-            if (hour != 0) {
-                s.append("+");
-            }
-            s.append(Integer.toString(minute) + "*ONE_MINUTE");
-            if (minus && hour != 0) {
-                s.append(")");
-            }
-        }
-
-        return s.toString();
-    }
-}
--- a/make/tools/src/build/tools/javazic/Timezone.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,454 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Timezone represents all information of a single point of time to
- * generate its time zone database.
- *
- * @since 1.4
- */
-class Timezone {
-    /**
-     * zone name of this time zone
-     */
-    private String name;
-
-    /**
-     * transition time values in UTC (millisecond)
-     */
-    private List<Long> transitions;
-
-    /**
-     * All offset values in millisecond
-     * @see sun.util.calendar.ZoneInfo
-     */
-    private List<Integer> offsets;
-
-    /**
-     * Indices of GMT offset values (both raw and raw+saving)
-     * at transitions
-     */
-    private List<Integer> gmtOffsets;
-
-    /**
-     * Indices of regular or "direct" saving time values
-     * at transitions
-     */
-    private List<Integer> dstOffsets;
-
-    /**
-     * Zone records of this time zone
-     */
-    private List<ZoneRec> usedZoneRecs;
-
-    /**
-     * Rule records referred to by this time zone
-     */
-    private List<RuleRec> usedRuleRecs;
-
-    /**
-     * Type of DST rules in this time zone
-     */
-    private int dstType;
-    static final int UNDEF_DST = 0;     // DST type not set yet
-    static final int NO_DST = 1;        // never observed DST
-    static final int LAST_DST = 2;      // last rule ends in DST (all year round DST-only)
-    static final int X_DST = 3;         // used to observe DST
-    static final int DST = 4;           // observing DST regularly
-
-    /**
-     * Raw GMT offset of this time zone in the last rule
-     */
-    private int rawOffset;
-
-    /**
-     * The CRC32 value of the transitions data
-     */
-    private int crc32;
-
-    /**
-     * The last ZoneRec
-     */
-    private ZoneRec lastZoneRec;
-
-    /**
-     * The last DST rules. lastRules[0] is the DST start
-     * rule. lastRules[1] is the DST end rules.
-     */
-    private List<RuleRec> lastRules;
-
-    /**
-     * The amount of DST saving value (millisecond) in the last DST
-     * rule.
-     */
-    private int lastSaving;
-
-    /**
-     * true if the raw offset will change in the future time.
-     */
-    private boolean willRawOffsetChange = false;
-
-
-    /**
-     * Constracts a Timezone object with the given zone name.
-     * @param name the zone name
-     */
-    Timezone(String name) {
-        this.name = name;
-    }
-
-    /**
-     * @return the number of transitions
-     */
-    int getNTransitions() {
-        if (transitions == null) {
-            return 0;
-        }
-        return transitions.size();
-    }
-
-    /**
-     * @return the zone name
-     */
-    String getName() {
-        return name;
-    }
-
-    /**
-     * Returns the list of all rule records that have been referred to
-     * by this time zone.
-     * @return the rule records list
-     */
-    List<RuleRec> getRules() {
-        return usedRuleRecs;
-    }
-
-    /**
-     * Returns the list of all zone records that have been referred to
-     * by this time zone.
-     * @return the zone records list
-     */
-    List<ZoneRec> getZones() {
-        return usedZoneRecs;
-    }
-
-    /**
-     * @return the transition table (list)
-     */
-    List<Long> getTransitions() {
-        return transitions;
-    }
-
-    /**
-     * @return the offsets list
-     */
-    List<Integer> getOffsets() {
-        return offsets;
-    }
-
-    /**
-     * @return the DST saving offsets list
-     */
-    List<Integer> getDstOffsets() {
-        return dstOffsets;
-    }
-
-    /**
-     * @return the GMT offsets list
-     */
-    List<Integer> getGmtOffsets() {
-        return gmtOffsets;
-    }
-
-    /**
-     * @return the checksum (crc32) value of the trasition table
-     */
-    int getCRC32() {
-        return crc32;
-    }
-
-    /**
-     * @return true if the GMT offset of this time zone would change
-     * after the time zone database has been generated, false, otherwise.
-     */
-    boolean willGMTOffsetChange() {
-        return willRawOffsetChange;
-    }
-
-    /**
-     * @return the last known GMT offset value in milliseconds
-     */
-    int getRawOffset() {
-        return rawOffset;
-    }
-
-    /**
-     * Sets time zone's GMT offset to <code>offset</code>.
-     * @param offset the GMT offset value in milliseconds
-     */
-    void setRawOffset(int offset) {
-        rawOffset = offset;
-    }
-
-    /**
-     * Sets time zone's GMT offset value to <code>offset</code>. If
-     * <code>startTime</code> is future time, then the {@link
-     * #willRawOffsetChange} value is set to true.
-     * @param offset the GMT offset value in milliseconds
-     * @param startTime the UTC time at which the GMT offset is in effective
-     */
-    void setRawOffset(int offset, long startTime) {
-        // if this rawOffset is for the future time, let the run-time
-        // look for the current GMT offset.
-        if (startTime > Time.getCurrentTime()) {
-            willRawOffsetChange = true;
-        }
-        setRawOffset(offset);
-    }
-
-    /**
-     * Adds the specified transition information to the end of the transition table.
-     * @param time the UTC time at which this transition happens
-     * @param offset the total amount of the offset from GMT in milliseconds
-     * @param dstOffset the amount of time in milliseconds saved at this transition
-     */
-    void addTransition(long time, int offset, int dstOffset) {
-        if (transitions == null) {
-            transitions = new ArrayList<Long>();
-            offsets = new ArrayList<Integer>();
-            dstOffsets = new ArrayList<Integer>();
-        }
-        transitions.add(time);
-        offsets.add(offset);
-        dstOffsets.add(dstOffset);
-    }
-
-    /**
-     * Sets the type of historical daylight saving time
-     * observation. For example, China used to observed daylight
-     * saving time, but it no longer does. Then, X_DST is set to the
-     * China time zone.
-     * @param type the type of daylight saving time
-     */
-    void setDSTType(int type) {
-        dstType = type;
-    }
-
-    /**
-     * @return the type of historical daylight saving time
-     * observation.
-     */
-    int getDSTType() {
-        return dstType;
-    }
-
-    /**
-     * Adds the specified zone record to the zone records list.
-     * @param rec the zone record
-     */
-    void addUsedRec(ZoneRec rec) {
-        if (usedZoneRecs == null) {
-            usedZoneRecs = new ArrayList<ZoneRec>();
-        }
-        usedZoneRecs.add(rec);
-    }
-
-    /**
-     * Adds the specified rule record to the rule records list.
-     * @param rec the rule record
-     */
-    void addUsedRec(RuleRec rec) {
-        if (usedRuleRecs == null) {
-            usedRuleRecs = new ArrayList<RuleRec>();
-        }
-        // if the last used rec is the same as the given rec, avoid
-        // putting the same rule.
-        int n = usedRuleRecs.size();
-        for (int i = 0; i < n; i++) {
-            if (usedRuleRecs.get(i).equals(rec)) {
-                return;
-            }
-        }
-        usedRuleRecs.add(rec);
-    }
-
-    /**
-     * Sets the last zone record for this time zone.
-     * @param the last zone record
-     */
-    void setLastZoneRec(ZoneRec zrec) {
-        lastZoneRec = zrec;
-    }
-
-    /**
-     * @return the last zone record for this time zone.
-     */
-    ZoneRec getLastZoneRec() {
-        return lastZoneRec;
-    }
-
-    /**
-     * Sets the last rule records for this time zone. Those are used
-     * for generating SimpleTimeZone parameters.
-     * @param rules the last rule records
-     */
-    void setLastRules(List<RuleRec> rules) {
-        int n = rules.size();
-        if (n > 0) {
-            lastRules = rules;
-            RuleRec rec = rules.get(0);
-            int offset = rec.getSave();
-            if (offset > 0) {
-                setLastDSTSaving(offset);
-            } else {
-                System.err.println("\t    No DST starting rule in the last rules.");
-            }
-        }
-    }
-
-    /**
-     * @return the last rule records for this time zone.
-     */
-    List<RuleRec> getLastRules() {
-        return lastRules;
-    }
-
-    /**
-     * Sets the last daylight saving amount.
-     * @param the daylight saving amount
-     */
-    void setLastDSTSaving(int offset) {
-        lastSaving = offset;
-    }
-
-    /**
-     * @return the last daylight saving amount.
-     */
-    int getLastDSTSaving() {
-        return lastSaving;
-    }
-
-    /**
-     * Calculates the CRC32 value from the transition table and sets
-     * the value to <code>crc32</code>.
-     */
-    void checksum() {
-        if (transitions == null) {
-            crc32 = 0;
-            return;
-        }
-        Checksum sum = new Checksum();
-        for (int i = 0; i < transitions.size(); i++) {
-            int offset = offsets.get(i);
-            // adjust back to make the transition in local time
-            sum.update(transitions.get(i) + offset);
-            sum.update(offset);
-            sum.update(dstOffsets.get(i));
-        }
-        crc32 = (int)sum.getValue();
-    }
-
-    /**
-     * Removes unnecessary transitions for Java time zone support.
-     */
-    void optimize() {
-        // if there is only one offset, delete all transitions. This
-        // could happen if only time zone abbreviations changed.
-        if (gmtOffsets.size() == 1) {
-            transitions = null;
-            usedRuleRecs =  null;
-            setDSTType(NO_DST);
-            return;
-        }
-        for (int i = 0; i < (transitions.size() - 2); i++) { // don't remove the last one
-            if (transitions.get(i) == transitions.get(i+1)) {
-                transitions.remove(i);
-                offsets.remove(i);
-                dstOffsets.remove(i);
-                i--;
-            }
-        }
-
-        for (int i = 0; i < (transitions.size() - 2); i++) { // don't remove the last one
-            if (offsets.get(i) == offsets.get(i+1)
-                && dstOffsets.get(i) == dstOffsets.get(i+1)) {
-                transitions.remove(i+1);
-                offsets.remove(i+1);
-                dstOffsets.remove(i+1);
-                i--;
-            }
-        }
-    }
-
-    /**
-     * Stores the specified offset value from GMT in the GMT offsets
-     * table and returns its index. The offset value includes the base
-     * GMT offset and any additional daylight saving if applicable. If
-     * the same value as the specified offset is already in the table,
-     * its index is returned.
-     * @param offset the offset value in milliseconds
-     * @return the index to the offset value in the GMT offsets table.
-     */
-    int getOffsetIndex(int offset) {
-        return getOffsetIndex(offset, 0);
-    }
-
-    /**
-     * Stores the specified daylight saving value in the GMT offsets
-     * table and returns its index. If the same value as the specified
-     * offset is already in the table, its index is returned. If 0 is
-     * specified, it's not stored in the table and -1 is returned.
-     * @param offset the offset value in milliseconds
-     * @return the index to the specified offset value in the GMT
-     * offsets table, or -1 if 0 is specified.
-     */
-    int getDstOffsetIndex(int offset) {
-        if (offset == 0) {
-            return -1;
-        }
-        return getOffsetIndex(offset, 1);
-    }
-
-    private int getOffsetIndex(int offset, int index) {
-        if (gmtOffsets == null) {
-            gmtOffsets = new ArrayList<Integer>();
-        }
-        for (int i = index; i < gmtOffsets.size(); i++) {
-            if (offset == gmtOffsets.get(i)) {
-                return i;
-            }
-        }
-        if (gmtOffsets.size() < index) {
-            gmtOffsets.add(0);
-        }
-        gmtOffsets.add(offset);
-        return gmtOffsets.size() - 1;
-    }
-}
--- a/make/tools/src/build/tools/javazic/Zone.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,168 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.io.BufferedReader;
-import java.io.FileReader;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.StringTokenizer;
-
-/**
- * Zone holds information corresponding to a "Zone" part of a time
- * zone definition file.
- *
- * @since 1.4
- */
-class Zone {
-    // zone name (e.g., "America/Los_Angeles")
-    private String name;
-
-    // zone records
-    private List<ZoneRec> list;
-
-    // target zone names for this compilation
-    private static Set<String> targetZones;
-
-    /**
-     * Constructs a Zone with the specified zone name.
-     * @param name the zone name
-     */
-    Zone(String name) {
-        this.name = name;
-        list = new ArrayList<ZoneRec>();
-    }
-
-    /**
-     * Reads time zone names to be generated, called "target zone
-     * name", from the specified text file and creats an internal hash
-     * table to keep those names. It's assumed that one text line
-     * contains a zone name or comments if it starts with
-     * '#'. Comments can't follow a zone name in a single line.
-     * @param fileName the text file name
-     */
-    static void readZoneNames(String fileName) {
-        if (fileName == null) {
-            return;
-        }
-        BufferedReader in = null;
-        try {
-            FileReader fr = new FileReader(fileName);
-            in = new BufferedReader(fr);
-        } catch (FileNotFoundException e) {
-            Main.panic("can't open file: " + fileName);
-        }
-        targetZones = new HashSet<String>();
-        String line;
-
-        try {
-            while ((line = in.readLine()) != null) {
-                line = line.trim();
-                if (line.length() == 0 || line.charAt(0) == '#') {
-                    continue;
-                }
-                if (!targetZones.add(line)) {
-                    Main.warning("duplicated target zone name: " + line);
-                }
-            }
-            in.close();
-        } catch (IOException e) {
-            Main.panic("IO error: "+e.getMessage());
-        }
-    }
-
-    /**
-     * Determines whether the specified zone is one of the target zones.
-     * If no target zones are specified, this method always returns
-     * true for any zone name.
-     * @param zoneName the zone name
-     * @return true if the specified name is a target zone.
-     */
-    static boolean isTargetZone(String zoneName) {
-        if (targetZones == null) {
-            return true;
-        }
-        return targetZones.contains(zoneName);
-    }
-
-    /**
-     * Forces to add "MET" to the target zone table. This is because
-     * there is a conflict between Java zone name "WET" and Olson zone
-     * name.
-     */
-    static void addMET() {
-        if (targetZones != null) {
-            targetZones.add("MET");
-        }
-    }
-
-    /**
-     * @return the zone name
-     */
-    String getName() {
-        return name;
-    }
-
-    /**
-     * Adds the specified zone record to the zone record list.
-     */
-    void add(ZoneRec rec) {
-        list.add(rec);
-    }
-
-    /**
-     * @param index the index at which the zone record in the list is returned.
-     * @return the zone record specified by the index.
-     */
-    ZoneRec get(int index) {
-        return list.get(index);
-    }
-
-    /**
-     * @return the size of the zone record list
-     */
-    int size() {
-        return list.size();
-    }
-
-    /**
-     * Resolves the reference to a rule in each zone record.
-     * @param zi the Zoneinfo object with which the rule reference is
-     * resolved.
-     */
-    void resolve(Zoneinfo zi) {
-        for (int i = 0; i < list.size(); i++) {
-            ZoneRec rec = list.get(i);
-            rec.resolve(zi);
-        }
-    }
-}
--- a/make/tools/src/build/tools/javazic/ZoneRec.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,252 +0,0 @@
-/*
- * Copyright (c) 2000, 2004, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.io.BufferedReader;
-import java.io.FileReader;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.StringTokenizer;
-
-/**
- * ZoneRec hold information of time zone corresponding to each text
- * line of the "Zone" part.
- *
- * @since 1.4
- */
-class ZoneRec {
-    private int gmtOffset;
-    private String ruleName;
-    private int directSave;
-    private Rule ruleRef;
-    private String format;
-    private boolean hasUntil;
-    private int untilYear;
-    private Month untilMonth;
-    private RuleDay untilDay;
-    private Time untilTime;
-    private long untilInMillis;
-    private String line;
-
-    /**
-     * @return the "UNTIL" value in milliseconds
-     */
-    Time getUntilTime() {
-        return untilTime;
-    }
-
-    /**
-     * @return the GMT offset value in milliseconds
-     */
-    int getGmtOffset() {
-        return gmtOffset;
-    }
-
-    /**
-     * @return the rule name to which this zone record refers
-     */
-    String getRuleName() {
-        return ruleName;
-    }
-
-    /**
-     * @return the amount of saving time directly defined in the
-     * "RULES/SAVE" field.
-     */
-    int getDirectSave() {
-        return directSave;
-    }
-
-    /**
-     * @return true if this zone record has a reference to a rule
-     */
-    boolean hasRuleReference() {
-        return ruleRef != null;
-    }
-
-    /**
-     * Returns the "FORMAT" field string of this zone record. This
-     * @return the "FORMAT" field
-     */
-    String getFormat() {
-        return format;
-    }
-
-    /**
-     * @return the year in the "UNTIL" field
-     */
-    int getUntilYear() {
-        return untilYear;
-    }
-
-    /**
-     * Returns the "UNTIL" field value in milliseconds from Janurary
-     * 1, 1970 0:00 GMT.
-     * @param currentSave the amount of daylight saving in
-     * milliseconds that is used to adjust wall-clock time.
-     * @return the milliseconds value of the "UNTIL" field
-     */
-    long getUntilTime(int currentSave) {
-        if (untilTime.isWall()) {
-            return untilInMillis - currentSave;
-        }
-        return untilInMillis;
-    }
-
-    /**
-     * Returns the "UNTIL" time in milliseconds without adjusting GMT
-     * offsets or daylight saving.
-     * @return local "UNTIL" time in milliseconds
-     */
-    long getLocalUntilTime() {
-        return Time.getLocalTime(untilYear,
-                                 untilMonth,
-                                 untilDay,
-                                 untilTime.getTime());
-    }
-
-    /**
-     * Returns the "UNTIL" time in milliseconds with adjusting GMT offsets and daylight saving.
-     * @return the "UNTIL" time after the adjustment
-     */
-    long getLocalUntilTime(int save, int gmtOffset) {
-        return Time.getLocalTime(untilYear,
-                                 untilMonth,
-                                 untilDay,
-                                 save,
-                                 gmtOffset,
-                                 untilTime);
-    }
-
-    /**
-     * @return the text line of this zone record
-     */
-    String getLine() {
-        return line;
-    }
-
-    /**
-     * Sets the specified text line to this zone record
-     */
-    void setLine(String line) {
-        this.line = line;
-    }
-
-    /**
-     * @return true if this zone record has the "UNTIL" field
-     */
-    boolean hasUntil() {
-        return this.hasUntil;
-    }
-
-    /**
-     * Adjusts the "UNTIL" time to GMT offset if this zone record has
-     * it.  <code>untilTime</code> is not adjusted to daylight saving
-     * in this method.
-     */
-    void adjustTime() {
-        if (!hasUntil()) {
-            return;
-        }
-        if (untilTime.isSTD() || untilTime.isWall()) {
-            // adjust to gmt offset only here.  adjust to real
-            // wall-clock time when tracking rules
-            untilInMillis -= gmtOffset;
-        }
-    }
-
-    /**
-     * @return the reference to the Rule object
-     */
-    Rule getRuleRef() {
-        return ruleRef;
-    }
-
-    /**
-     * Resolves the reference to a Rule and adjusts its "UNTIL" time
-     * to GMT offset.
-     */
-    void resolve(Zoneinfo zi) {
-        if (ruleName != null && (!"-".equals(ruleName))) {
-                ruleRef = zi.getRule(ruleName);
-        }
-        adjustTime();
-    }
-
-    /**
-     * Parses a Zone text line that is described by a StringTokenizer.
-     * @param tokens represents tokens of a Zone text line
-     * @return the zone record produced by parsing the text
-     */
-    static ZoneRec parse(StringTokenizer tokens) {
-        ZoneRec rec = new ZoneRec();
-        try {
-            rec.gmtOffset = (int) Time.parse(tokens.nextToken()).getTime();
-            String token = tokens.nextToken();
-            char c = token.charAt(0);
-            if (c >= '0' && c <= '9') {
-                rec.directSave = (int) Time.parse(token).getTime();
-            } else {
-                rec.ruleName = token;
-            }
-            rec.format = tokens.nextToken();
-            if (tokens.hasMoreTokens()) {
-                rec.hasUntil = true;
-                rec.untilYear = Integer.parseInt(tokens.nextToken());
-                if (tokens.hasMoreTokens()) {
-                    rec.untilMonth = Month.parse(tokens.nextToken());
-                } else {
-                    rec.untilMonth = Month.JANUARY;
-                }
-                if (tokens.hasMoreTokens()) {
-                    rec.untilDay = RuleDay.parse(tokens.nextToken());
-                } else {
-                    rec.untilDay = new RuleDay(1);
-                }
-                if (tokens.hasMoreTokens()) {
-                    rec.untilTime = Time.parse(tokens.nextToken());
-                } else {
-                    rec.untilTime = Time.parse("0:00");
-                }
-                rec.untilInMillis = rec.getLocalUntilTime();
-            }
-        } catch (Exception e) {
-            // TODO: error reporting
-            e.printStackTrace();
-        }
-        return rec;
-    }
-
-    private static void panic(String msg) {
-        Main.panic(msg);
-    }
-}
--- a/make/tools/src/build/tools/javazic/Zoneinfo.java	Thu Apr 04 11:33:40 2013 -0700
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,569 +0,0 @@
-/*
- * Copyright (c) 2000, 2011, 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
- * under the terms of the GNU General Public License version 2 only, as
- * published by the Free Software Foundation.  Oracle designates this
- * particular file as subject to the "Classpath" exception as provided
- * by Oracle in the LICENSE file that accompanied this code.
- *
- * This code is distributed in the hope that it will be useful, but WITHOUT
- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
- * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
- * version 2 for more details (a copy is included in the LICENSE file that
- * accompanied this code).
- *
- * You should have received a copy of the GNU General Public License version
- * 2 along with this work; if not, write to the Free Software Foundation,
- * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
- *
- * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
- * or visit www.oracle.com if you need additional information or have any
- * questions.
- */
-
-package build.tools.javazic;
-
-import java.io.BufferedReader;
-import java.io.FileReader;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.StringTokenizer;
-
-/**
- * Zoneinfo provides javazic compiler front-end functionality.
- * @since 1.4
- */
-class Zoneinfo {
-
-    private static final int minYear = 1900;
-    private static final int maxYear = 2037;
-    private static final long minTime = Time.getLocalTime(minYear, Month.JANUARY, 1, 0);
-    private static int startYear = minYear;
-    private static int endYear = maxYear;
-
-    /**
-     * True if javazic should generate a list of SimpleTimeZone
-     * instances for the SimpleTimeZone-based time zone support.
-     */
-    static boolean isYearForTimeZoneDataSpecified = false;
-
-    /**
-     * Zone name to Zone mappings
-     */
-    private Map<String,Zone> zones;
-
-    /**
-     * Rule name to Rule mappings
-     */
-    private Map<String,Rule> rules;
-
-    /**
-     * Alias name to real name mappings
-     */
-    private Map<String,String> aliases;
-
-    /**
-     * Constracts a Zoneinfo.
-     */
-    Zoneinfo() {
-        zones = new HashMap<String,Zone>();
-        rules = new HashMap<String,Rule>();
-        aliases = new HashMap<String,String>();
-    }
-
-    /**
-     * Adds the given zone to the list of Zones.
-     * @param zone Zone to be added to the list.
-     */
-    void add(Zone zone) {
-        String name = zone.getName();
-        zones.put(name, zone);
-    }
-
-    /**
-     * Adds the given rule to the list of Rules.
-     * @param rule Rule to be added to the list.
-     */
-    void add(Rule rule) {
-        String name = rule.getName();
-        rules.put(name, rule);
-    }
-
-    /**
-     * Puts the specifid name pair to the alias table.
-     * @param name1 an alias time zone name
-     * @param name2 the real time zone of the alias name
-     */
-    void putAlias(String name1, String name2) {
-        aliases.put(name1, name2);
-    }
-
-    /**
-     * Sets the given year for SimpleTimeZone list output.
-     * This method is called when the -S option is specified.
-     * @param year the year for which SimpleTimeZone list should be generated
-     */
-    static void setYear(int year) {
-        setStartYear(year);
-        setEndYear(year);
-        isYearForTimeZoneDataSpecified = true;
-    }
-
-    /**
-     * Sets the start year.
-     * @param year the start year value
-     * @throws IllegalArgumentException if the specified year value is
-     * smaller than the minimum year or greater than the end year.
-     */
-    static void setStartYear(int year) {
-        if (year < minYear || year > endYear) {
-            throw new IllegalArgumentException("invalid start year specified: " + year);
-        }
-        startYear = year;
-    }
-
-    /**
-     * @return the start year value
-     */
-    static int getStartYear() {
-        return startYear;
-    }
-
-    /**
-     * Sets the end year.
-     * @param year the end year value
-     * @throws IllegalArgumentException if the specified year value is
-     * smaller than the start year or greater than the maximum year.
-     */
-    static void setEndYear(int year) {
-        if (year < startYear || year > maxYear) {
-            throw new IllegalArgumentException();
-        }
-        endYear = year;
-    }
-
-    /**
-     * @return the end year value
-     */
-    static int getEndYear() {
-        return endYear;
-    }
-
-    /**
-     * @return the minimum year value
-     */
-    static int getMinYear() {
-        return minYear;
-    }
-
-    /**
-     * @return the maximum year value
-     */
-    static int getMaxYear() {
-        return maxYear;
-    }
-
-    /**
-     * @return the alias table
-     */
-    Map<String,String> getAliases() {
-        return aliases;
-    }
-
-    /**
-     * @return the Zone list
-     */
-    Map<String,Zone> getZones() {
-        return zones;
-    }
-
-    /**
-     * @return a Zone specified by name.
-     * @param name a zone name
-     */
-    Zone getZone(String name) {
-        return zones.get(name);
-    }
-
-    /**
-     * @return a Rule specified by name.
-     * @param name a rule name
-     */
-    Rule getRule(String name) {
-        return rules.get(name);
-    }
-
-    private static String line;
-
-    private static int lineNum;
-
-    /**
-     * Parses the specified time zone data file and creates a Zoneinfo
-     * that has all Rules, Zones and Links (aliases) information.
-     * @param fname the time zone data file name
-     * @return a Zoneinfo object
-     */
-    static Zoneinfo parse(String fname) {
-        BufferedReader in = null;
-        try {
-            FileReader fr = new FileReader(fname);
-            in = new BufferedReader(fr);
-        } catch (FileNotFoundException e) {
-            panic("can't open file: "+fname);
-        }
-        Zoneinfo zi = new Zoneinfo();
-        boolean continued = false;
-        Zone zone = null;
-        String l;
-        lineNum = 0;
-
-        try {
-            while ((line = in.readLine()) != null) {
-                lineNum++;
-                // skip blank and comment lines
-                if (line.length() == 0 || line.charAt(0) == '#') {
-                    continue;
-                }
-
-                // trim trailing comments
-                int rindex = line.lastIndexOf('#');
-                if (rindex != -1) {
-                    // take the data part of the line
-                    l = line.substring(0, rindex);
-                } else {
-                    l = line;
-                }
-
-                StringTokenizer tokens = new StringTokenizer(l);
-                if (!tokens.hasMoreTokens()) {
-                    continue;
-                }
-                String token = tokens.nextToken();
-
-                if (continued || "Zone".equals(token)) {
-                    if (zone == null) {
-                        if (!tokens.hasMoreTokens()) {
-                            panic("syntax error: zone no more token");
-                        }
-                        token = tokens.nextToken();
-                        // if the zone name is in "GMT+hh" or "GMT-hh"
-                        // format, ignore it due to spec conflict.
-                        if (token.startsWith("GMT+") || token.startsWith("GMT-")) {
-                            continue;
-                        }
-                        zone = new Zone(token);
-                    } else {
-                        // no way to push the current token back...
-                        tokens = new StringTokenizer(l);
-                    }
-
-                    ZoneRec zrec = ZoneRec.parse(tokens);
-                    zrec.setLine(line);
-                    zone.add(zrec);
-                    if ((continued = zrec.hasUntil()) == false) {
-                        if (Zone.isTargetZone(zone.getName())) {
-                            // zone.resolve(zi);
-                            zi.add(zone);
-                        }
-                        zone = null;
-                    }
-                } else if ("Rule".equals(token)) {
-                    if (!tokens.hasMoreTokens()) {
-                        panic("syntax error: rule no more token");
-                    }
-                    token = tokens.nextToken();
-                    Rule rule = zi.getRule(token);
-                    if (rule == null) {
-                        rule = new Rule(token);
-                        zi.add(rule);
-                    }
-                    RuleRec rrec = RuleRec.parse(tokens);
-                    rrec.setLine(line);
-                    rule.add(rrec);
-                } else if ("Link".equals(token)) {
-                    // Link <newname> <oldname>
-                    try {
-                        String name1 = tokens.nextToken();
-                        String name2 = tokens.nextToken();
-
-                        // if the zone name is in "GMT+hh" or "GMT-hh"
-                        // format, ignore it due to spec conflict with
-                        // custom time zones. Also, ignore "ROC" for
-                        // PC-ness.
-                        if (name2.startsWith("GMT+") || name2.startsWith("GMT-")
-                            || "ROC".equals(name2)) {
-                            continue;
-                        }
-                        zi.putAlias(name2, name1);
-                    } catch (Exception e) {
-                        panic("syntax error: no more token for Link");
-                    }
-                }
-            }
-            in.close();
-        } catch (IOException ex) {
-            panic("IO error: " + ex.getMessage());
-        }
-
-        return zi;
-    }
-
-    /**
-     * Interprets a zone and constructs a Timezone object that
-     * contains enough information on GMT offsets and DST schedules to
-     * generate a zone info database.
-     *
-     * @param zoneName the zone name for which a Timezone object is
-     * constructed.
-     *
-     * @return a Timezone object that contains all GMT offsets and DST
-     * rules information.
-     */
-    Timezone phase2(String zoneName) {
-        Timezone tz = new Timezone(zoneName);
-        Zone zone = getZone(zoneName);
-        zone.resolve(this);
-
-        // TODO: merge phase2's for the regular and SimpleTimeZone ones.
-        if (isYearForTimeZoneDataSpecified) {
-            ZoneRec zrec = zone.get(zone.size()-1);
-            tz.setLastZoneRec(zrec);
-            tz.setRawOffset(zrec.getGmtOffset());
-            if (zrec.hasRuleReference()) {
-                /*
-                 * This part assumes that the specified year is covered by
-                 * the rules referred to by the last zone record.
-                 */
-                List<RuleRec> rrecs = zrec.getRuleRef().getRules(startYear);
-
-                if (rrecs.size() == 2) {
-                    // make sure that one is a start rule and the other is
-                    // an end rule.
-                    RuleRec r0 = rrecs.get(0);
-                    RuleRec r1 = rrecs.get(1);
-                    if (r0.getSave() == 0 && r1.getSave() > 0) {
-                        rrecs.set(0, r1);
-                        rrecs.set(1, r0);
-                    } else if (!(r0.getSave() > 0 && r1.getSave() == 0)) {
-                        rrecs = null;
-                        Main.error(zoneName + ": rules for " +  startYear + " not found.");
-                    }
-                } else {
-                    rrecs = null;
-                }
-                if (rrecs != null) {
-                    tz.setLastRules(rrecs);
-                }
-            }
-            return tz;
-        }
-
-        int gmtOffset;
-        int year = minYear;
-        int fromYear = year;
-        long fromTime = Time.getLocalTime(startYear,
-                                          Month.JANUARY,
-                                          1, 0);
-
-        // take the index 0 for the GMT offset of the last zone record
-        ZoneRec zrec = zone.get(zone.size()-1);
-        tz.getOffsetIndex(zrec.getGmtOffset());
-
-        int currentSave = 0;
-        boolean usedZone;
-        for (int zindex = 0; zindex < zone.size(); zindex++) {
-            zrec = zone.get(zindex);
-            usedZone = false;
-            gmtOffset = zrec.getGmtOffset();
-            int stdOffset = zrec.getDirectSave();
-
-            // If this is the last zone record, take the last rule info.
-            if (!zrec.hasUntil()) {
-                tz.setRawOffset(gmtOffset, fromTime);
-                if (zrec.hasRuleReference()) {
-                    tz.setLastRules(zrec.getRuleRef().getLastRules());
-                } else if (stdOffset != 0) {
-                    // in case the last rule is all year round DST-only
-                    // (Asia/Amman once announced this rule.)
-                    tz.setLastDSTSaving(stdOffset);
-                }
-            }
-            if (!zrec.hasRuleReference()) {
-                if (!zrec.hasUntil() || zrec.getUntilTime(stdOffset) >= fromTime) {
-                    tz.addTransition(fromTime,
-                                     tz.getOffsetIndex(gmtOffset+stdOffset),
-                                     tz.getDstOffsetIndex(stdOffset));
-                    usedZone = true;
-                }
-                currentSave = stdOffset;
-                // optimization in case the last rule is fixed.
-                if (!zrec.hasUntil()) {
-                    if (tz.getNTransitions() > 0) {
-                        if (stdOffset == 0) {
-                            tz.setDSTType(Timezone.X_DST);
-                        } else {
-                            tz.setDSTType(Timezone.LAST_DST);
-                        }
-                        long time = Time.getLocalTime(maxYear,
-                                                      Month.JANUARY, 1, 0);
-                        time -= zrec.getGmtOffset();
-                        tz.addTransition(time,
-                                         tz.getOffsetIndex(gmtOffset+stdOffset),
-                                         tz.getDstOffsetIndex(stdOffset));
-                        tz.addUsedRec(zrec);
-                    } else {
-                        tz.setDSTType(Timezone.NO_DST);
-                    }
-                    break;
-                }
-            } else {
-                Rule rule = zrec.getRuleRef();
-                boolean fromTimeUsed = false;
-                currentSave = 0;
-            year_loop:
-                for (year = getMinYear(); year <= endYear; year++) {
-                    if (zrec.hasUntil() && year > zrec.getUntilYear()) {
-                        break;
-                    }
-                    List<RuleRec> rules = rule.getRules(year);
-                    if (rules.size() > 0) {
-                        for (int i = 0; i < rules.size(); i++) {
-                            RuleRec rrec = rules.get(i);
-                            long transition = rrec.getTransitionTime(year,
-                                                                     gmtOffset,
-                                                                     currentSave);
-                            if (zrec.hasUntil()) {
-                                if (transition >= zrec.getUntilTime(currentSave)) {
-                                    break year_loop;
-                                }
-                            }
-
-                            if (fromTimeUsed == false) {
-                                if (fromTime <= transition) {
-                                    fromTimeUsed = true;
-
-                                    if (fromTime != minTime) {
-                                        int prevsave;
-
-                                        ZoneRec prevzrec = zone.get(zindex - 1);
-
-                                        // See if until time in the previous
-                                        // ZoneRec is the same thing as the
-                                        // local time in the next rule.
-                                        // (examples are Asia/Ashkhabad in 1991,
-                                        // Europe/Riga in 1989)
-
-                                        if (i > 0) {
-                                            prevsave = rules.get(i-1).getSave();
-                                        } else {
-                                            List<RuleRec> prevrules = rule.getRules(year-1);
-
-                                            if (prevrules.size() > 0) {
-                                                prevsave = prevrules.get(prevrules.size()-1).getSave();
-                                            } else {
-                                                prevsave = 0;
-                                            }
-                                        }
-
-                                        if (rrec.isSameTransition(prevzrec, prevsave, gmtOffset)) {
-                                            currentSave = rrec.getSave();
-                                            tz.addTransition(fromTime,
-                                                         tz.getOffsetIndex(gmtOffset+currentSave),
-                                                         tz.getDstOffsetIndex(currentSave));
-                                            tz.addUsedRec(rrec);
-                                            usedZone = true;
-                                            continue;
-                                        }
-                                        if (!prevzrec.hasRuleReference()
-                                            || rule != prevzrec.getRuleRef()
-                                            || (rule == prevzrec.getRuleRef()
-                                                && gmtOffset != prevzrec.getGmtOffset())) {
-                                            int save = (fromTime == transition) ? rrec.getSave() : currentSave;
-                                            tz.addTransition(fromTime,
-                                                         tz.getOffsetIndex(gmtOffset+save),
-                                                         tz.getDstOffsetIndex(save));
-                                            tz.addUsedRec(rrec);
-                                            usedZone = true;
-                                        }
-                                    } else {  // fromTime == minTime
-                                        int save = rrec.getSave();
-                                        tz.addTransition(minTime,
-                                                         tz.getOffsetIndex(gmtOffset),
-                                                         tz.getDstOffsetIndex(0));
-
-                                        tz.addTransition(transition,
-                                                         tz.getOffsetIndex(gmtOffset+save),
-                                                         tz.getDstOffsetIndex(save));
-
-                                        tz.addUsedRec(rrec);
-                                        usedZone = true;
-                                    }
-                                } else if (year == fromYear && i == rules.size()-1) {
-                                    int save = rrec.getSave();
-                                    tz.addTransition(fromTime,
-                                                     tz.getOffsetIndex(gmtOffset+save),
-                                                     tz.getDstOffsetIndex(save));
-                                }
-                            }
-
-                            currentSave = rrec.getSave();
-                            if (fromTime < transition) {
-                                tz.addTransition(transition,
-                                                 tz.getOffsetIndex(gmtOffset+currentSave),
-                                                 tz.getDstOffsetIndex(currentSave));
-                                tz.addUsedRec(rrec);
-                                usedZone = true;
-                            }
-                        }
-                    } else {
-                        if (year == fromYear) {
-                            tz.addTransition(fromTime,
-                                             tz.getOffsetIndex(gmtOffset+currentSave),
-                                             tz.getDstOffsetIndex(currentSave));
-                            fromTimeUsed = true;
-                        }
-                        if (year == endYear && !zrec.hasUntil()) {
-                            if (tz.getNTransitions() > 0) {
-                                // Assume that this Zone stopped DST
-                                tz.setDSTType(Timezone.X_DST);
-                                long time = Time.getLocalTime(maxYear, Month.JANUARY,
-                                                              1, 0);
-                                time -= zrec.getGmtOffset();
-                                tz.addTransition(time,
-                                                 tz.getOffsetIndex(gmtOffset),
-                                                 tz.getDstOffsetIndex(0));
-                                usedZone = true;
-                            } else {
-                                tz.setDSTType(Timezone.NO_DST);
-                            }
-                        }
-                    }
-                }
-            }
-            if (usedZone) {
-                tz.addUsedRec(zrec);
-            }
-            if (zrec.hasUntil() && zrec.getUntilTime(currentSave) > fromTime) {
-                fromTime = zrec.getUntilTime(currentSave);
-                fromYear = zrec.getUntilYear();
-                year = zrec.getUntilYear();
-            }
-        }
-
-        if (tz.getDSTType() == Timezone.UNDEF_DST) {
-            tz.setDSTType(Timezone.DST);
-        }
-        tz.optimize();
-        tz.checksum();
-        return tz;
-    }
-
-    private static void panic(String msg) {
-        Main.panic(msg);
-    }
-}
--- a/makefiles/CompileLaunchers.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/CompileLaunchers.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -311,6 +311,9 @@
 $(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" }' \
--- a/makefiles/CompileNativeLibraries.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/CompileNativeLibraries.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 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
@@ -464,12 +464,13 @@
 	$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/windows \
 	$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/windows \
 	$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/d3d
+    LIBAWT_CFLAGS+=-I$(DXSDK_INCLUDE_PATH)
 else
     LIBAWT_DIRS+=\
 	$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/x11
 endif
 
-LIBAWT_CFLAGS:=-D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES \
+LIBAWT_CFLAGS+=-D__MEDIALIB_OLD_NAMES -D__USE_J2D_NAMES \
 	$(X_CFLAGS) \
 	$(foreach dir,$(LIBAWT_DIRS),-I$(dir))
 
@@ -842,6 +843,7 @@
 	debug_trace.c \
 	debug_util.c \
 	awt_Plugin.c \
+        gnome_interface.c \
 	gtk2_interface.c \
         swing_GTKEngine.c \
         swing_GTKStyle.c \
@@ -1218,7 +1220,7 @@
                 OUTPUT_DIR:=$(INSTALL_LIBRARIES_HERE),\
                 SRC:=$(JDK_TOPDIR)/src/share/native/sun/java2d/cmm/lcms,\
 		LANG:=C,\
-		OPTIMIZATION:=LOW, \
+		OPTIMIZATION:=HIGHEST, \
 		CFLAGS:=$(filter-out -xc99=%none,$(CFLAGS_JDKLIB)) \
 			$(SHARED_LIBRARY_FLAGS) \
 			-I$(JDK_TOPDIR)/src/share/native/sun/java2d \
@@ -1461,7 +1463,8 @@
 		        -I$(JDK_TOPDIR)/src/share/native/sun/awt/debug \
 		        -I$(JDK_TOPDIR)/src/share/native/sun/java2d \
 			-I$(JDK_TOPDIR)/src/share/native/sun/awt/image/cvutils \
-			-I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/windows, \
+			-I$(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/java2d/windows \
+			-I$(DXSDK_INCLUDE_PATH), \
 		LDFLAGS:=$(LDFLAGS_JDKLIB) $(KERNEL32_LIB) $(LDFLAGS_CXX_JDK) \
 			 advapi32.lib $(WIN_AWT_LIB),\
 		LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX),\
@@ -1957,8 +1960,6 @@
 				        -lsendfile -ljava -lnet -lc,\
 		LDFLAGS_SUFFIX_windows:=jvm.lib ws2_32.lib $(WIN_JAVA_LIB) \
 					$(JDK_OUTPUTDIR)/objs/libnet/net.lib \
-                                        $(JDK_OUTPUTDIR)/objs/libjava/io_util.obj \
-		                        $(JDK_OUTPUTDIR)/objs/libjava/FileDescriptor_md.obj \
 					advapi32.lib,\
 		LDFLAGS_SUFFIX_macosx:=-ljava -lnet -pthread -framework CoreFoundation,\
 		LDFLAGS_SUFFIX:=,\
@@ -2385,18 +2386,23 @@
 
 ifndef BUILD_HEADLESS_ONLY
 LIBSPLASHSCREEN_DIRS:=\
-	$(JDK_TOPDIR)/src/share/native/sun/awt/giflib \
 	$(JDK_TOPDIR)/src/share/native/sun/awt/image/jpeg \
 	$(JDK_TOPDIR)/src/share/native/sun/awt/libpng \
 	$(JDK_TOPDIR)/src/share/native/sun/awt/splashscreen
 
+ifeq ($(USE_EXTERNAL_LIBGIF),true)
+    GIFLIB_LDFLAGS := -lgif
+else
+    LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/share/native/sun/awt/giflib
+    GIFLIB_CFLAGS := -I$(JDK_TOPDIR)/src/share/native/sun/awt/giflib
+endif
+
 ifneq ($(OPENJDK_TARGET_OS), macosx)
     LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/$(OPENJDK_TARGET_OS_API_DIR)/native/sun/awt/splashscreen
 else
     LIBSPLASHSCREEN_DIRS += $(JDK_TOPDIR)/src/macosx/native/sun/awt/splashscreen
 endif
 
-
 LIBSPLASHSCREEN_CFLAGS:=-DSPLASHSCREEN -DPNG_NO_MMX_CODE \
 	$(foreach dir,$(LIBSPLASHSCREEN_DIRS),-I$(dir))
 
@@ -2448,11 +2454,11 @@
 		EXCLUDE_FILES:=imageioJPEG.c jpegdecoder.c pngtest.c,\
 		LANG:=C,\
 		OPTIMIZATION:=LOW, \
-		CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB),\
+		CFLAGS:=$(LIBSPLASHSCREEN_CFLAGS) $(CFLAGS_JDKLIB) $(GIFLIB_CFLAGS),\
 		MAPFILE:=$(JDK_TOPDIR)/makefiles/mapfiles/libsplashscreen/mapfile-vers, \
 		LDFLAGS:=$(LDFLAGS_JDKLIB) \
 			 $(call SET_SHARED_LIBRARY_ORIGIN),\
-		LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ),\
+		LDFLAGS_SUFFIX:=$(LIBSPLASHSCREEN_LDFLAGS_SUFFIX) $(LIBZ) $(GIFLIB_LDFLAGS),\
 		LDFLAGS_SUFFIX_solaris:=-lc,\
 		VERSIONINFO_RESOURCE:=$(JDK_TOPDIR)/src/windows/resource/version.rc,\
 		RC_FLAGS:=$(RC_FLAGS)\
@@ -2663,11 +2669,8 @@
 
 ##########################################################################################
 
-ifndef DISABLE_INTREE_EC
-#
-# TODO Set DISABLE_INTREE_EC in configure if src/share/native/sun/security/ec/impl
-#      is not present
-#
+ifeq ($(ENABLE_INTREE_EC),yes)
+
 BUILD_LIBSUNEC_FLAGS:= -I$(JDK_TOPDIR)/src/share/native/sun/security/ec \
                        -I$(JDK_TOPDIR)/src/share/native/sun/security/ec/impl
 
@@ -2907,7 +2910,8 @@
 		OPTIMIZATION:=LOW, \
 		CFLAGS:=$(CFLAGS_JDKLIB) \
 			$(LIBJSOUND_CFLAGS) \
-			-DUSE_DAUDIO=TRUE, \
+			-DUSE_DAUDIO=TRUE \
+                        -I$(DXSDK_INCLUDE_PATH), \
 		LDFLAGS:=$(LDFLAGS_JDKLIB) $(LDFLAGS_CXX_JDK) \
 			 $(call SET_SHARED_LIBRARY_ORIGIN),\
 		LDFLAGS_SUFFIX:=$(LDFLAGS_JDKLIB_SUFFIX) dsound.lib winmm.lib user32.lib ole32.lib,\
--- a/makefiles/CopyFiles.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/CopyFiles.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -81,17 +81,6 @@
 ##########################################################################################
 
 LIBDIR = $(JDK_OUTPUTDIR)/lib
-SERVICETAG_LIBDIR = $(LIBDIR)/servicetag
-
-$(SERVICETAG_LIBDIR)/jdk_header.png: $(JDK_TOPDIR)/src/share/classes/com/sun/servicetag/resources/jdk_header.png
-	$(MKDIR) -p $(@D)
-	$(RM) $@
-	$(CP) $< $@
-	$(CHMOD) 444 $@
-
-COPY_FILES += $(SERVICETAG_LIBDIR)/jdk_header.png
-
-##########################################################################################
 
 MGMT_LIBDIR = $(LIBDIR)/management
 MGMT_LIB_SRC = $(JDK_TOPDIR)/src/share/lib/management
--- a/makefiles/CopyIntoClasses.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/CopyIntoClasses.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -59,15 +59,6 @@
 COPY_FILES += \
   $(JDK_TOPDIR)/src/share/classes/sun/jvmstat/perfdata/resources/aliasmap
 
-# Servicetag resources
-SERVICETAG_RESOURCES_DIR = $(JDK_TOPDIR)/src/share/classes/com/sun/servicetag/resources
-COPY_FILES += \
-  $(SERVICETAG_RESOURCES_DIR)/product_registration.xsd \
-  $(SERVICETAG_RESOURCES_DIR)/register.html \
-  $(SERVICETAG_RESOURCES_DIR)/register_ja.html \
-  $(SERVICETAG_RESOURCES_DIR)/register_zh_CN.html \
-  $(wildcard  $(SERVICETAG_RESOURCES_DIR)/javase_*.properties)
-
 # JConsole resources
 JCONSOLE_RESOURCES_DIR = $(JDK_TOPDIR)/src/share/classes/sun/tools/jconsole/resources
 COPY_FILES += \
--- a/makefiles/CreateJars.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/CreateJars.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -76,8 +76,6 @@
 $(IMAGES_OUTPUTDIR)/lib/tzdb.jar: $(JDK_OUTPUTDIR)/lib/tzdb.jar
 	$(install-file)
 
-JARS += $(IMAGES_OUTPUTDIR)/lib/tzdb.jar 
-
 ##########################################################################################
 
 LOCALEDATA_INCLUDE_LOCALES := ar be bg ca cs da de el es et fi fr ga hi hr hu in is it \
@@ -357,23 +355,25 @@
 
 
 # Support for removing the addPropertyChangeListener and removePropertyChangeListener
-# methods from classes that only go into the profile builds. For now the Pack200.Packer
-# and Packer200.Unpacker classes have special handling because of the $ in the file
-# name.
+# methods from classes that only go into the profile builds. 
 BEANLESS_CLASSES = $(IMAGES_OUTPUTDIR)/beanless
 
+# When there are $ characters in filenames we have some very subtle interactions between
+# make expansion and shell expansion. In this particular case $< will contain a single $ while
+# $@ will contain \$. So we have to pass $< in single-quotes to avoid shell expansion
 $(BEANLESS_CLASSES)/%: $(JDK_OUTPUTDIR)/classes/%
 	$(MKDIR) -p $(@D)
-	$(TOOL_REMOVEMETHODS) $< $@ addPropertyChangeListener removePropertyChangeListener
+	$(TOOL_REMOVEMETHODS) '$<' $@ addPropertyChangeListener removePropertyChangeListener
 
 CLASSES_TO_DEBEAN = \
     java/util/logging/LogManager.class \
+    java/util/jar/Pack200\$$Packer.class \
+    java/util/jar/Pack200\$$Unpacker.class \
     com/sun/java/util/jar/pack/PackerImpl.class \
-    com/sun/java/util/jar/pack/UnpackerImpl.class
+    com/sun/java/util/jar/pack/UnpackerImpl.class 
 
-BEANLESS_CLASSES_TARGETS =
 ifneq ($(PROFILE),)
-    BEANLESS_CLASSES_TARGETS := $(foreach c, $(CLASSES_TO_DEBEAN), $(BEANLESS_CLASSES)/$c)
+    BEANLESS_CLASSES_TARGETS := $(addprefix $(BEANLESS_CLASSES)/, $(CLASSES_TO_DEBEAN))
 endif
 
 
@@ -400,13 +400,8 @@
 	      $(ECHO)  Updating rt.jar $(PROFILE) && \
 	      $(CD) $(patsubst %$(VERSION_CLASS_PATH),%,$(CLASS_FILE)) && \
                 $(JAR) $(RT_JAR_UPDATE_OPTIONS) $@.tmp $(VERSION_CLASS_PATH); \
-	      $(MKDIR) -p $(BEANLESS_CLASSES)/java/util/jar; \
-	      $(TOOL_REMOVEMETHODS) $(JDK_OUTPUTDIR)/classes/java/util/jar/Pack200\$$Packer.class \
-		$(BEANLESS_CLASSES)/java/util/jar/Pack200\$$Packer.class addPropertyChangeListener removePropertyChangeListener; \
-	      $(TOOL_REMOVEMETHODS) $(JDK_OUTPUTDIR)/classes/java/util/jar/Pack200\$$Unpacker.class \
-		$(BEANLESS_CLASSES)/java/util/jar/Pack200\$$Unpacker.class addPropertyChangeListener removePropertyChangeListener; \
 	      $(CD) $(BEANLESS_CLASSES) && \
-		$(JAR) $(RT_JAR_UPDATE_OPTIONS) $@.tmp $(CLASSES_TO_DEBEAN) java/util/jar/* ; \
+		$(JAR) $(RT_JAR_UPDATE_OPTIONS) $@.tmp $(CLASSES_TO_DEBEAN); \
             fi
 	$(MV) $@.tmp $@
 
@@ -871,8 +866,7 @@
 # This is an interim solution until the ct.sym is replaced
 # with a new module system (being discussed for JDK 8).
 #
-EXPORTED_PRIVATE_PKGS = com.sun.servicetag \
-                        com.oracle.net \
+EXPORTED_PRIVATE_PKGS = com.oracle.net \
                         com.oracle.nio
 
 $(IMAGES_OUTPUTDIR)/symbols/_the.symbols: $(IMAGES_OUTPUTDIR)/lib/rt.jar
@@ -1119,6 +1113,12 @@
 
 ##########################################################################################
 
+# Import nashorn.jar from nashorn dist dir.
+$(IMAGES_OUTPUTDIR)/lib/ext/nashorn.jar: $(NASHORN_DIST)/nashorn.jar
+	$(install-file)
+
+##########################################################################################
+
 -include $(CUSTOM_MAKE_DIR)/CreateJars.gmk
 
 ##########################################################################################
--- a/makefiles/GensrcProperties.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/GensrcProperties.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -194,7 +194,6 @@
 	$(call CacheFind,$(JDK_TOPDIR)/src/share/classes/com/sun/rowset)),\
 	%zh_TW,%zh_HK))
 
-#com/sun/servicetag/resources
 #com/sun/swing/internal/plaf/basic/resources
 $(eval $(call add_properties_to_compile,COM_SUN_SWING_PLAF_BASIC,\
 	$(filter %.properties,\
--- a/makefiles/Images.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/Images.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -264,6 +264,13 @@
 $(foreach f,$(filter $(JDK_OUTPUTDIR)/lib$(OPENJDK_TARGET_CPU_ISADIR)/%,$(JDKJRE_JDKOUT_LIB_LIST)),\
     $(eval $(call AddFileToCopy,$(JDK_OUTPUTDIR),$(JDK_OVERLAY_IMAGE_DIR)/jre,$f,JDKJRE_OVERLAY_LIB_TARGETS)))
 
+ifneq ($(PROFILE),)
+# Files in lib$(PROFILE) are excluded from the generic copying routines so 
+# we have to add them back in here
+$(foreach f,$(CUSTOM_PROFILE_JARS),\
+    $(eval $(call AddFileToCopy,$(IMAGES_OUTPUTDIR)/lib$(PROFILE),$(JRE_IMAGE_DIR)/lib,$f,JRE_LIB_TARGETS)))
+endif
+
 # CTE plugin security change require new empty directory lib/applet
 $(JRE_IMAGE_DIR)/lib/applet: 
 	$(ECHO) $(LOG_INFO) Creating $(patsubst $(OUTPUT_ROOT)/%,%,$@)
@@ -602,6 +609,7 @@
 	$(call info-file-item, "OS_NAME",      "$(REQUIRED_OS_NAME)")
 	$(call info-file-item, "OS_VERSION",   "$(REQUIRED_OS_VERSION)")
 	$(call info-file-item, "OS_ARCH",      "$(OPENJDK_TARGET_CPU_LEGACY)")
+	if [ -n "$(JDK_ARCH_ABI_PROP_NAME)" ]; then $(call info-file-item, "SUN_ARCH_ABI", "$(JDK_ARCH_ABI_PROP_NAME)"); fi
 	$(call info-file-item, "SOURCE",       "$(ALL_SOURCE_TIPS)")
 endef
 
@@ -641,7 +649,7 @@
         EXEC_LIST_BIN:=$(filter-out %$(notdir $(MSVCR_DLL)),$(filter %.exe %.dll,$(ALL_BIN_LIST)))
     else
         # Find all executables in JDK_OUTPUTDIR since they exist when this makefile is parsed
-        EXEC_LIST_BIN:=$(shell $(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX)` \
+        EXEC_LIST_BIN:=$(shell $(FILE) `$(FIND) $(JDK_OUTPUTDIR)/bin -type f -name \*$(EXE_SUFFIX) ! -name \*.debuginfo` \
 		| $(EGREP) 'ELF' | $(CUT) -d':' -f1)
         # On mac, the old build searches for static libraries for stripping instead of shared.
         # Not clear if it's intentional.
@@ -738,11 +746,6 @@
 	$(JDKJRE_OVERLAY_STRIP_LIST) $(JDK_OVERLAY_BIN_STRIP_LIST) 
 
 ifneq ($(PROFILE),)
-# Files in lib$(PROFILE) are excluded from the generic copying routines so
-# we have to add them back in here
-$(foreach f,$(CUSTOM_PROFILE_JARS),\
-    $(eval $(call AddFileToCopy,$(IMAGES_OUTPUTDIR)/lib$(PROFILE),$(JRE_IMAGE_DIR)/lib,$f,JRE_LIB_TARGETS)))
-
 PROFILE_IMAGE_JARS := $(filter %.jar, $(JRE_LIB_TARGETS))
 
 PROFILE_IMAGE_JARS_CHECKED := $(IMAGES_OUTPUTDIR)/lib$(PROFILE)/_jars_checked
--- a/makefiles/ProfileNames.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/ProfileNames.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -30,9 +30,8 @@
 
 PROFILE_NAMES := compact1 compact2 compact3
 
-# The include files use 1,2,3,4 for simplicity and conciseness. Internally we
-# use profile_1, profile_2 and profile_3. Note that profile_4 is a full JRE so
-# we never have to use it directly.
+# The include files use 1,2,3 for simplicity and conciseness. Internally we
+# use profile_1, profile_2 and profile_3. 
 
 ALL_PROFILES := profile_1 profile_2 profile_3
 
--- a/makefiles/Profiles.gmk	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/Profiles.gmk	Mon Apr 08 15:57:12 2013 -0700
@@ -74,19 +74,19 @@
     $(PROFILE_2_JARS)
 
 ifdef OPENJDK
-  PROFILE_4_JRE_JAR_FILES := $(filter-out alt-rt.jar, $(PROFILE_4_JRE_JAR_FILES))
+  FULL_JRE_JAR_FILES := $(filter-out alt-rt.jar, $(FULL_JRE_JAR_FILES))
 endif
 
-PROFILE_4_JARS := \
-    $(addprefix $(IMAGES_OUTPUTDIR)/lib/, $(PROFILE_4_JRE_JAR_FILES)) \
+FULL_JRE_JARS := \
+    $(addprefix $(IMAGES_OUTPUTDIR)/lib/, $(FULL_JRE_JAR_FILES)) \
     $(PROFILE_3_JARS)
 
 # The full set of "jar" files needed for a complete JDK (ct.sym and src.zip
 # are also included.)
 # Note we need to add back the regular form of all the custom profile jars e.g.
-# rt.jar and resources.jar
+# rt.jar and resources.jar that we filtered out above
 
-ALL_JARS := $(PROFILE_4_JARS) \
+ALL_JARS := $(FULL_JRE_JARS) \
         $(IMAGES_OUTPUTDIR)/lib/rt.jar \
         $(IMAGES_OUTPUTDIR)/lib/resources.jar \
         $(IMAGES_OUTPUTDIR)/lib/jconsole.jar \
@@ -94,7 +94,6 @@
         $(IMAGES_OUTPUTDIR)/lib/tools.jar \
         $(IMAGES_OUTPUTDIR)/lib/ct.sym \
         $(IMAGES_OUTPUTDIR)/src.zip \
-        $(IMAGES_OUTPUTDIR)/lib/ext/cldrdata.jar \
         $(IMAGES_OUTPUTDIR)/lib/sa-jdi.jar
 
 ifeq ($(OPENJDK_TARGET_OS),solaris)
@@ -140,7 +139,7 @@
    $(PROFILE_1_JRE_BIN_FILES) \
    $(PROFILE_2_JRE_BIN_FILES) \
    $(PROFILE_3_JRE_BIN_FILES) \
-   $(PROFILE_4_JRE_BIN_FILES) 
+   $(FULL_JRE_BIN_FILES) 
 
 NOT_JRE_BIN_FILES := $(filter-out $(ALL_JRE_BIN_FILES), $(NEW_ALL_BIN_LIST))
 
@@ -149,18 +148,18 @@
     NOT_JRE_BIN_FILES += \
         $(PROFILE_2_JRE_BIN_FILES) \
         $(PROFILE_3_JRE_BIN_FILES) \
-        $(PROFILE_4_JRE_BIN_FILES) 
+        $(FULL_JRE_BIN_FILES) 
 endif
 
 ifeq ($(PROFILE), profile_2)
     NOT_JRE_BIN_FILES += \
         $(PROFILE_3_JRE_BIN_FILES) \
-        $(PROFILE_4_JRE_BIN_FILES) 
+        $(FULL_JRE_BIN_FILES) 
 endif
 
 ifeq ($(PROFILE), profile_3)
     NOT_JRE_BIN_FILES += \
-        $(PROFILE_4_JRE_BIN_FILES) 
+        $(FULL_JRE_BIN_FILES) 
 endif
 
 NOT_JRE_BIN_FILES := $(addprefix $(JDK_OUTPUTDIR)/bin/, $(NOT_JRE_BIN_FILES))
@@ -173,7 +172,7 @@
    $(PROFILE_1_JRE_LIB_FILES) \
    $(PROFILE_2_JRE_LIB_FILES) \
    $(PROFILE_3_JRE_LIB_FILES) \
-   $(PROFILE_4_JRE_LIB_FILES) 
+   $(FULL_JRE_LIB_FILES) 
 
 NOT_JRE_LIB_FILES := $(filter-out $(ALL_JRE_LIB_FILES), $(NEW_ALL_LIB_LIST))
 
@@ -189,18 +188,18 @@
     NOT_JRE_LIB_FILES += \
         $(PROFILE_2_JRE_LIB_FILES) \
         $(PROFILE_3_JRE_LIB_FILES) \
-        $(PROFILE_4_JRE_LIB_FILES) 
+        $(FULL_JRE_LIB_FILES) 
 endif
 
 ifeq ($(PROFILE), profile_2)
     NOT_JRE_LIB_FILES += \
         $(PROFILE_3_JRE_LIB_FILES) \
-        $(PROFILE_4_JRE_LIB_FILES) 
+        $(FULL_JRE_LIB_FILES) 
 endif
 
 ifeq ($(PROFILE), profile_3)
     NOT_JRE_LIB_FILES += \
-        $(PROFILE_4_JRE_LIB_FILES) 
+        $(FULL_JRE_LIB_FILES) 
 endif
 
 # Exclude the custom jar files as these will be added back via a special rule
@@ -279,13 +278,13 @@
 
 ifeq ($(PROFILE), profile_1)
   RT_JAR_EXCLUDES += \
-    $(PROFILE_1_RTJAR_EXCLUDE_TYPES) \
+    $(call class_list, $(PROFILE_1_RTJAR_EXCLUDE_TYPES)) \
     $(PROFILE_2_RTJAR_INCLUDE_PACKAGES) \
     $(call class_list, $(PROFILE_2_RTJAR_INCLUDE_TYPES)) \
     $(PROFILE_3_RTJAR_INCLUDE_PACKAGES) \
     $(call class_list, $(PROFILE_3_RTJAR_INCLUDE_TYPES)) \
-    $(PROFILE_4_RTJAR_INCLUDE_PACKAGES) \
-    $(call class_list, $(PROFILE_4_RTJAR_INCLUDE_TYPES))
+    $(FULL_JRE_RTJAR_INCLUDE_PACKAGES) \
+    $(call class_list, $(FULL_JRE_RTJAR_INCLUDE_TYPES))
   RT_JAR_INCLUDE_TYPES := \
 	$(call class_list, $(PROFILE_1_RTJAR_INCLUDE_TYPES))
   PROFILE_INCLUDE_METAINF_SERVICES := \
@@ -293,11 +292,11 @@
 endif
 ifeq ($(PROFILE), profile_2)
   RT_JAR_EXCLUDES += \
-    $(PROFILE_2_RTJAR_EXCLUDE_TYPES) \
+    $(call class_list, $(PROFILE_2_RTJAR_EXCLUDE_TYPES)) \
     $(PROFILE_3_RTJAR_INCLUDE_PACKAGES) \
     $(call class_list, $(PROFILE_3_RTJAR_INCLUDE_TYPES)) \
-    $(PROFILE_4_RTJAR_INCLUDE_PACKAGES) \
-    $(call class_list, $(PROFILE_4_RTJAR_INCLUDE_TYPES))
+    $(FULL_JRE_RTJAR_INCLUDE_PACKAGES) \
+    $(call class_list, $(FULL_JRE_RTJAR_INCLUDE_TYPES))
   RT_JAR_INCLUDE_TYPES := \
 	$(call class_list, $(PROFILE_1_RTJAR_INCLUDE_TYPES)) \
 	$(call class_list, $(PROFILE_2_RTJAR_INCLUDE_TYPES))
@@ -307,9 +306,9 @@
 endif
 ifeq ($(PROFILE), profile_3)
   RT_JAR_EXCLUDES += \
-    $(PROFILE_3_RTJAR_EXCLUDE_TYPES) \
-    $(PROFILE_4_RTJAR_INCLUDE_PACKAGES) \
-    $(call class_list, $(PROFILE_4_RTJAR_INCLUDE_TYPES))
+    $(call class_list, $(PROFILE_3_RTJAR_EXCLUDE_TYPES)) \
+    $(FULL_JRE_RTJAR_INCLUDE_PACKAGES) \
+    $(call class_list, $(FULL_JRE_RTJAR_INCLUDE_TYPES))
   RT_JAR_INCLUDE_TYPES := \
 	$(call class_list, $(PROFILE_1_RTJAR_INCLUDE_TYPES)) \
 	$(call class_list, $(PROFILE_2_RTJAR_INCLUDE_TYPES)) \
--- a/makefiles/mapfiles/libjava/mapfile-vers	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/mapfiles/libjava/mapfile-vers	Mon Apr 08 15:57:12 2013 -0700
@@ -133,6 +133,7 @@
 		Java_java_lang_ClassLoader_00024NativeLibrary_find;
 		Java_java_lang_ClassLoader_00024NativeLibrary_load;
 		Java_java_lang_ClassLoader_00024NativeLibrary_unload;
+		Java_java_lang_ClassLoader_00024NativeLibrary_findBuiltinLib;
 		Java_java_lang_ClassLoader_getCaller; 
 		Java_java_lang_ClassLoader_registerNatives;
 		Java_java_lang_Compiler_registerNatives;
--- a/makefiles/mapfiles/liblcms/mapfile-vers	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/mapfiles/liblcms/mapfile-vers	Mon Apr 08 15:57:12 2013 -0700
@@ -27,13 +27,12 @@
 
 SUNWprivate_1.1 {
 	global:
-        Java_sun_java2d_cmm_lcms_LCMS_loadProfile;
-        Java_sun_java2d_cmm_lcms_LCMS_freeProfile;
+        Java_sun_java2d_cmm_lcms_LCMS_loadProfileNative;
+        Java_sun_java2d_cmm_lcms_LCMS_freeProfileNative;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileSize;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileData;
-        Java_sun_java2d_cmm_lcms_LCMS_getTagSize;
-        Java_sun_java2d_cmm_lcms_LCMS_getTagData;
-        Java_sun_java2d_cmm_lcms_LCMS_setTagData;
+        Java_sun_java2d_cmm_lcms_LCMS_getTagNative;
+        Java_sun_java2d_cmm_lcms_LCMS_setTagDataNative;
         Java_sun_java2d_cmm_lcms_LCMS_colorConvert;
         Java_sun_java2d_cmm_lcms_LCMS_getProfileID;
         Java_sun_java2d_cmm_lcms_LCMS_initLCMS;
--- a/makefiles/profile-includes.txt	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/profile-includes.txt	Mon Apr 08 15:57:12 2013 -0700
@@ -27,6 +27,7 @@
     keytool$(EXE_SUFFIX)
 
 PROFILE_1_JRE_LIB_FILES := \
+    $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)j2pkcs11$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)java$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)jsig$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)jsig.diz \
@@ -34,6 +35,7 @@
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)nio$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)npt$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)npt.diz \
+    $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)sunec$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)unpack$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)verify$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)verify.diz \
@@ -61,7 +63,9 @@
     currency.data \
     ext/localedata.jar \
     ext/meta-index \
+    ext/sunec.jar \
     ext/sunjce_provider.jar \
+    ext/sunpkcs11.jar \
     jce.jar \
     jsse.jar \
     logging.properties \
@@ -88,7 +92,9 @@
 
 PROFILE_1_JRE_JAR_FILES := \
     ext/localedata.jar \
+    ext/sunec.jar \
     ext/sunjce_provider.jar \
+    ext/sunpkcs11.jar \
     jce.jar \
     jsse.jar \
     resources.jar \
@@ -142,7 +148,7 @@
     management-agent.jar
 
 
-PROFILE_4_JRE_BIN_FILES := \
+FULL_JRE_BIN_FILES := \
     orbd$(EXE_SUFFIX) \
     pack200$(EXE_SUFFIX) \
     policytool$(EXE_SUFFIX) \
@@ -150,7 +156,7 @@
     tnameserv$(EXE_SUFFIX) \
     unpack200$(EXE_SUFFIX)
 
-PROFILE_4_JRE_LIB_FILES := \
+FULL_JRE_LIB_FILES := \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)awt$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)awt_headless$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)awt_xawt$(SHARED_LIBRARY_SUFFIX) \
@@ -158,7 +164,6 @@
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)dt_socket$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)dt_socket.diz \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)fontmanager$(SHARED_LIBRARY_SUFFIX) \
-    $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)j2pkcs11$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)jawt$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)jdwp$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)jpeg$(SHARED_LIBRARY_SUFFIX) \
@@ -167,7 +172,6 @@
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)kcms$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)mlib_image$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)splashscreen$(SHARED_LIBRARY_SUFFIX) \
-    $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)sunec$(SHARED_LIBRARY_SUFFIX) \
     $(OPENJDK_TARGET_CPU_LEGACY_LIB)/$(LIBRARY_PREFIX)t2k$(SHARED_LIBRARY_SUFFIX) \
     alt-rt.jar \
     charsets.jar \
@@ -178,8 +182,7 @@
     cmm/sRGB.pf \
     ext/cldrdata.jar \
     ext/dnsns.jar \
-    ext/sunec.jar \
-    ext/sunpkcs11.jar \
+    ext/nashorn.jar \
     ext/zipfs.jar \
     flavormap.properties \
     fontconfig.RedHat.5.bfc \
@@ -219,10 +222,9 @@
     oblique-fonts/fonts.dir \
     psfont.properties.ja \
     psfontj2d.properties \
-    servicetag/jdk_header.png \
     sound.properties
 
-PROFILE_4_JRE_OTHER_FILES := \
+FULL_JRE_OTHER_FILES := \
     man/ja_JP.UTF-8/man1/java.1 \
     man/ja_JP.UTF-8/man1/javaws.1 \
     man/ja_JP.UTF-8/man1/keytool.1 \
@@ -246,13 +248,12 @@
     man/man1/tnameserv.1 \
     man/man1/unpack200.1
 
-PROFILE_4_JRE_JAR_FILES := \
+FULL_JRE_JAR_FILES := \
     alt-rt.jar \
     charsets.jar \
     ext/cldrdata.jar \
     ext/dnsns.jar \
-    ext/sunec.jar \
-    ext/sunpkcs11.jar \
+    ext/nashorn.jar \
     ext/zipfs.jar
 
 
--- a/makefiles/profile-rtjar-includes.txt	Thu Apr 04 11:33:40 2013 -0700
+++ b/makefiles/profile-rtjar-includes.txt	Mon Apr 08 15:57:12 2013 -0700
@@ -22,119 +22,55 @@
 # or visit www.oracle.com if you need additional information or have any
 # questions.
 #
+
+# Included or excluded types must take one of two forms
+# - *.class   to indicate all classes; or else
+# - a full single type name e.g.
+#      com/sun/security/auth/callback/DialogCallbackHandler$$1.class
+# You can not use arbitrary wildcards like DialogCallbackHandler*.class.
+#
+# Notes:
+#  -  Nested types must use $$ in place of $ as $ is the make meta-character
+#  -  If a package is not listed in any profile's inclusion list then it will
+#     not appear in any profile. But if a package is also missing from the
+#     full JRE's inclusion list then it will still be part of the full JRE.
+#     This is because the full JRE's inclusion lists are only used to define
+#     the exclusion lists for profiles; they are not used to define the full
+#     JRE contents - that is still done with the pre-profile legacy mechanism
+#     (all packagesthat can be found, less those not intended for rt.jar).
+#     This was done to minimize the impact of profiles on the regular
+#     non-profile build.
+#
 PROFILE_1_RTJAR_INCLUDE_PACKAGES := \
     com/sun/demo/jvmti/hprof \
     com/sun/java/util/jar/pack \
     com/sun/net/ssl \
-    com/sun/net/ssl/internal/www/protocol/https \
     com/sun/nio/file \
     com/sun/security/cert/internal/x509 \
     java/io \
     java/lang \
-    java/lang/annotation \
-    java/lang/invoke \
-    java/lang/ref \
-    java/lang/reflect \
     java/math \
     java/net \
     java/nio \
-    java/nio/channels \
-    java/nio/channels/spi \
-    java/nio/charset \
-    java/nio/charset/spi \
-    java/nio/file \
-    java/nio/file/attribute \
-    java/nio/file/spi \
     java/security \
-    java/security/cert \
-    java/security/interfaces \
-    java/security/spec \
     java/text \
-    java/text/spi \
     java/time \
     java/util \
-    java/util/concurrent \
-    java/util/concurrent/atomic \
-    java/util/concurrent/locks \
-    java/util/function \
-    java/util/jar \
-    java/util/logging \
-    java/util/regex \
-    java/util/spi \
-    java/util/zip \
     javax/net \
-    javax/net/ssl \
-    javax/security/auth \
-    javax/security/auth/callback \
-    javax/security/auth/login \
-    javax/security/auth/spi \
-    javax/security/auth/x500 \
-    javax/security/cert \
-    jdk/internal \
+    javax/security \
+    jdk \
     sun/invoke \
-    sun/invoke/anon \
-    sun/invoke/empty \
-    sun/invoke/util \
     sun/launcher \
-    sun/launcher/resources \
     sun/misc \
-    sun/misc/resources \
     sun/net/ \
-    sun/net/idn \
-    sun/net/sdp \
-    sun/net/spi \
-    sun/net/spi/nameservice \
-    sun/net/util \
-    sun/net/www \
-    sun/net/www/http \
-    sun/net/www/protocol/file \
-    sun/net/www/protocol/http/ \
-    sun/net/www/protocol/http/logging \
-    sun/net/www/protocol/https \
-    sun/net/www/protocol/jar \
     sun/nio \
-    sun/nio/ch \
-    sun/nio/cs \
-    sun/nio/fs \
     sun/reflect \
-    sun/reflect/annotation \
-    sun/reflect/generics/factory \
-    sun/reflect/generics/parser \
-    sun/reflect/generics/reflectiveObjects \
-    sun/reflect/generics/repository \
-    sun/reflect/generics/scope \
-    sun/reflect/generics/tree \
-    sun/reflect/generics/visitor \
-    sun/reflect/misc \
-    sun/security/action \
-    sun/security/ec \
-    sun/security/jca \
-    sun/security/pkcs \
-    sun/security/pkcs10 \
-    sun/security/pkcs12 \
-    sun/security/provider \
-    sun/security/provider/certpath \
-    sun/security/provider/certpath/ssl \
-    sun/security/rsa \
-    sun/security/timestamp \
-    sun/security/tools \
-    sun/security/tools/keytool \
-    sun/security/util \
-    sun/security/validator \
-    sun/security/x509 \
+    sun/security \
     sun/text \
-    sun/text/bidi \
-    sun/text/normalizer \
-    sun/text/resources \
     sun/usagetracker \
-    sun/util \
-    sun/util/calendar \
-    sun/util/locale \
-    sun/util/logging \
-    sun/util/logging/resources \
-    sun/util/resources
+    sun/util
 
-PROFILE_1_RTJAR_INCLUDE_TYPES :=
+PROFILE_1_RTJAR_INCLUDE_TYPES := 
 
 PROFILE_1_RTJAR_EXCLUDE_TYPES := 
 
@@ -144,139 +80,19 @@
 PROFILE_2_RTJAR_INCLUDE_PACKAGES := \
     com/sun/java_cup/internal/runtime \
     com/sun/net/httpserver \
-    com/sun/net/httpserver/spi \
-    com/sun/org/apache/bcel/internal \
-    com/sun/org/apache/bcel/internal/classfile \
-    com/sun/org/apache/bcel/internal/generic \
-    com/sun/org/apache/bcel/internal/util \
-    com/sun/org/apache/regexp/internal \
-    com/sun/org/apache/xalan/internal \
-    com/sun/org/apache/xalan/internal/extensions \
-    com/sun/org/apache/xalan/internal/lib \
-    com/sun/org/apache/xalan/internal/res \
-    com/sun/org/apache/xalan/internal/templates \
-    com/sun/org/apache/xalan/internal/utils \
-    com/sun/org/apache/xalan/internal/xslt \
-    com/sun/org/apache/xalan/internal/xsltc \
-    com/sun/org/apache/xalan/internal/xsltc/cmdline \
-    com/sun/org/apache/xalan/internal/xsltc/cmdline/getopt \
-    com/sun/org/apache/xalan/internal/xsltc/compiler \
-    com/sun/org/apache/xalan/internal/xsltc/compiler/util \
-    com/sun/org/apache/xalan/internal/xsltc/dom \
-    com/sun/org/apache/xalan/internal/xsltc/runtime \
-    com/sun/org/apache/xalan/internal/xsltc/runtime/output \
-    com/sun/org/apache/xalan/internal/xsltc/trax \
-    com/sun/org/apache/xalan/internal/xsltc/util \
-    com/sun/org/apache/xerces/internal/dom \
-    com/sun/org/apache/xerces/internal/dom/events \
-    com/sun/org/apache/xerces/internal/impl \
-    com/sun/org/apache/xerces/internal/impl/dtd \
-    com/sun/org/apache/xerces/internal/impl/dtd/models \
-    com/sun/org/apache/xerces/internal/impl/dv \
-    com/sun/org/apache/xerces/internal/impl/dv/dtd \
-    com/sun/org/apache/xerces/internal/impl/dv/util \
-    com/sun/org/apache/xerces/internal/impl/dv/xs \
-    com/sun/org/apache/xerces/internal/impl/io \
-    com/sun/org/apache/xerces/internal/impl/msg \
-    com/sun/org/apache/xerces/internal/impl/validation \
-    com/sun/org/apache/xerces/internal/impl/xpath \
-    com/sun/org/apache/xerces/internal/impl/xpath/regex \
-    com/sun/org/apache/xerces/internal/impl/xs \
-    com/sun/org/apache/xerces/internal/impl/xs/identity \
-    com/sun/org/apache/xerces/internal/impl/xs/models \
-    com/sun/org/apache/xerces/internal/impl/xs/opti \
-    com/sun/org/apache/xerces/internal/impl/xs/traversers \
-    com/sun/org/apache/xerces/internal/impl/xs/util \
-    com/sun/org/apache/xerces/internal/jaxp \
-    com/sun/org/apache/xerces/internal/jaxp/datatype \
-    com/sun/org/apache/xerces/internal/jaxp/validation \
-    com/sun/org/apache/xerces/internal/parsers \
-    com/sun/org/apache/xerces/internal/util \
-    com/sun/org/apache/xerces/internal/utils \
-    com/sun/org/apache/xerces/internal/xinclude \
-    com/sun/org/apache/xerces/internal/xni \
-    com/sun/org/apache/xerces/internal/xni/grammars \
-    com/sun/org/apache/xerces/internal/xni/parser \
-    com/sun/org/apache/xerces/internal/xpointer \
-    com/sun/org/apache/xerces/internal/xs \
-    com/sun/org/apache/xerces/internal/xs/datatypes \
-    com/sun/org/apache/xml/internal/dtm \
-    com/sun/org/apache/xml/internal/dtm/ref \
-    com/sun/org/apache/xml/internal/dtm/ref/dom2dtm \
-    com/sun/org/apache/xml/internal/dtm/ref/sax2dtm \
-    com/sun/org/apache/xml/internal/res \
-    com/sun/org/apache/xml/internal/resolver \
-    com/sun/org/apache/xml/internal/resolver/helpers \
-    com/sun/org/apache/xml/internal/resolver/readers \
-    com/sun/org/apache/xml/internal/resolver/tools \
-    com/sun/org/apache/xml/internal/serialize \
-    com/sun/org/apache/xml/internal/serializer \
-    com/sun/org/apache/xml/internal/serializer/utils \
-    com/sun/org/apache/xml/internal/utils \
-    com/sun/org/apache/xml/internal/utils/res \
-    com/sun/org/apache/xpath/internal \
-    com/sun/org/apache/xpath/internal/axes \
-    com/sun/org/apache/xpath/internal/compiler \
-    com/sun/org/apache/xpath/internal/domapi \
-    com/sun/org/apache/xpath/internal/functions \
-    com/sun/org/apache/xpath/internal/jaxp \
-    com/sun/org/apache/xpath/internal/objects \
-    com/sun/org/apache/xpath/internal/operations \
-    com/sun/org/apache/xpath/internal/patterns \
-    com/sun/org/apache/xpath/internal/res \
+    com/sun/org/apache \
     com/sun/rmi/rmid \
-    com/sun/xml/internal/stream/ \
-    com/sun/xml/internal/stream/dtd \
-    com/sun/xml/internal/stream/dtd/nonvalidating \
-    com/sun/xml/internal/stream/events \
-    com/sun/xml/internal/stream/util \
-    com/sun/xml/internal/stream/writers \
+    com/sun/xml/internal/stream \
     java/rmi \
-    java/rmi/activation \
-    java/rmi/dgc \
-    java/rmi/registry \
-    java/rmi/server \
     java/sql \
     javax/rmi/ssl \
     javax/sql \
     javax/transaction \
-    javax/transaction/xa \
     javax/xml \
-    javax/xml/datatype \
-    javax/xml/namespace \
-    javax/xml/parsers \
-    javax/xml/stream \
-    javax/xml/stream/events \
-    javax/xml/stream/util \
-    javax/xml/transform \
-    javax/xml/transform/dom \
-    javax/xml/transform/sax \
-    javax/xml/transform/stax \
-    javax/xml/transform/stream \
-    javax/xml/validation \
-    javax/xml/xpath \
-    org/w3c/dom \
-    org/w3c/dom/bootstrap \
-    org/w3c/dom/css \
-    org/w3c/dom/events \
-    org/w3c/dom/html \
-    org/w3c/dom/ls \
-    org/w3c/dom/ranges \
-    org/w3c/dom/stylesheets \
-    org/w3c/dom/traversal \
-    org/w3c/dom/views \
-    org/w3c/dom/xpath \
+    org/w3c \
     org/xml/sax \
-    org/xml/sax/ext \
-    org/xml/sax/helpers \
     sun/net/httpserver \
-    sun/rmi/log \
-    sun/rmi/registry \
-    sun/rmi/runtime \
-    sun/rmi/server \
-    sun/rmi/transport \
-    sun/rmi/transport/proxy \
-    sun/rmi/transport/tcp \
+    sun/rmi \
     sun/util/xml
 
 PROFILE_2_RTJAR_INCLUDE_TYPES := 
@@ -284,287 +100,83 @@
 PROFILE_2_RTJAR_EXCLUDE_TYPES := 
 
 PROFILE_2_INCLUDE_METAINF_SERVICES := \
-    META-INF/services/sun.util.spi.XmlPropertiesProvider
+    META-INF/services/sun.util.spi.XmlPropertiesProvider 
 
 
 PROFILE_3_RTJAR_INCLUDE_PACKAGES := \
-    com/sun/jmx/defaults \
-    com/sun/jmx/interceptor \
-    com/sun/jmx/mbeanserver \
-    com/sun/jmx/remote/internal \
-    com/sun/jmx/remote/protocol/rmi \
-    com/sun/jmx/remote/security \
-    com/sun/jmx/remote/util \
-    com/sun/jmx/snmp \
-    com/sun/jmx/snmp/IPAcl \
-    com/sun/jmx/snmp/agent \
-    com/sun/jmx/snmp/daemon \
-    com/sun/jmx/snmp/defaults \
-    com/sun/jmx/snmp/internal \
-    com/sun/jmx/snmp/mpm \
-    com/sun/jmx/snmp/tasks \
-    com/sun/jmx/trace \
-    com/sun/jndi/dns \
-    com/sun/jndi/ldap \
-    com/sun/jndi/ldap/ext \
-    com/sun/jndi/ldap/pool \
-    com/sun/jndi/ldap/sasl \
-    com/sun/jndi/rmi/registry \
-    com/sun/jndi/toolkit/ctx \
-    com/sun/jndi/toolkit/dir \
-    com/sun/jndi/toolkit/url \
-    com/sun/jndi/url/dns \
-    com/sun/jndi/url/ldap \
-    com/sun/jndi/url/ldaps \
-    com/sun/jndi/url/rmi \
+    com/sun/jmx \
+    com/sun/jndi \
     com/sun/management \
-    com/sun/management/jmx \
     com/sun/naming/internal \
     com/sun/nio/sctp \
     com/sun/org/apache/xml/internal/security \
-    com/sun/org/apache/xml/internal/security/algorithms \
-    com/sun/org/apache/xml/internal/security/algorithms/implementations \
-    com/sun/org/apache/xml/internal/security/c14n \
-    com/sun/org/apache/xml/internal/security/c14n/helper \
-    com/sun/org/apache/xml/internal/security/c14n/implementations \
-    com/sun/org/apache/xml/internal/security/encryption \
-    com/sun/org/apache/xml/internal/security/exceptions \
-    com/sun/org/apache/xml/internal/security/keys \
-    com/sun/org/apache/xml/internal/security/keys/content \
-    com/sun/org/apache/xml/internal/security/keys/content/keyvalues \
-    com/sun/org/apache/xml/internal/security/keys/content/x509 \
-    com/sun/org/apache/xml/internal/security/keys/keyresolver \
-    com/sun/org/apache/xml/internal/security/keys/keyresolver/implementations \
-    com/sun/org/apache/xml/internal/security/keys/storage \
-    com/sun/org/apache/xml/internal/security/keys/storage/implementations \
-    com/sun/org/apache/xml/internal/security/signature \
-    com/sun/org/apache/xml/internal/security/transforms \
-    com/sun/org/apache/xml/internal/security/transforms/implementations \
-    com/sun/org/apache/xml/internal/security/transforms/params \
-    com/sun/org/apache/xml/internal/security/utils \
-    com/sun/org/apache/xml/internal/security/utils/resolver \
-    com/sun/org/apache/xml/internal/security/utils/resolver/implementations \
     com/sun/rowset \
-    com/sun/rowset/internal \
-    com/sun/rowset/providers \
-    com/sun/script/javascript \
-    com/sun/script/util \
-    com/sun/security/auth/callback \
-    com/sun/security/auth/login \
-    com/sun/security/auth/module \
+    com/sun/script \
+    com/sun/security/auth \
     com/sun/security/jgss \
     com/sun/security/ntlm \
     com/sun/security/sasl \
-    com/sun/security/sasl/digest \
-    com/sun/security/sasl/gsskerb \
-    com/sun/security/sasl/ntlm \
-    com/sun/security/sasl/util \
     com/sun/tracing \
-    com/sun/tracing/dtrace \
     java/lang/instrument \
     java/lang/management \
     java/security/acl \
     java/util/prefs \
     javax/annotation/processing \
     javax/lang/model \
-    javax/lang/model/element \
-    javax/lang/model/type \
-    javax/lang/model/util \
     javax/management \
-    javax/management/loading \
-    javax/management/modelmbean \
-    javax/management/monitor \
-    javax/management/openmbean \
-    javax/management/relation \
-    javax/management/remote \
-    javax/management/remote/rmi \
-    javax/management/timer \
     javax/naming \
-    javax/naming/directory \
-    javax/naming/event \
-    javax/naming/ldap \
-    javax/naming/spi \
     javax/script \
     javax/security/auth/kerberos \
     javax/security/sasl \
     javax/smartcardio \
     javax/sql/rowset \
-    javax/sql/rowset/serial \
-    javax/sql/rowset/spi \
     javax/tools \
-    javax/tools/annotation \
     javax/xml/crypto \
-    javax/xml/crypto/dom \
-    javax/xml/crypto/dsig \
-    javax/xml/crypto/dsig/dom \
-    javax/xml/crypto/dsig/keyinfo \
-    javax/xml/crypto/dsig/spec \
     org/ietf/jgss \
-    org/jcp/xml/dsig/internal \
-    org/jcp/xml/dsig/internal/dom \
+    org/jcp/xml \
     sun/instrument \
     sun/management \
-    sun/management/counter \
-    sun/management/counter/perf \
-    sun/management/jmxremote \
-    sun/management/resources \
-    sun/management/snmp \
-    sun/management/snmp/jvminstr \
-    sun/management/snmp/jvmmib \
-    sun/management/snmp/util \
     sun/net/dns \
     sun/net/www/protocol/http/ntlm \
     sun/net/www/protocol/http/spnego \
     sun/nio/ch/sctp \
-    sun/org/mozilla/classfile/internal \
-    sun/org/mozilla/javascript/internal \
-    sun/org/mozilla/javascript/internal/annotations \
-    sun/org/mozilla/javascript/internal/ast \
-    sun/org/mozilla/javascript/internal/debug \
-    sun/org/mozilla/javascript/internal/jdk13 \
-    sun/org/mozilla/javascript/internal/jdk15 \
-    sun/org/mozilla/javascript/internal/json \
-    sun/org/mozilla/javascript/internal/optimizer \
-    sun/org/mozilla/javascript/internal/regexp \
-    sun/org/mozilla/javascript/internal/serialize \
-    sun/org/mozilla/javascript/internal/xml \
-    sun/org/mozilla/javascript/internal/xmlimpl \
+    sun/org/mozilla \
     sun/security/acl \
     sun/security/jgss \
-    sun/security/jgss/krb5 \
-    sun/security/jgss/spi \
-    sun/security/jgss/spnego \
-    sun/security/jgss/wrapper \
     sun/security/krb5 \
-    sun/security/krb5/internal \
-    sun/security/krb5/internal/ccache \
-    sun/security/krb5/internal/crypto \
-    sun/security/krb5/internal/crypto/dk \
-    sun/security/krb5/internal/ktab \
-    sun/security/krb5/internal/rcache \
-    sun/security/krb5/internal/util \
     sun/security/provider/certpath/ldap \
     sun/security/smartcardio \
-    sun/tracing \
-    sun/tracing/dtrace
+    sun/tracing
 
-PROFILE_3_RTJAR_INCLUDE_TYPES := \
-    com/sun/security/auth/*.class
+PROFILE_3_RTJAR_INCLUDE_TYPES := 
 
 PROFILE_3_RTJAR_EXCLUDE_TYPES := \
+    com/sun/security/auth/callback/DialogCallbackHandler$$1.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$2.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$Action.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$ConfirmationInfo.class \
+    com/sun/security/auth/callback/DialogCallbackHandler.class \
     javax/management/remote/rmi/_RMIConnectionImpl_Tie.class \
     javax/management/remote/rmi/_RMIConnection_Stub.class \
     javax/management/remote/rmi/_RMIServerImpl_Tie.class \
-    javax/management/remote/rmi/_RMIServer_Stub.class \
-    com/sun/security/auth/callback/DialogCallbackHandler.class \
-    com/sun/security/auth/callback/DialogCallbackHandler\$$$$1.class \
-    com/sun/security/auth/callback/DialogCallbackHandler\$$$$2.class \
-    com/sun/security/auth/callback/DialogCallbackHandler\$$$$Action.class \
-    com/sun/security/auth/callback/DialogCallbackHandler\$$$$ConfirmationInfo.class
+    javax/management/remote/rmi/_RMIServer_Stub.class
 
 PROFILE_3_INCLUDE_METAINF_SERVICES := \
     META-INF/services/javax.script.ScriptEngineFactory 
 
 
-PROFILE_4_RTJAR_INCLUDE_PACKAGES := \
-    com/oracle/net \
-    com/oracle/nio \
-    com/oracle/util \
+FULL_JRE_RTJAR_INCLUDE_PACKAGES := \
+    com/oracle \
     com/sun/accessibility/internal/resources \
     com/sun/activation/registries \
     com/sun/awt \
     com/sun/beans \
-    com/sun/beans/decoder \
-    com/sun/beans/finder \
-    com/sun/corba/se/impl/activation \
-    com/sun/corba/se/impl/copyobject \
-    com/sun/corba/se/impl/corba \
-    com/sun/corba/se/impl/dynamicany \
-    com/sun/corba/se/impl/encoding \
-    com/sun/corba/se/impl/interceptors \
-    com/sun/corba/se/impl/io \
-    com/sun/corba/se/impl/ior \
-    com/sun/corba/se/impl/ior/iiop \
-    com/sun/corba/se/impl/javax/rmi \
-    com/sun/corba/se/impl/javax/rmi/CORBA \
-    com/sun/corba/se/impl/legacy/connection \
-    com/sun/corba/se/impl/logging \
-    com/sun/corba/se/impl/monitoring \
-    com/sun/corba/se/impl/naming/cosnaming \
-    com/sun/corba/se/impl/naming/namingutil \
-    com/sun/corba/se/impl/naming/pcosnaming \
-    com/sun/corba/se/impl/oa \
-    com/sun/corba/se/impl/oa/poa \
-    com/sun/corba/se/impl/oa/toa \
-    com/sun/corba/se/impl/orb \
-    com/sun/corba/se/impl/orbutil \
-    com/sun/corba/se/impl/orbutil/closure \
-    com/sun/corba/se/impl/orbutil/concurrent \
-    com/sun/corba/se/impl/orbutil/fsm \
-    com/sun/corba/se/impl/orbutil/graph \
-    com/sun/corba/se/impl/orbutil/threadpool \
-    com/sun/corba/se/impl/presentation/rmi \
-    com/sun/corba/se/impl/protocol \
-    com/sun/corba/se/impl/protocol/giopmsgheaders \
-    com/sun/corba/se/impl/resolver \
-    com/sun/corba/se/impl/transport \
-    com/sun/corba/se/impl/util \
-    com/sun/corba/se/internal/CosNaming \
-    com/sun/corba/se/internal/Interceptors \
-    com/sun/corba/se/internal/POA \
-    com/sun/corba/se/internal/corba \
-    com/sun/corba/se/internal/iiop \
-    com/sun/corba/se/org/omg/CORBA \
-    com/sun/corba/se/pept/broker \
-    com/sun/corba/se/pept/encoding \
-    com/sun/corba/se/pept/protocol \
-    com/sun/corba/se/pept/transport \
-    com/sun/corba/se/spi/activation \
-    com/sun/corba/se/spi/activation/InitialNameServicePackage \
-    com/sun/corba/se/spi/activation/LocatorPackage \
-    com/sun/corba/se/spi/activation/RepositoryPackage \
-    com/sun/corba/se/spi/copyobject \
-    com/sun/corba/se/spi/encoding \
-    com/sun/corba/se/spi/extension \
-    com/sun/corba/se/spi/ior \
-    com/sun/corba/se/spi/ior/iiop \
-    com/sun/corba/se/spi/legacy/connection \
-    com/sun/corba/se/spi/legacy/interceptor \
-    com/sun/corba/se/spi/logging \
-    com/sun/corba/se/spi/monitoring \
-    com/sun/corba/se/spi/oa \
-    com/sun/corba/se/spi/orb \
-    com/sun/corba/se/spi/orbutil/closure \
-    com/sun/corba/se/spi/orbutil/fsm \
-    com/sun/corba/se/spi/orbutil/proxy \
-    com/sun/corba/se/spi/orbutil/threadpool \
-    com/sun/corba/se/spi/presentation/rmi \
-    com/sun/corba/se/spi/protocol \
-    com/sun/corba/se/spi/resolver \
-    com/sun/corba/se/spi/servicecontext \
-    com/sun/corba/se/spi/transport \
+    com/sun/corba \
     com/sun/image/codec/jpeg \
-    com/sun/imageio/plugins/bmp \
-    com/sun/imageio/plugins/common \
-    com/sun/imageio/plugins/gif \
-    com/sun/imageio/plugins/jpeg \
-    com/sun/imageio/plugins/png \
-    com/sun/imageio/plugins/wbmp \
-    com/sun/imageio/spi \
-    com/sun/imageio/stream \
-    com/sun/istack/internal \
-    com/sun/istack/internal/localization \
-    com/sun/istack/internal/logging \
-    com/sun/java/browser/dom \
-    com/sun/java/browser/net \
+    com/sun/imageio \
+    com/sun/istack \
+    com/sun/java/browser \
     com/sun/java/swing \
-    com/sun/java/swing/plaf/gtk \
-    com/sun/java/swing/plaf/gtk/resources \
-    com/sun/java/swing/plaf/motif \
-    com/sun/java/swing/plaf/motif/resources \
-    com/sun/java/swing/plaf/nimbus \
-    com/sun/java/swing/plaf/windows \
-    com/sun/java/swing/plaf/windows/resources \
     com/sun/jmx/remote/protocol/iiop \
     com/sun/jndi/cosnaming \
     com/sun/jndi/toolkit/corba \
@@ -572,313 +184,40 @@
     com/sun/jndi/url/iiop \
     com/sun/jndi/url/iiopname \
     com/sun/media/sound \
-    com/sun/org/glassfish/external/amx \
-    com/sun/org/glassfish/external/arc \
-    com/sun/org/glassfish/external/probe/provider \
-    com/sun/org/glassfish/external/probe/provider/annotations \
-    com/sun/org/glassfish/external/statistics \
-    com/sun/org/glassfish/external/statistics/annotations \
-    com/sun/org/glassfish/external/statistics/impl \
-    com/sun/org/glassfish/gmbal \
-    com/sun/org/glassfish/gmbal/util \
-    com/sun/org/omg/CORBA \
-    com/sun/org/omg/CORBA/ValueDefPackage \
-    com/sun/org/omg/CORBA/portable \
-    com/sun/org/omg/SendingContext \
-    com/sun/org/omg/SendingContext/CodeBasePackage \
-    com/sun/servicetag \
-    com/sun/swing/internal/plaf/basic/resources \
-    com/sun/swing/internal/plaf/metal/resources \
-    com/sun/swing/internal/plaf/synth/resources \
+    com/sun/org/glassfish \
+    com/sun/org/omg \
+    com/sun/swing \
     com/sun/xml/internal/bind \
-    com/sun/xml/internal/bind/annotation \
-    com/sun/xml/internal/bind/api \
-    com/sun/xml/internal/bind/api/impl \
-    com/sun/xml/internal/bind/marshaller \
-    com/sun/xml/internal/bind/unmarshaller \
-    com/sun/xml/internal/bind/util \
-    com/sun/xml/internal/bind/v2 \
-    com/sun/xml/internal/bind/v2/bytecode \
-    com/sun/xml/internal/bind/v2/model/annotation \
-    com/sun/xml/internal/bind/v2/model/core \
-    com/sun/xml/internal/bind/v2/model/impl \
-    com/sun/xml/internal/bind/v2/model/nav \
-    com/sun/xml/internal/bind/v2/model/runtime \
-    com/sun/xml/internal/bind/v2/runtime \
-    com/sun/xml/internal/bind/v2/runtime/output \
-    com/sun/xml/internal/bind/v2/runtime/property \
-    com/sun/xml/internal/bind/v2/runtime/reflect \
-    com/sun/xml/internal/bind/v2/runtime/reflect/opt \
-    com/sun/xml/internal/bind/v2/runtime/unmarshaller \
-    com/sun/xml/internal/bind/v2/schemagen \
-    com/sun/xml/internal/bind/v2/schemagen/episode \
-    com/sun/xml/internal/bind/v2/schemagen/xmlschema \
-    com/sun/xml/internal/bind/v2/util \
     com/sun/xml/internal/fastinfoset \
-    com/sun/xml/internal/fastinfoset/algorithm \
-    com/sun/xml/internal/fastinfoset/alphabet \
-    com/sun/xml/internal/fastinfoset/dom \
-    com/sun/xml/internal/fastinfoset/org/apache/xerces/util \
-    com/sun/xml/internal/fastinfoset/sax \
-    com/sun/xml/internal/fastinfoset/stax \
-    com/sun/xml/internal/fastinfoset/stax/events \
-    com/sun/xml/internal/fastinfoset/stax/factory \
-    com/sun/xml/internal/fastinfoset/stax/util \
-    com/sun/xml/internal/fastinfoset/tools \
-    com/sun/xml/internal/fastinfoset/util \
-    com/sun/xml/internal/fastinfoset/vocab \
-    com/sun/xml/internal/messaging/saaj \
-    com/sun/xml/internal/messaging/saaj/client/p2p \
-    com/sun/xml/internal/messaging/saaj/packaging/mime \
-    com/sun/xml/internal/messaging/saaj/packaging/mime/internet \
-    com/sun/xml/internal/messaging/saaj/packaging/mime/util \
-    com/sun/xml/internal/messaging/saaj/soap \
-    com/sun/xml/internal/messaging/saaj/soap/dynamic \
-    com/sun/xml/internal/messaging/saaj/soap/impl \
-    com/sun/xml/internal/messaging/saaj/soap/name \
-    com/sun/xml/internal/messaging/saaj/soap/ver1_1 \
-    com/sun/xml/internal/messaging/saaj/soap/ver1_2 \
-    com/sun/xml/internal/messaging/saaj/util \
-    com/sun/xml/internal/messaging/saaj/util/transform \
-    com/sun/xml/internal/org/jvnet/fastinfoset \
-    com/sun/xml/internal/org/jvnet/fastinfoset/sax \
-    com/sun/xml/internal/org/jvnet/fastinfoset/sax/helpers \
-    com/sun/xml/internal/org/jvnet/fastinfoset/stax \
-    com/sun/xml/internal/org/jvnet/mimepull \
-    com/sun/xml/internal/org/jvnet/staxex \
-    com/sun/xml/internal/org/jvnet/ws \
-    com/sun/xml/internal/org/jvnet/ws/databinding \
-    com/sun/xml/internal/org/jvnet/ws/message \
+    com/sun/xml/internal/messaging \
+    com/sun/xml/internal/org \
     com/sun/xml/internal/stream/buffer \
-    com/sun/xml/internal/stream/buffer/sax \
-    com/sun/xml/internal/stream/buffer/stax \
     com/sun/xml/internal/txw2 \
-    com/sun/xml/internal/txw2/annotation \
-    com/sun/xml/internal/txw2/output \
-    com/sun/xml/internal/ws/addressing \
-    com/sun/xml/internal/ws/addressing/model \
-    com/sun/xml/internal/ws/addressing/policy \
-    com/sun/xml/internal/ws/addressing/v200408 \
-    com/sun/xml/internal/ws/api \
-    com/sun/xml/internal/ws/api/addressing \
-    com/sun/xml/internal/ws/api/client \
-    com/sun/xml/internal/ws/api/config/management \
-    com/sun/xml/internal/ws/api/config/management/policy \
-    com/sun/xml/internal/ws/api/databinding \
-    com/sun/xml/internal/ws/api/fastinfoset \
-    com/sun/xml/internal/ws/api/ha \
-    com/sun/xml/internal/ws/api/handler \
-    com/sun/xml/internal/ws/api/message \
-    com/sun/xml/internal/ws/api/message/saaj \
-    com/sun/xml/internal/ws/api/message/stream \
-    com/sun/xml/internal/ws/api/model \
-    com/sun/xml/internal/ws/api/model/soap \
-    com/sun/xml/internal/ws/api/model/wsdl \
-    com/sun/xml/internal/ws/api/pipe \
-    com/sun/xml/internal/ws/api/pipe/helper \
-    com/sun/xml/internal/ws/api/policy \
-    com/sun/xml/internal/ws/api/policy/subject \
-    com/sun/xml/internal/ws/api/server \
-    com/sun/xml/internal/ws/api/streaming \
-    com/sun/xml/internal/ws/api/wsdl/parser \
-    com/sun/xml/internal/ws/api/wsdl/writer \
-    com/sun/xml/internal/ws/binding \
-    com/sun/xml/internal/ws/client \
-    com/sun/xml/internal/ws/client/dispatch \
-    com/sun/xml/internal/ws/client/sei \
-    com/sun/xml/internal/ws/config/management/policy \
-    com/sun/xml/internal/ws/db \
-    com/sun/xml/internal/ws/db/glassfish \
-    com/sun/xml/internal/ws/developer \
-    com/sun/xml/internal/ws/encoding \
-    com/sun/xml/internal/ws/encoding/fastinfoset \
-    com/sun/xml/internal/ws/encoding/policy \
-    com/sun/xml/internal/ws/encoding/soap \
-    com/sun/xml/internal/ws/encoding/soap/streaming \
-    com/sun/xml/internal/ws/encoding/xml \
-    com/sun/xml/internal/ws/fault \
-    com/sun/xml/internal/ws/handler \
-    com/sun/xml/internal/ws/message \
-    com/sun/xml/internal/ws/message/jaxb \
-    com/sun/xml/internal/ws/message/saaj \
-    com/sun/xml/internal/ws/message/source \
-    com/sun/xml/internal/ws/message/stream \
-    com/sun/xml/internal/ws/model \
-    com/sun/xml/internal/ws/model/soap \
-    com/sun/xml/internal/ws/model/wsdl \
-    com/sun/xml/internal/ws/org/objectweb/asm \
-    com/sun/xml/internal/ws/policy \
-    com/sun/xml/internal/ws/policy/jaxws \
-    com/sun/xml/internal/ws/policy/jaxws/spi \
-    com/sun/xml/internal/ws/policy/privateutil \
-    com/sun/xml/internal/ws/policy/sourcemodel \
-    com/sun/xml/internal/ws/policy/sourcemodel/attach \
-    com/sun/xml/internal/ws/policy/sourcemodel/wspolicy \
-    com/sun/xml/internal/ws/policy/spi \
-    com/sun/xml/internal/ws/policy/subject \
-    com/sun/xml/internal/ws/protocol/soap \
-    com/sun/xml/internal/ws/protocol/xml \
-    com/sun/xml/internal/ws/resources \
-    com/sun/xml/internal/ws/server \
-    com/sun/xml/internal/ws/server/provider \
-    com/sun/xml/internal/ws/server/sei \
-    com/sun/xml/internal/ws/spi \
-    com/sun/xml/internal/ws/spi/db \
-    com/sun/xml/internal/ws/streaming \
-    com/sun/xml/internal/ws/transport \
-    com/sun/xml/internal/ws/transport/http \
-    com/sun/xml/internal/ws/transport/http/client \
-    com/sun/xml/internal/ws/transport/http/server \
-    com/sun/xml/internal/ws/util \
-    com/sun/xml/internal/ws/util/exception \
-    com/sun/xml/internal/ws/util/localization \
-    com/sun/xml/internal/ws/util/pipe \
-    com/sun/xml/internal/ws/util/xml \
-    com/sun/xml/internal/ws/wsdl \
-    com/sun/xml/internal/ws/wsdl/parser \
-    com/sun/xml/internal/ws/wsdl/writer \
-    com/sun/xml/internal/ws/wsdl/writer/document \
-    com/sun/xml/internal/ws/wsdl/writer/document/http \
-    com/sun/xml/internal/ws/wsdl/writer/document/soap \
-    com/sun/xml/internal/ws/wsdl/writer/document/soap12 \
-    com/sun/xml/internal/ws/wsdl/writer/document/xsd \
+    com/sun/xml/internal/ws \
     java/applet \
     java/awt \
-    java/awt/color \
-    java/awt/datatransfer \
-    java/awt/dnd \
-    java/awt/dnd/peer \
-    java/awt/event \
-    java/awt/font \
-    java/awt/geom \
-    java/awt/im \
-    java/awt/im/spi \
-    java/awt/image \
-    java/awt/image/renderable \
-    java/awt/peer \
-    java/awt/print \
     java/beans \
     javax/accessibility \
     javax/activation \
     javax/activity \
     javax/imageio \
-    javax/imageio/event \
-    javax/imageio/metadata \
-    javax/imageio/plugins/bmp \
-    javax/imageio/plugins/jpeg \
-    javax/imageio/spi \
-    javax/imageio/stream \
     javax/jws \
-    javax/jws/soap \
     javax/print \
-    javax/print/attribute \
-    javax/print/attribute/standard \
-    javax/print/event \
     javax/rmi/CORBA \
-    javax/sound/midi \
-    javax/sound/midi/spi \
-    javax/sound/sampled \
-    javax/sound/sampled/spi \
+    javax/sound \
     javax/swing \
-    javax/swing/border \
-    javax/swing/colorchooser \
-    javax/swing/event \
-    javax/swing/filechooser \
-    javax/swing/plaf \
-    javax/swing/plaf/basic \
-    javax/swing/plaf/metal \
-    javax/swing/plaf/multi \
-    javax/swing/plaf/nimbus \
-    javax/swing/plaf/synth \
-    javax/swing/table \
-    javax/swing/text \
-    javax/swing/text/html \
-    javax/swing/text/html/parser \
-    javax/swing/text/rtf \
-    javax/swing/tree \
-    javax/swing/undo \
     javax/xml/bind \
-    javax/xml/bind/annotation \
-    javax/xml/bind/annotation/adapters \
-    javax/xml/bind/attachment \
-    javax/xml/bind/helpers \
-    javax/xml/bind/util \
     javax/xml/soap \
     javax/xml/ws \
-    javax/xml/ws/handler \
-    javax/xml/ws/handler/soap \
-    javax/xml/ws/http \
-    javax/xml/ws/soap \
-    javax/xml/ws/spi \
-    javax/xml/ws/spi/http \
-    javax/xml/ws/wsaddressing \
-    org/omg/CORBA \
-    org/omg/CORBA/DynAnyPackage \
-    org/omg/CORBA/ORBPackage \
-    org/omg/CORBA/TypeCodePackage \
-    org/omg/CORBA/portable \
-    org/omg/CORBA_2_3 \
-    org/omg/CORBA_2_3/portable \
-    org/omg/CosNaming \
-    org/omg/CosNaming/NamingContextExtPackage \
-    org/omg/CosNaming/NamingContextPackage \
-    org/omg/Dynamic \
-    org/omg/DynamicAny \
-    org/omg/DynamicAny/DynAnyFactoryPackage \
-    org/omg/DynamicAny/DynAnyPackage \
-    org/omg/IOP \
-    org/omg/IOP/CodecFactoryPackage \
-    org/omg/IOP/CodecPackage \
-    org/omg/Messaging \
-    org/omg/PortableInterceptor \
-    org/omg/PortableInterceptor/ORBInitInfoPackage \
-    org/omg/PortableServer \
-    org/omg/PortableServer/CurrentPackage \
-    org/omg/PortableServer/POAManagerPackage \
-    org/omg/PortableServer/POAPackage \
-    org/omg/PortableServer/ServantLocatorPackage \
-    org/omg/PortableServer/portable \
-    org/omg/SendingContext \
-    org/omg/stub/java/rmi \
-    org/omg/stub/javax/management/remote/rmi \
+    org/omg \
     sun/applet \
-    sun/applet/resources \
     sun/audio \
     sun/awt \
-    sun/awt/X11 \
-    sun/awt/datatransfer \
-    sun/awt/dnd \
-    sun/awt/event \
-    sun/awt/geom \
-    sun/awt/im \
-    sun/awt/image \
-    sun/awt/image/codec \
-    sun/awt/motif \
-    sun/awt/resources \
-    sun/awt/shell \
-    sun/awt/util \
-    sun/awt/windows \
-    sun/beans/editors \
-    sun/beans/infos \
     sun/corba \
     sun/dc \
-    sun/dc/path \
-    sun/dc/pr \
     sun/font \
     sun/java2d \
-    sun/java2d/cmm \
-    sun/java2d/cmm/kcms \
-    sun/java2d/cmm/lcms \
-    sun/java2d/jules \
-    sun/java2d/loops \
-    sun/java2d/opengl \
-    sun/java2d/pipe \
-    sun/java2d/pipe/hw \
-    sun/java2d/pisces \
-    sun/java2d/x11 \
-    sun/java2d/xr \
     sun/net/ftp \
-    sun/net/ftp/impl \
     sun/net/smtp \
     sun/net/www/content/audio \
     sun/net/www/content/image \
@@ -887,27 +226,26 @@
     sun/net/www/protocol/mailto \
     sun/net/www/protocol/netdoc \
     sun/print \
-    sun/print/resources \
     sun/security/tools/policytool \
     sun/swing \
-    sun/swing/icon \
-    sun/swing/plaf \
-    sun/swing/plaf/synth \
-    sun/swing/plaf/windows \
-    sun/swing/table \
-    sun/swing/text \
-    sun/swing/text/html \
-    sun/tools/jar \
-    sun/tools/jar/resources
+    sun/tools/jar
 
-PROFILE_4_RTJAR_INCLUDE_TYPES := \
-    com/sun/xml/internal/ws/*.class \
+FULL_JRE_RTJAR_INCLUDE_TYPES := \
+    com/sun/security/auth/callback/DialogCallbackHandler$$1.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$2.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$Action.class \
+    com/sun/security/auth/callback/DialogCallbackHandler$$ConfirmationInfo.class \
+    com/sun/security/auth/callback/DialogCallbackHandler.class \
     javax/annotation/*.class \
+    javax/management/remote/rmi/_RMIConnectionImpl_Tie.class \
+    javax/management/remote/rmi/_RMIConnection_Stub.class \
+    javax/management/remote/rmi/_RMIServerImpl_Tie.class \
+    javax/management/remote/rmi/_RMIServer_Stub.class \
     javax/rmi/*.class
 
-PROFILE_4_RTJAR_EXCLUDE_TYPES := 
+FULL_JRE_RTJAR_EXCLUDE_TYPES := 
 
-PROFILE_4_INCLUDE_METAINF_SERVICES := \
+FULL_JRE_INCLUDE_METAINF_SERVICES := \
     META-INF/services/com.sun.tools.internal.ws.wscompile.Plugin  \
     META-INF/services/com.sun.tools.internal.xjc.Plugin  \
     META-INF/services/javax.print.PrintServiceLookup  \
--- a/src/macosx/classes/com/apple/laf/AquaButtonBorder.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/com/apple/laf/AquaButtonBorder.java	Mon Apr 08 15:57:12 2013 -0700
@@ -83,14 +83,19 @@
         painter.state.set(state);
         painter.state.set((state != State.DISABLED && state != State.INACTIVE) && b.isFocusPainted() && isFocused(b) ? Focused.YES : Focused.NO);
 
+        // Full border size of the component.
+        // g.setColor(new Color(0, 255, 0, 70));
+        // g.drawRect(x, y, width - 1, height - 1);
+
         final Insets subInsets = sizeVariant.insets;
         x += subInsets.left;
         y += subInsets.top;
         width -= (subInsets.left + subInsets.right);
         height -= (subInsets.top + subInsets.bottom);
 
-//        g.setColor(Color.magenta);
-//        g.drawRect(x, y, width - 1, height - 1);
+        // Where the native border should start to paint.
+        // g.setColor(new Color(255, 0, 255, 70));
+        // g.drawRect(x, y, width - 1, height - 1);
 
         doButtonPaint(b, model, g, x, y, width, height);
     }
--- a/src/macosx/classes/com/apple/laf/AquaButtonExtendedTypes.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/com/apple/laf/AquaButtonExtendedTypes.java	Mon Apr 08 15:57:12 2013 -0700
@@ -184,30 +184,30 @@
             new BorderDefinedTypeSpecifier("round", Widget.BUTTON_ROUND, new SizeVariant().alterInsets(2, 0, 0, 0).alterMinSize(28, 28), -3, -3, -3, -3),
             new BorderDefinedTypeSpecifier("texturedRound", Widget.BUTTON_ROUND_INSET, new SizeVariant().alterInsets(0, 0, 0, 0).alterMinSize(26, 26), -2, -2, 0, 0),
 
-            new SegmentedBorderDefinedTypeSpecifier("segmented-first", Widget.BUTTON_SEGMENTED, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 16, 6, 10).alterInsets(5, 3, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmented-middle", Widget.BUTTON_SEGMENTED, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 9, 6, 10).alterInsets(5, 0, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmented-last", Widget.BUTTON_SEGMENTED, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 9, 6, 16).alterInsets(5, 0, 5, 3).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmented-only", Widget.BUTTON_SEGMENTED, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 16, 6, 16).alterInsets(5, 3, 5, 3).alterMinSize(34, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmented-first", Widget.BUTTON_SEGMENTED, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 16, 6, 10).alterInsets(2, 3, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmented-middle", Widget.BUTTON_SEGMENTED, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 9, 6, 10).alterInsets(2, 0, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmented-last", Widget.BUTTON_SEGMENTED, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 9, 6, 16).alterInsets(2, 0, 2, 3).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmented-only", Widget.BUTTON_SEGMENTED, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 16, 6, 16).alterInsets(2, 3, 2, 3).alterMinSize(34, 28), 0, -3, 0, -3),
 
-            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-first", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(5, 2, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-middle", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(5, 0, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-last", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(5, 0, 5, 2).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-only", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(5, 2, 5, 2).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-first", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(2, 2, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-middle", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(2, 0, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-last", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(2, 0, 2, 2).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedRoundRect-only", Widget.BUTTON_SEGMENTED_INSET, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(2, 2, 2, 2).alterMinSize(0, 28), 0, -3, 0, -3),
 
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-first", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(5, 2, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-middle", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(5, 0, 5, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-last", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(5, 0, 5, 2).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-only", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(5, 2, 5, 2).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-first", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(2, 2, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-middle", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(2, 0, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-last", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(2, 0, 2, 2).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTexturedRounded-only", Widget.BUTTON_SEGMENTED_SCURVE, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(2, 2, 2, 2).alterMinSize(0, 28), 0, -3, 0, -3),
 
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-first", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(6, 3, 6, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-middle", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(6, 0, 6, 0).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-last", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(6, 0, 6, 3).alterMinSize(0, 28), 0, -3, 0, -3),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-only", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(6, 3, 6, 3).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-first", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(2, 3, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-middle", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(2, 0, 2, 0).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-last", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(2, 0, 2, 3).alterMinSize(0, 28), 0, -3, 0, -3),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedTextured-only", Widget.BUTTON_SEGMENTED_TEXTURED, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(2, 3, 2, 3).alterMinSize(0, 28), 0, -3, 0, -3),
 
-            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-first", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(5, 2, 5, 0).alterMinSize(0, 28), 0, 0, 0, 0),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-middle", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(5, 0, 5, 0).alterMinSize(0, 28), 0, 0, 0, 0),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-last", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(5, 0, 5, 2).alterMinSize(0, 28), 0, 0, 0, 0),
-            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-only", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(5, 2, 5, 2).alterMinSize(34, 28), 0, 0, 0, 0),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-first", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.FIRST, new SizeVariant().alterMargins(6, 12, 6, 8).alterInsets(2, 2, 2, 0).alterMinSize(0, 28), 0, 0, 0, 0),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-middle", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.MIDDLE, new SizeVariant().alterMargins(6, 8, 6, 8).alterInsets(2, 0, 2, 0).alterMinSize(0, 28), 0, 0, 0, 0),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-last", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.LAST, new SizeVariant().alterMargins(6, 8, 6, 12).alterInsets(2, 0, 2, 2).alterMinSize(0, 28), 0, 0, 0, 0),
+            new SegmentedBorderDefinedTypeSpecifier("segmentedCapsule-only", Widget.BUTTON_SEGMENTED_TOOLBAR, SegmentPosition.ONLY, new SizeVariant().alterMargins(6, 12, 6, 12).alterInsets(2, 2, 2, 2).alterMinSize(34, 28), 0, 0, 0, 0),
 
             new BorderDefinedTypeSpecifier("segmentedGradient-first", Widget.BUTTON_BEVEL_INSET, new SizeVariant(18, 18).alterMargins(4, 5, 4, 5).replaceInsets(new Insets(-2,-0,-2,-0))),
             new BorderDefinedTypeSpecifier("segmentedGradient-middle", Widget.BUTTON_BEVEL_INSET, new SizeVariant(18, 18).alterMargins(4, 5, 4, 5).replaceInsets(new Insets(-2,-1,-2,-0))),
--- a/src/macosx/classes/com/apple/laf/AquaComboBoxUI.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/com/apple/laf/AquaComboBoxUI.java	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 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
@@ -34,7 +34,6 @@
 import javax.swing.event.*;
 import javax.swing.plaf.*;
 import javax.swing.plaf.basic.*;
-import com.apple.laf.ClientPropertyApplicator;
 import com.apple.laf.ClientPropertyApplicator.Property;
 import apple.laf.JRSUIConstants.Size;
 
@@ -142,35 +141,46 @@
         return new AquaComboBoxEditor();
     }
 
-    class AquaComboBoxEditor extends BasicComboBoxEditor implements UIResource, DocumentListener {
-        protected AquaComboBoxEditor() {
+    final class AquaComboBoxEditor extends BasicComboBoxEditor
+            implements UIResource, DocumentListener {
+
+        AquaComboBoxEditor() {
             super();
             editor = new AquaCustomComboTextField();
             editor.addFocusListener(this);
             editor.getDocument().addDocumentListener(this);
         }
 
+        @Override
         public void focusGained(final FocusEvent e) {
-            arrowButton.repaint();
+            if (arrowButton != null) {
+                arrowButton.repaint();
+            }
         }
 
+        @Override
         public void focusLost(final FocusEvent e) {
-            arrowButton.repaint();
+            if (arrowButton != null) {
+                arrowButton.repaint();
+            }
         }
 
+        @Override
         public void changedUpdate(final DocumentEvent e) {
             editorTextChanged();
         }
 
+        @Override
         public void insertUpdate(final DocumentEvent e) {
             editorTextChanged();
         }
 
+        @Override
         public void removeUpdate(final DocumentEvent e) {
             editorTextChanged();
         }
 
-        protected void editorTextChanged() {
+        private void editorTextChanged() {
             if (!popup.isVisible()) return;
 
             final Object text = editor.getText();
--- a/src/macosx/classes/sun/awt/CGraphicsConfig.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/awt/CGraphicsConfig.java	Mon Apr 08 15:57:12 2013 -0700
@@ -53,7 +53,7 @@
 
     @Override
     public Rectangle getBounds() {
-        final Rectangle2D nativeBounds = nativeGetBounds(device.getCoreGraphicsScreen());
+        final Rectangle2D nativeBounds = nativeGetBounds(device.getCGDisplayID());
         return nativeBounds.getBounds(); // does integer rounding
     }
 
--- a/src/macosx/classes/sun/awt/CGraphicsDevice.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/awt/CGraphicsDevice.java	Mon Apr 08 15:57:12 2013 -0700
@@ -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
@@ -25,11 +25,12 @@
 
 package sun.awt;
 
+import java.awt.AWTPermission;
+import java.awt.DisplayMode;
 import java.awt.GraphicsConfiguration;
 import java.awt.GraphicsDevice;
+import java.awt.Insets;
 import java.awt.Window;
-import java.awt.AWTPermission;
-import java.awt.DisplayMode;
 import java.util.Objects;
 
 import sun.java2d.opengl.CGLGraphicsConfig;
@@ -58,9 +59,12 @@
     }
 
     /**
+     * Returns CGDirectDisplayID, which is the same id as @"NSScreenNumber" in
+     * NSScreen.
+     *
      * @return CoreGraphics display id.
      */
-    public int getCoreGraphicsScreen() {
+    public int getCGDisplayID() {
         return displayID;
     }
 
@@ -107,8 +111,9 @@
         return nativeGetYResolution(displayID);
     }
 
-    private static native double nativeGetXResolution(int displayID);
-    private static native double nativeGetYResolution(int displayID);
+    public Insets getScreenInsets() {
+        return nativeGetScreenInsets(displayID);
+    }
 
     /**
      * Enters full-screen mode, or returns to windowed mode.
@@ -214,9 +219,15 @@
         return nativeGetDisplayModes(displayID);
     }
 
-    private native void nativeSetDisplayMode(int displayID, int w, int h, int bpp, int refrate);
+    private static native void nativeSetDisplayMode(int displayID, int w, int h, int bpp, int refrate);
 
-    private native DisplayMode nativeGetDisplayMode(int displayID);
+    private static native DisplayMode nativeGetDisplayMode(int displayID);
 
-    private native DisplayMode[] nativeGetDisplayModes(int displayID);
+    private static native DisplayMode[] nativeGetDisplayModes(int displayID);
+
+    private static native double nativeGetXResolution(int displayID);
+
+    private static native double nativeGetYResolution(int displayID);
+
+    private static native Insets nativeGetScreenInsets(int displayID);
 }
--- a/src/macosx/classes/sun/font/CStrike.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/font/CStrike.java	Mon Apr 08 15:57:12 2013 -0700
@@ -500,7 +500,10 @@
                 final Iterator<Long> i = generalCache.values().iterator();
                 while (i.hasNext()) {
                     final long longValue = i.next().longValue();
-                    if (longValue != -1 && longValue != 0) StrikeCache.freeLongPointer(longValue);
+                    if (longValue != -1 && longValue != 0) {
+                        removeGlyphInfoFromCache(longValue);
+                        StrikeCache.freeLongPointer(longValue);
+                    }
                 }
             }
 
@@ -512,7 +515,10 @@
         private static void disposeLongArray(final long[] longArray) {
             for (int i = 0; i < longArray.length; i++) {
                 final long ptr = longArray[i];
-                if (ptr != 0 && ptr != -1) StrikeCache.freeLongPointer(ptr); // free's the native struct pointer
+                if (ptr != 0 && ptr != -1) {
+                    removeGlyphInfoFromCache(ptr);
+                    StrikeCache.freeLongPointer(ptr); // free's the native struct pointer
+                }
             }
         }
 
--- a/src/macosx/classes/sun/font/CStrikeDisposer.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/font/CStrikeDisposer.java	Mon Apr 08 15:57:12 2013 -0700
@@ -85,4 +85,6 @@
     }
 
     private native void freeNativeScalerContext(long pContext);
+
+    protected static native void removeGlyphInfoFromCache(long glyphInfo);
 }
--- a/src/macosx/classes/sun/java2d/opengl/CGLGraphicsConfig.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/java2d/opengl/CGLGraphicsConfig.java	Mon Apr 08 15:57:12 2013 -0700
@@ -80,10 +80,8 @@
     private ContextCapabilities oglCaps;
     private OGLContext context;
     private final Object disposerReferent = new Object();
-
-    public static native int getDefaultPixFmt(int screennum);
     private static native boolean initCGL();
-    private static native long getCGLConfigInfo(int screennum, int visualnum,
+    private static native long getCGLConfigInfo(int displayID, int visualnum,
                                                 int swapInterval);
     private static native int getOGLCapabilities(long configInfo);
 
@@ -137,15 +135,16 @@
             // Java-level context and flush the queue...
             OGLContext.invalidateCurrentContext();
 
-            cfginfo = getCGLConfigInfo(device.getCoreGraphicsScreen(), pixfmt,
+            cfginfo = getCGLConfigInfo(device.getCGDisplayID(), pixfmt,
                                        kOpenGLSwapInterval);
-
-            OGLContext.setScratchSurface(cfginfo);
-            rq.flushAndInvokeNow(new Runnable() {
-                public void run() {
-                    ids[0] = OGLContext.getOGLIdString();
-                }
-            });
+            if (cfginfo != 0L) {
+                OGLContext.setScratchSurface(cfginfo);
+                rq.flushAndInvokeNow(new Runnable() {
+                    public void run() {
+                        ids[0] = OGLContext.getOGLIdString();
+                    }
+                });
+            }
         } finally {
             rq.unlock();
         }
@@ -253,8 +252,8 @@
 
     @Override
     public String toString() {
-        int screen = getDevice().getCoreGraphicsScreen();
-        return ("CGLGraphicsConfig[dev="+screen+",pixfmt="+pixfmt+"]");
+        int displayID = getDevice().getCGDisplayID();
+        return ("CGLGraphicsConfig[dev="+displayID+",pixfmt="+pixfmt+"]");
     }
 
     @Override
@@ -413,8 +412,8 @@
 
     @Override
     public void addDeviceEventListener(AccelDeviceEventListener l) {
-        int screen = getDevice().getCoreGraphicsScreen();
-        AccelDeviceEventNotifier.addListener(l, screen);
+        int displayID = getDevice().getCGDisplayID();
+        AccelDeviceEventNotifier.addListener(l, displayID);
     }
 
     @Override
--- a/src/macosx/classes/sun/lwawt/LWComponentPeer.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/LWComponentPeer.java	Mon Apr 08 15:57:12 2013 -0700
@@ -439,7 +439,7 @@
     }
 
     @Override
-    public final Graphics getGraphics() {
+    public Graphics getGraphics() {
         final Graphics g = getOnscreenGraphics();
         if (g != null) {
             synchronized (getPeerTreeLock()){
@@ -1227,10 +1227,10 @@
     }
 
     protected void sendEventToDelegate(final AWTEvent e) {
+        if (getDelegate() == null || !isShowing() || !isEnabled()) {
+            return;
+        }
         synchronized (getDelegateLock()) {
-            if (getDelegate() == null || !isShowing() || !isEnabled()) {
-                return;
-            }
             AWTEvent delegateEvent = createDelegateEvent(e);
             if (delegateEvent != null) {
                 AWTAccessor.getComponentAccessor()
@@ -1244,7 +1244,12 @@
         }
     }
 
-    protected AWTEvent createDelegateEvent(AWTEvent e) {
+    /**
+     * Changes the target of the AWTEvent from awt component to appropriate
+     * swing delegate.
+     */
+    private AWTEvent createDelegateEvent(final AWTEvent e) {
+        // TODO modifiers should be changed to getModifiers()|getModifiersEx()?
         AWTEvent delegateEvent = null;
         if (e instanceof MouseWheelEvent) {
             MouseWheelEvent me = (MouseWheelEvent) e;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/macosx/classes/sun/lwawt/LWLightweightFramePeer.java	Mon Apr 08 15:57:12 2013 -0700
@@ -0,0 +1,115 @@
+/*
+ * Copyright (c) 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package sun.lwawt;
+
+import java.awt.Graphics;
+import java.awt.Insets;
+import java.awt.Point;
+import java.awt.Rectangle;
+import java.awt.Window;
+import java.awt.dnd.DropTarget;
+
+import sun.awt.CausedFocusEvent;
+import sun.awt.LightweightFrame;
+
+public class LWLightweightFramePeer extends LWWindowPeer {
+
+    public LWLightweightFramePeer(LightweightFrame target,
+                                  PlatformComponent platformComponent,
+                                  PlatformWindow platformWindow)
+    {
+        super(target, platformComponent, platformWindow, LWWindowPeer.PeerType.LW_FRAME);
+    }
+
+    private LightweightFrame getLwTarget() {
+        return (LightweightFrame)getTarget();
+    }
+
+    @Override
+    public Graphics getGraphics() {
+        return getLwTarget().getGraphics();
+    }
+
+    @Override
+    protected void setVisibleImpl(final boolean visible) {
+    }
+
+    @Override
+    public boolean requestWindowFocus(CausedFocusEvent.Cause cause) {
+        if (!focusAllowedFor()) {
+            return false;
+        }
+        if (getPlatformWindow().rejectFocusRequest(cause)) {
+            return false;
+        }
+
+        Window opposite = LWKeyboardFocusManagerPeer.getInstance().
+            getCurrentFocusedWindow();
+
+        changeFocusedWindow(true, opposite);
+
+        return true;
+    }
+
+    @Override
+    public Point getLocationOnScreen() {
+        Rectangle bounds = getBounds();
+        return new Point(bounds.x, bounds.y); // todo
+    }
+
+    @Override
+    public Insets getInsets() {
+        return new Insets(0, 0, 0, 0);
+    }
+
+    @Override
+    public void setBounds(int x, int y, int w, int h, int op) {
+        setBounds(x, y, w, h, op, true, false);
+    }
+
+    @Override
+    public void updateCursorImmediately() {
+        // TODO: tries to switch to the awt/fx toolkit thread and causes a deadlock on macosx
+    }
+
+    @Override
+    public void addDropTarget(DropTarget dt) {
+    }
+
+    @Override
+    public void removeDropTarget(DropTarget dt) {
+    }
+
+    @Override
+    public void grab() {
+        getLwTarget().grabFocus();
+    }
+
+    @Override
+    public void ungrab() {
+        getLwTarget().ungrabFocus();
+    }
+}
--- a/src/macosx/classes/sun/lwawt/LWToolkit.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/LWToolkit.java	Mon Apr 08 15:57:12 2013 -0700
@@ -218,6 +218,23 @@
         return peer;
     }
 
+    private LWLightweightFramePeer createDelegatedLwPeer(LightweightFrame target,
+                                                         PlatformComponent platformComponent,
+                                                         PlatformWindow platformWindow)
+    {
+        LWLightweightFramePeer peer = new LWLightweightFramePeer(target, platformComponent, platformWindow);
+        targetCreatedPeer(target, peer);
+        peer.initialize();
+        return peer;
+    }
+
+    @Override
+    public FramePeer createLightweightFrame(LightweightFrame target) {
+        PlatformComponent platformComponent = createLwPlatformComponent();
+        PlatformWindow platformWindow = createPlatformWindow(LWWindowPeer.PeerType.LW_FRAME);
+        return createDelegatedLwPeer(target, platformComponent, platformWindow);
+    }
+
     @Override
     public WindowPeer createWindow(Window target) {
         PlatformComponent platformComponent = createPlatformComponent();
@@ -502,6 +519,8 @@
 
     protected abstract PlatformComponent createPlatformComponent();
 
+    protected abstract PlatformComponent createLwPlatformComponent();
+
     protected abstract FileDialogPeer createFileDialogPeer(FileDialog target);
 
     // ---- UTILITY METHODS ---- //
--- a/src/macosx/classes/sun/lwawt/LWWindowPeer.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/LWWindowPeer.java	Mon Apr 08 15:57:12 2013 -0700
@@ -48,7 +48,8 @@
         FRAME,
         DIALOG,
         EMBEDDED_FRAME,
-        VIEW_EMBEDDED_FRAME
+        VIEW_EMBEDDED_FRAME,
+        LW_FRAME
     }
 
     private static final PlatformLogger focusLog = PlatformLogger.getLogger("sun.lwawt.focus.LWWindowPeer");
@@ -1090,7 +1091,7 @@
         return platformWindow.requestWindowFocus();
     }
 
-    private boolean focusAllowedFor() {
+    protected boolean focusAllowedFor() {
         Window window = getTarget();
         // TODO: check if modal blocked
         return window.isVisible() && window.isEnabled() && isFocusableWindow();
@@ -1113,10 +1114,15 @@
         return !(window instanceof Dialog || window instanceof Frame);
     }
 
+    @Override
+    public void emulateActivation(boolean activate) {
+        changeFocusedWindow(activate, null);
+    }
+
     /*
      * Changes focused window on java level.
      */
-    private void changeFocusedWindow(boolean becomesFocused, Window opposite) {
+    protected void changeFocusedWindow(boolean becomesFocused, Window opposite) {
         if (focusLog.isLoggable(PlatformLogger.FINE)) {
             focusLog.fine((becomesFocused?"gaining":"loosing") + " focus window: " + this);
         }
--- a/src/macosx/classes/sun/lwawt/macosx/CDropTargetContextPeer.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CDropTargetContextPeer.java	Mon Apr 08 15:57:12 2013 -0700
@@ -128,6 +128,15 @@
         }
     }
 
+    @Override
+    protected int postDropTargetEvent(Component component, int x, int y, int dropAction,
+                                      int actions, long[] formats, long nativeCtxt, int eventID,
+                                      boolean dispatchType) {
+        // On MacOS X all the DnD events should be synchronous
+        return super.postDropTargetEvent(component, x, y, dropAction, actions, formats, nativeCtxt,
+                eventID, SunDropTargetContextPeer.DISPATCH_SYNC);
+    }
+
     // Signal drop complete:
     protected void doDropDone(boolean success, int dropAction, boolean isLocal) {
         long nativeDropTarget = this.getNativeDragContext();
--- a/src/macosx/classes/sun/lwawt/macosx/CPlatformComponent.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformComponent.java	Mon Apr 08 15:57:12 2013 -0700
@@ -35,7 +35,7 @@
  * On OSX {@code CPlatformComponent} stores pointer to the native CAlayer which
  * can be used from JAWT.
  */
-final class CPlatformComponent extends CFRetainedResource
+class CPlatformComponent extends CFRetainedResource
         implements PlatformComponent {
 
     private volatile PlatformWindow platformWindow;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformLWComponent.java	Mon Apr 08 15:57:12 2013 -0700
@@ -0,0 +1,53 @@
+/*
+ * Copyright (c) 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+
+package sun.lwawt.macosx;
+
+import sun.lwawt.PlatformWindow;
+
+class CPlatformLWComponent extends CPlatformComponent {
+
+    CPlatformLWComponent() {
+        super();
+    }
+
+    @Override
+    public long getPointer() {
+        return 0;
+    }
+
+    @Override
+    public void initialize(final PlatformWindow platformWindow) {
+    }
+
+    @Override
+    public void setBounds(final int x, final int y, final int w, final int h) {
+    }
+
+    @Override
+    public void dispose() {
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformLWView.java	Mon Apr 08 15:57:12 2013 -0700
@@ -0,0 +1,82 @@
+/*
+ * Copyright (c) 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package sun.lwawt.macosx;
+
+import sun.lwawt.LWWindowPeer;
+import sun.java2d.SurfaceData;
+
+public class CPlatformLWView extends CPlatformView {
+
+    public CPlatformLWView() {
+        super();
+    }
+
+    @Override
+    public void initialize(LWWindowPeer peer, CPlatformResponder responder) {
+        initializeBase(peer, responder);
+    }
+
+    @Override
+    public long getAWTView() {
+        return 0;
+    }
+
+    @Override
+    public boolean isOpaque() {
+        return true;
+    }
+
+    @Override
+    public void setBounds(int x, int y, int width, int height) {
+    }
+
+    @Override
+    public void enterFullScreenMode() {
+    }
+
+    @Override
+    public void exitFullScreenMode() {
+    }
+
+    @Override
+    public SurfaceData replaceSurfaceData() {
+        return null;
+    }
+
+    @Override
+    public SurfaceData getSurfaceData() {
+        return null;
+    }
+
+    @Override
+    public void dispose() {
+    }
+
+    @Override
+    public long getWindowLayerPtr() {
+        return 0;
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformLWWindow.java	Mon Apr 08 15:57:12 2013 -0700
@@ -0,0 +1,202 @@
+/*
+ * Copyright (c) 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
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.  Oracle designates this
+ * particular file as subject to the "Classpath" exception as provided
+ * by Oracle in the LICENSE file that accompanied this code.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+package sun.lwawt.macosx;
+
+import java.awt.Font;
+import java.awt.FontMetrics;
+import java.awt.Graphics;
+import java.awt.GraphicsDevice;
+import java.awt.Insets;
+import java.awt.MenuBar;
+import java.awt.Point;
+import java.awt.Window;
+import sun.awt.CausedFocusEvent;
+import sun.java2d.SurfaceData;
+import sun.lwawt.LWWindowPeer;
+import sun.lwawt.PlatformWindow;
+
+public class CPlatformLWWindow extends CPlatformWindow {
+
+    @Override
+    public void initialize(Window target, LWWindowPeer peer, PlatformWindow owner) {
+        initializeBase(target, peer, owner, new CPlatformLWView());
+    }
+
+    @Override
+    public void toggleFullScreen() {
+    }
+
+    @Override
+    public void setMenuBar(MenuBar mb) {
+    }
+
+    @Override
+    public void dispose() {
+    }
+
+    @Override
+    public FontMetrics getFontMetrics(Font f) {
+        return null;
+    }
+
+    @Override
+    public Insets getInsets() {
+        return new Insets(0, 0, 0, 0);
+    }
+
+    @Override
+    public Point getLocationOnScreen() {
+        return null;
+    }
+
+    @Override
+    public GraphicsDevice getGraphicsDevice() {
+        return null;
+    }
+
+    @Override
+    public SurfaceData getScreenSurface() {
+        return null;
+    }
+
+    @Override
+    public SurfaceData replaceSurfaceData() {
+        return null;
+    }
+
+    @Override
+    public void setBounds(int x, int y, int w, int h) {
+        if (getPeer() != null) {
+            getPeer().notifyReshape(x, y, w, h);
+        }
+    }
+
+    @Override
+    public void setVisible(boolean visible) {
+    }
+
+    @Override
+    public void setTitle(String title) {
+    }
+
+    @Override
+    public void updateIconImages() {
+    }
+
+    @Override
+    public long getNSWindowPtr() {
+        return 0;
+    }
+
+    @Override
+    public SurfaceData getSurfaceData() {
+        return null;
+    }
+
+    @Override
+    public void toBack() {
+    }
+
+    @Override
+    public void toFront() {
+    }
+
+    @Override
+    public void setResizable(final boolean resizable) {
+    }
+
+    @Override
+    public void setSizeConstraints(int minW, int minH, int maxW, int maxH) {
+    }
+
+    @Override
+    public boolean rejectFocusRequest(CausedFocusEvent.Cause cause) {
+        return false;
+    }
+
+    @Override
+    public boolean requestWindowFocus() {
+        return true;
+    }
+
+    @Override
+    public boolean isActive() {
+        return true;
+    }
+
+    @Override
+    public void updateFocusableWindowState() {
+    }
+
+    @Override
+    public Graphics transformGraphics(Graphics g) {
+        return null;
+    }
+
+    @Override
+    public void setAlwaysOnTop(boolean isAlwaysOnTop) {
+    }
+
+    @Override
+    public PlatformWindow getTopmostPlatformWindowUnderMouse(){
+        return null;
+    }
+
+    @Override
+    public void setOpacity(float opacity) {
+    }
+
+    @Override
+    public void setOpaque(boolean isOpaque) {
+    }
+
+    @Override
+    public void enterFullScreenMode() {
+    }
+
+    @Override
+    public void exitFullScreenMode() {
+    }
+
+    @Override
+    public void setWindowState(int windowState) {
+    }
+
+    @Override
+    public LWWindowPeer getPeer() {
+        return super.getPeer();
+    }
+
+    @Override
+    public CPlatformView getContentView() {
+        return super.getContentView();
+    }
+
+    @Override
+    public long getLayerPtr() {
+        return 0;
+    }
+}
--- a/src/macosx/classes/sun/lwawt/macosx/CPlatformView.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformView.java	Mon Apr 08 15:57:12 2013 -0700
@@ -54,8 +54,7 @@
     }
 
     public void initialize(LWWindowPeer peer, CPlatformResponder responder) {
-        this.peer = peer;
-        this.responder = responder;
+        initializeBase(peer, responder);
 
         if (!LWCToolkit.getSunAwtDisableCALayers()) {
             this.windowLayer = new CGLLayer(peer);
@@ -63,6 +62,11 @@
         setPtr(nativeCreateView(0, 0, 0, 0, getWindowLayerPtr()));
     }
 
+    protected void initializeBase(LWWindowPeer peer, CPlatformResponder responder) {
+        this.peer = peer;
+        this.responder = responder;
+    }
+
     public long getAWTView() {
         return ptr;
         }
--- a/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CPlatformWindow.java	Mon Apr 08 15:57:12 2013 -0700
@@ -30,6 +30,7 @@
 import java.awt.event.*;
 import java.awt.peer.WindowPeer;
 import java.beans.*;
+import java.lang.reflect.InvocationTargetException;
 import java.util.List;
 
 import javax.swing.*;
@@ -44,7 +45,7 @@
 import com.apple.laf.ClientPropertyApplicator.Property;
 import com.sun.awt.AWTUtilities;
 
-public final class CPlatformWindow extends CFRetainedResource implements PlatformWindow {
+public class CPlatformWindow extends CFRetainedResource implements PlatformWindow {
     private native long nativeCreateNSWindow(long nsViewPtr, long styleBits, double x, double y, double w, double h);
     private static native void nativeSetNSWindowStyleBits(long nsWindowPtr, int mask, int data);
     private static native void nativeSetNSWindowMenuBar(long nsWindowPtr, long menuBarPtr);
@@ -218,11 +219,7 @@
      */
     @Override // PlatformWindow
     public void initialize(Window _target, LWWindowPeer _peer, PlatformWindow _owner) {
-        this.peer = _peer;
-        this.target = _target;
-        if (_owner instanceof CPlatformWindow) {
-            this.owner = (CPlatformWindow)_owner;
-        }
+        initializeBase(_target, _peer, _owner, new CPlatformView());
 
         final int styleBits = getInitialStyleBits();
 
@@ -231,7 +228,6 @@
         String warningString = target.getWarningString();
 
         responder = new CPlatformResponder(peer, false);
-        contentView = new CPlatformView();
         contentView.initialize(peer, responder);
 
         final long nativeWindowPtr = nativeCreateNSWindow(contentView.getAWTView(), styleBits, 0, 0, 0, 0);
@@ -253,6 +249,15 @@
         validateSurface();
     }
 
+    protected void initializeBase(Window target, LWWindowPeer peer, PlatformWindow owner, CPlatformView view) {
+        this.peer = peer;
+        this.target = target;
+        if (owner instanceof CPlatformWindow) {
+            this.owner = (CPlatformWindow)owner;
+        }
+        this.contentView = view;
+    }
+
     private int getInitialStyleBits() {
         // defaults style bits
         int styleBits = DECORATED | HAS_SHADOW | CLOSEABLE | MINIMIZABLE | ZOOMABLE | RESIZABLE;
@@ -857,7 +862,16 @@
 
     private void flushBuffers() {
         if (isVisible() && !nativeBounds.isEmpty()) {
-            LWCToolkit.getLWCToolkit().flushPendingEventsOnAppkit(target);
+            try {
+                LWCToolkit.invokeAndWait(new Runnable() {
+                    @Override
+                    public void run() {
+                        //Posting an empty to flush the EventQueue without blocking the main thread
+                    }
+                }, target);
+            } catch (InterruptedException | InvocationTargetException e) {
+                e.printStackTrace();
+            }
         }
     }
 
--- a/src/macosx/classes/sun/lwawt/macosx/CRobot.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CRobot.java	Mon Apr 08 15:57:12 2013 -0700
@@ -65,7 +65,7 @@
         mouseLastX = x;
         mouseLastY = y;
 
-        mouseEvent(fDevice.getCoreGraphicsScreen(), mouseLastX, mouseLastY,
+        mouseEvent(fDevice.getCGDisplayID(), mouseLastX, mouseLastY,
                    mouseButtonsState, true, true);
     }
 
@@ -79,7 +79,7 @@
     public void mousePress(int buttons) {
         mouseButtonsState |= buttons;
 
-        mouseEvent(fDevice.getCoreGraphicsScreen(), mouseLastX, mouseLastY,
+        mouseEvent(fDevice.getCGDisplayID(), mouseLastX, mouseLastY,
                    buttons, true, false);
     }
 
@@ -93,7 +93,7 @@
     public void mouseRelease(int buttons) {
         mouseButtonsState &= ~buttons;
 
-        mouseEvent(fDevice.getCoreGraphicsScreen(), mouseLastX, mouseLastY,
+        mouseEvent(fDevice.getCGDisplayID(), mouseLastX, mouseLastY,
                    buttons, false, false);
     }
 
@@ -163,7 +163,7 @@
     }
 
     private native void initRobot();
-    private native void mouseEvent(int screen, int lastX, int lastY,
+    private native void mouseEvent(int displayID, int lastX, int lastY,
                                    int buttonsState,
                                    boolean isButtonsDownState,
                                    boolean isMouseMove);
--- a/src/macosx/classes/sun/lwawt/macosx/CToolkitThreadBlockedHandler.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/CToolkitThreadBlockedHandler.java	Mon Apr 08 15:57:12 2013 -0700
@@ -25,27 +25,33 @@
 
 package sun.lwawt.macosx;
 
+import sun.awt.Mutex;
 import sun.awt.datatransfer.ToolkitThreadBlockedHandler;
 
-final class CToolkitThreadBlockedHandler implements ToolkitThreadBlockedHandler {
-    private final LWCToolkit toolkit = (LWCToolkit)java.awt.Toolkit.getDefaultToolkit();
+final class CToolkitThreadBlockedHandler extends Mutex implements ToolkitThreadBlockedHandler {
+    private long awtRunLoopMediator = 0;
+    private final boolean processEvents;
 
-    public void lock() {
-    }
-
-    public void unlock() {
-    }
-
-    protected boolean isOwned() {
-       return false;
+    CToolkitThreadBlockedHandler() {
+        super();
+        this.processEvents = true;
     }
 
     public void enter() {
-        // Execute the next AppKit event while we are waiting for system to
-        // finish our request - this will save us from biting our own tail
-        toolkit.executeNextAppKitEvent();
+        if (!isOwned()) {
+            throw new IllegalMonitorStateException();
+        }
+        awtRunLoopMediator = LWCToolkit.createAWTRunLoopMediator();
+        unlock();
+        LWCToolkit.doAWTRunLoop(awtRunLoopMediator, processEvents);
+        lock();
     }
 
     public void exit() {
+        if (!isOwned()) {
+            throw new IllegalMonitorStateException();
+        }
+        LWCToolkit.stopAWTRunLoop(awtRunLoopMediator);
+        awtRunLoopMediator = 0;
     }
 }
--- a/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Mon Apr 08 15:57:12 2013 -0700
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 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
@@ -63,8 +63,6 @@
 
     private static native void initIDs();
 
-    static native void executeNextAppKitEvent();
-
     private static CInputMethodDescriptor sInputMethodDescriptor;
 
     static {
@@ -160,6 +158,8 @@
             return new CPlatformEmbeddedFrame();
         } else if (peerType == PeerType.VIEW_EMBEDDED_FRAME) {
             return new CViewPlatformEmbeddedFrame();
+        } else if (peerType == PeerType.LW_FRAME) {
+            return new CPlatformLWWindow();
         } else {
             assert (peerType == PeerType.SIMPLEWINDOW || peerType == PeerType.DIALOG || peerType == PeerType.FRAME);
             return new CPlatformWindow();
@@ -172,6 +172,11 @@
     }
 
     @Override
+    protected PlatformComponent createLwPlatformComponent() {
+        return new CPlatformLWComponent();
+    }
+
+    @Override
     protected FileDialogPeer createFileDialogPeer(FileDialog target) {
         return new CFileDialog(target);
     }
@@ -346,22 +351,7 @@
 
     @Override
     public Insets getScreenInsets(final GraphicsConfiguration gc) {
-        final CGraphicsConfig cgc = (CGraphicsConfig) gc;
-        final int displayId = cgc.getDevice().getCoreGraphicsScreen();
-        Rectangle fullScreen, workArea;
-        final long screen = CWrapper.NSScreen.screenByDisplayId(displayId);
-        try {
-            fullScreen = CWrapper.NSScreen.frame(screen).getBounds();
-            workArea = CWrapper.NSScreen.visibleFrame(screen).getBounds();
-        } finally {
-            CWrapper.NSObject.release(screen);
-        }
-        // Convert between Cocoa's coordinate system and Java.
-        int bottom = workArea.y - fullScreen.y;
-        int top = fullScreen.height - workArea.height - bottom;
-        int left = workArea.x - fullScreen.x;
-        int right = fullScreen.width - workArea.width - left;
-        return  new Insets(top, left, bottom, right);
+        return ((CGraphicsConfig) gc).getDevice().getScreenInsets();
     }
 
     @Override
@@ -495,30 +485,6 @@
         synchronized(ret) { return ret[0]; }
     }
 
-    /**
-     * Just a wrapper for LWCToolkit.invokeAndWait. Posts an empty event to the
-     * appropriate event queue and waits for it to finish.
-     */
-    public static void flushPendingEventsOnAppkit(final Component component) {
-        try {
-            invokeAndWait(new Runnable() {
-                @Override
-                public void run() {
-                }
-            }, component);
-        } catch (Exception e) {
-            e.printStackTrace();
-        }
-    }
-
-    // Kicks an event over to the appropriate eventqueue and waits for it to finish
-    // To avoid deadlocking, we manually run the NSRunLoop while waiting
-    // Any selector invoked using ThreadUtilities performOnMainThread will be processed in doAWTRunLoop
-    // The CInvocationEvent will call LWCToolkit.stopAWTRunLoop() when finished, which will stop our manual runloop
-    public static void invokeAndWait(Runnable event, Component component) throws InterruptedException, InvocationTargetException {
-        invokeAndWait(event, component, true);
-    }
-
     public static <T> T invokeAndWait(final Callable<T> callable, Component component) throws Exception {
         final CallableWrapper<T> wrapper = new CallableWrapper<T>(callable);
         invokeAndWait(wrapper, component);
@@ -548,10 +514,27 @@
         }
     }
 
-    public static void invokeAndWait(Runnable event, Component component, boolean detectDeadlocks) throws InterruptedException, InvocationTargetException {
-        long mediator = createAWTRunLoopMediator();
+    // Kicks an event over to the appropriate eventqueue and waits for it to finish
+    // To avoid deadlocking, we manually run the NSRunLoop while waiting
+    // Any selector invoked using ThreadUtilities performOnMainThread will be processed in doAWTRunLoop
+    // The InvocationEvent will call LWCToolkit.stopAWTRunLoop() when finished, which will stop our manual runloop
+    // Does not dispatch native events while in the loop
+    public static void invokeAndWait(Runnable event, Component component) throws InterruptedException, InvocationTargetException {
+        final long mediator = createAWTRunLoopMediator();
 
-        InvocationEvent invocationEvent = new CPeerEvent(event, mediator);
+        InvocationEvent invocationEvent =
+                new InvocationEvent(component != null ? component : Toolkit.getDefaultToolkit(), event) {
+                    @Override
+                    public void dispatch() {
+                        try {
+                            super.dispatch();
+                        } finally {
+                            if (mediator != 0) {
+                                stopAWTRunLoop(mediator);
+                            }
+                        }
+                    }
+                };
 
         if (component != null) {
             AppContext appContext = SunToolkit.targetToAppContext(component);
@@ -564,7 +547,7 @@
             ((LWCToolkit)Toolkit.getDefaultToolkit()).getSystemEventQueueForInvokeAndWait().postEvent(invocationEvent);
         }
 
-        doAWTRunLoop(mediator, true, detectDeadlocks);
+        doAWTRunLoop(mediator, false);
 
         Throwable eventException = invocationEvent.getException();
         if (eventException != null) {
@@ -576,7 +559,8 @@
     }
 
     public static void invokeLater(Runnable event, Component component) throws InvocationTargetException {
-        final InvocationEvent invocationEvent = new CPeerEvent(event, 0);
+        final InvocationEvent invocationEvent =
+                new InvocationEvent(component != null ? component : Toolkit.getDefaultToolkit(), event);
 
         if (component != null) {
             final AppContext appContext = SunToolkit.targetToAppContext(component);
@@ -681,31 +665,6 @@
         return false;
     }
 
-    // Extends PeerEvent because we want to pass long an ObjC mediator object and because we want these events to be posted early
-    // Typically, rather than relying on the notifier to call notifyAll(), we use the mediator to stop the runloop
-    public static class CPeerEvent extends PeerEvent {
-        private long _mediator = 0;
-
-        public CPeerEvent(Runnable runnable, long mediator) {
-            super(Toolkit.getDefaultToolkit(), runnable, null, true, 0);
-            _mediator = mediator;
-        }
-
-        public void dispatch() {
-            try {
-                super.dispatch();
-            } finally {
-                if (_mediator != 0) {
-                    LWCToolkit.stopAWTRunLoop(_mediator);
-                }
-            }
-        }
-    }
-
-    // Call through to native methods
-    public static void doAWTRunLoop(long mediator, boolean awtMode) { doAWTRunLoop(mediator, awtMode, true); }
-    public static void doAWTRunLoop(long mediator) { doAWTRunLoop(mediator, true); }
-
     private static Boolean sunAwtDisableCALayers = null;
 
     /**
@@ -730,12 +689,20 @@
      * Native methods section
      ************************/
 
-    // These are public because they are accessed from WebKitPluginObject in JavaDeploy
-    // Basic usage:
-    // createAWTRunLoopMediator. Start client code on another thread. doAWTRunLoop. When client code is finished, stopAWTRunLoop.
-    public static native long createAWTRunLoopMediator();
-    public static native void doAWTRunLoop(long mediator, boolean awtMode, boolean detectDeadlocks);
-    public static native void stopAWTRunLoop(long mediator);
+    static native long createAWTRunLoopMediator();
+    /**
+     * Method to run a nested run-loop. The nested loop is spinned in the javaRunLoop mode, so selectors sent
+     * by [JNFRunLoop performOnMainThreadWaiting] are processed.
+     * @param mediator a native pointer to the mediator object created by createAWTRunLoopMediator
+     * @param processEvents if true - dispatches event while in the nested loop. Used in DnD.
+     *                      Additional attention is needed when using this feature as we short-circuit normal event
+     *                      processing which could break Appkit.
+     *                      (One known example is when the window is resized with the mouse)
+     *
+     *                      if false - all events come after exit form the nested loop
+     */
+    static native void doAWTRunLoop(long mediator, boolean processEvents);
+    static native void stopAWTRunLoop(long mediator);
 
     private native boolean nativeSyncQueue(long timeout);
 
--- a/src/macosx/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java	Thu Apr 04 11:33:40 2013 -0700
+++ b/src/macosx/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java	Mon Apr 08 15:57:12 2013 -0700
@@ -32,11 +32,13 @@
 import java.text.spi.DecimalFormatSymbolsProvider;
 import java.text.spi.NumberFormatProvider;
 import java.util.Collections;
+import java.util.Calendar;
 import java.util.HashSet;
 import java.util.Locale;
 import java.util.Map;
 import java.util.ResourceBundle.Control;
 import java.util.Set;
+import java.util.TimeZone;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ConcurrentMap;
 import java.util.concurrent.atomic.AtomicReferenceArray;
@@ -45,6 +47,7 @@
 import java.util.spi.CurrencyNameProvider;
 import java.util.spi.LocaleNameProvider;
 import java.util.spi.TimeZoneNameProvider;
+import sun.util.spi.CalendarProvider;
 
 /**
  * LocaleProviderAdapter implementation for the Mac OS X locale data
@@ -94,17 +97,56 @@
 
     private static final Set<Locale> supportedLocaleSet;
     static {
-        Set<Locale> tmpSet = new HashSet<Locale>();
+        Set<Locale> tmpSet = new HashSet<>();
         // Assuming the default locales do not include any extensions, so
         // no stripping is needed here.
-        Locale l = Locale.forLanguageTag(getDefaultLocale(CAT_FORMAT).replaceAll("_","-"));
+        Locale l = convertMacOSXLocaleToJavaLocale(getDefaultLocale(CAT_FORMAT));
         tmpSet.addAll(Control.getNoFallbackControl(Control.FORMAT_DEFAULT).getCandidateLocales("", l));
-        l = Locale.forLanguageTag(getDefaultLocale(CAT_DISPLAY).replaceAll("_","-"));
+        l = convertMacOSXLocaleToJavaLocale(getDefaultLocale(CAT_DISPLAY));
         tmpSet.addAll(Control.getNoFallbackControl(Control.FORMAT_DEFAULT).getCandidateLocales("", l));
         supportedLocaleSet = Collections.unmodifiableSet(tmpSet);
     }
     private final static Locale[] supportedLocale = supportedLocaleSet.toArray(new Locale[0]);
 
+    @SuppressWarnings("fallthrough")
+    private static Locale convertMacOSXLocaleToJavaLocale(String macosxloc) {
+        // MacOSX may return ICU notation, here is the quote from CFLocale doc:
+        // "The corresponding value is a CFString containing the POSIX locale
+        // identifier as used by ICU, such as "ja_JP". If you have a variant
+        // locale or a different currency or calendar, it can be as complex as
+        // "en_US_POSIX@calendar=japanese;currency=EUR" or
+        // "az_Cyrl_AZ@calendar=buddhist;currency=JPY".
+        String[] tmp = macosxloc.split("@");
+        String langTag = tmp[0].replace('_', '-');
+        if (tmp.length > 1) {
+            String[] ext = tmp[1].split(";");
+            for (String keyval : ext) {
+                // We are only interested in "calendar" value for now.
+                if (keyval.startsWith("calendar=")) {
+                    String calid = keyval.substring(keyval.indexOf('=')+1);
+                    switch (calid) {
+                        case "gregorian":
+                            langTag += "-u-ca-gregory";
+                            break;
+                        case "japanese":
+                            // Tweak for ja_JP_JP
+                            if (tmp[0].equals("ja_JP")) {
+                                return JRELocaleConstants.JA_JP_JP;
+                            }
+
+                            // fall through
+
+                        default:
+                            langTag += "-u-ca-" + calid;
+                            break;
+                    }
+                }
+            }
+        }
+
+        return Locale.forLanguageTag(langTag);
+    }
+
     public static DateFormatProvider getDateFormatProvider() {
         return new DateFormatProvider() {
 
@@ -170,9 +212,8 @@
                 if (isSupportedLocale(Locale.getDefault(Locale.Category.FORMAT))) {
                     return supportedLocale;
                 }
-
-                        return new Locale[0];
-                    }
+                return new Locale[0];
+            }
 
             @Override
             public boolean isSupportedLocale(Locale locale) {
@@ -362,6 +403,30 @@
         };
     }
 
+    public static CalendarProvider getCalendarProvider() {
+        return new CalendarProvider() {
+            @Override
+            public Locale[] getAvailableLocales() {
+                return getSupportedCalendarLocales();
+            }
+
+            @Override
+            public boolean isSupportedLocale(Locale locale) {
+                return isSupportedCalendarLocale(locale);
+            }
+
+            @Override
+            public Calendar getInstance(TimeZone zone, Locale locale) {
+                return new Calendar.Builder()
+                             .setLocale(locale)
+                             .setCalendarType(getCalendarID(locale.toLanguageTag()))
+                             .setTimeZone(zone)
+                             .setInstant(System.currentTimeMillis())
+                             .build();
+            }
+        };
+    }
+
     public static CurrencyNameProvider getCurrencyNameProvider() {
         return new CurrencyNameProvider() {
             @Override
@@ -455,23 +520,20 @@
     }
 
     private static boolean isSupportedCalendarLocale(Locale locale) {
-        // special case for ja_JP_JP
-        if (JRELocaleConstants.JA_JP_JP.equals(locale)) {
-            return isJapaneseCalendar();
-        }
-
         Locale base = locale.stripExtensions();
         if (!supportedLocaleSet.contains(base)) {
             return false;
         }
 
-        String caltype = locale.getUnicodeLocaleType("ca");
-        if (caltype == null) {
-            return true;
+        String requestedCalType = locale.getUnicodeLocaleType("ca");
+        String nativeCalType =
+            getCalendarID(locale.toLanguageTag()).replaceFirst("gregorian", "gregory");
+
+        if (requestedCalType == null) {
+            return Calendar.getAvailableCalendarTypes().contains(nativeCalType);
+        } else {
+            return requestedCalType.equals(nativeCalType);
         }
-
-        return caltype.replaceFirst("gregory", "gregorian").equals(
-                getCalendarID(locale.toLanguageTag()));