changeset 4938:30225dea7a97

Merge
author lana
date Thu, 02 Feb 2012 13:39:04 -0800
parents 6485e842d7f7 d56728a282c6
children d568e85567cc
files .hgtags src/solaris/bin/java_md.c
diffstat 1076 files changed, 161879 insertions(+), 3142 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Fri Jan 27 16:48:41 2012 -0800
+++ b/.hgtags	Thu Feb 02 13:39:04 2012 -0800
@@ -141,10 +141,13 @@
 79c8c4608f60e1f981b17ba4077dfcaa2ed67be4 jdk7u2-b12
 fb2980d7c9439e3d62ab12f40506a2a2db2df0f4 jdk7u2-b13
 24e42f1f9029f9f5a9b1481d523facaf09452e5b jdk7u2-b21
+c0b98811b1fce5f479d487fe69db742874b22129 jdk7u4-b200
 6f7af0f0e7db448bb6c21a08b3aadc461d9e2456 jdk7u4-b04
 b97711a217859410d2724b8fdc90ef5937faa11b jdk7u4-b02
 9621edd8118f1a3e9691f4afc022d05cd5a64ef3 jdk7u4-b05
 2c1b789d18036febd45ef0ce29eb7c6ac34f2fd1 jdk7u4-b06
+ac2948107df1dcce6c026749dd14e4eb36a39091 jdk7u4-b225
 d34bb20fc52e6373f4547c05b938bdc31d974fdf jdk7u4-b07
 bcceb5734a34b37a28cf81fc2408dc47a97a9454 jdk7u4-b08
+2e4258236920ffd9b30799d817fadf88254e16b6 jdk7u4-b227
 0e394800a961634c95f208f11c0282a1515181c9 jdk7u4-b09
--- a/make/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -233,6 +233,9 @@
 all build:: sanity-all post-sanity-all
 
 SUBDIRS       = tools java javax sun com
+ifeq ($(PLATFORM), macosx)
+  SUBDIRS += apple
+endif
 SUBDIRS_tools = launchers
 SUBDIRS_misc  = org sunw jpda mkdemo mksample
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/apple/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,39 @@
+#
+# Copyright (c) 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.
+#
+
+#
+# Makefile for building com/apple
+#
+
+BUILDDIR = ..
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+SUBDIRS = applescript
+
+include $(BUILDDIR)/common/Subdirs.gmk
+
+all build clean clobber::
+	$(SUBDIRS-loop)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/apple/applescript/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,71 @@
+#
+# Copyright (c) 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 = apple.applescript
+LIBRARY = AppleScriptEngine
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+
+#
+# Files
+#
+AUTO_FILES_JAVA_DIRS = apple/applescript
+
+FILES_objc = \
+        $(TARGDIR)AppleScriptEngine.m \
+        $(TARGDIR)AppleScriptExecutionContext.m \
+        $(TARGDIR)AS_NS_ConversionUtils.m \
+        $(TARGDIR)NS_Java_ConversionUtils.m
+
+
+FILES_export = \
+	apple/applescript/AppleScriptEngine.java \
+	apple/applescript/AppleScriptEngineFactory.java
+
+#
+# Rules
+#
+include $(BUILDDIR)/common/Mapfile-vers.gmk
+include $(BUILDDIR)/common/Library.gmk
+
+
+#
+# Extra rules
+#
+
+#
+# Add to ambient vpath to get files in a subdirectory
+#
+vpath %.m   $(call NativeSrcDirList,,native/apple/applescript)
+
+CPPFLAGS += \
+	-I$(TEMPDIR)/../../sun.awt/awt/CClassHeaders
+
+OTHER_LDLIBS = \
+    -framework Cocoa \
+    -framework Carbon \
+    -framework JavaNativeFoundation
--- a/make/com/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -32,6 +32,11 @@
 include $(BUILDDIR)/common/Defs.gmk
 
 SUBDIRS = sun oracle
+
+ifeq ($(PLATFORM), macosx)
+    SUBDIRS += apple
+endif
+
 include $(BUILDDIR)/common/Subdirs.gmk
 
 all build clean clobber::
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/com/apple/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,40 @@
+#
+# Copyright (c) 1997, 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.
+#
+
+#
+# Makefile for building com/apple
+#
+
+BUILDDIR = ../..
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+# MMM: disable for now, depends on Max AWT (undisabled)
+SUBDIRS = osx osxui
+
+include $(BUILDDIR)/common/Subdirs.gmk
+
+all build clean clobber::
+	$(SUBDIRS-loop)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/com/apple/osx/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,91 @@
+#
+# Copyright (c) 1997, 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.apple.osx
+LIBRARY = osx
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+
+#
+# Files
+#
+AUTO_FILES_JAVA_DIRS = apple/launcher apple/security com/apple/concurrent com/apple/eio java/util/prefs
+
+FILES_objc += \
+    $(TARGDIR)Dispatch.m \
+    $(TARGDIR)CFileManager.m \
+    $(TARGDIR)KeystoreImpl.m \
+    $(TARGDIR)JavaAppLauncher.m \
+    $(TARGDIR)MacOSXPreferencesFile.m \
+    $(TARGDIR)SCDynamicStoreConfig.m
+
+FILES_export += \
+	com/apple/concurrent/LibDispatchNative.java \
+	com/apple/eio/FileManager.java \
+	apple/security/KeychainStore.java \
+	apple/launcher/JavaAppLauncher.java \
+	java/util/prefs/MacOSXPreferencesFile.java
+
+# TODO: couldn't figure out how to get resources working
+#LOCALE_SET_DEFINITION = jre
+#RESOURCE_BUNDLES_UNCOMPILED_PROPERTIES = apple/launcher/appLauncherErrors.properties
+
+
+#
+# Rules
+#
+include $(BUILDDIR)/common/Mapfile-vers.gmk
+include $(BUILDDIR)/common/Library.gmk
+
+
+#
+# Extra rules
+#
+
+#
+# Add to ambient vpath to get files in a subdirectory
+#
+vpath %.m   $(call NativeSrcDirList,,native/com/apple/concurrent)
+vpath %.m   $(call NativeSrcDirList,,native/com/apple/eio)
+vpath %.m   $(call NativeSrcDirList,,native/apple/launcher)
+vpath %.m   $(call NativeSrcDirList,,native/apple/security)
+vpath %.m   $(call NativeSrcDirList,,native/java/util)
+
+CPPFLAGS += \
+	$(call NativeSrcDirList,-I,native/com/apple/laf) \
+	$(call NativeSrcDirList,-I,native/apple/awt) \
+	$(call NativeSrcDirList,-I,native/sun/awt) \
+	$(call NativeSrcDirList,-I,native/sun/osxapp)
+
+OTHER_LDLIBS = \
+    -losxapp \
+    -framework Cocoa \
+    -framework ApplicationServices \
+    -framework JavaNativeFoundation \
+    -framework JavaRuntimeSupport \
+    -framework Security \
+    -framework SystemConfiguration
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/com/apple/osxui/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,106 @@
+#
+# Copyright (c) 1997, 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.apple.osxui
+LIBRARY = osxui
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+
+#
+# Files
+#
+AUTO_FILES_JAVA_DIRS = apple/laf com/apple/laf com/apple/eawt
+
+FILES_objc = \
+        $(TARGDIR)AquaFileView.m \
+        $(TARGDIR)AquaLookAndFeel.m \
+        $(TARGDIR)AquaNativeResources.m \
+        $(TARGDIR)JRSUIConstantSync.m \
+        $(TARGDIR)JRSUIController.m \
+        $(TARGDIR)JRSUIFocus.m \
+        $(TARGDIR)ScreenPopupFactory.m \
+        $(TARGDIR)ScreenMenu.m
+
+FILES_export = \
+	apple/laf/AquaLookAndFeel.java \
+	apple/laf/JRSUIConstants.java \
+	apple/laf/JRSUIControl.java \
+	apple/laf/JRSUIFocus.java \
+	apple/laf/JRSUIState.java \
+	apple/laf/JRSUIStateFactory.java \
+	apple/laf/JRSUIUtils.java \
+	com/apple/laf/AquaFileView.java \
+	com/apple/laf/AquaNativeResources.java \
+	com/apple/laf/ScreenPopupFactory.java \
+	com/apple/laf/ScreenMenu.java \
+	com/apple/laf/ScreenMenuBar.java \
+	com/apple/laf/ScreenMenuBarProvider.java \
+	com/apple/laf/ScreenMenuItem.java \
+	com/apple/laf/ScreenMenuItemCheckbox.java \
+	com/apple/laf/ScreenMenuItemUI.java \
+	com/apple/laf/ScreenMenuPropertyHandler.java \
+	com/apple/laf/ScreenMenuPropertyListener.java
+
+#RESOURCE_BUNDLES_COMPILED_PROPERTIES += \
+#	com/apple/laf/resources/aqua.properties \
+#	com/apple/laf/resources/aqua_de.properties \
+#	com/apple/laf/resources/aqua_fr.properties \
+#	com/apple/laf/resources/aqua_ja.properties
+
+
+#
+# Rules
+#
+include $(BUILDDIR)/common/Mapfile-vers.gmk
+include $(BUILDDIR)/common/Library.gmk
+
+
+#
+# Extra rules
+#
+
+#
+# Add to ambient vpath to get files in a subdirectory
+#
+vpath %.m   $(call NativeSrcDirList,,native/com/apple/laf)
+vpath %.m $(call NativeSrcDirList,,native/com/apple/eawt)
+
+CPPFLAGS += \
+	$(call NativeSrcDirList,-I,native/com/apple/laf) \
+	$(call NativeSrcDirList,-I,native/apple/awt) \
+	$(call NativeSrcDirList,-I,native/sun/awt) \
+	$(call NativeSrcDirList,-I,native/sun/osxapp) \
+	-I$(TEMPDIR)/../../sun.awt/awt/CClassHeaders
+
+OTHER_LDLIBS = \
+    -lawt -losxapp \
+    -llwawt -L$(LIBDIR)/lwawt -Xlinker -rpath -Xlinker @loader_path/lwawt \
+    -framework Cocoa \
+    -framework Carbon \
+    -framework ApplicationServices \
+    -framework JavaNativeFoundation \
+    -framework JavaRuntimeSupport
--- a/make/com/sun/java/pack/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/java/pack/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -57,6 +57,7 @@
 vpath %.cpp $(SHARE_SRC)/native/$(PKGDIR)
 
 ifeq ($(STANDALONE),true)
+ ifneq ($(SYSTEM_ZLIB),true)
   ZIPOBJDIR = $(OUTPUTDIR)/tmp/sun/java.util.zip/zip/$(OBJDIRNAME)
 
   ZIPOBJS =  $(ZIPOBJDIR)/zcrc32.$(OBJECT_SUFFIX) \
@@ -73,6 +74,10 @@
   ZINCLUDE=-I$(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
   OTHER_CXXFLAGS += $(ZINCLUDE)
   LDDFLAGS += $(ZIPOBJS)
+ else
+  LDDFLAGS += -lz
+  OTHER_CXXFLAGS += -DSYSTEM_ZLIB
+ endif
 else
   OTHER_CXXFLAGS += -DNO_ZLIB -DUNPACK_JNI
   OTHER_LDLIBS += $(JVMLIB)
--- a/make/com/sun/nio/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/nio/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -30,8 +30,12 @@
 BUILDDIR = ../../..
 include $(BUILDDIR)/common/Defs.gmk
 
+# MMM: disable for now
+ifneq ($(PLATFORM), macosx)
+include $(BUILDDIR)/common/Subdirs.gmk
 SUBDIRS = sctp
-include $(BUILDDIR)/common/Subdirs.gmk
+endif
+
 
 all build clean clobber::
 	$(SUBDIRS-loop)
--- a/make/com/sun/security/auth/module/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/security/auth/module/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -67,7 +67,7 @@
   include FILES_c_solaris.gmk
 endif # solaris
 
-ifeq ($(PLATFORM), linux)
+ifneq (,$(findstring $(PLATFORM), linux macosx))
   LIBRARY = jaas_unix
   include FILES_export_unix.gmk
   include FILES_c_unix.gmk
--- a/make/com/sun/tools/attach/Exportedfiles.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/tools/attach/Exportedfiles.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -43,5 +43,7 @@
 	sun/tools/attach/LinuxVirtualMachine.java
 endif
 
-
-
+ifeq ($(PLATFORM), macosx)
+FILES_export = \
+	sun/tools/attach/BsdVirtualMachine.java
+endif
--- a/make/com/sun/tools/attach/FILES_c.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/tools/attach/FILES_c.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -39,4 +39,7 @@
 	LinuxVirtualMachine.c
 endif
 
-
+ifeq ($(PLATFORM), macosx)
+FILES_c = \
+	BsdVirtualMachine.c
+endif
--- a/make/com/sun/tools/attach/FILES_java.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/tools/attach/FILES_java.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -43,6 +43,11 @@
 	sun/tools/attach/LinuxAttachProvider.java
 endif
 
+ifeq ($(PLATFORM), macosx)
+FILES_java += \
+	sun/tools/attach/BsdAttachProvider.java
+endif
+
 #
 # Files that need to be copied
 #
--- a/make/com/sun/tools/attach/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/com/sun/tools/attach/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -36,6 +36,9 @@
 ifeq ($(PLATFORM), linux)
 FILES_m = mapfile-linux
 endif
+ifeq ($(PLATFORM), macosx)
+FILES_m = mapfile-bsd 
+endif
 include $(BUILDDIR)/common/Mapfile-vers.gmk
 
 #
@@ -52,7 +55,11 @@
 EXTRA_LIBS += psapi.lib
 endif
 
-vpath %.c $(PLATFORM_SRC)/native/sun/tools/attach
+ifeq ($PLATFORM), macosx)
+  vpath %.c $(call NativeSrcDirList,,native/sun/tools/attach)
+else
+  vpath %.c $(PLATFORM_SRC)/native/sun/tools/attach
+endif
 
 all: classes copy-files
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/com/sun/tools/attach/mapfile-bsd	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,41 @@
+#
+# Copyright (c) 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.
+#
+
+# Define public interface.
+
+SUNWprivate_1.1 {
+	global:
+	    Java_sun_tools_attach_BsdVirtualMachine_checkPermissions;
+	    Java_sun_tools_attach_BsdVirtualMachine_close;
+	    Java_sun_tools_attach_BsdVirtualMachine_connect;
+	    Java_sun_tools_attach_BsdVirtualMachine_open;
+	    Java_sun_tools_attach_BsdVirtualMachine_sendQuitTo;
+	    Java_sun_tools_attach_BsdVirtualMachine_socket;
+	    Java_sun_tools_attach_BsdVirtualMachine_read;
+	    Java_sun_tools_attach_BsdVirtualMachine_write;
+	    Java_sun_tools_attach_BsdVirtualMachine_createAttachFile;
+	local:
+		*;
+};
--- a/make/common/Defs-linux.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Defs-linux.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -375,6 +375,7 @@
 override LIBNSL                  =
 override LIBSCF                  =
 override LIBTHREAD               =
+override LIBDL                   = -ldl
 override MOOT_PRIORITIES         = true
 override NO_INTERRUPTIBLE_IO     = true
 ifeq ($(ARCH), amd64)
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/common/Defs-macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,400 @@
+#
+# Copyright (c) 1999, 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.
+#
+
+#
+# Makefile to specify compiler flags for programs and libraries
+# targeted to MACOSX.  Should not contain any rules.
+#
+# WARNING: This file is shared with other workspaces. 
+#          So when it includes other files, it must use JDK_TOPDIR.
+#
+
+# Warning: the following variables are overriden by Defs.gmk. Set
+# values will be silently ignored:
+#   CFLAGS        (set $(OTHER_CFLAGS) instead)
+#   CPPFLAGS      (set $(OTHER_CPPFLAGS) instead)
+#   CXXFLAGS      (set $(OTHER_CXXFLAGS) instead)
+#   LDFLAGS       (set $(OTHER_LDFAGS) instead)
+#   LDLIBS        (set $(EXTRA_LIBS) instead)
+#   LDLIBS_COMMON (set $(EXTRA_LIBS) instead)
+
+# Get shared JDK settings
+include $(JDK_MAKE_SHARED_DIR)/Defs.gmk
+
+# Part of INCREMENTAL_BUILD mechanism.
+#   Compiler emits things like:  path/file.o: file.h
+#   We want something like: relative_path/file.o relative_path/file.d: file.h
+CC_DEPEND	 = -MM
+CC_DEPEND_FILTER = $(SED) -e 's!$*\.$(OBJECT_SUFFIX)!$(dir $@)& $(dir $@)$*.$(DEPEND_SUFFIX)!g'
+
+ifndef PLATFORM_SRC
+  PLATFORM_SRC = $(BUILDDIR)/../src/solaris
+endif # PLATFORM_SRC
+
+# BSD build pulls its platform sources from the solaris tree.
+JAVA_SRCDIR_LIST = src/$(PLATFORM) src/solaris src/share
+NATIVE_SRCDIR_LIST = src/$(PLATFORM) src/solaris src/share
+
+# Platform specific closed sources
+ifndef OPENJDK
+  ifndef CLOSED_PLATFORM_SRC
+    CLOSED_PLATFORM_SRC = $(BUILDDIR)/../src/closed/solaris
+  endif
+endif
+
+# platform specific include files
+PLATFORM_INCLUDE_NAME = $(OS_NAME)
+PLATFORM_INCLUDE      = $(INCLUDEDIR)/$(PLATFORM_INCLUDE_NAME)
+
+# suffix used for make dependencies files.
+DEPEND_SUFFIX = d
+# The suffix applied to the library name for FDLIBM
+FDDLIBM_SUFFIX = a
+# The suffix applied to scripts (.bat for windows, nothing for unix)
+SCRIPT_SUFFIX =
+# CC compiler object code output directive flag value
+CC_OBJECT_OUTPUT_FLAG = -o #trailing blank required!
+CC_PROGRAM_OUTPUT_FLAG = -o #trailing blank required!
+
+#
+# Default optimization
+#
+
+ifndef OPTIMIZATION_LEVEL
+  ifeq ($(PRODUCT), java)
+    OPTIMIZATION_LEVEL = HIGHER
+  else
+    OPTIMIZATION_LEVEL = LOWER
+  endif
+endif
+ifndef FASTDEBUG_OPTIMIZATION_LEVEL
+  FASTDEBUG_OPTIMIZATION_LEVEL = LOWER
+endif
+
+# For macosx use -Os by default, unless -O3 can be proved to be worth the cost, as per policy
+# <http://wikis.sun.com/display/OpenJDK/Mac+OS+X+Port+Compilers>
+CC_OPT/NONE     = 
+CC_OPT/LOWER    = -Os
+CC_OPT/HIGHER   = -Os
+CC_OPT/HIGHEST  = -Os
+
+CC_OPT          = $(CC_OPT/$(OPTIMIZATION_LEVEL))
+
+# For all platforms, do not omit the frame pointer register usage. 
+#    We need this frame pointer to make it easy to walk the stacks.
+#    This should be the default on X86, but ia64 and amd64 may not have this
+#    as the default.
+CFLAGS_REQUIRED_amd64   += -m64 -fno-omit-frame-pointer -D_LITTLE_ENDIAN
+LDFLAGS_COMMON_amd64    += -m64
+CFLAGS_REQUIRED_i586    += -m32 -fno-omit-frame-pointer -D_LITTLE_ENDIAN
+LDFLAGS_COMMON_i586     += -m32
+CFLAGS_REQUIRED_ia64    += -m64 -fno-omit-frame-pointer -D_LITTLE_ENDIAN
+CFLAGS_REQUIRED_sparcv9 += -m64 -mcpu=v9
+LDFLAGS_COMMON_sparcv9  += -m64 -mcpu=v9
+CFLAGS_REQUIRED_sparc   += -m32 -mcpu=v9
+LDFLAGS_COMMON_sparc    += -m32 -mcpu=v9
+CFLAGS_REQUIRED_arm     += -fsigned-char -D_LITTLE_ENDIAN
+CFLAGS_REQUIRED_ppc     += -fsigned-char -D_BIG_ENDIAN
+ifeq ($(ZERO_BUILD), true)
+  CFLAGS_REQUIRED       =  $(ZERO_ARCHFLAG)
+  ifeq ($(ZERO_ENDIANNESS), little)
+    CFLAGS_REQUIRED     += -D_LITTLE_ENDIAN
+  endif
+  LDFLAGS_COMMON        += $(ZERO_ARCHFLAG)
+else ifeq ($(ARCH), universal)
+  CFLAGS_REQUIRED       += -arch i386 -arch x86_64 -D_LITTLE_ENDIAN
+  LDFLAGS_COMMON        += -arch i386 -arch x86_64
+else
+  CFLAGS_REQUIRED       =  $(CFLAGS_REQUIRED_$(ARCH))
+  LDFLAGS_COMMON        += $(LDFLAGS_COMMON_$(ARCH))
+endif
+# 16-byte stack re-alignment on 32-bit Darwin
+CFLAGS_REQUIRED_i586 += -mstackrealign
+
+OTHER_CFLAGS = \
+         -F/System/Library/Frameworks/JavaVM.framework/Frameworks \
+	     -F/System/Library/Frameworks/ApplicationServices.framework/Frameworks
+
+#
+# Selection of warning messages
+#
+GCC_INHIBIT	= -Wno-unused -Wno-parentheses
+GCC_STYLE	= 
+GCC_WARNINGS	= -W -Wall $(GCC_STYLE) $(GCC_INHIBIT)
+
+#
+# Treat compiler warnings as errors, if warnings not allowed
+#
+ifeq ($(COMPILER_WARNINGS_FATAL),true)
+  GCC_WARNINGS += -Werror
+endif
+
+#
+# Misc compiler options
+#
+ifneq ($(ARCH),ppc)
+  CFLAGS_COMMON   = -fno-strict-aliasing
+endif 
+PIC_CODE_LARGE = -fPIC
+PIC_CODE_SMALL = -fpic
+GLOBAL_KPIC = $(PIC_CODE_LARGE)
+CFLAGS_COMMON   += $(GLOBAL_KPIC) $(GCC_WARNINGS)
+ifeq ($(ARCH), amd64)
+ CFLAGS_COMMON += -pipe
+endif
+
+# BSD 64bit machines use Dwarf2, which can be HUGE, have fastdebug use -g1
+DEBUG_FLAG = -g
+ifeq ($(FASTDEBUG), true)
+  ifeq ($(ARCH_DATA_MODEL), 64)
+    DEBUG_FLAG = -g1
+  endif
+endif
+
+# DEBUG_BINARIES overrides everything, use full -g debug information
+ifeq ($(DEBUG_BINARIES), true)
+  DEBUG_FLAG = -g
+  CFLAGS_REQUIRED += $(DEBUG_FLAG)
+endif
+
+CFLAGS_OPT      = $(CC_OPT)
+CFLAGS_DBG      = $(DEBUG_FLAG)
+CFLAGS_COMMON += $(CFLAGS_REQUIRED)
+
+CXXFLAGS_COMMON = $(GLOBAL_KPIC) -DCC_NOEX $(GCC_WARNINGS)
+CXXFLAGS_OPT	= $(CC_OPT)
+CXXFLAGS_DBG	= $(DEBUG_FLAG)
+CXXFLAGS_COMMON += $(CFLAGS_REQUIRED)
+
+# FASTDEBUG: Optimize the code in the -g versions, gives us a faster debug java
+ifeq ($(FASTDEBUG), true)
+  CFLAGS_DBG    += $(CC_OPT/$(FASTDEBUG_OPTIMIZATION_LEVEL))
+  CXXFLAGS_DBG	+= $(CC_OPT/$(FASTDEBUG_OPTIMIZATION_LEVEL))
+endif
+
+CPP_ARCH_FLAGS = -DARCH='"$(ARCH)"'
+
+# Alpha arch does not like "alpha" defined (potential general arch cleanup issue here)
+ifneq ($(ARCH),alpha)
+  CPP_ARCH_FLAGS += -D$(ARCH)
+else
+  CPP_ARCH_FLAGS += -D_$(ARCH)_
+endif
+CPPFLAGS_COMMON = $(CPP_ARCH_FLAGS) -D_ALLBSD_SOURCE $(VERSION_DEFINES) \
+		  -D_LARGEFILE64_SOURCE -D_GNU_SOURCE -D_REENTRANT
+
+CPPFLAGS_COMMON += -DMACOSX
+
+ifeq ($(ARCH_DATA_MODEL), 64)
+CPPFLAGS_COMMON += -D_LP64=1
+endif
+
+CPPFLAGS_OPT    = -DNDEBUG
+CPPFLAGS_DBG    = -DDEBUG
+ifneq ($(PRODUCT), java)
+  CPPFLAGS_DBG    += -DLOGGING 
+endif
+
+# Libraries need to locate other libraries at runtime, and you can tell
+#   a library where to look by way of the dynamic runpaths (RPATH or RUNPATH)
+#   buried inside the .{so,dylib}. The {$ORIGIN,@loader_path/} says to look
+#   relative to where the library itself is and it can be followed
+#   with relative paths from that. By default we always look in
+#   {$ORIGIN,@loader_path/}, optionally we add relative paths if the Makefile
+#   sets LD_RUNPATH_EXTRAS to those relative paths.
+#   Except on MacOS X we add a flag -z origin, not sure if this is necessary,
+#   but doesn't seem to hurt.
+#   The environment variable LD_LIBRARY_PATH will over-ride these runpaths.
+#   See 'man {dyld,rtld}' for more information.
+#   Try: 'readelf -d lib*.so' to see these settings in a library.
+#
+LDFLAGS_COMMON += -Xlinker -rpath -Xlinker @loader_path/.
+LDFLAGS_COMMON += $(LD_RUNPATH_EXTRAS:%=-Xlinker -rpath -Xlinker @loader_path/%)
+LDFLAGS_COMMON += -Xlinker -install_name -Xlinker @rpath/$(@F)
+
+#
+# -L paths for finding and -ljava
+#
+LDFLAGS_COMMON += -L$(LIBDIR)
+
+#
+# -static-libgcc is a gcc-3 flag to statically link libgcc, gcc-2.9x always
+# statically link libgcc but will print a warning with the flag. We don't 
+# want the warning, so check gcc version first.
+#
+ifeq ($(CC_MAJORVER),3)
+  OTHER_LDFLAGS  += -static-libgcc
+endif
+
+# Automatic precompiled header option to use (if COMPILE_APPROACH=batch)
+#   (See Rules.gmk) The gcc 5 compiler might have an option for this?
+AUTOMATIC_PCH_OPTION = 
+
+#
+# Post Processing of libraries/executables
+#
+ifeq ($(VARIANT), OPT)
+  ifneq ($(NO_STRIP), true)
+    ifneq ($(DEBUG_BINARIES), true)
+      # Debug 'strip -S' leaves local function Elf symbols (better stack
+      # traces)
+      POST_STRIP_PROCESS = $(STRIP) -S
+    endif
+  endif
+endif
+
+#
+# Use: ld $(LD_MAPFILE_FLAG) mapfile *.o
+#
+LD_MAPFILE_FLAG = -Xlinker --version-script -Xlinker
+
+#
+# Support for Quantify.
+#
+ifdef QUANTIFY
+QUANTIFY_CMD = quantify
+QUANTIFY_OPTIONS = -cache-dir=/tmp/quantify -always-use-cache-dir=yes
+LINK_PRE_CMD = $(QUANTIFY_CMD) $(QUANTIFY_OPTIONS)
+endif
+
+# Darwin does not support linker map files.
+LDNOMAP=true
+
+#
+# Path and option to link against the VM, if you have to.  Note that
+# there are libraries that link against only -ljava, but they do get
+# -L to the -ljvm, this is because -ljava depends on -ljvm, whereas
+# the library itself should not.
+#
+VM_NAME         = server
+JVMLIB          = -L$(LIBDIR)/$(VM_NAME) -ljvm
+JAVALIB         = -ljava $(JVMLIB)
+
+#
+# We want to privatize JVM symbols on Solaris. This is so the user can
+# write a function called FindClass and this should not override the 
+# FindClass that is inside the JVM. At this point in time we are not
+# concerned with other JNI libraries because we hope that there will
+# not be as many clashes there.
+#
+PRIVATIZE_JVM_SYMBOLS = false
+
+USE_PTHREADS = true
+override ALT_CODESET_KEY         = _NL_CTYPE_CODESET_NAME
+override AWT_RUNPATH             =
+override HAVE_ALTZONE            = false
+override HAVE_FILIOH             = false
+override HAVE_GETHRTIME          = false
+override HAVE_GETHRVTIME         = false
+override HAVE_SIGIGNORE          = true
+override LEX_LIBRARY             = -lfl
+ifeq ($(STATIC_CXX),true)
+override LIBCXX                  = -Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic
+else
+override LIBCXX                  = -lstdc++
+endif
+override LIBPOSIX4               =
+override LIBSOCKET               =
+override LIBNSL                  =
+override LIBTHREAD               =
+override LIBDL                   =
+override MOOT_PRIORITIES         = true
+override NO_INTERRUPTIBLE_IO     = true
+override OPENWIN_HOME            = $(X11_PATH)
+override OPENWIN_LIB             = $(OPENWIN_HOME)/lib
+override OTHER_M4FLAGS           = -D__GLIBC__ -DGNU_ASSEMBLER
+override SUN_CMM_SUBDIR          =
+override THREADS_FLAG            = native
+override USE_GNU_M4              = true
+override USING_GNU_TAR           = true
+override WRITE_LIBVERSION        = false
+
+ifdef ALT_X11_PATH
+  X11_PATH = $(ALT_X11_PATH)
+else
+  X11_PATH = /usr/X11R6
+endif
+
+ifdef ALT_PACKAGE_PATH
+  PACKAGE_PATH = $(ALT_PACKAGE_PATH)
+else
+  PACKAGE_PATH = /opt/local
+endif
+
+# ALSA
+ifdef ALT_ALSA_LIB_PATH
+  ALSA_LIB_PATH = $(ALT_ALSA_LIB_PATH)
+else
+  ALSA_LIB_PATH = $(PACKAGE_PATH)/lib
+endif
+
+ifdef ALT_ALSA_HEADERS_PATH
+  ALSA_HEADERS_PATH = $(ALT_ALSA_HEADERS_PATH)
+else
+  ALSA_HEADERS_PATH = $(PACKAGE_PATH)/include
+endif
+
+# USE_EXECNAME forces the launcher to look up argv[0] on $PATH, and put the
+# resulting resolved absolute name of the executable in the environment
+# variable EXECNAME.  That executable name is then used that to locate the
+# installation area.
+override USE_EXECNAME            = true
+
+# If your platform has DPS, it will have Type1 fonts too, in which case
+# it is best to enable DPS support until such time as 2D's rasteriser
+# can fully handle Type1 fonts in all cases. Default is "yes".
+# HAVE_DPS should only be "no" if the platform has no DPS headers or libs
+# DPS (Displayable PostScript) is available on Solaris machines
+HAVE_DPS = no
+
+SYSTEM_ZLIB = true
+
+#
+# Japanese manpages
+#
+JA_SOURCE_ENCODING = eucJP
+JA_TARGET_ENCODINGS = UTF-8
+
+# Settings for the JDI - Serviceability Agent binding.
+
+HOTSPOT_SALIB_PATH = $(HOTSPOT_IMPORT_PATH)/jre/lib
+SALIB_NAME = $(LIB_PREFIX)saproc.$(LIBRARY_SUFFIX)
+
+# The JDI - Serviceability Agent binding is not currently supported
+# on ia64.
+ifeq ($(ARCH), ia64)
+  INCLUDE_SA = false
+else
+  INCLUDE_SA = true
+endif
+
+ifdef CROSS_COMPILE_ARCH
+  # X11 headers are not under /usr/include
+  OTHER_CFLAGS += -I$(OPENWIN_HOME)/include
+  OTHER_CXXFLAGS += -I$(OPENWIN_HOME)/include
+  OTHER_CPPFLAGS += -I$(OPENWIN_HOME)/include
+endif
+
+LIB_LOCATION ?= $(LIBDIR)
--- a/make/common/Defs-solaris.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Defs-solaris.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -714,6 +714,9 @@
 # service configuration facility library
 LIBSCF = -lscf
 
+# Dynamic Loading library
+LIBDL = -ldl
+
 # GLOBAL_KPIC: If set means all libraries are PIC, position independent code
 #    EXCEPT for select compiles
 #    If a .o file is compiled non-PIC then it should be forced
--- a/make/common/Defs.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Defs.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -179,11 +179,18 @@
 
   ifdef ALT_FREETYPE_LIB_PATH
     FREETYPE_LIB_PATH = $(ALT_FREETYPE_LIB_PATH)
+    ifeq ($(PLATFORM), macosx)
+      USING_SYSTEM_FT_LIB=true
+    endif
   else
     ifeq ($(DEVTOOLS_FT_DIR_EXISTS), true)
       FREETYPE_LIB_PATH = $(DEVTOOLS_FT_DIR)/lib
     else
-      FREETYPE_LIB_PATH = /usr/lib
+      ifeq ($(PLATFORM), macosx)
+        FREETYPE_LIB_PATH = /usr/X11R6/lib
+      else
+        FREETYPE_LIB_PATH = /usr/lib
+      endif
       USING_SYSTEM_FT_LIB=true
     endif
   endif 
@@ -194,7 +201,11 @@
     ifeq ($(DEVTOOLS_FT_DIR_EXISTS), true)
       FREETYPE_HEADERS_PATH = $(DEVTOOLS_FT_DIR)/include
     else
-      FREETYPE_HEADERS_PATH = /usr/include
+      ifeq ($(PLATFORM), macosx)
+        FREETYPE_HEADERS_PATH = /usr/X11R6/include
+      else
+        FREETYPE_HEADERS_PATH = /usr/include
+      endif
     endif
   endif
 endif
@@ -243,6 +254,10 @@
     LDLIBS_COMMON = -ldl
   endif
 
+  ifeq ($(PLATFORM), macosx)
+    LDLIBS_COMMON = -pthread
+  endif
+
 endif # PROGRAM
 
 LDLIBS_COMMON += $(EXTRA_LIBS)
@@ -383,7 +398,12 @@
 # We define an intermediate variable for Java files because
 # we use its value later to help define $SOURCEPATH
 
-VPATH0.java = $(GENSRCDIR)$(CLASSPATH_SEPARATOR)$(PLATFORM_SRC)/classes$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/classes
+ifeq ($(PLATFORM), macosx)
+  VPATH0.java = $(subst $(ONESPACE),:,$(GENSRCDIR) $(call JavaSrcDirList,,classes))
+else
+  VPATH0.java = $(GENSRCDIR)$(CLASSPATH_SEPARATOR)$(PLATFORM_SRC)/classes$(CLASSPATH_SEPARATOR)$(SHARE_SRC)/classes
+endif
+
 ifdef OPENJDK
   VPATH.java = $(VPATH0.java)
 else
--- a/make/common/Library.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Library.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -58,6 +58,17 @@
 FILES_o  += $(patsubst %.s,   %.$(OBJECT_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_s))))
 FILES_o  += $(patsubst %.cpp, %.$(OBJECT_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_cpp))))
 
+ifeq ($(PLATFORM), macosx)
+FILES_o  += $(patsubst %.m,   %.$(OBJECT_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_objc))))
+FILES_o  += $(patsubst %.mm,  %.$(OBJECT_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_objcpp))))
+
+# MMM: why?
+INCREMENTAL_BUILD=false
+
+endif # PLATFORM
+
+
+
 ifeq ($(INCREMENTAL_BUILD),true)
 FILES_d   = $(patsubst %.c,   %.$(DEPEND_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_c))))
 FILES_d  += $(patsubst %.cpp, %.$(DEPEND_SUFFIX), $(addprefix $(OBJDIR)/, $(notdir $(FILES_cpp))))
@@ -217,12 +228,17 @@
 # the shared library.  On other platforms set this to false at the
 # make command line.
 #
+
+ifneq ($(PLATFORM), macosx)
+  ARFLAGS = -r
+endif
+
 $(ACTUAL_LIBRARY):: $(COMPILE_FILES_o) $(FILES_m) $(FILES_reorder)
 	@$(prep-target)
 	@$(ECHO) "STATS: LIBRARY=$(LIBRARY), PRODUCT=$(PRODUCT), OPTIMIZATION_LEVEL=$(OPTIMIZATION_LEVEL)"
 	@$(ECHO) "Rebuilding $@ because of $?"
 ifeq ($(LIBRARY), fdlibm)
-	$(AR) -r $@ $(FILES_o)
+	$(AR) $(ARFLAGS) $@ $(FILES_o)
 else # LIBRARY
 	$(LINKER) $(SHARED_LIBRARY_FLAG) -o $@ $(FILES_o) $(LDLIBS)
 	@$(call binary_file_verification,$@)
--- a/make/common/Program.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Program.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 1995, 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
@@ -38,12 +38,18 @@
   override COMPILE_APPROACH = normal
 endif
 
-ifndef LAUNCHER_PLATFORM_SRC
-LAUNCHER_PLATFORM_SRC = $(PLATFORM_SRC)
-endif
+# set the platform specific directory for macosx, also this platform shares
+# substantial family ties with its siblings (solaris and linux), thus we add
+# solaris src path to its compilation dependencies.
+ifeq ($(PLATFORM), macosx)
+  LAUNCHER_PLATFORM_SRC = $(BUILDDIR)/../src/macosx
+  LAUNCHER_SOLARIS_PLATFORM_SRC  = $(BUILDDIR)/../src/solaris
+else # ! MACOSX
+  LAUNCHER_PLATFORM_SRC = $(PLATFORM_SRC)
+endif # MACOSX  
 
 ifndef LAUNCHER_SHARE_SRC
-LAUNCHER_SHARE_SRC = $(SHARE_SRC)
+  LAUNCHER_SHARE_SRC = $(SHARE_SRC)
 endif
 
 ACTUAL_PROGRAM_NAME = $(PROGRAM)$(EXE_SUFFIX)
@@ -66,7 +72,7 @@
 include $(JDK_TOPDIR)/make/common/Rules.gmk
 
 ifdef NEVER_ACT_AS_SERVER_CLASS_MACHINE
-OTHER_CPPFLAGS += -DNEVER_ACT_AS_SERVER_CLASS_MACHINE
+  OTHER_CPPFLAGS += -DNEVER_ACT_AS_SERVER_CLASS_MACHINE
 endif
 
 #
@@ -78,40 +84,51 @@
 # On Windows, this is done by using the same directory as the executable
 # itself, as with all the Windows libraries.
 #
-ifneq (,$(findstring $(PLATFORM), linux solaris))	# UNIX systems
-    LDFLAGS += -L $(LIBDIR)/$(LIBARCH)/jli
-    OTHER_LDLIBS += -ljli
-    ifeq ($(PLATFORM), solaris)
-	ifeq ($(ARCH_DATA_MODEL), 32)
-		LDFLAGS += -R \$$ORIGIN/../lib/$(LIBARCH)/jli
-		LDFLAGS += -R \$$ORIGIN/../jre/lib/$(LIBARCH)/jli
-	else
-		LDFLAGS += -R \$$ORIGIN/../../lib/$(LIBARCH)/jli
-		LDFLAGS += -R \$$ORIGIN/../../jre/lib/$(LIBARCH)/jli
-	endif
-    endif
-    ifeq ($(PLATFORM), linux)
-	LDFLAGS += $(LDFLAG_Z_ORIGIN)
-	LDFLAGS += -Wl,--allow-shlib-undefined
-	LDFLAGS += -Wl,-rpath -Wl,\$$ORIGIN/../lib/$(LIBARCH)/jli
-	LDFLAGS += -Wl,-rpath -Wl,\$$ORIGIN/../jre/lib/$(LIBARCH)/jli
-    endif
-endif
+ifeq ($(PLATFORM), macosx)
+  ifneq ($(ARCH), universal)
+    LDFLAGS += -Wl,-all_load
+  endif # ARCH
+  LDFLAGS += $(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/static/libjli.a
+
+  ifeq ($(SYSTEM_ZLIB),true)
+    OTHER_LDLIBS += -lz
+  endif # SYSTEM_ZLIB
+endif # PLATFORM
+
+ifneq (,$(findstring $(PLATFORM), linux solaris)) # UNIX systems
+  LDFLAGS += -L $(LIBDIR)/$(LIBARCH)/jli
+  OTHER_LDLIBS += -ljli
+  ifeq ($(PLATFORM), solaris)
+    ifeq ($(ARCH_DATA_MODEL), 32)
+      LDFLAGS += -R \$$ORIGIN/../lib/$(LIBARCH)/jli
+      LDFLAGS += -R \$$ORIGIN/../jre/lib/$(LIBARCH)/jli
+    else # ! ARCH_DATA_MODEL 64-bit
+      LDFLAGS += -R \$$ORIGIN/../../lib/$(LIBARCH)/jli
+      LDFLAGS += -R \$$ORIGIN/../../jre/lib/$(LIBARCH)/jli
+    endif # ARCH_DATA_MODEL
+  endif # PLATFORM SOLARIS
+  ifeq ($(PLATFORM), linux)
+    LDFLAGS += $(LDFLAG_Z_ORIGIN)
+    LDFLAGS += -Wl,--allow-shlib-undefined
+    LDFLAGS += -Wl,-rpath -Wl,\$$ORIGIN/../lib/$(LIBARCH)/jli
+    LDFLAGS += -Wl,-rpath -Wl,\$$ORIGIN/../jre/lib/$(LIBARCH)/jli
+  endif # PLATFORM LINUX
+endif # PLATFORM linux solaris
+
 ifeq ($(PLATFORM), windows)
-	JLI_LCF = $(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/jli.lcf
-	ifdef STATIC_JLI
-	    LDFLAGS += -libpath:$(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/static
-	else
-	    LDFLAGS += -libpath:$(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)
-	endif
-	OTHER_LDLIBS += jli.lib
-endif
+  JLI_LCF = $(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/jli.lcf
+  ifdef STATIC_JLI
+    LDFLAGS += -libpath:$(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/static
+  else # !STATIC_JLI
+    LDFLAGS += -libpath:$(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)
+  endif # STATIC_JLI
+  OTHER_LDLIBS += jli.lib
+endif # PLATFORM
 
 #
 # Launcher specific files.
 #
-FILES_o = \
-	$(OBJDIR)/main.$(OBJECT_SUFFIX)
+FILES_o = $(OBJDIR)/main.$(OBJECT_SUFFIX)
 
 $(ACTUAL_PROGRAM):: classes $(INIT) 
 
@@ -119,82 +136,98 @@
 # Windows only
 #
 ifeq ($(PLATFORM), windows)
+  # JDK name required here
+  RC_FLAGS += /D "JDK_FNAME=$(PROGRAM)$(EXE_SUFFIX)" \
+              /D "JDK_INTERNAL_NAME=$(PROGRAM)" \
+              /D "JDK_FTYPE=0x1L"
 
-# JDK name required here
-RC_FLAGS += /D "JDK_FNAME=$(PROGRAM)$(EXE_SUFFIX)" \
-	    /D "JDK_INTERNAL_NAME=$(PROGRAM)" \
-	    /D "JDK_FTYPE=0x1L"
+  $(OBJDIR)/$(PROGRAM).res: $(VERSIONINFO_RESOURCE)
+	@$(prep-target)
+  ifndef LOCAL_RESOURCE_FILE
+	$(RC) $(RC_FLAGS) $(CC_OBJECT_OUTPUT_FLAG)$(@) $(VERSIONINFO_RESOURCE)
+  endif # LOCAL_RESOURCE_FILE
 
-$(OBJDIR)/$(PROGRAM).res: $(VERSIONINFO_RESOURCE)
-	@$(prep-target)
-ifndef LOCAL_RESOURCE_FILE
-	$(RC) $(RC_FLAGS) $(CC_OBJECT_OUTPUT_FLAG)$(@) $(VERSIONINFO_RESOURCE)
-endif
-
-$(OBJDIR)/$(PROGRAM).lcf: $(OBJDIR)/$(PROGRAM).res $(FILES_o)
+  $(OBJDIR)/$(PROGRAM).lcf: $(OBJDIR)/$(PROGRAM).res $(FILES_o)
 	@$(prep-target)
 	@$(ECHO) $(FILES_o) > $@ 
   ifndef LOCAL_RESOURCE_FILE
 	@$(ECHO) $(OBJDIR)/$(PROGRAM).res >> $@
-  endif
+  endif # LOCAL_RESOURCE_FILE
 	@$(ECHO) setargv.obj >> $@
 	@$(ECHO) Created $@ 
 
-$(ACTUAL_PROGRAM):: $(OBJDIR)/$(PROGRAM)$(EXE_SUFFIX)
+  $(ACTUAL_PROGRAM):: $(OBJDIR)/$(PROGRAM)$(EXE_SUFFIX)
 	@$(install-file)
 
-ifeq ($(ARCH_DATA_MODEL), 32)
-  STACK_SIZE=327680
-else
-# We need more Stack for Windows 64bit
-  STACK_SIZE=1048576
-endif
+  ifeq ($(ARCH_DATA_MODEL), 32)
+    STACK_SIZE=327680
+  else # !32 BIT
+    # We need more Stack for Windows 64bit
+    STACK_SIZE=1048576
+  endif # ARCH_DATA_MODEL
 
-IMVERSION=$(JDK_MINOR_VERSION).$(JDK_MICRO_VERSION).$(JDK_UPDATE_VER).$(COOKED_BUILD_NUMBER)
-$(OBJDIR)/$(PROGRAM).exe.manifest: $(JDK_TOPDIR)/src/windows/resource/java.manifest
+  IMVERSION=$(JDK_MINOR_VERSION).$(JDK_MICRO_VERSION).$(JDK_UPDATE_VER).$(COOKED_BUILD_NUMBER)
+  $(OBJDIR)/$(PROGRAM).exe.manifest: $(JDK_TOPDIR)/src/windows/resource/java.manifest
 	@$(prep-target)
 	$(SED) 's%IMVERSION%$(IMVERSION)%g;s%PROGRAM%$(PROGRAM)%g' $< > $@
 
-# We used a hand-crafted manifest file for all executables.
-# It is tweaked to embed the build number and executable name.
-# Use ";#2" for .dll and ";#1" for .exe in the MT command below:
-$(OBJDIR)/$(PROGRAM)$(EXE_SUFFIX):: $(OBJDIR)/$(PROGRAM).lcf $(FILES_o) $(JLI_LCF) $(OBJDIR)/$(PROGRAM).exe.manifest
+  # We used a hand-crafted manifest file for all executables.
+  # It is tweaked to embed the build number and executable name.
+  # Use ";#2" for .dll and ";#1" for .exe in the MT command below:
+  $(OBJDIR)/$(PROGRAM)$(EXE_SUFFIX):: $(OBJDIR)/$(PROGRAM).lcf $(FILES_o) $(JLI_LCF) $(OBJDIR)/$(PROGRAM).exe.manifest
 	@$(prep-target)
 	@set -- $?; \
 	    $(ECHO) Rebuilding $@ because of $$1 $$2 $$3 $$4 $$5 $$6 $${7:+...};
 	$(LINK) -out:$@ /STACK:$(STACK_SIZE) \
 	    -map:$(OBJDIR)/$(PROGRAM).map $(LFLAGS) $(LDFLAGS) \
 	    @$(OBJDIR)/$(PROGRAM).lcf $(LDLIBS)
-ifdef MT
+  ifdef MT
 	$(MT) /manifest $(OBJDIR)/$(PROGRAM).exe.manifest /outputresource:$@;#1
-endif
+  endif # MT
 	@$(call binary_file_verification,$@)
+else # *NIXES
+  #
+  # Note that we have to link -lthread even when USE_PTHREADS is true.
+  # This is becuase checkForCorrectLibthread() croaks otherwise.
+  #
+  LIBTHREAD = -lthread
+  ifeq ($(USE_PTHREADS),true)
+    THREADLIBS = -lpthread $(LIBTHREAD)
+  else # !USE_PTHREADS
+    THREADLIBS = $(LIBTHREAD)
+  endif # USE_PTHREADS
 
-else # PLATFORM
+  ifeq ($(PLATFORM), macosx)
+    THREADLIBS = -pthread
+    # Needed for linking the various launchers
+    LDFLAGS += -framework Cocoa -framework Security \
+               -framework ApplicationServices
+    OTHER_CPPFLAGS += -DPACKAGE_PATH='"$(PACKAGE_PATH)"'
 
-#
-# Note that we have to link -lthread even when USE_PTHREADS is true.
-# This is becuase checkForCorrectLibthread() croaks otherwise.
-#
-LIBTHREAD = -lthread
-ifeq ($(USE_PTHREADS),true)
-  THREADLIBS = -lpthread $(LIBTHREAD)
-else # USE_PTHREADS
-  THREADLIBS = $(LIBTHREAD)
-endif # USE_PTHREADS
+    # Default Info.plist file for the command line tools. This gets overridden by
+    # some of the jvmstat tools so that they have task_for_pid() privileges
+    ifndef INFO_PLIST_FILE
+      INFO_PLIST_FILE = Info-cmdline.plist
+    endif # INFO_PLIST_FILE 
+    LDFLAGS += -sectcreate __TEXT __info_plist $(LAUNCHER_PLATFORM_SRC)/lib/$(INFO_PLIST_FILE)
+  else # SOLARIS/LINUX
+    INFO_PLIST_FILE=
+  endif # MACOSX
 
-#
-# This rule only applies on unix.  It supports quantify and its ilk.
-#
-$(ACTUAL_PROGRAM):: $(FILES_o)
+  #
+  # This rule only applies on unix.  It supports quantify and its ilk.
+  #
+  $(ACTUAL_PROGRAM):: $(FILES_o)
 	@$(prep-target)
 	@set -- $?; \
-	    $(ECHO) Rebuilding $@ because of $$1 $$2 $$3 $$4 $$5 $$6 $${7:+...};
+	$(ECHO) Rebuilding $@ because of $$1 $$2 $$3 $$4 $$5 $$6 $${7:+...};
 	@$(MKDIR) -p $(TEMPDIR)
 	$(LINK_PRE_CMD) $(CC) $(CC_OBJECT_OUTPUT_FLAG)$@ $(LDFLAGS) \
-	    $(FILES_o) $(THREADLIBS) $(LDLIBS)
+	$(FILES_o) $(THREADLIBS) $(LDLIBS)
+  ifeq ($(findstring privileged, $(INFO_PLIST_FILE)), privileged)
+	-codesign -s openjdk_codesign $@
+  endif # INFO_PLIST_FILE
 	@$(call binary_file_verification,$@)
-
 endif # PLATFORM
 
 clean:: 
@@ -218,42 +251,49 @@
 # Now include make dependencies (created during compilation, see Rules.gmk)
 #
 ifeq ($(INCREMENTAL_BUILD),true)
-# Workaround: gnumake sometimes says files is empty when it shouldn't
-#    was:  files := $(foreach file, $(wildcard */$(ARCH)/*.$(DEPEND_SUFFIX)), $(file))
-files := $(shell $(LS) $(OBJDIR)/*.$(DEPEND_SUFFIX) 2>/dev/null)
-ifneq ($(strip $(files)),)
-include $(files)
-endif # files
+  # Workaround: gnumake sometimes says files is empty when it shouldn't
+  #    was:  files := $(foreach file, $(wildcard */$(ARCH)/*.$(DEPEND_SUFFIX)), $(file))
+  files := $(shell $(LS) $(OBJDIR)/*.$(DEPEND_SUFFIX) 2>/dev/null)
+  ifneq ($(strip $(files)),)
+    include $(files)
+  endif # files
 endif # INCREMENTAL_BUILD
 
 ifdef JAVA_ARGS
-OTHER_CPPFLAGS += -DJAVA_ARGS='$(JAVA_ARGS)'
-OTHER_CPPFLAGS += -DLAUNCHER_NAME='"$(LAUNCHER_NAME)"'
-endif
+  OTHER_CPPFLAGS += -DJAVA_ARGS='$(JAVA_ARGS)'
+  OTHER_CPPFLAGS += -DLAUNCHER_NAME='"$(LAUNCHER_NAME)"'
+endif # JAVA_ARGS
 
 ifeq ($(PLATFORM), windows)
-ifdef RELEASE
-OTHER_CPPFLAGS += -DVERSION='"$(RELEASE)"'
-endif
-endif
+  ifdef RELEASE
+    OTHER_CPPFLAGS += -DVERSION='"$(RELEASE)"'
+  endif #RELEASE
+endif #PLATFORM
 
 
 ifneq ($(PLATFORM), windows)
-HAVE_GETHRTIME=true
-endif
+  HAVE_GETHRTIME=true
+endif #PLATFORM
 
 ifeq ($(HAVE_GETHRTIME),true)
-OTHER_CPPFLAGS += -DHAVE_GETHRTIME
+  OTHER_CPPFLAGS += -DHAVE_GETHRTIME
 endif
 
 OTHER_INCLUDES += -I$(LAUNCHER_SHARE_SRC)/bin -I$(LAUNCHER_PLATFORM_SRC)/bin
-OTHER_INCLUDES += -I$(SHARE_SRC)/native/java/util/zip/zlib-1.1.3
+ifeq ($(PLATFORM), macosx)
+  OTHER_INCLUDES += -I$(LAUNCHER_SOLARIS_PLATFORM_SRC)/bin
+  ifneq ($(SYSTEM_ZLIB), true)
+    OTHER_INCLUDES += -I$(SHARE_SRC)/native/java/util/zip/zlib-1.1.3
+  endif # SYSTEM_ZLIB
+else # PLATFORM !MACOSX
+  OTHER_INCLUDES += -I$(SHARE_SRC)/native/java/util/zip/zlib-1.1.3
+endif
 
-OTHER_CPPFLAGS += -DPROGNAME='"$(PROGRAM)"'
+OTHER_CPPFLAGS  += -DPROGNAME='"$(PROGRAM)"'
 VERSION_DEFINES += -DFULL_VERSION='"$(FULL_VERSION)"'
 
 VERSION_DEFINES += -DJDK_MAJOR_VERSION='"$(JDK_MAJOR_VERSION)"' \
-		   -DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"'
+                   -DJDK_MINOR_VERSION='"$(JDK_MINOR_VERSION)"'
 
 
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/common/Release-macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,77 @@
+#
+# Copyright (c) 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.
+#
+
+MANBASEDIRS=$(JDK_TOPDIR)/src/bsd/doc $(IMPORTDOCDIR)
+MAN1SUBDIR = man
+JA_DIRNAME=ja_JP.UTF-8
+
+# Defines the release targets for Mac OS X build products
+
+JDK_BUNDLE_DIR = $(ABS_OUTPUTDIR)/j2sdk-bundle/$(THIS_JDK_VERSION).jdk/Contents
+JRE_BUNDLE_DIR = $(ABS_OUTPUTDIR)/j2re-bundle/$(THIS_JDK_VERSION).jre/Contents
+
+MACOSX_SRC	 = $(JDK_TOPDIR)/src/macosx
+
+BUNDLE_ID ?= net.java.openjdk
+BUNLDE_ID_JRE ?= $(BUNDLE_ID).jre
+BUNLDE_ID_JDK ?= $(BUNDLE_ID).jdk
+
+BUNDLE_NAME ?= OpenJDK 7
+BUNDLE_NAME_JRE ?= $(BUNDLE_NAME)
+BUNDLE_NAME_JDK ?= $(BUNDLE_NAME)
+
+BUNDLE_INFO ?= OpenJDK (1.7.0)
+BUNDLE_INFO_JRE ?= $(BUNDLE_INFO)
+BUNDLE_INFO_JDK ?= $(BUNDLE_INFO)
+
+BUNDLE_PLATFORM_VERSION ?= 1.7
+BUNDLE_VERSION ?= 1.7.0
+BUNDLE_VENDOR ?= UNDEFINED
+
+jre-bundle-setup:
+	$(RM) -r $(JRE_BUNDLE_DIR)
+
+jdk-bundle-setup:
+	$(RM) -r $(JDK_BUNDLE_DIR)
+
+jre-bundle-files:
+	$(MKDIR) -p $(JRE_BUNDLE_DIR)/MacOS
+	ln -s ../Home/lib/jli/libjli.dylib $(JRE_BUNDLE_DIR)/MacOS/
+	$(MV) $(JRE_IMAGE_DIR) $(JRE_BUNDLE_DIR)/Home
+	$(SED) -e "s/@@ID@@/$(BUNDLE_ID_JRE)/g" -e "s/@@NAME@@/$(BUNDLE_NAME_JRE)/g" -e "s/@@INFO@@/$(BUNDLE_INFO_JRE)/g" -e "s/@@PLATFORM_VERSION@@/$(BUNDLE_PLATFORM_VERSION)/g" -e "s/@@VERSION@@/$(BUNDLE_VERSION)/g" -e "s/@@VENDOR@@/$(BUNDLE_VENDOR)/g" < $(MACOSX_SRC)/bundle/JRE-Info.plist > $(JRE_BUNDLE_DIR)/Info.plist
+	/usr/bin/SetFile -a B $(JRE_BUNDLE_DIR)/../
+	$(MV) $(ABS_OUTPUTDIR)/j2re-bundle $(JRE_IMAGE_DIR)
+
+jdk-bundle-files:
+	$(MKDIR) -p $(JDK_BUNDLE_DIR)/MacOS
+	ln -s ../Home/jre/lib/jli/libjli.dylib $(JDK_BUNDLE_DIR)/MacOS/
+	$(MV) $(JDK_IMAGE_DIR) $(JDK_BUNDLE_DIR)/Home
+	$(SED) -e "s/@@ID@@/$(BUNDLE_ID_JDK)/g" -e "s/@@NAME@@/$(BUNDLE_NAME_JDK)/g" -e "s/@@INFO@@/$(BUNDLE_INFO_JDK)/g" -e "s/@@PLATFORM_VERSION@@/$(BUNDLE_PLATFORM_VERSION)/g" -e "s/@@VERSION@@/$(BUNDLE_VERSION)/g" -e "s/@@VENDOR@@/$(BUNDLE_VENDOR)/g" < $(MACOSX_SRC)/bundle/JDK-Info.plist > $(JDK_BUNDLE_DIR)/Info.plist
+	/usr/bin/SetFile -a B $(JDK_BUNDLE_DIR)/../
+	$(MV) $(ABS_OUTPUTDIR)/j2sdk-bundle $(JDK_IMAGE_DIR)
+
+EXTRA_IMAGE_TARGETS += jre-bundle-setup jdk-bundle-setup jre-bundle-files jdk-bundle-files
+
+.PHONY: $(EXTRA_JRE_TARGETS) $(EXTRA_IMAGE_TARGETS)
--- a/make/common/Release.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Release.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 1997, 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
@@ -75,6 +75,10 @@
 
 JTG_DOCS            = $(JDK_TOPDIR)/src/solaris/doc
 
+ifeq ($(PLATFORM), macosx)
+  include $(JDK_TOPDIR)/make/common/Release-$(PLATFORM).gmk
+endif
+
 # The base names of all the license and document files for the jdk and jre
 #   (These files get placed in the jdk and jre install images)
 ifdef OPENJDK
@@ -232,11 +236,22 @@
 	@$(ECHO) ">>>Making "$@" @ `$(DATE)` ..."
 
 # Order is important here, trim jre after jdk image is created
+ifeq ($(PLATFORM), macosx)
+
+images:: sanity-images post-sanity-images  \
+	 $(INITIAL_IMAGE_JRE) $(EXTRA_JRE_TARGETS) $(INITIAL_IMAGE_JDK) \
+	 trim-image-jre trim-image-jdk \
+     identify-image-jre identify-image-jdk \
+	 process-image-jre process-image-jdk sec-files sec-files-win jgss-files \
+	 $(EXTRA_IMAGE_TARGETS)
+else
+
 images:: sanity-images post-sanity-images  \
 	 $(INITIAL_IMAGE_JRE) $(INITIAL_IMAGE_JDK) \
 	 trim-image-jre trim-image-jdk \
          identify-image-jre identify-image-jdk \
 	 process-image-jre process-image-jdk sec-files sec-files-win jgss-files 
+endif
 
 # Don't use these
 image-jre:: initial-image-jre trim-image-jre identify-image-jre process-image-jre
@@ -818,6 +833,10 @@
 	    $(BOOT_JAVA_CMD) -jar $(BUILDMETAINDEX_JARFILE) \
 		-o meta-index *.jar
 	@$(CD) $(JRE_IMAGE_DIR)/lib/ext && $(java-vm-cleanup)
+ifeq ($(PLATFORM), macosx)
+	@#install jobjc, apple mac only
+	$(CP) $(OUTPUTDIR)/JObjC.build/JObjC.jar $(JRE_IMAGE_DIR)/lib/JObjC.jar
+endif # macosx
 ifeq ($(PLATFORM), windows)
 	@# Remove certain *.lib files
 	$(CD) $(JRE_IMAGE_DIR)/lib && \
@@ -960,6 +979,10 @@
 	$(RM) $(JDK_IMAGE_DIR)/db/index.html $(JDK_IMAGE_DIR)/db/register.html
 endif
 
+# The launcher source files we need for src.zip
+FILES_launcher = $(wildcard $(SHARE_SRC)/bin/*) \
+                 $(wildcard $(PLATFORM_SRC)/bin/java_md*)
+
 # Standard jdk image
 initial-image-jdk:: initial-image-jdk-setup \
 		    initial-image-jdk-db \
@@ -1046,7 +1069,8 @@
 	@# generated by the more efficient solaris/windows method of copying files.
 	@# So for Linux, make use of the -T option (like Solaris' -I option) of
 	@# obtaining the list of files from a file. MKS tar has no such option.
-  ifeq ($(PLATFORM), linux)
+
+  ifneq (,$(findstring $(PLATFORM), linux macosx))
 	for d in $(SOURCE_DIRS); do \
 	  $(RM) $(ABS_TEMPDIR)/src-files.list; \
 	  ($(CD) $$d &&  \
@@ -1084,20 +1108,7 @@
 	$(RM) $(ABS_TEMPDIR)/src-files.list
 	$(CHMOD) -R +w $(JDK_IMAGE_DIR)/src
 	$(MKDIR) -p $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/java.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/java.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/manifest_info.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/parse_manifest.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/version_comp.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/version_comp.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/wildcard.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/wildcard.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/jli_util.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/jli_util.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/splashscreen_stubs.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(SHARE_SRC)/bin/splashscreen.h $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(PLATFORM_SRC)/bin/java_md.c $(JDK_IMAGE_DIR)/src/launcher
-	$(CP) $(PLATFORM_SRC)/bin/java_md.h $(JDK_IMAGE_DIR)/src/launcher
+	$(CP) $(FILES_launcher) $(JDK_IMAGE_DIR)/src/launcher
 	$(CD) $(JDK_IMAGE_DIR)/src && $(ZIPEXE) -qr ../src.zip *
 	$(RM) -r $(JDK_IMAGE_DIR)/src
 	@#
--- a/make/common/Rules.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/Rules.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -51,12 +51,23 @@
 #
 # All source tree areas for java/properties files (a few may be closed)
 #
-ifdef OPENJDK
-  ALL_CLASSES_SRC = $(SHARE_SRC)/classes $(PLATFORM_SRC)/classes
+ifeq ($(PLATFORM), macosx)
+  ifdef OPENJDK
+    ALL_CLASSES_SRC = $(call JavaSrcDirList,,classes)
+  else
+    # TODO(cpc): maybe we should modify JavaSrcDirList macro instead...
+    ALL_CLASSES_SRC = \
+	  $(CLOSED_SHARE_SRC)/classes $(CLOSED_PLATFORM_SRC)/classes \
+	  $(call JavaSrcDirList,,classes)
+  endif
 else
-  ALL_CLASSES_SRC = \
-	$(CLOSED_SHARE_SRC)/classes $(CLOSED_PLATFORM_SRC)/classes \
-	$(SHARE_SRC)/classes $(PLATFORM_SRC)/classes
+  ifdef OPENJDK
+    ALL_CLASSES_SRC = $(SHARE_SRC)/classes $(PLATFORM_SRC)/classes
+  else
+    ALL_CLASSES_SRC = \
+	  $(CLOSED_SHARE_SRC)/classes $(CLOSED_PLATFORM_SRC)/classes \
+	  $(SHARE_SRC)/classes $(PLATFORM_SRC)/classes
+  endif
 endif
 
 #
@@ -200,8 +211,15 @@
 
 $(CLASSDESTDIR)/%.class: $(GENSRCDIR)/%.java
 	@$(add-java-file)
+
+ifeq ($(PLATFORM), macosx)
+# TODO(cpc): need to document why this is necessary...
+$(CLASSDESTDIR)/%.class: $(JDK_TOPDIR)/src/macosx/classes/%.java
+	@$(add-java-file)
+endif
 $(CLASSDESTDIR)/%.class: $(PLATFORM_SRC)/classes/%.java
 	@$(add-java-file)
+
 $(CLASSDESTDIR)/%.class: $(SHARE_SRC)/classes/%.java
 	@$(add-java-file)
 
--- a/make/common/internal/NativeCompileRules.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/internal/NativeCompileRules.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -176,6 +176,24 @@
     endif
 	@$(check-conventions)
 
+# Obj-C files (Mac OS X only).
+ifeq ($(PLATFORM), macosx)
+$(OBJDIR)/%.$(OBJECT_SUFFIX): %.m
+	@$(prep-target)
+	$(COMPILE.c) $(CC_OBJECT_OUTPUT_FLAG)$@ $(CFLAGS_GPROF) $<
+	@$(check-conventions)
+
+$(OBJDIR)/%.$(OBJECT_SUFFIX): %.mm
+	@$(prep-target)
+	$(COMPILE.cc) $(CC_OBJECT_OUTPUT_FLAG)$@ $(CFLAGS_GPROF) $<
+	@$(check-conventions)
+
+$(OBJDIR)/%.$(OBJECT_SUFFIX): %.c
+	@$(prep-target)
+	$(COMPILE.c) $(CC_OBJECT_OUTPUT_FLAG)$@ $(CFLAGS_GPROF) $<
+	@$(check-conventions)
+endif # PLATFORM
+
 #
 # Quick hack for making the compiler generate just the assembly file.
 #	$ gnumake obj/sparc/myfile.s
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/common/shared/Compiler-llvm.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,59 @@
+#
+# Copyright (c) 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.
+#
+
+#
+# LLVM Compiler settings
+#
+
+ifeq ($(PLATFORM), macosx)
+
+  # Settings specific to Mac OS X
+  ifeq ($(origin CC), default)
+   CC             = $(COMPILER_PATH)llvm-gcc
+  endif
+  CPP             = $(COMPILER_PATH)llvm-gcc -E
+  ifeq ($(origin CXX), default)
+   CXX            = $(COMPILER_PATH)llvm-g++
+  endif
+
+  REQUIRED_CC_VER = 4.2.1
+
+  # Option used to create a shared library
+  SHARED_LIBRARY_FLAG = -Wl,-install_name,@rpath/$(@F) -dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0
+  SUN_COMP_VER := $(shell $(CC) --verbose 2>&1 )
+
+  AR = $(CC)
+  ARFLAGS = -nostdlib -r -arch i386 -arch x86_64 -o
+
+endif
+
+# Get llvm version
+_CC_VER :=$(shell $(CC) -dumpversion 2>&1 )
+CC_VER  :=$(call GetVersion,"$(_CC_VER)")
+
+# Name of compiler
+COMPILER_NAME = LLVM-GCC$(call MajorVersion,$(CC_VER))
+COMPILER_VERSION = $(COMPILER_NAME)
+
--- a/make/common/shared/Defs-java.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Defs-java.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -66,7 +66,12 @@
    -XX:-PrintVMOptions -XX:+UnlockDiagnosticVMOptions -XX:-LogVMOutput
 
 # JVM options
-JAVA_JVM_FLAGS = $(JAVA_HOTSPOT_DISABLE_PRINT_VMOPTIONS)
+# MMM: is headless option necessary?
+ifeq ($(PLATFORM), macosx)
+  JAVA_JVM_FLAGS = $(JAVA_HOTSPOT_DISABLE_PRINT_VMOPTIONS) -Djava.awt.headless=true
+else
+  JAVA_JVM_FLAGS = $(JAVA_HOTSPOT_DISABLE_PRINT_VMOPTIONS)
+endif
 
 ifeq ($(ADD_CLIENT_VM_OPTION), true)
   JAVA_JVM_FLAGS += -client
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/common/shared/Defs-macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,252 @@
+#
+# Copyright (c) 2005, 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.
+#
+
+#
+# Definitions for Bsd.
+#
+
+# Default for COMPILER_WARNINGS_FATAL on Bsd (C & C++ compiler warnings)
+ifndef COMPILER_WARNINGS_FATAL
+  COMPILER_WARNINGS_FATAL=false
+endif
+
+# Bsd should use parallel compilation for best build times
+ifndef COMPILE_APPROACH
+  COMPILE_APPROACH = parallel
+endif
+
+# Indication that we are doing an incremental build.
+#    This may trigger the creation of make depend files.
+ifndef INCREMENTAL_BUILD
+  INCREMENTAL_BUILD = false
+endif
+
+# FullPath just makes sure it never ends with a / and no duplicates
+define FullPath
+$(shell cd $1 2> $(DEV_NULL) && pwd)
+endef
+
+# OptFullPath: Absolute path name of a dir that might not initially exist.
+define OptFullPath
+$(shell if [ "$1" != "" -a -d "$1" ]; then (cd $1 && pwd); else echo "$1"; fi)
+endef
+
+# Location on system where jdk installs might be
+USRJDKINSTANCES_PATH = $(PACKAGE_PATH)
+
+# UNIXCOMMAND_PATH: path to where the most common Unix commands are.
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq "$(origin ALT_UNIXCOMMAND_PATH)" "undefined"
+  UNIXCOMMAND_PATH :=$(call PrefixPath,$(ALT_UNIXCOMMAND_PATH))
+else
+  UNIXCOMMAND_PATH  = /bin/
+endif
+
+# USRBIN_PATH: path to where the most common Unix commands are.
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq "$(origin ALT_USRBIN_PATH)" "undefined"
+  USRBIN_PATH :=$(call PrefixPath,$(ALT_USRBIN_PATH))
+else
+  USRBIN_PATH  = /usr/bin/
+endif
+
+# UNIXCCS_PATH: path to where the Solaris ported UNIX commands can be found
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq "$(origin ALT_UNIXCCS_PATH)" "undefined"
+  UNIXCCS_PATH :=$(call PrefixPath,$(ALT_UNIXCCS_PATH))
+else
+  UNIXCCS_PATH = /usr/ccs/bin/
+endif
+
+# SLASH_JAVA: location of all network accessable files
+ifdef ALT_SLASH_JAVA
+  SLASH_JAVA  :=$(ALT_SLASH_JAVA)
+else
+  SLASH_JAVA  := $(call DirExists,/java,/java,/NOT-SET)
+endif
+
+# JDK_DEVTOOLS_DIR: common path for all the java devtools
+ifdef ALT_JDK_DEVTOOLS_DIR
+  JDK_DEVTOOLS_DIR  =$(ALT_JDK_DEVTOOLS_DIR)
+else
+  JDK_DEVTOOLS_DIR =$(SLASH_JAVA)/devtools
+endif
+
+# COMPILER_PATH: path to where the compiler and tools are installed.
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq "$(origin ALT_COMPILER_PATH)" "undefined"
+  COMPILER_PATH :=$(call PrefixPath,$(ALT_COMPILER_PATH))
+else
+ ifeq ($(OS_VENDOR), Apple)
+  ifndef DEVELOPER_DIR
+   DEVELOPER_DIR = $(shell /usr/bin/xcode-select -print-path)/usr/bin/
+  endif
+  
+  COMPILER_PATH  := $(call DirExists,$(DEVELOPER_DIR),/usr/bin/,/NOT-SET)
+ else
+  COMPILER_PATH  =/usr/bin/
+ endif
+endif
+
+# OPENWIN_HOME: path to where the X11 environment is installed.
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq ($(ALT_OPENWIN_HOME),)
+  OPENWIN_HOME :=$(call PrefixPath,$(ALT_OPENWIN_HOME))
+else
+  OPENWIN_HOME  =$(X11_PATH)
+endif
+
+# DEVTOOLS_PATH: for other tools required for building (such as zip, etc.)
+#  NOTE: Must end with / so that it could be empty, allowing PATH usage.
+ifneq "$(origin ALT_DEVTOOLS_PATH)" "undefined"
+  DEVTOOLS_PATH :=$(call PrefixPath,$(ALT_DEVTOOLS_PATH))
+else
+  DEVTOOLS_PATH =$(PACKAGE_PATH)/bin/
+endif
+
+# _BOOTDIR1: First choice for a Bootstrap JDK, previous released JDK.
+# _BOOTDIR2: Second choice
+ifndef ALT_BOOTDIR
+  _BOOTDIR1  =$(SLASH_JAVA)/re/jdk/$(PREVIOUS_JDK_VERSION)/archive/fcs/binaries/$(PLATFORM)-$(ARCH)
+  _BOOTDIR2  =$(USRJDKINSTANCES_PATH)/jdk$(PREVIOUS_JDK_VERSION)
+endif
+
+# Always build headless on Bsd
+BUILD_HEADLESS = true
+LIBM=-lm
+
+ifeq ($(OS_VENDOR), Apple)
+  _CUPS_HEADERS_PATH=/usr/include
+else
+  _CUPS_HEADERS_PATH=$(PACKAGE_PATH)/include
+endif
+
+# Import JDK images allow for partial builds, components not built are
+#    imported (or copied from) these import areas when needed.
+
+# BUILD_JDK_IMPORT_PATH: location of JDK install trees to import for 
+#   multiple platforms, e.g. windows-i586, solaris-sparc, bsd-586, etc.
+ifdef ALT_BUILD_JDK_IMPORT_PATH
+  BUILD_JDK_IMPORT_PATH  :=$(call FullPath,$(ALT_BUILD_JDK_IMPORT_PATH))
+else
+  BUILD_JDK_IMPORT_PATH   = $(PROMOTED_BUILD_BINARIES)
+endif
+BUILD_JDK_IMPORT_PATH:=$(call AltCheckValue,BUILD_JDK_IMPORT_PATH)
+
+# JDK_IMPORT_PATH: location of JDK install tree (this version) to import
+ifdef ALT_JDK_IMPORT_PATH
+  JDK_IMPORT_PATH  :=$(call FullPath,$(ALT_JDK_IMPORT_PATH))
+else
+  JDK_IMPORT_PATH   = $(BUILD_JDK_IMPORT_PATH)/$(PLATFORM)-$(ARCH)$(_JDK_IMPORT_VARIANT)
+endif
+JDK_IMPORT_PATH:=$(call AltCheckValue,JDK_IMPORT_PATH)
+
+# HOTSPOT_IMPORT_PATH: location of hotspot pre-built files
+ifdef ALT_HOTSPOT_IMPORT_PATH
+  HOTSPOT_IMPORT_PATH :=$(call FullPath,$(ALT_HOTSPOT_IMPORT_PATH))
+else
+  HOTSPOT_IMPORT_PATH =$(JDK_IMPORT_PATH)
+endif
+HOTSPOT_IMPORT_PATH:=$(call AltCheckValue,HOTSPOT_IMPORT_PATH)
+
+# HOTSPOT_CLIENT_PATH: location of client jvm library file.
+ifeq ($(ARCH_DATA_MODEL), 32)
+  ifdef ALT_HOTSPOT_CLIENT_PATH
+    HOTSPOT_CLIENT_PATH :=$(call FullPath,$(ALT_HOTSPOT_CLIENT_PATH))
+  else
+    HOTSPOT_CLIENT_PATH   =$(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/client
+  endif
+  HOTSPOT_CLIENT_PATH:=$(call AltCheckValue,HOTSPOT_CLIENT_PATH)
+endif
+
+# HOTSPOT_SERVER_PATH: location of server jvm library file.
+ifdef ALT_HOTSPOT_SERVER_PATH
+  HOTSPOT_SERVER_PATH :=$(call FullPath,$(ALT_HOTSPOT_SERVER_PATH))
+else
+  HOTSPOT_SERVER_PATH   =$(HOTSPOT_IMPORT_PATH)/$(ARCH_VM_SUBDIR)/server
+endif
+HOTSPOT_SERVER_PATH:=$(call AltCheckValue,HOTSPOT_SERVER_PATH)
+
+# Special define for checking the binaries
+
+# Debug builds should downgrade warnings to just info
+MAPFILE_WARNING-DBG=INFO
+MAPFILE_WARNING-OPT=WARNING
+MAPFILE_WARNING-=WARNING
+MAPFILE_WARNING=$(MAPFILE_WARNING-$(VARIANT))
+
+# Macro to check it's input file for banned dependencies and verify the
+#   binary built properly. Relies on process exit code.
+ifndef CROSS_COMPILE_ARCH
+ifeq ($(OS_VENDOR), Apple)
+define binary_file_verification # binary_file
+( \
+  $(ECHO) "Checking for mapfile use in: $1" && \
+  if [ "`$(NM) -g $1 | $(EGREP) 'SUNWprivate'`" = "" ] ; then \
+    $(ECHO) "WARNING: File was not built with a mapfile: $1"; \
+  fi && \
+  $(ECHO) "Library loads for: $1" && \
+  $(OTOOL) -L $1 && \
+  $(ECHO) "RUNPATH for: $1" && \
+  ( $(OTOOL) -l $1 | $(EGREP) 'path ' ) \
+) || true
+endef
+else
+ifeq ($(OS_VENDOR), OpenBSD)
+define binary_file_verification # binary_file
+( \
+  $(ECHO) "Checking for mapfile use in: $1" && \
+  if [ "`$(OBJDUMP) -T $1 | $(EGREP) '[0-9a-f]* g *DF \.text.*SUNWprivate'`" = "" ] ; then \
+    $(ECHO) "$(MAPFILE_WARNING): File was not built with a mapfile: $1"; \
+  fi && \
+  $(ECHO) "Library loads for: $1" && \
+  $(LDD) $1 && \
+  $(ECHO) "RUNPATH for: $1" && \
+  ( $(READELF) -d $1 | $(EGREP) 'NEEDED|RUNPATH|RPATH' ) \
+) || true
+endef
+else
+define binary_file_verification # binary_file
+( \
+  $(ECHO) "Checking for mapfile use in: $1" && \
+  if [ "`$(NM) -D -g --defined-only $1 | $(EGREP) 'SUNWprivate'`" = "" ] ; then \
+    $(ECHO) "$(MAPFILE_WARNING): File was not built with a mapfile: $1"; \
+  fi && \
+  $(ECHO) "Library loads for: $1" && \
+  $(LDD) $1 && \
+  $(ECHO) "RUNPATH for: $1" && \
+  ( $(READELF) -d $1 | $(EGREP) 'NEEDED|RUNPATH|RPATH' ) \
+)
+endef
+endif # OS_VENDOR == OpenBSD
+endif # OS_VENDOR == Apple
+else
+define binary_file_verification 
+( \
+  $(ECHO) "Skipping binary file verification for cross-compile build" \
+)
+endef
+endif
+
--- a/make/common/shared/Defs-utils.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Defs-utils.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -67,6 +67,13 @@
   UTILS_DEVTOOL_PATH=$(DEVTOOLS_PATH)
 endif
 
+ifeq ($(PLATFORM),macosx)
+  UTILS_COMMAND_PATH=$(UNIXCOMMAND_PATH)
+  UTILS_USR_BIN_PATH=$(USRBIN_PATH)
+  UTILS_CCS_BIN_PATH=$(USRBIN_PATH)
+  UTILS_DEVTOOL_PATH=$(DEVTOOLS_PATH)
+endif
+
 # Utilities
 ifdef CROSS_COMPILE_ARCH
   AR             = $(COMPILER_PATH)ar
@@ -126,6 +133,7 @@
 MSGFMT         = $(UTILS_USR_BIN_PATH)msgfmt
 MV             = $(UTILS_COMMAND_PATH)mv
 NAWK           = $(UTILS_USR_BIN_PATH)nawk
+OTOOL          = $(UTILS_USR_BIN_PATH)otool
 PKGMK          = $(UTILS_COMMAND_PATH)pkgmk
 PRINTF         = $(UTILS_USR_BIN_PATH)printf
 PWD            = $(UTILS_COMMAND_PATH)pwd
@@ -220,3 +228,26 @@
   ECHO           = /usr/bin/echo
 endif
 
+ifeq ($(PLATFORM), macosx) 
+  BASENAME     = $(UTILS_USR_BIN_PATH)basename
+  EGREP        = $(UTILS_USR_BIN_PATH)egrep
+  EXPR         = $(UTILS_COMMAND_PATH)expr
+  FMT          = $(UTILS_USR_BIN_PATH)fmt
+  GREP         = $(UTILS_USR_BIN_PATH)grep
+  GUNZIP       = $(UTILS_USR_BIN_PATH)gunzip
+  ID           = $(UTILS_USR_BIN_PATH)id
+  MSGFMT       = $(UTILS_DEVTOOL_PATH)msgfmt
+  SED          = $(UTILS_USR_BIN_PATH)sed
+  SORT         = $(UTILS_USR_BIN_PATH)sort
+  TEST         = $(UTILS_COMMAND_PATH)test
+  TOUCH        = $(UTILS_USR_BIN_PATH)touch
+  TRUE         = $(UTILS_USR_BIN_PATH)true
+  UNAME        = $(UTILS_USR_BIN_PATH)uname
+  NAWK         = $(UTILS_USR_BIN_PATH)awk
+  UNZIPSFX     = $(UTILS_USR_BIN_PATH)unzipsfx
+  ZIPEXE       = $(UTILS_USR_BIN_PATH)zip
+  CPIO         = $(UTILS_USR_BIN_PATH)cpio
+  TAR          = $(UTILS_USR_BIN_PATH)tar
+  # Builtin shell command, no -e option needed
+  ECHO         = echo
+endif
--- a/make/common/shared/Defs-versions.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Defs-versions.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -44,6 +44,11 @@
   override CC_VERSION = gcc
 endif
 
+# Mac OS X uses LLVM by default
+ifeq ($(PLATFORM), macosx)
+  override CC_VERSION = llvm
+endif
+
 ##########################################################################
 #
 # List of JDK official minimum, expected, or required versions:
@@ -164,6 +169,17 @@
   endif
 endif
 
+# Mac specific
+ifeq ($(PLATFORM), macosx)
+  REQUIRED_OS_NAME            = Darwin
+  REQUIRED_OS_VERSION         = 11.2
+  REQUIRED_OS_VARIANT_NAME    = MacOSX
+  REQUIRED_OS_VARIANT_VERSION = 10.7.2
+  REQUIRED_COMPILER_NAME      = GCC4
+  REQUIRED_COMPILER_VERSION   = GCC4
+  REQUIRED_CC_VER             = 4.2.1
+endif
+
 # Windows specific
 ifeq ($(PLATFORM), windows)
   REQUIRED_OS_NAME            = Windows
--- a/make/common/shared/Defs.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Defs.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -177,6 +177,19 @@
   fi)
 endef
 
+# Expand SRCDIR_LIST, which is used to automatically include various
+# platform and shared sources/headers.  This is mainly useful for the
+# Mac OS X build, which pulls its platform sources from the solaris and/or
+# macosx trees, depending on the component.
+ifeq ($(PLATFORM), macosx)
+  define JavaSrcDirList
+  $(JAVA_SRCDIR_LIST:%=$1$(JDK_TOPDIR)/%/$2)
+  endef
+  define NativeSrcDirList
+  $(NATIVE_SRCDIR_LIST:%=$1$(JDK_TOPDIR)/%/$2)
+  endef
+endif
+
 # Make sure certain variables are non-empty at this point
 _check_values:=\
 $(call CheckValue,ARCH,),\
--- a/make/common/shared/Platform.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Platform.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -224,6 +224,80 @@
   MB_OF_MEMORY := $(shell free -m | fgrep Mem: | awk '{print $$2;}' )
 endif
 
+ifeq ($(SYSTEM_UNAME), Darwin)
+  PLATFORM = macosx
+  OS_NAME = darwin
+  OS_VENDOR = Apple
+  GB_OF_MEMORY := $(shell system_profiler SPHardwareDataType | fgrep Memory: | awk '{print $$2}')
+  MB_OF_MEMORY := $(shell expr ${GB_OF_MEMORY} '*' 1024)
+endif
+
+# Platform settings specific to BSD/Mac OS X
+ifeq ($(PLATFORM), macosx)
+  OS_VERSION := $(shell uname -r)
+
+  # Arch and OS name/version
+  # Darwin x86 builds are i386/amd64 universal by default.
+  # Allow arch to be set from the environment to avoid this.
+  ifeq ($(origin ARCH), undefined)
+   ifeq ($(PLATFORM), macosx)
+# MMM: revisit when hotspot producinging universal libs
+#   mach := universal
+    mach := x86_64
+   else
+    mach := $(shell uname -m)
+   endif
+  else
+   mach := $(ARCH)
+  endif
+
+  archExpr = case "$(mach)" in \
+                i[3-9]86) \
+                    echo i586 \
+                    ;; \
+                sparc64) \
+                    echo sparcv9 \
+                    ;; \
+                sparc*) \
+                    echo sparc \
+                    ;; \
+                x86_64) \
+                    echo amd64 \
+                    ;; \
+                "Power Macintosh") \
+                    echo ppc \
+                    ;; \
+                *) \
+                    echo $(mach) \
+                    ;; \
+      esac
+  ARCH        := $(shell $(archExpr) )
+  ARCH_FAMILY := $(ARCH)
+
+  # i586, sparc, and ppc are 32 bit, amd64 and sparc64 are 64
+  # ARCH_DATA_MODEL does not exactly mean anything in universal
+  # but it has to be one or the other, so pick 32
+  ifneq (,$(findstring $(ARCH), i586 sparc ppc universal))
+    ARCH_DATA_MODEL=32
+  else
+    ARCH_DATA_MODEL=64
+  endif
+
+  # Need to maintain the jre/lib/i386 location for 32-bit Intel
+  ifeq ($(ARCH), i586)
+    LIBARCH = i386
+  else
+    LIBARCH = $(ARCH)
+  endif
+
+  # Value of Java os.arch property
+  ARCHPROP  = $(LIBARCH)
+
+  # Suffix for file bundles used in previous release
+  BUNDLE_FILE_SUFFIX=.tar.gz
+  # How much RAM does this machine have:
+endif
+
 # Windows with and without CYGWIN will be slightly different
 ifeq ($(SYSTEM_UNAME), Windows_NT)
   PLATFORM = windows
@@ -425,6 +499,22 @@
   ARCH_VM_SUBDIR=jre/lib/$(LIBARCH)
 endif
 
+# Darwin-specific Overrides
+ifeq ($(SYSTEM_UNAME),Darwin)
+  # The suffix applied to runtime libraries
+  LIBRARY_SUFFIX = dylib
+  # The suffix applied to link libraries
+  ifeq ($(ARCH), universal)
+    LIB_SUFFIX = o
+  else
+    LIB_SUFFIX = a
+  endif
+
+  ifeq ($(PLATFORM), macosx)
+  	ARCH_VM_SUBDIR=jre/lib
+  endif
+endif
+
 # Machines with 512Mb or less of real memory are considered low memory
 #    build machines and adjustments will be made to prevent excessing
 #    system swapping during the build.
--- a/make/common/shared/Sanity.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/common/shared/Sanity.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -113,6 +113,13 @@
   ALSA_VERSION := $(call GetVersion,$(_ALSA_VERSION))
 endif
 
+ifeq ($(PLATFORM), macosx)
+  # What kind of system we are using
+  OS_VERSION := $(shell uname -r)
+  OS_VARIANT_NAME := MacOSX
+  OS_VARIANT_VERSION := $(shell sw_vers -productVersion)
+endif
+
 ifeq ($(PLATFORM), windows)
   # Windows 2000 is 5.0, Windows XP is 5.1, Windows 2003 is 5.2
   #    Assume 5.0 (Windows 2000) if systeminfo does not help
@@ -839,8 +846,10 @@
 
 ######################################################
 # Check for existence of DEVTOOLS_PATH
+# All needed tools come with base system on Apple
 ######################################################
 sane-devtools_path:
+ifneq ($(OS_VENDOR), Apple)
 	@if [ "$(DEVTOOLS_PATH)" != "" -a ! -r "$(DEVTOOLS_PATH)" ]; then \
 	  $(ECHO) "ERROR: You do not have a valid DEVTOOLS_PATH setting. \n" \
 	    "      Please check your access to \n" \
@@ -848,6 +857,7 @@
 	    "      and/or check your value of ALT_DEVTOOLS_PATH. \n" \
 	    "" >> $(ERROR_FILE) ; \
 	fi
+endif
 
 ######################################################
 # Check for existence of MS_RUNTIME_LIBRARIES
--- a/make/docs/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/docs/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -70,6 +70,8 @@
 #    WARNING: This could cause thrashing on low memory machines.
 ifeq ($(ARCH_DATA_MODEL),64)
   MAX_VM_MEMORY = 1024
+else ifeq ($(ARCH),universal)
+  MAX_VM_MEMORY = 1024
 else
   MAX_VM_MEMORY = 512
 endif
--- a/make/docs/NON_CORE_PKGS.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/docs/NON_CORE_PKGS.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -88,6 +88,13 @@
 
 SCTPAPI_PKGS     = com.sun.nio.sctp
 
+ifeq ($(PLATFORM), macosx)
+APPLE_EXT_PKGS   = com.apple.concurrent   \
+                   com.apple.eawt         \
+                   com.apple.eawt.event   \
+                   com.apple.eio
+endif
+
 # non-core packages in rt.jar
 NON_CORE_PKGS    = $(DOMAPI_PKGS) \
                    $(MGMT_PKGS) \
@@ -97,5 +104,6 @@
                    $(OLD_JSSE_PKGS) \
                    $(HTTPSERVER_PKGS) \
                    $(SMARTCARDIO_PKGS) \
-                   $(SCTPAPI_PKGS)
+                   $(SCTPAPI_PKGS) \
+                   $(APPLE_EXT_PKGS)
 
--- a/make/java/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -57,6 +57,10 @@
   SUBDIRS += jexec
 endif # PLATFORM
 
+ifeq ($(PLATFORM), macosx)
+  SUBDIRS += jobjc
+endif # PLATFORM
+
 include $(BUILDDIR)/common/Subdirs.gmk
 
 all build clean clobber::
--- a/make/java/instrument/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/instrument/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -102,6 +102,16 @@
   # equivalent of strcasecmp is stricmp on Windows
   CPPFLAGS_COMMON += -Dstrcasecmp=stricmp
 else
+ifneq (,$(findstring $(PLATFORM), macosx))
+  ifneq ($(ARCH), universal)
+    LDFLAGS += -Wl,-all_load
+  endif
+  LDFLAGS += $(OUTPUTDIR)/tmp/java/jli/$(OBJDIRNAME)/static/libjli.a
+  OTHER_LDLIBS += -liconv
+  ifeq ($(SYSTEM_ZLIB), true)
+    OTHER_LDLIBS += -lz
+  endif
+else
   LDFLAGS += -L $(LIBDIR)/$(LIBARCH)/jli
   OTHER_LDLIBS += -ljli
   OTHER_LDLIBS += -ldl 
@@ -114,6 +124,11 @@
     LDFLAGS += -Wl,-rpath -Wl,\$$ORIGIN/jli
   endif
 endif
+endif
+
+ifeq ($(PLATFORM), macosx)
+  LDFLAGS += -framework Cocoa -framework Security -framework ApplicationServices
+endif
 
 #
 # Library to compile.
--- a/make/java/java/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/java/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -94,6 +94,15 @@
 
 endif # PLATFORM
 
+ifeq ($(PLATFORM), macosx)
+FILES_c    +=   java_props_macosx.c
+FILES_java += 	java/util/prefs/MacOSXPreferences.java \
+		java/util/prefs/MacOSXPreferencesFile.java \
+		java/util/prefs/MacOSXPreferencesFactory.java
+
+CFLAGS_$(VARIANT)/java_props_md.o = -Os -x objective-c
+endif
+
 #
 # Make sure first rule does 'all'
 #
@@ -165,8 +174,10 @@
 # Is the altzone extern documented in ctime(3C) available?
 #
 ifneq ($(PLATFORM), windows)
+ifneq ($(PLATFORM), macosx)
 HAVE_ALTZONE=true
 endif
+endif
 
 ifeq ($(HAVE_ALTZONE),true)
 OTHER_CPPFLAGS += -DHAVE_ALTZONE
@@ -205,8 +216,14 @@
 		       -libpath:$(OBJDIR)/../../../verify/$(OBJDIRNAME) verify.lib \
 		       shell32.lib delayimp.lib /DELAYLOAD:shell32.dll
 else
-OTHER_LDLIBS += $(JVMLIB) -lverify $(LIBSOCKET) $(LIBNSL) $(LIBSCF) -ldl \
+OTHER_LDLIBS += $(JVMLIB) -lverify $(LIBSOCKET) $(LIBNSL) $(LIBSCF) $(LIBDL) \
 		-L$(OBJDIR)/../../../fdlibm/$(OBJDIRNAME) -lfdlibm.$(ARCH)
+ifeq ($(PLATFORM), macosx)
+OTHER_LDLIBS += \
+        -framework CoreFoundation \
+        -framework Security \
+        -framework SystemConfiguration
+endif
 endif
 
 #
@@ -243,8 +260,15 @@
 # UNIXProcess.java is different for solaris and linux. We need to copy
 # the correct UNIXProcess.java over to $(GENSRCDIR)/java/lang/.
 
-$(GENSRCDIR)/java/lang/UNIXProcess.java: \
+ifeq ($(PLATFORM), macosx)
+PLATFORM_UNIX_PROCESS = \
+    $(PLATFORM_SRC)/classes/java/lang/UNIXProcess.java.bsd
+else
+PLATFORM_UNIX_PROCESS = \
     $(PLATFORM_SRC)/classes/java/lang/UNIXProcess.java.$(PLATFORM)
+endif
+
+$(GENSRCDIR)/java/lang/UNIXProcess.java: $(PLATFORM_UNIX_PROCESS)
 	$(install-file)
 
 clean:: 
--- a/make/java/java/genlocales.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/java/genlocales.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -73,6 +73,26 @@
 LOCALEGEN_SH=localegen.sh
 RESOURCE_NAMES="FormatData CollationData TimeZoneNames LocaleNames CurrencyNames CalendarData"
 
+
+# On MacOSX sed does not enter a newline as it does on other platforms with the same pattern
+# Using awk instead
+
+ifeq ($(PLATFORM), macosx)
+
+$(LocaleDataMetaInfo_Dest):$(LocaleDataMetaInfo_Src) $(LOCALEGEN_SH)
+	@$(RM) $@.tmp.euro $@.tmp.noneuro;
+	@$(prep-target) 
+	@$(ECHO) $(Euro_Resources_properties) | $(NAWK) 'gsub(/.properties/,"\n") {print}'  > $@.tmp.euro;
+	@$(ECHO) $(Euro_Resources_java) | $(NAWK) 'gsub(/.java/,"\n") {print}' >> $@.tmp.euro;
+	@$(ECHO) $(NonEuro_Resources_properties) | $(NAWK) 'gsub(/.properties/,"\n") {print}' > $@.tmp.noneuro;
+	@$(ECHO) $(NonEuro_Resources_java) | $(NAWK) 'gsub(/.java/,"\n") {print}' >> $@.tmp.noneuro;
+	NAWK="$(NAWK)" SED="$(SED)" SORT="$(SORT)" \
+	     $(SH) $(LOCALEGEN_SH) $(RESOURCE_NAMES) $@.tmp.euro \
+		$@.tmp.noneuro $< $@
+	@$(RM) $@.tmp.euro $@.tmp.noneuro;
+
+else
+
 $(LocaleDataMetaInfo_Dest):$(LocaleDataMetaInfo_Src) $(LOCALEGEN_SH)
 	@$(RM) $@.tmp.euro $@.tmp.noneuro;
 	@$(prep-target) 
@@ -84,6 +104,7 @@
 	     $(SH) $(LOCALEGEN_SH) $(RESOURCE_NAMES) $@.tmp.euro \
 		$@.tmp.noneuro $< $@
 	@$(RM) $@.tmp.euro $@.tmp.noneuro;
+endif
 	
 genlocales : $(LocaleDataMetaInfo_Dest)  
 
--- a/make/java/java/localegen.sh	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/java/localegen.sh	Thu Feb 02 13:39:04 2012 -0800
@@ -52,12 +52,13 @@
 
 sed_script="$SED -e \"s@^#warn .*@// -- This file was mechanically generated: Do not edit! -- //@\" " 
 
+# MMM: check two sed script changes below work other platforms than mac
 for FILE in $RESOURCE_NAMES 
 do
     getlocalelist $FILE $EURO_FILES_LIST
-    sed_script=$sed_script"-e \"s/#"$FILE"_EuroLocales#/$localelist/g\" "
+    sed_script=$sed_script"-e \"s@#"$FILE"_EuroLocales#@$localelist@g\" "
     getlocalelist $FILE $NONEURO_FILES_LIST
-    sed_script=$sed_script"-e \"s/#"$FILE"_NonEuroLocales#/$localelist/g\" "
+    sed_script=$sed_script"-e \"s@#"$FILE"_NonEuroLocales#@$localelist@g\" "
 done
 
 sed_script=$sed_script"$INPUT_FILE > $OUTPUT_FILE"
--- a/make/java/java_hprof_demo/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/java_hprof_demo/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -83,7 +83,7 @@
 ifeq ($(PLATFORM), windows)
   OTHER_LDLIBS += wsock32.lib winmm.lib
 else
-  OTHER_LDLIBS += $(LIBSOCKET) $(LIBNSL) -ldl
+  OTHER_LDLIBS += $(LIBSOCKET) $(LIBNSL) $(LIBDL)
 endif
 
 #
--- a/make/java/jli/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/jli/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2005, 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
@@ -44,92 +44,121 @@
 
 include $(BUILDDIR)/common/Defs.gmk
 
-ZIP_SRC = $(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+ifneq ($(SYSTEM_ZLIB),true)
+  ZIP_SRC = $(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+endif #SYSTEM_ZLIB
 LAUNCHER_SHARE_SRC = $(SHARE_SRC)/bin
-LAUNCHER_PLATFORM_SRC = $(PLATFORM_SRC)/bin
+
+# set the platform specific directory for macosx, also this platform shares
+# substantial family ties with its siblings (solaris and linux), thus we add
+# solaris src path to its compilation dependencies.
+ifeq ($(PLATFORM), macosx)
+ LAUNCHER_PLATFORM_SRC = $(BUILDDIR)/../src/macosx/bin
+ LAUNCHER_SOLARIS_PLATFORM_SRC  = $(BUILDDIR)/../src/solaris/bin
+else # !MACOSX
+ LAUNCHER_PLATFORM_SRC = $(PLATFORM_SRC)/bin
+endif #PLATFORM
 
 ifeq ($(ZERO_BUILD), true)
-ERGO_FAMILY=zero
-else
-ifeq ($(ARCH_FAMILY), amd64)
-ERGO_FAMILY=i586
-else
-ERGO_FAMILY=$(ARCH_FAMILY)
-endif
-endif
-
+  ERGO_FAMILY=zero
+else # !ZERO_BUILD
+  ifneq (,$(findstring $(ARCH_FAMILY), amd64 x86_64))
+    ERGO_FAMILY=i586
+  else # !X86 FAMILY
+    ERGO_FAMILY=$(ARCH_FAMILY)
+  endif #ARCH_FAMILY
+endif # ZERO_BUILD
 
 #
 # Files to compile.
 #
-FILES_c = \
-	java.c \
-	splashscreen_stubs.c \
-	java_md.c \
-	parse_manifest.c \
-	version_comp.c \
-	wildcard.c \
-	jli_util.c \
-	inflate.c \
-	inftrees.c \
-	inffast.c \
-	zadler32.c \
-	zcrc32.c \
-	zutil.c
+FILES_c = java.c \
+          splashscreen_stubs.c \
+          parse_manifest.c \
+          version_comp.c \
+          wildcard.c \
+          jli_util.c
 
-ifneq ($(PLATFORM), windows)
-  FILES_c += ergo.c 
-  ERGO_ARCH_FILE = ergo_$(ERGO_FAMILY).c
-  # if the architecture specific ergo file exists then
-  # use it, else use the generic definitions from ergo.c
-  ifneq ($(wildcard $(LAUNCHER_PLATFORM_SRC)/$(ERGO_ARCH_FILE)),)
-    FILES_c += $(ERGO_ARCH_FILE)
-  else
-    OTHER_CPPFLAGS += -DUSE_GENERIC_ERGO
-  endif
-endif
+ifneq ($(SYSTEM_ZLIB),true)
+  FILES_c += inflate.c \
+             inftrees.c \
+             inffast.c \
+             zadler32.c \
+             zcrc32.c \
+             zutil.c
+endif # SYSTEM_ZLIB
+
+# add platform specific files
+ifeq ($(PLATFORM), windows)
+  FILES_c += java_md.c
+else # NIXES
+  FILES_c += java_md_common.c
+  ifeq ($(PLATFORM), macosx)
+    FILES_c += java_md_macosx.c
+  else # SOLARIS/LINUX
+    FILES_c += java_md_solinux.c
+    FILES_c += ergo.c 
+    ERGO_ARCH_FILE = ergo_$(ERGO_FAMILY).c
+    # if the architecture specific ergo file exists then
+    # use it, else use the generic definitions from ergo.c
+    ifneq ($(wildcard $(LAUNCHER_PLATFORM_SRC)/$(ERGO_ARCH_FILE)),)
+      FILES_c += $(ERGO_ARCH_FILE)
+    else # !ERGO_ARCH_FILE
+      OTHER_CPPFLAGS += -DUSE_GENERIC_ERGO
+    endif # ERGO_ARCH_FILE
+  endif #MACOSX
+endif #WINDOWS
 
 # Names of arch directories
 LIBARCH_DEFINES = -DLIBARCHNAME='"$(LIBARCH)"'
 ifeq ($(PLATFORM), solaris)
   LIBARCH_DEFINES += -DLIBARCH32NAME='"$(LIBARCH32)"'
   LIBARCH_DEFINES += -DLIBARCH64NAME='"$(LIBARCH64)"'
-endif
+endif # PLATFORM
 
-OTHER_CPPFLAGS += $(LIBARCH_DEFINES)
-
+ifeq ($(PLATFORM), macosx)
+  OTHER_CPPFLAGS += $(LIBARCH_DEFINES) -DPACKAGE_PATH=\"$(PACKAGE_PATH)\"
+else # ! MACOSX
+  OTHER_CPPFLAGS += $(LIBARCH_DEFINES)
+endif #PLATFORM
 
 ifneq ($(PLATFORM), windows)	# UNIX systems
-        LD_RUNPATH_EXTRAS += ..
-	LIB_LOCATION = $(LIBDIR)/$(LIBARCH)/jli
-	# Note: its important to keep this order meaning -lc is the
-	# last library otherwise it could cause compatibility issues
-	# by pulling in SUNW_private symbols from libc
-	LDLIBS = -ldl -lc
-ifeq ($(USE_PTHREADS),true)
-	LDLIBS += -lpthread
-endif # USE_PTHREADS 
+  ifeq ($(PLATFORM), macosx)
+    LIB_LOCATION = $(LIBDIR)/jli
+  else # SOLARIS/LINUX
+    LD_RUNPATH_EXTRAS += ..
+    LIB_LOCATION = $(LIBDIR)/$(LIBARCH)/jli
+    # Note: it is important to keep this order, meaning -lc as the
+    # last library, otherwise it could cause compatibility issues
+    # by pulling in SUNW_private symbols from libc
+    LDLIBS = -ldl -lc
+    ifeq ($(USE_PTHREADS),true)
+      LDLIBS += -lpthread
+    endif # USE_PTHREADS 
+  endif # PLATFORM
 endif # PLATFORM
 
 ifeq ($(PLATFORM), windows)
-	EXTRA_LIBS = advapi32.lib \
-		     comctl32.lib \
-		     user32.lib
-
-	JAVALIB =
-	OTHER_LCF =  -export:JLI_Launch \
-		     -export:JLI_ManifestIterate \
-		     -export:JLI_SetTraceLauncher \
-		     -export:JLI_ReportErrorMessage \
-		     -export:JLI_ReportErrorMessageSys \
-		     -export:JLI_ReportMessage \
-		     -export:JLI_ReportExceptionDescription
-
-endif
+  EXTRA_LIBS = advapi32.lib \
+               comctl32.lib \
+               user32.lib
+  JAVALIB =
+  OTHER_LCF = -export:JLI_Launch \
+              -export:JLI_ManifestIterate \
+              -export:JLI_SetTraceLauncher \
+              -export:JLI_ReportErrorMessage \
+              -export:JLI_ReportErrorMessageSys \
+              -export:JLI_ReportMessage \
+              -export:JLI_ReportExceptionDescription
+endif # PLATFORM
 
 OTHER_INCLUDES += -I$(LAUNCHER_SHARE_SRC)
 OTHER_INCLUDES += -I$(LAUNCHER_PLATFORM_SRC)
-OTHER_INCLUDES += -I$(ZIP_SRC)
+ifneq ($(SYSTEM_ZLIB),true)
+  OTHER_INCLUDES += -I$(ZIP_SRC)
+else # !SYSTEM_ZLIB
+  LDLIBS += -lz
+endif # SYSTEM_ZLIB
 
 #
 # Library to compile.
@@ -150,18 +179,52 @@
 # library.
 #
 ifeq ($(PLATFORM), windows)
+  STATIC_LIBRARY = $(OBJDIR)/static/$(LIBPREFIX)$(LIBRARY).lib
 
-STATIC_LIBRARY = $(OBJDIR)/static/$(LIBPREFIX)$(LIBRARY).lib
-
-$(STATIC_LIBRARY): $(FILES_o)
+  $(STATIC_LIBRARY): $(FILES_o)
 	@$(prep-target)
 	$(LIBEXE) -nologo -out:$@ $(FILES_o)
 
+  library:: $(STATIC_LIBRARY)
+endif # PLATFORM
+
+ifeq ($(PLATFORM), macosx)
+  # Some Obj-C code is embedded in java_md_macosx.c, we stipulate so, using
+  # "-x" option. Not doing so will cause the compiler to choose the language
+  # based on the filename suffix, also "-Os" optimizes the file for size.
+  CFLAGS_$(VARIANT)/java_md_macosx.o = -Os -x objective-c
+  # Needed for linking the various launchers
+  LDFLAGS += -framework Cocoa -framework Security \
+             -framework ApplicationServices
+  # Add solaris sources containing common logic to the header path
+  OTHER_INCLUDES += -I$(LAUNCHER_SOLARIS_PLATFORM_SRC)
+endif # PLATFORM
+
+STATIC_LIBRARY_DIR = $(OBJDIR)/static
+STATIC_LIBRARY_NAME = lib$(LIBRARY).a
+STATIC_LIBRARY = $(STATIC_LIBRARY_DIR)/$(STATIC_LIBRARY_NAME)
+
+$(STATIC_LIBRARY_DIR): | $(OBJDIR)
+	@$(MKDIR) $(STATIC_LIBRARY_DIR)
+
+$(STATIC_LIBRARY): $(STATIC_LIBRARY_DIR)
+	@$(prep-target)
+	$(AR) $(ARFLAGS) $@ $(FILES_o)
+
 library:: $(STATIC_LIBRARY)
 
-endif	# PLATFORM
-
-#
-# Add to ambient vpath so we pick up the library files
-#
-vpath %.c $(LAUNCHER_SHARE_SRC) $(ZIP_SRC) $(LAUNCHER_PLATFORM_SRC)
+vpath %.c $(LAUNCHER_SHARE_SRC) $(LAUNCHER_PLATFORM_SRC)
+ifneq ($(SYSTEM_ZLIB),true)
+  vpath %.c $(ZIP_SRC)
+else # !SYSTEM_ZLIB
+  #
+  # Add to ambient vpath so we pick up the library files, for macos we add 
+  # solaris sources which contains the common logic for all nixes
+  #
+  ifeq ($(PLATFORM), macosx)
+    vpath %.c $(LAUNCHER_SHARE_SRC) $(ZIP_SRC) $(LAUNCHER_PLATFORM_SRC) \
+          $(LAUNCHER_SOLARIS_PLATFORM_SRC)
+  else # !MACOSX
+    vpath %.c $(LAUNCHER_SHARE_SRC) $(ZIP_SRC) $(LAUNCHER_PLATFORM_SRC)
+  endif # MACOSX
+endif # SYSTEM_LIB
--- a/make/java/jli/mapfile-vers	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/jli/mapfile-vers	Thu Feb 02 13:39:04 2012 -0800
@@ -25,6 +25,7 @@
 
 # Define public interface.
 
+# MMM: Three JNI funcs added for Mac. Check this out!
 SUNWprivate_1.1 {
 	global:
 		JLI_Launch;
@@ -34,6 +35,9 @@
 		JLI_ReportErrorMessageSys;
 		JLI_ReportMessage;
 		JLI_ReportExceptionDescription;
+#		JNI_CreateJavaVM;
+#		JNI_GetCreatedJavaVMs;
+#		JNI_GetDefaultJavaVMInitArgs;
 	local:
 		*;
 };
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/java/jobjc/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,73 @@
+#
+# Copyright (c) 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.
+#
+
+#
+# Makefile for building jobjc
+
+BUILDDIR = ../..
+include $(BUILDDIR)/common/Defs.gmk
+SRCDIR = $(JDK_TOPDIR)/src/macosx/native/jobjc
+
+ifeq ($(PLATFORM),macosx)
+
+# FRAMEWORKS for which we want to build bridge support
+FRAMEWORKS = Foundation CoreFoundation AppKit
+
+# metadata stuff
+GEN_DIR = $(OUTPUTDIR)/bridge_metadata
+STABLE_GEN_DIR = $(OUTPUTDIR)/stable_bridge_metadata
+STABLE_METADATA_FILES = $(addsuffix Full.bridgesupport,$(addprefix $(STABLE_GEN_DIR)/,$(FRAMEWORKS)))
+
+# source files
+CORE_SRC = $(shell $(FIND) $(SRCDIR) -type f -name "*.hs" -or -name "*.java" -or -name "*.m" -or -name "*.h" -print)
+GENERATOR_SRC = $(shell $(FIND) $(SRCDIR) -type f -name "*.java" -print)
+ADDITIONS_SRC = $(shell $(FIND) $(SRCDIR) -type f -name "*.java" -or -name "*.m" -or -name "*.h" -print)
+BUILD_SRC = $(SRCDIR)/JObjC.xcodeproj/project.pbxproj $(SRCDIR)/bridgesupport.gmk $(SRCDIR)/build.xml $(SRCDIR)/extract_classes.pl $(SRCDIR)/run-and-write-if-okay $(SRCDIR)/rungen $(SRCDIR)/runjava
+
+# jobjc products for jdk
+BUILT_DYLIB = $(OUTPUTDIR)/JObjC.dst/Debug/libJObjC.dylib
+BUILT_JAR = $(OUTPUTDIR)/JObjC.build/JObjC.jar
+
+$(GEN_DIR):
+	mkdir -p $(GEN_DIR)
+
+stabilize: $(GEN_DIR)
+	@echo Updating bridge support in $(GEN_DIR)
+	($(CD) $(GEN_DIR); $(MAKE) STABLE_GEN_DIR="$(STABLE_GEN_DIR)" FRAMEWORKS="$(FRAMEWORKS)" -f $(SRCDIR)/bridgesupport.gmk all)
+
+$(STABLE_METADATA_FILES): stabilize
+
+$(BUILT_DYLIB) $(BUILT_JAR): $(STABLE_METADATA_FILES) $(CORE_SRC) $(GENERATOR_SRC) $(ADDITIONS_SRC) $(BUILD_SRC)
+	@echo JObjC dylib or jar out of data wrt FRAMEWORKS '(' $(FRAMEWORKS) ')' or JObjC source '(' core, generator, additions, build ')'
+	@echo Running ant with java_home set to ${ALT_BOOTDIR}
+	(cd $(SRCDIR); OBJROOT="$(OUTPUTDIR)/JObjC.build" DSTROOT="$(OUTPUTDIR)/JObjC.dst" JAVA_HOME=${ALT_BOOTDIR} STABLE_GEN_DIR="$(STABLE_GEN_DIR)" /usr/bin/ant -verbose all)
+
+all: $(BUILD_DYLIB) $(BUILT_JAR)
+	$(CP) $(BUILT_DYLIB) $(LIB_LOCATION)/libJObjC.dylib
+
+clean clobber::
+	(cd $(SRCDIR); export OBJROOT=$(OUTPUTDIR)/JObjC.build; export DSTROOT=$(OUTPUTDIR)/JObjC.dst; /usr/bin/ant clean)
+
+endif
--- a/make/java/jvm/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/jvm/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -43,7 +43,12 @@
 $(PLATFORM_INCLUDE)/%.h: $(PLATFORM_SRC)/javavm/export/%.h
 	$(install-file)
 
-JVMCFG_DIR = $(LIBDIR)/$(LIBARCH)
+ifeq ($(PLATFORM),macosx)
+  JVMCFG_DIR = $(LIBDIR)
+else
+  JVMCFG_DIR = $(LIBDIR)/$(LIBARCH)
+endif
+
 JVMCFG = $(JVMCFG_DIR)/jvm.cfg
 
 #
--- a/make/java/management/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/management/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -77,6 +77,12 @@
 
 endif # PLATFORM linux
 
+ifeq ($(PLATFORM),macosx)
+
+FILES_c     += MacosxOperatingSystem.c
+
+endif # PLATFORM macosx
+
 endif # PLATFORM
 
 #
--- a/make/java/net/FILES_c.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/net/FILES_c.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -43,6 +43,10 @@
     FILES_c += linux_close.c
 endif
 
+ifeq ($(PLATFORM), macosx)
+    FILES_c += bsd_close.c
+endif
+
 ifeq ($(PLATFORM), windows)
     FILES_c += TwoStacksPlainSocketImpl.c
     FILES_c += DualStackPlainSocketImpl.c
--- a/make/java/net/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/net/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -91,16 +91,23 @@
 
 include $(BUILDDIR)/common/Library.gmk
 
+ifeq ($(PLATFORM), macosx)
+ifdef DONT_ENABLE_IPV6
+  OTHER_CFLAGS += -DDONT_ENABLE_IPV6
+endif
+  OTHER_LDLIBS = $(JVMLIB) -pthread
+else
 ifeq ($(PLATFORM), windows)
   OTHER_LDLIBS = ws2_32.lib $(JVMLIB) \
                  secur32.lib iphlpapi.lib delayimp.lib \
                  /DELAYLOAD:secur32.dll /DELAYLOAD:iphlpapi.dll
 else
-  OTHER_LDLIBS = $(LIBSOCKET) $(LIBNSL) -ldl $(JVMLIB)
+  OTHER_LDLIBS = $(LIBSOCKET) $(LIBNSL) $(LIBDL) $(JVMLIB)
 endif
 ifeq ($(PLATFORM), linux)
   OTHER_LDLIBS += -lpthread
 endif
+endif # PLATFORM
 
 CLASSES.export += java.lang.Integer java.io.FileDescriptor java.net.InetAddressImplFactory java.net.Inet4AddressImpl java.net.Inet6AddressImpl
 
--- a/make/java/nio/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/nio/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -260,6 +260,91 @@
 	sun/nio/fs/UnixConstants.java
 endif # PLATFORM = linux
 
+ifeq ($(PLATFORM), macosx)
+FILES_java += \
+        sun/nio/ch/AbstractPollSelectorImpl.java \
+	sun/nio/ch/BsdAsynchronousChannelProvider.java \
+	sun/nio/ch/InheritedChannel.java \
+	sun/nio/ch/KQueue.java \
+	sun/nio/ch/KQueuePort.java \
+        sun/nio/ch/PollSelectorProvider.java \
+        sun/nio/ch/PollSelectorImpl.java \
+	sun/nio/ch/Port.java \
+	sun/nio/ch/SimpleAsynchronousFileChannelImpl.java \
+	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
+	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
+	\
+	sun/nio/fs/GnomeFileTypeDetector.java \
+	sun/nio/fs/BsdFileStore.java \
+	sun/nio/fs/BsdFileSystem.java \
+	sun/nio/fs/BsdFileSystemProvider.java \
+	sun/nio/fs/BsdNativeDispatcher.java \
+	sun/nio/fs/PollingWatchService.java \
+	sun/nio/fs/UnixChannelFactory.java \
+	sun/nio/fs/UnixCopyFile.java \
+	sun/nio/fs/UnixDirectoryStream.java \
+	sun/nio/fs/UnixException.java \
+	sun/nio/fs/UnixFileAttributeViews.java \
+	sun/nio/fs/UnixFileAttributes.java \
+	sun/nio/fs/UnixFileKey.java \
+	sun/nio/fs/UnixFileModeAttribute.java \
+	sun/nio/fs/UnixFileStore.java \
+	sun/nio/fs/UnixFileStoreAttributes.java \
+	sun/nio/fs/UnixFileSystem.java \
+	sun/nio/fs/UnixFileSystemProvider.java \
+	sun/nio/fs/UnixMountEntry.java \
+	sun/nio/fs/UnixNativeDispatcher.java \
+	sun/nio/fs/UnixPath.java \
+	sun/nio/fs/UnixSecureDirectoryStream.java \
+	sun/nio/fs/UnixUriUtils.java \
+	sun/nio/fs/UnixUserPrincipals.java
+
+FILES_c += \
+	InheritedChannel.c \
+	NativeThread.c \
+        PollArrayWrapper.c \
+	UnixAsynchronousServerSocketChannelImpl.c \
+	UnixAsynchronousSocketChannelImpl.c \
+	\
+	GnomeFileTypeDetector.c \
+	BsdNativeDispatcher.c \
+	UnixCopyFile.c \
+	UnixNativeDispatcher.c \
+	\
+	KQueue.c \
+	KQueuePort.c
+
+FILES_export += \
+	sun/nio/ch/InheritedChannel.java \
+	sun/nio/ch/KQueue.java \
+	sun/nio/ch/KQueuePort.java \
+	sun/nio/ch/NativeThread.java \
+	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
+	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
+	\
+	sun/nio/fs/GnomeFileTypeDetector.java \
+	sun/nio/fs/BsdNativeDispatcher.java \
+	sun/nio/fs/UnixCopyFile.java \
+	sun/nio/fs/UnixNativeDispatcher.java
+	
+FILES_gen += \
+	sun/nio/fs/UnixConstants.java
+endif # PLATFORM = bsd, macosx
+
+ifeq ($(PLATFORM), macosx)
+FILES_java += \
+    sun/nio/ch/KQueueSelectorProvider.java \
+    sun/nio/ch/KQueueSelectorImpl.java \
+    sun/nio/ch/KQueueArrayWrapper.java
+
+FILES_c += \
+    KQueueArrayWrapper.c
+
+vpath %.c $(call NativeSrcDirList,,native/sun/nio/fs)
+vpath %.c $(call NativeSrcDirList,,native/sun/nio/ch)
+
+else
+
 #
 # Find platform-specific C source files
 #
@@ -267,6 +352,8 @@
 vpath %.c $(PLATFORM_SRC)/native/sun/nio/ch
 vpath %.c $(SHARE_SRC)/native/sun/nio/ch
 
+endif # PLATFORM = macosx
+
 #
 # Various variables
 #
@@ -292,10 +379,13 @@
      $(OBJDIR)/../../../java.lang/java/$(OBJDIRNAME)/FileDescriptor_md.obj
 endif
 ifeq ($(PLATFORM), linux)
-OTHER_LDLIBS += -L$(LIBDIR)/$(LIBARCH) -ljava -lnet -lpthread -ldl
+OTHER_LDLIBS += -L$(LIBDIR)/$(LIBARCH) -ljava -lnet -lpthread $(LIBDL)
+endif
+ifeq ($(PLATFORM), macosx)
+OTHER_LDLIBS += -L$(LIBDIR) -ljava -lnet -pthread
 endif
 ifeq ($(PLATFORM), solaris)
-OTHER_LDLIBS += $(JVMLIB) $(LIBSOCKET) -lposix4 -ldl -lsendfile \
+OTHER_LDLIBS += $(JVMLIB) $(LIBSOCKET) -lposix4 $(LIBDL) -lsendfile \
 		-L$(LIBDIR)/$(LIBARCH) -ljava -lnet
 endif # PLATFORM
 
@@ -316,6 +406,9 @@
 ifeq ($(PLATFORM), linux)
 FILES_m = mapfile-linux
 endif
+ifeq ($(PLATFORM), macosx)
+FILES_m = mapfile-bsd
+endif
 include $(BUILDDIR)/common/Mapfile-vers.gmk
 include $(BUILDDIR)/common/Library.gmk
 
@@ -818,9 +911,15 @@
 $(TEMPDIR)/$(GENSOR_SRC) : $(GENSOR_SRC)
 	$(install-file)
 
+ifeq ($(PLATFORM), macosx)
+  NIO_CC=$(HOST_CC)
+else
+  NIO_CC=$(CC)
+endif
+
 $(GENSOR_EXE) : $(TEMPDIR)/$(GENSOR_SRC)
 	$(prep-target)
-	($(CD) $(TEMPDIR); $(CC) $(CPPFLAGS) $(LDDFLAGS) \
+	($(CD) $(TEMPDIR); $(NIO_CC) $(CPPFLAGS) $(LDDFLAGS) \
 	   -o genSocketOptionRegistry$(EXE_SUFFIX) $(GENSOR_SRC))
 
 ifdef NIO_PLATFORM_CLASSES_ROOT_DIR
@@ -856,7 +955,7 @@
 
 $(GENUC_EXE) : $(GENUC_SRC)
 	$(prep-target)
-	$(CC) $(CPPFLAGS) -o $@ $(GENUC_SRC)
+	$(NIO_CC) $(CPPFLAGS) -o $@ $(GENUC_SRC)
 
 ifdef NIO_PLATFORM_CLASSES_ROOT_DIR
 $(SFS_GEN)/UnixConstants.java: $(NIO_PLATFORM_CLASSES_ROOT_DIR)/sun/nio/fs/UnixConstants-$(PLATFORM)-$(ARCH).java
@@ -878,7 +977,7 @@
 
 $(GENSC_EXE) : $(GENSC_SRC)
 	$(prep-target)
-	$(CC) $(CPPFLAGS) -o $@ $(GENSC_SRC)
+	$(NIO_CC) $(CPPFLAGS) -o $@ $(GENSC_SRC)
 
 ifdef NIO_PLATFORM_CLASSES_ROOT_DIR
 $(SFS_GEN)/SolarisConstants.java: $(NIO_PLATFORM_CLASSES_ROOT_DIR)/sun/nio/fs/SolarisConstants-$(PLATFORM)-$(ARCH).java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/java/nio/mapfile-bsd	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,179 @@
+#
+# 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.
+#
+
+SUNWprivate_1.1 {
+	global:
+                Java_java_nio_MappedByteBuffer_force0;
+                Java_java_nio_MappedByteBuffer_isLoaded0;
+                Java_java_nio_MappedByteBuffer_load0;
+                Java_sun_nio_ch_DatagramChannelImpl_disconnect0;
+                Java_sun_nio_ch_DatagramChannelImpl_initIDs;
+                Java_sun_nio_ch_DatagramChannelImpl_receive0;
+                Java_sun_nio_ch_DatagramChannelImpl_send0;
+                Java_sun_nio_ch_DatagramDispatcher_read0;
+                Java_sun_nio_ch_DatagramDispatcher_readv0;
+                Java_sun_nio_ch_DatagramDispatcher_write0;
+                Java_sun_nio_ch_DatagramDispatcher_writev0;
+                Java_sun_nio_ch_FileChannelImpl_close0;
+                Java_sun_nio_ch_FileChannelImpl_initIDs;
+                Java_sun_nio_ch_FileChannelImpl_map0;
+                Java_sun_nio_ch_FileChannelImpl_position0;
+                Java_sun_nio_ch_FileChannelImpl_transferTo0;
+                Java_sun_nio_ch_FileChannelImpl_unmap0;
+                Java_sun_nio_ch_FileDispatcherImpl_close0;
+                Java_sun_nio_ch_FileDispatcherImpl_closeIntFD;
+		Java_sun_nio_ch_FileDispatcherImpl_force0;
+                Java_sun_nio_ch_FileDispatcherImpl_init;
+		Java_sun_nio_ch_FileDispatcherImpl_lock0;
+                Java_sun_nio_ch_FileDispatcherImpl_preClose0;
+                Java_sun_nio_ch_FileDispatcherImpl_pread0;
+                Java_sun_nio_ch_FileDispatcherImpl_pwrite0;
+                Java_sun_nio_ch_FileDispatcherImpl_read0;
+                Java_sun_nio_ch_FileDispatcherImpl_readv0;
+		Java_sun_nio_ch_FileDispatcherImpl_release0;
+		Java_sun_nio_ch_FileDispatcherImpl_size0;
+		Java_sun_nio_ch_FileDispatcherImpl_truncate0;
+                Java_sun_nio_ch_FileDispatcherImpl_write0;
+                Java_sun_nio_ch_FileDispatcherImpl_writev0;
+                Java_sun_nio_ch_FileKey_init;
+                Java_sun_nio_ch_FileKey_initIDs;
+		Java_sun_nio_ch_InheritedChannel_close0;
+		Java_sun_nio_ch_InheritedChannel_dup;
+		Java_sun_nio_ch_InheritedChannel_dup2;
+		Java_sun_nio_ch_InheritedChannel_open0;
+		Java_sun_nio_ch_InheritedChannel_peerAddress0;
+		Java_sun_nio_ch_InheritedChannel_peerPort0;
+		Java_sun_nio_ch_InheritedChannel_soType0;
+                Java_sun_nio_ch_IOUtil_configureBlocking;
+                Java_sun_nio_ch_IOUtil_drain;
+                Java_sun_nio_ch_IOUtil_fdVal;
+                Java_sun_nio_ch_IOUtil_initIDs;
+                Java_sun_nio_ch_IOUtil_makePipe;
+                Java_sun_nio_ch_IOUtil_randomBytes;
+                Java_sun_nio_ch_IOUtil_setfdVal;
+		Java_sun_nio_ch_KQueue_kqueue;
+		Java_sun_nio_ch_KQueue_keventRegister;
+		Java_sun_nio_ch_KQueue_keventPoll;
+		Java_sun_nio_ch_KQueue_keventSize;
+		Java_sun_nio_ch_KQueue_identOffset;
+		Java_sun_nio_ch_KQueue_filterOffset;
+		Java_sun_nio_ch_KQueue_flagsOffset;
+		Java_sun_nio_ch_KQueuePort_socketpair;
+		Java_sun_nio_ch_KQueuePort_interrupt;
+		Java_sun_nio_ch_KQueuePort_drain1;
+		Java_sun_nio_ch_KQueuePort_close0;
+		Java_sun_nio_ch_NativeThread_current;
+		Java_sun_nio_ch_NativeThread_init;
+		Java_sun_nio_ch_NativeThread_signal;
+		Java_sun_nio_ch_Net_canIPv6SocketJoinIPv4Group0;
+		Java_sun_nio_ch_Net_canJoin6WithIPv4Group0;
+		Java_sun_nio_ch_Net_socket0;
+		Java_sun_nio_ch_Net_bind0;
+		Java_sun_nio_ch_Net_connect0;
+		Java_sun_nio_ch_Net_listen;
+		Java_sun_nio_ch_Net_localPort;
+		Java_sun_nio_ch_Net_localInetAddress;
+		Java_sun_nio_ch_Net_getIntOption0;
+		Java_sun_nio_ch_Net_setIntOption0;
+                Java_sun_nio_ch_Net_initIDs;
+		Java_sun_nio_ch_Net_isIPv6Available0;
+		Java_sun_nio_ch_Net_joinOrDrop4;
+		Java_sun_nio_ch_Net_blockOrUnblock4;
+		Java_sun_nio_ch_Net_joinOrDrop6;
+		Java_sun_nio_ch_Net_blockOrUnblock6;
+		Java_sun_nio_ch_Net_setInterface4;
+		Java_sun_nio_ch_Net_getInterface4;
+		Java_sun_nio_ch_Net_setInterface6;
+		Java_sun_nio_ch_Net_getInterface6;
+		Java_sun_nio_ch_Net_shutdown;
+                Java_sun_nio_ch_PollArrayWrapper_interrupt;
+                Java_sun_nio_ch_PollArrayWrapper_poll0;
+                Java_sun_nio_ch_ServerSocketChannelImpl_accept0;
+                Java_sun_nio_ch_ServerSocketChannelImpl_initIDs;
+                Java_sun_nio_ch_SocketChannelImpl_checkConnect;
+		Java_sun_nio_ch_SocketChannelImpl_sendOutOfBandData;
+		Java_sun_nio_ch_UnixAsynchronousServerSocketChannelImpl_accept0;
+		Java_sun_nio_ch_UnixAsynchronousServerSocketChannelImpl_initIDs;
+		Java_sun_nio_ch_UnixAsynchronousSocketChannelImpl_checkConnect;
+		Java_sun_nio_fs_BsdNativeDispatcher_initIDs;
+		Java_sun_nio_fs_BsdNativeDispatcher_getfsstat;
+		Java_sun_nio_fs_BsdNativeDispatcher_fsstatEntry;
+		Java_sun_nio_fs_BsdNativeDispatcher_endfsstat;
+		Java_sun_nio_fs_GnomeFileTypeDetector_initializeGio;
+		Java_sun_nio_fs_GnomeFileTypeDetector_probeUsingGio;
+		Java_sun_nio_fs_GnomeFileTypeDetector_initializeGnomeVfs;
+		Java_sun_nio_fs_GnomeFileTypeDetector_probeUsingGnomeVfs;
+		Java_sun_nio_fs_UnixNativeDispatcher_init;
+		Java_sun_nio_fs_UnixNativeDispatcher_getcwd;
+		Java_sun_nio_fs_UnixNativeDispatcher_strerror;
+		Java_sun_nio_fs_UnixNativeDispatcher_dup;
+		Java_sun_nio_fs_UnixNativeDispatcher_access0;
+		Java_sun_nio_fs_UnixNativeDispatcher_stat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_lstat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fstat;
+		Java_sun_nio_fs_UnixNativeDispatcher_fstatat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_chmod0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fchmod;
+		Java_sun_nio_fs_UnixNativeDispatcher_chown0;
+		Java_sun_nio_fs_UnixNativeDispatcher_lchown0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fchown;
+		Java_sun_nio_fs_UnixNativeDispatcher_utimes0;
+		Java_sun_nio_fs_UnixNativeDispatcher_futimes;
+		Java_sun_nio_fs_UnixNativeDispatcher_open0;
+		Java_sun_nio_fs_UnixNativeDispatcher_openat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_close;
+		Java_sun_nio_fs_UnixNativeDispatcher_read;
+		Java_sun_nio_fs_UnixNativeDispatcher_write;
+		Java_sun_nio_fs_UnixNativeDispatcher_fopen0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fclose;
+		Java_sun_nio_fs_UnixNativeDispatcher_opendir0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fdopendir;
+		Java_sun_nio_fs_UnixNativeDispatcher_readdir;
+		Java_sun_nio_fs_UnixNativeDispatcher_closedir;
+		Java_sun_nio_fs_UnixNativeDispatcher_link0;
+		Java_sun_nio_fs_UnixNativeDispatcher_unlink0;
+		Java_sun_nio_fs_UnixNativeDispatcher_unlinkat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_rename0;
+		Java_sun_nio_fs_UnixNativeDispatcher_renameat0;
+		Java_sun_nio_fs_UnixNativeDispatcher_mkdir0;
+		Java_sun_nio_fs_UnixNativeDispatcher_rmdir0;
+		Java_sun_nio_fs_UnixNativeDispatcher_symlink0;
+		Java_sun_nio_fs_UnixNativeDispatcher_readlink0;
+		Java_sun_nio_fs_UnixNativeDispatcher_realpath0;
+		Java_sun_nio_fs_UnixNativeDispatcher_statvfs0;
+		Java_sun_nio_fs_UnixNativeDispatcher_pathconf0;
+		Java_sun_nio_fs_UnixNativeDispatcher_fpathconf;
+		Java_sun_nio_fs_UnixNativeDispatcher_mknod0;
+		Java_sun_nio_fs_UnixNativeDispatcher_getpwuid;
+		Java_sun_nio_fs_UnixNativeDispatcher_getgrgid;
+		Java_sun_nio_fs_UnixNativeDispatcher_getpwnam0;
+		Java_sun_nio_fs_UnixNativeDispatcher_getgrnam0;
+		Java_sun_nio_fs_UnixNativeDispatcher_getextmntent;
+		Java_sun_nio_fs_UnixCopyFile_transfer;
+		handleSocketError;
+
+	local:
+		*;
+};
--- a/make/java/npt/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/npt/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -67,6 +67,11 @@
   OTHER_LCF += -export:nptInitialize -export:nptTerminate
 endif
 
+# Add location of iconv header
+ifeq ($(PLATFORM), macosx))
+  OTHER_LDLIBS += -liconv
+endif
+
 #
 # Add to ambient vpath so we pick up the library files
 #
--- a/make/java/redist/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/redist/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -46,6 +46,8 @@
 
 ifeq ($(PLATFORM), windows)
   LIB_LOCATION = $(BINDIR)
+else ifeq ($(PLATFORM), macosx)
+  LIB_LOCATION = $(LIBDIR)
 else
   LIB_LOCATION = $(LIBDIR)/$(LIBARCH)
 endif
--- a/make/java/redist/sajdi/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/redist/sajdi/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -29,6 +29,8 @@
 
 ifeq ($(PLATFORM), windows)
   LIB_LOCATION = $(BINDIR)
+else ifeq ($(PLATFORM), macosx)
+  LIB_LOCATION = $(LIBDIR)
 else
   LIB_LOCATION = $(LIBDIR)/$(LIBARCH)
 endif
--- a/make/java/security/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/security/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -42,13 +42,20 @@
 ifeq ($(PLATFORM), solaris)
 PROPS_SRC   = $(TOPDIR)/src/share/lib/security/java.security-solaris
 
-else # PLATFORM
+else # NOT_SOLARIS
 
 # Register Microsoft CryptoAPI provider only on Windows platform.
 ifeq ($(PLATFORM), windows)
   PROPS_SRC   = $(TOPDIR)/src/share/lib/security/java.security-windows
-endif
-endif # PLATFORM
+
+else # NOT_WINDOWS
+
+ifeq ($(PLATFORM), macosx)
+  PROPS_SRC   = $(TOPDIR)/src/share/lib/security/java.security-macosx
+endif # MACOSX
+
+endif # NOT_WINDOWS
+endif # NOT_SOLARIS
 
 
 PROPS_BUILD = $(LIBDIR)/security/java.security
--- a/make/java/zip/FILES_c.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/zip/FILES_c.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -29,7 +29,10 @@
 	Deflater.c \
 	Inflater.c \
 	ZipFile.c \
-	zip_util.c \
+	zip_util.c
+
+ifneq ($(SYSTEM_ZLIB),true)
+FILES_c += \
 	compress.c \
 	deflate.c \
 	gzio.c \
@@ -41,4 +44,5 @@
 	uncompr.c \
 	zadler32.c \
 	zcrc32.c \
-	zutil.c 
+	zutil.c
+endif
--- a/make/java/zip/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/java/zip/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -74,16 +74,24 @@
 CPPFLAGS += -UDEBUG 
 endif
 
-CPPFLAGS += -I$(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
 CPPFLAGS += -I$(SHARE_SRC)/native/java/io
 CPPFLAGS += -I$(PLATFORM_SRC)/native/java/io
 
+ifneq ($(SYSTEM_ZLIB),true)
+CPPFLAGS += -I$(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+
 #
 # Add to ambient vpath so we pick up the library files
 #
 vpath %.c $(SHARE_SRC)/native/$(PKGDIR)/zlib-$(ZLIB_VERSION)
+endif
 
 #
 # Link to JVM library for JVM_Zip* functions
 #
+ifeq ($(SYSTEM_ZLIB),true)
+OTHER_LDLIBS = -lz
+else
 OTHER_LDLIBS = $(JVMLIB)
+endif
+
--- a/make/javax/sound/FILES_c.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/javax/sound/FILES_c.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -34,6 +34,18 @@
 
 FILES_linux = 
 
+FILES_bsd =
+
+FILES_macosx = \
+    PLATFORM_API_MacOSX_MidiIn.c \
+    PLATFORM_API_MacOSX_MidiOut.c \
+    PLATFORM_API_MacOSX_MidiUtils.c
+
+FILES_cpp_macosx = \
+    PLATFORM_API_MacOSX_Utils.cpp \
+    PLATFORM_API_MacOSX_PCM.cpp \
+    PLATFORM_API_MacOSX_Ports.cpp
+
 FILES_windows = \
 	PLATFORM_API_WinOS_MidiIn.c \
 	PLATFORM_API_WinOS_MidiOut.c \
--- a/make/javax/sound/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/javax/sound/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -27,6 +27,11 @@
 PACKAGE = javax.sound
 LIBRARY = jsound
 PRODUCT = sun
+
+ifeq ($(PLATFORM),macosx)
+CPLUSPLUSLIBRARY = true
+endif
+
 include $(BUILDDIR)/common/Defs.gmk
 
 # include defines for sound
@@ -77,6 +82,7 @@
 	$(FILES_mkdirs)
 
 FILES_c += $(FILES_$(PLATFORM))
+FILES_cpp += $(FILES_cpp_$(PLATFORM))
 
 
 #
@@ -105,6 +111,22 @@
   #MXSPP_ADD = $(PLATFORM)-$(ARCH)/
 endif # PLATFORM linux
 
+ifeq ($(PLATFORM), macosx)
+  CPPFLAGS += -DUSE_PORTS=TRUE \
+              -DUSE_DAUDIO=TRUE \
+              -DUSE_PLATFORM_MIDI_OUT=TRUE \
+              -DUSE_PLATFORM_MIDI_IN=TRUE
+
+  INCLUDE_PORTS = TRUE
+  INCLUDE_DAUDIO = TRUE
+  INCLUDE_MIDI = TRUE
+
+  LDFLAGS += -framework CoreAudio -framework CoreFoundation \
+             -framework CoreServices -framework AudioUnit -lstdc++ \
+             -framework CoreMIDI
+  CXXFLAGS += -I`xcode-select -print-path`/Extras/CoreAudio/PublicUtility
+endif
+
 ifeq ($(PLATFORM), solaris)
   # build with ports and direct audio
   CPPFLAGS += -DUSE_PORTS=TRUE 	\
@@ -144,6 +166,11 @@
 CPPFLAGS += \
 	-I$(SHARE_SRC)/native/com/sun/media/sound
 
+ifeq ($(PLATFORM), macosx)
+vpath %.c   $(call NativeSrcDirList,,native/com/sun/media/sound)
+vpath %.cpp $(call NativeSrcDirList,,native/com/sun/media/sound)
+
+else
 #
 # Add to the ambient VPATH.
 #
@@ -151,6 +178,7 @@
 vpath %.c $(PLATFORM_SRC)/native/com/sun/media/sound
 vpath %.cpp $(PLATFORM_SRC)/native/com/sun/media/sound
 
+endif
 
 #
 # Include rules
--- a/make/javax/sound/SoundDefs.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/javax/sound/SoundDefs.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -40,6 +40,10 @@
   CPPFLAGS += -DX_PLATFORM=X_LINUX
 endif # PLATFORM linux
 
+ifeq ($(PLATFORM), macosx)
+  CPPFLAGS += -DX_PLATFORM=X_MACOSX
+endif # PLATFORM macosx
+
 ifeq ($(PLATFORM), solaris)
   CPPFLAGS += -DX_PLATFORM=X_SOLARIS
 
--- a/make/jpda/back/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/jpda/back/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -49,7 +49,7 @@
                  -I$(GENNATIVESRCDIR)/jdwp
 
 ifneq ($(PLATFORM), windows)
-  OTHER_LDLIBS += -ldl
+  OTHER_LDLIBS += $(LIBDL)
 endif # PLATFORM
 
 #
--- a/make/jpda/transport/socket/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/jpda/transport/socket/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -40,6 +40,11 @@
   OTHER_LDLIBS += $(LIBNSL) $(LIBSOCKET) -lpthread
 endif
 
+ifeq ($(PLATFORM), macosx))
+  LIBSOCKET =
+  OTHER_LDLIBS += -pthread
+endif
+
 ifeq ($(PLATFORM), solaris)
   OTHER_LDLIBS += $(LIBNSL) $(LIBSOCKET)
 endif
--- a/make/jprt.properties	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/jprt.properties	Thu Feb 02 13:39:04 2012 -0800
@@ -25,268 +25,80 @@
 
 # Properties for jprt
 
-# At submit time, the release supplied will be in jprt.submit.release
-#    and will be one of the official release names defined in jprt.
-#    jprt supports property value expansion using ${property.name} syntax.
-
-# This tells jprt what default release we want to build
-jprt.tools.default.release=${jprt.submit.release}
+# Locked down to jdk7
+jprt.tools.default.release=jdk7
 
 # The different build flavors we want, we override here so we just get these 2
 jprt.build.flavors=product,fastdebug
 
-# Define the Windows we want (temporary)
-jprt.my.windows.i586.jdk7b107=windows_i586_5.0
-jprt.my.windows.i586.jdk7temp=windows_i586_5.0
-jprt.my.windows.i586.jdk7=windows_i586_5.1
-jprt.my.windows.i586=${jprt.my.windows.i586.${jprt.tools.default.release}}
-
 # Standard list of jprt build targets for this source tree
-jprt.build.targets= 						\
-    solaris_sparc_5.10-{product|fastdebug}, 			\
+jprt.build.targets=                                         	\
+    solaris_sparc_5.10-{product|fastdebug},                 	\
     solaris_sparcv9_5.10-{product|fastdebug}, 			\
     solaris_i586_5.10-{product|fastdebug}, 			\
     solaris_x64_5.10-{product|fastdebug}, 			\
     linux_i586_2.6-{product|fastdebug}, 			\
     linux_x64_2.6-{product|fastdebug}, 				\
-    ${jprt.my.windows.i586}-{product|fastdebug}, 		\
+    macosx_x64_10.7-{product|fastdebug}, 			\
+    windows_i586_5.1-{product|fastdebug}, 			\
     windows_x64_5.2-{product|fastdebug}
 
 # User can select the test set with jprt submit "-testset name" option
 jprt.my.test.set=${jprt.test.set}
 
-# Standard vm test target
+# Test target list (no fastdebug & limited c2 testing)
+jprt.my.test.target.set= \
+    solaris_sparc_5.10-product-c1-TESTNAME,                     \
+    solaris_sparcv9_5.10-product-c2-TESTNAME,                   \
+    solaris_i586_5.10-product-c1-TESTNAME,                      \
+    solaris_x64_5.10-product-c2-TESTNAME,                       \
+    linux_i586_2.6-product-{c1|c2}-TESTNAME,                    \
+    linux_x64_2.6-product-c2-TESTNAME,                          \
+    macosx_x64_10.7-product-c2-TESTNAME,                        \
+    windows_i586_5.1-product-c1-TESTNAME,                       \
+    windows_x64_5.2-product-c2-TESTNAME
+
+# Default vm test targets (testset=default)
 jprt.vm.default.test.targets=					\
-    solaris_sparc_5.10-product-c1-jvm98, 			\
-    solaris_sparcv9_5.10-product-c2-jvm98, 			\
-    solaris_i586_5.10-product-c1-jvm98, 			\
-    solaris_x64_5.10-product-c2-jvm98, 				\
-    linux_i586_2.6-product-{c1|c2}-jvm98, 			\
-    linux_x64_2.6-product-c2-jvm98, 				\
-    ${jprt.my.windows.i586}-product-c1-jvm98, 			\
-    windows_x64_5.2-product-c2-jvm98
+    ${jprt.my.test.target.set:TESTNAME=jvm98}
 
-# Select vm testlist to use (allow for testset to be empty too)
-jprt.vm.all.test.targets=${jprt.vm.default.test.targets}
-jprt.vm..test.targets=${jprt.vm.default.test.targets} 
-jprt.test.targets=${jprt.vm.${jprt.my.test.set}.test.targets} 
+# Default jdk test targets (testset=default)
+jprt.make.rule.default.test.targets=				\
+    ${jprt.my.test.target.set:TESTNAME=jdk_beans1},             \
+    ${jprt.my.test.target.set:TESTNAME=jdk_io},                 \
+    ${jprt.my.test.target.set:TESTNAME=jdk_lang},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_math},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_misc},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_net},                \
+    ${jprt.my.test.target.set:TESTNAME=jdk_nio1},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_nio2},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_nio3},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_security1},          \
+    ${jprt.my.test.target.set:TESTNAME=jdk_text},               \
+    ${jprt.my.test.target.set:TESTNAME=jdk_tools1},             \
+    ${jprt.my.test.target.set:TESTNAME=jdk_util}
 
-# Default jdk test targets in test/Makefile (no fastdebug & limited c2)
-jprt.make.rule.default.test.targets=				\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_beans1, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_beans1, 		\
-    solaris_i586_5.10-product-c1-jdk_beans1, 			\
-    solaris_x64_5.10-product-c2-jdk_beans1, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_beans1, 			\
-    linux_x64_2.6-product-c2-jdk_beans1, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_beans1, 		\
-    windows_x64_5.2-product-c2-jdk_beans1, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_io, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_io, 			\
-    solaris_i586_5.10-product-c1-jdk_io, 			\
-    solaris_x64_5.10-product-c2-jdk_io, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_io, 			\
-    linux_x64_2.6-product-c2-jdk_io, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_io, 			\
-    windows_x64_5.2-product-c2-jdk_io, 				\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_lang, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_lang, 			\
-    solaris_i586_5.10-product-c1-jdk_lang, 			\
-    solaris_x64_5.10-product-c2-jdk_lang, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_lang, 			\
-    linux_x64_2.6-product-c2-jdk_lang, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_lang, 		\
-    windows_x64_5.2-product-c2-jdk_lang, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_math, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_math, 			\
-    solaris_i586_5.10-product-c1-jdk_math, 			\
-    solaris_x64_5.10-product-c2-jdk_math, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_math, 			\
-    linux_x64_2.6-product-c2-jdk_math, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_math, 		\
-    windows_x64_5.2-product-c2-jdk_math, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_misc, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_misc, 			\
-    solaris_i586_5.10-product-c1-jdk_misc, 			\
-    solaris_x64_5.10-product-c2-jdk_misc, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_misc, 			\
-    linux_x64_2.6-product-c2-jdk_misc, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_misc, 		\
-    windows_x64_5.2-product-c2-jdk_misc, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_net, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_net, 			\
-    solaris_i586_5.10-product-c1-jdk_net, 			\
-    solaris_x64_5.10-product-c2-jdk_net, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_net, 			\
-    linux_x64_2.6-product-c2-jdk_net, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_net, 		\
-    windows_x64_5.2-product-c2-jdk_net, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_nio1, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_nio1, 			\
-    solaris_i586_5.10-product-c1-jdk_nio1, 			\
-    solaris_x64_5.10-product-c2-jdk_nio1, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_nio1, 			\
-    linux_x64_2.6-product-c2-jdk_nio1, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_nio1, 		\
-    windows_x64_5.2-product-c2-jdk_nio1, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_nio2, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_nio2, 			\
-    solaris_i586_5.10-product-c1-jdk_nio2, 			\
-    solaris_x64_5.10-product-c2-jdk_nio2, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_nio2, 			\
-    linux_x64_2.6-product-c2-jdk_nio2, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_nio2, 		\
-    windows_x64_5.2-product-c2-jdk_nio2, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_nio3, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_nio3, 			\
-    solaris_i586_5.10-product-c1-jdk_nio3, 			\
-    solaris_x64_5.10-product-c2-jdk_nio3, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_nio3, 			\
-    linux_x64_2.6-product-c2-jdk_nio3, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_nio3, 		\
-    windows_x64_5.2-product-c2-jdk_nio3, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_security1, 		\
-    solaris_sparcv9_5.10-product-c2-jdk_security1, 		\
-    solaris_i586_5.10-product-c1-jdk_security1, 		\
-    solaris_x64_5.10-product-c2-jdk_security1, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_security1, 		\
-    linux_x64_2.6-product-c2-jdk_security1, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_security1, 		\
-    windows_x64_5.2-product-c2-jdk_security1, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_text, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_text, 			\
-    solaris_i586_5.10-product-c1-jdk_text, 			\
-    solaris_x64_5.10-product-c2-jdk_text, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_text, 			\
-    linux_x64_2.6-product-c2-jdk_text, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_text, 		\
-    windows_x64_5.2-product-c2-jdk_text, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_tools1, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_tools1, 		\
-    solaris_i586_5.10-product-c1-jdk_tools1, 			\
-    solaris_x64_5.10-product-c2-jdk_tools1, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_tools1, 			\
-    linux_x64_2.6-product-c2-jdk_tools1, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_tools1, 		\
-    windows_x64_5.2-product-c2-jdk_tools1, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_util, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_util, 			\
-    solaris_i586_5.10-product-c1-jdk_util, 			\
-    solaris_x64_5.10-product-c2-jdk_util, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_util, 			\
-    linux_x64_2.6-product-c2-jdk_util, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_util, 		\
-    windows_x64_5.2-product-c2-jdk_util
+# All vm test targets (testset=all)
+jprt.vm.all.test.targets=                                       \
+    ${jprt.vm.default.test.targets},                            \
+    ${jprt.my.test.target.set:TESTNAME=runThese},               \
+    ${jprt.my.test.target.set:TESTNAME=jbb_default}
 
-# All jdk test targets in test/Makefile (still no fastdebug & limited c2)
+# All jdk test targets (testset=all)
 jprt.make.rule.all.test.targets=    				\
-    								\
-   ${jprt.make.rule.default.test.targets}, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_awt, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_awt, 			\
-    solaris_i586_5.10-product-c1-jdk_awt, 			\
-    solaris_x64_5.10-product-c2-jdk_awt, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_awt, 			\
-    linux_x64_2.6-product-c2-jdk_awt, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_awt, 		\
-    windows_x64_5.2-product-c2-jdk_awt, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_beans2, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_beans2, 		\
-    solaris_i586_5.10-product-c1-jdk_beans2, 			\
-    solaris_x64_5.10-product-c2-jdk_beans2, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_beans2, 			\
-    linux_x64_2.6-product-c2-jdk_beans2, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_beans2, 		\
-    windows_x64_5.2-product-c2-jdk_beans2, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_beans3, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_beans3, 		\
-    solaris_i586_5.10-product-c1-jdk_beans3, 			\
-    solaris_x64_5.10-product-c2-jdk_beans3, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_beans3, 			\
-    linux_x64_2.6-product-c2-jdk_beans3, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_beans3, 		\
-    windows_x64_5.2-product-c2-jdk_beans3, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_management1, 		\
-    solaris_sparcv9_5.10-product-c2-jdk_management1, 		\
-    solaris_i586_5.10-product-c1-jdk_management1, 		\
-    solaris_x64_5.10-product-c2-jdk_management1, 		\
-    linux_i586_2.6-product-{c1|c2}-jdk_management1, 		\
-    linux_x64_2.6-product-c2-jdk_management1, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_management1, 	\
-    windows_x64_5.2-product-c2-jdk_management1, 		\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_management2, 		\
-    solaris_sparcv9_5.10-product-c2-jdk_management2, 		\
-    solaris_i586_5.10-product-c1-jdk_management2, 		\
-    solaris_x64_5.10-product-c2-jdk_management2, 		\
-    linux_i586_2.6-product-{c1|c2}-jdk_management2, 		\
-    linux_x64_2.6-product-c2-jdk_management2, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_management2, 	\
-    windows_x64_5.2-product-c2-jdk_management2, 		\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_rmi, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_rmi, 			\
-    solaris_i586_5.10-product-c1-jdk_rmi, 			\
-    solaris_x64_5.10-product-c2-jdk_rmi, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_rmi, 			\
-    linux_x64_2.6-product-c2-jdk_rmi, 				\
-    ${jprt.my.windows.i586}-product-c1-jdk_rmi, 		\
-    windows_x64_5.2-product-c2-jdk_rmi, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_security2, 		\
-    solaris_sparcv9_5.10-product-c2-jdk_security2, 		\
-    solaris_i586_5.10-product-c1-jdk_security2, 		\
-    solaris_x64_5.10-product-c2-jdk_security2, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_security2, 		\
-    linux_x64_2.6-product-c2-jdk_security2, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_security2, 		\
-    windows_x64_5.2-product-c2-jdk_security2, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_security3, 		\
-    solaris_sparcv9_5.10-product-c2-jdk_security3, 		\
-    solaris_i586_5.10-product-c1-jdk_security3, 		\
-    solaris_x64_5.10-product-c2-jdk_security3, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_security3, 		\
-    linux_x64_2.6-product-c2-jdk_security3, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_security3, 		\
-    windows_x64_5.2-product-c2-jdk_security3, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_swing, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_swing, 			\
-    solaris_i586_5.10-product-c1-jdk_swing, 			\
-    solaris_x64_5.10-product-c2-jdk_swing, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_swing, 			\
-    linux_x64_2.6-product-c2-jdk_swing, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_swing, 		\
-    windows_x64_5.2-product-c2-jdk_swing, 			\
-    								\
-    solaris_sparc_5.10-product-c1-jdk_tools2, 			\
-    solaris_sparcv9_5.10-product-c2-jdk_tools2, 		\
-    solaris_i586_5.10-product-c1-jdk_tools2, 			\
-    solaris_x64_5.10-product-c2-jdk_tools2, 			\
-    linux_i586_2.6-product-{c1|c2}-jdk_tools2, 			\
-    linux_x64_2.6-product-c2-jdk_tools2, 			\
-    ${jprt.my.windows.i586}-product-c1-jdk_tools2, 		\
-    windows_x64_5.2-product-c2-jdk_tools2
+    ${jprt.make.rule.default.test.targets}, 			\
+    ${jprt.my.test.target.set:TESTNAME=jdk_awt},                \
+    ${jprt.my.test.target.set:TESTNAME=jdk_beans2},             \
+    ${jprt.my.test.target.set:TESTNAME=jdk_beans3},             \
+    ${jprt.my.test.target.set:TESTNAME=jdk_management1},        \
+    ${jprt.my.test.target.set:TESTNAME=jdk_management2},        \
+    ${jprt.my.test.target.set:TESTNAME=jdk_rmi},                \
+    ${jprt.my.test.target.set:TESTNAME=jdk_security2},          \
+    ${jprt.my.test.target.set:TESTNAME=jdk_security3},          \
+    ${jprt.my.test.target.set:TESTNAME=jdk_swing},              \
+    ${jprt.my.test.target.set:TESTNAME=jdk_tools2}
 
-# JCK test targets in test/Makefile (no fastdebug & limited c2, windows broken)
+# JCK test targets in test/Makefile (no windows)
 jprt.my.jck.test.target.set=					\
     solaris_sparc_5.10-product-c1-JCK7TESTRULE, 		\
     solaris_sparcv9_5.10-product-c2-JCK7TESTRULE, 		\
@@ -302,8 +114,10 @@
     ${jprt.my.jck.test.target.set:JCK7TESTRULE=jck7compiler}
 
 # Select list to use (allow for testset to be empty too)
-jprt.make.rule..test.targets=${jprt.make.rule.default.test.targets} 
-jprt.make.rule.test.targets=${jprt.make.rule.${jprt.my.test.set}.test.targets} 
+jprt.make.rule..test.targets=${jprt.make.rule.default.test.targets}
+jprt.make.rule.test.targets=${jprt.make.rule.${jprt.my.test.set}.test.targets}
+jprt.vm..test.targets=${jprt.vm.default.test.targets}
+jprt.test.targets=${jprt.vm.${jprt.my.test.set}.test.targets}
 
 # Directories to be excluded from the source bundles
 jprt.bundle.exclude.src.dirs=build dist webrev
--- a/make/launchers/Makefile.launcher	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/launchers/Makefile.launcher	Thu Feb 02 13:39:04 2012 -0800
@@ -86,12 +86,15 @@
 endif
 ifeq ($(PROGRAM),jsadebugd)
   SA_TOOL=true
+  INFO_PLIST_FILE=Info-privileged.plist
 endif
 ifeq ($(PROGRAM),jinfo)
   SA_TOOL=true
+  INFO_PLIST_FILE=Info-privileged.plist
 endif
 ifeq ($(PROGRAM),jmap)
   SA_TOOL=true
+  INFO_PLIST_FILE=Info-privileged.plist
 endif
 
 # special idlj launcher
--- a/make/mkdemo/jvmti/hprof/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/mkdemo/jvmti/hprof/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -37,12 +37,11 @@
 
 ifeq ($(PLATFORM), windows)
   EXTRA_LIBS += wsock32.lib winmm.lib
+else
+  OTHER_LDLIBS += $(LIBSOCKET) $(LIBNSL) $(LIBDL)
+ifeq ($(PLATFORM), linux)
+  OTHER_LDLIBS += -lpthread
 endif
-ifeq ($(PLATFORM), solaris)
-  OTHER_LDLIBS += $(LIBSOCKET) $(LIBNSL) -ldl
-endif
-ifeq ($(PLATFORM), linux)
-  OTHER_LDLIBS += $(LIBSOCKET) $(LIBNSL) -ldl -lpthread
 endif
 
 #
--- a/make/mksample/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/mksample/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -47,6 +47,11 @@
 	SUBDIRS += dtrace
 endif
 
+# and Mac OS X too
+ifeq ($(PLATFORM), macosx) 
+	SUBDIRS += dtrace
+endif
+
 include $(BUILDDIR)/common/Subdirs.gmk
 
 TOPLEVEL_FILES =							\
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/netbeans/common/architectures/name-Bsd.properties	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,32 @@
+#
+# Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+#
+#   - Redistributions of source code must retain the above copyright
+#     notice, this list of conditions and the following disclaimer.
+#
+#   - Redistributions in binary form must reproduce the above copyright
+#     notice, this list of conditions and the following disclaimer in the
+#     documentation and/or other materials provided with the distribution.
+#
+#   - Neither the name of Oracle nor the names of its
+#     contributors may be used to endorse or promote products derived
+#     from this software without specific prior written permission.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+# IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+# PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+# PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+# LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+platform=bsd
--- a/make/sun/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -58,9 +58,17 @@
   XAWT_SUBDIR     = xawt
 endif
 
+ifeq ($(PLATFORM), macosx)
+  LWAWT_PRE_SUBDIR = osxapp
+  LWAWT_SUBDIR = lwawt
+endif
+
 ifndef OPENJDK
+ifneq ($(PLATFORM), macosx)
   JDBC_SUBDIR = jdbc
 endif
+endif
+
 ifdef OPENJDK
   RENDER_SUBDIR = pisces
 else
@@ -78,7 +86,7 @@
   DISPLAY_TOOLS = applet
 endif
 SUBDIRS_desktop    = audio $(RENDER_SUBDIR) image \
-                     $(DISPLAY_LIBS) $(DGA_SUBDIR) \
+                     $(LWAWT_PRE_SUBDIR) $(DISPLAY_LIBS) $(DGA_SUBDIR) $(LWAWT_SUBDIR) \
                      jawt font jpeg cmm $(DISPLAY_TOOLS) beans
 SUBDIRS_management = management
 SUBDIRS_misc       = $(ORG_SUBDIR) rmi $(JDBC_SUBDIR) tracing
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/awt/FILES_c_macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,28 @@
+#
+# Copyright (c) 1995, 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.
+#
+
+FILES_AWT_objc = \
+        $(TARGDIR)MacOSXResourceBundle.m
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/awt/FILES_export_macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,29 @@
+#
+# Copyright (c) 1995, 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.
+#
+
+# FILES_export definitions for Mac OS X
+
+FILES_export += \
+	com/apple/resources/MacOSXResourceBundle.java
--- a/make/sun/awt/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/awt/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -93,7 +93,7 @@
 ifeq  ($(PLATFORM), solaris)
 FILES_c = $(FILES_2D_c)
 FILES_c += awt_LoadLibrary.c
-OTHER_LDLIBS = $(JVMLIB) $(LIBM) -ldl
+OTHER_LDLIBS = $(JVMLIB) $(LIBM) $(LIBDL)
 ifeq ($(CC_VER), 5.8)
   ifndef REMOVE_ALL_WORKAROUNDS
     ifeq ($(ARCH_FAMILY), i586)
@@ -120,14 +120,42 @@
 FILES_c = $(FILES_2D_c)
 FILES_c += awt_LoadLibrary.c
 OTHER_CFLAGS += -DMLIB_NO_LIBSUNMATH
-OTHER_LDLIBS = $(JVMLIB) $(LIBM) -ldl
+OTHER_LDLIBS = $(JVMLIB) $(LIBM) $(LIBDL)
 endif
 
 FILES_c += initIDs.c
 
+ifeq ($(PLATFORM), macosx)
+FILES_c = $(FILES_2D_c)
+FILES_c += awt_LoadLibrary.c
+OTHER_CFLAGS += -DMLIB_NO_LIBSUNMATH
+OTHER_LDLIBS = $(JVMLIB) $(LIBM)
+endif
+
 # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SOLARIS/LINUX
 endif # PLATFORM 
 
+ifeq ($(PLATFORM), macosx)
+# vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv MAC OS X
+
+#
+# Files
+#
+include FILES_c_macosx.gmk
+include FILES_export_macosx.gmk
+
+FILES_objc = $(FILES_AWT_objc)
+OTHER_LDLIBS = -lmlib_image $(JVMLIB) $(LIBM) \
+    -framework Cocoa \
+    -framework OpenGL \
+    -framework JavaNativeFoundation \
+    -framework JavaRuntimeSupport \
+    -framework ApplicationServices \
+    -framework AudioToolbox
+
+# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ MAC OS X
+endif # PLATFORM 
+
 # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv SOLARIS-SPARC
 # solaris-sparc and solaris-sparcv9 both build 'vis'
 ifeq ("$(PLATFORM)-$(ARCH_FAMILY)", "solaris-sparc")
@@ -240,7 +268,7 @@
 # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ WINDOWS
 endif # PLATFORM
 
-ifeq ($(PLATFORM), linux)
+ifneq (,$(findstring $(PLATFORM), linux bsd))
 # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv LINUX
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)/../java2d/opengl
 vpath %.c   $(PLATFORM_SRC)/native/$(PKGDIR)/../java2d/opengl
@@ -249,6 +277,12 @@
 # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ LINUX
 endif # PLATFORM
 
+ifeq ($(PLATFORM), macosx)
+# vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv MAC OS X
+vpath %.m   $(call NativeSrcDirList,,native/com/apple/resources)
+# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ MAC OS X
+endif # PLATFORM
+
 ifeq ($(PLATFORM), windows)
 # vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv WINDOWS
 OTHER_LDLIBS = kernel32.lib user32.lib gdi32.lib winspool.lib \
@@ -391,6 +425,19 @@
 # ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ SOLARIS
 endif # PLATFORM
 
+
+ifeq ($(PLATFORM), macosx)
+# vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv MAC OS X
+
+FONTCONFIGS_SRC = $(JDK_TOPDIR)/src/macosx/classes/sun/awt/fontconfigs
+_FONTCONFIGS    = \
+        fontconfig.properties
+
+FONTCONFIGS_SRC_PREFIX = $(PLATFORM).
+
+# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ MAC OS X
+endif # PLATFORM
+
 FONTCONFIGS     = $(_FONTCONFIGS:%=$(LIBDIR)/%.src)
 BINARYFONTCONFIGS = $(_FONTCONFIGS:%.properties=$(LIBDIR)/%.bfc)
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/awt/mapfile-vers-bsd	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,577 @@
+#
+# Copyright (c) 2002, 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.
+#
+
+# Define public interface for libawt.so on Bsd.
+# Bsd port does not use mawt, all public symbols are in libawt.so
+
+SUNWprivate_1.1 {
+	global:
+		JNI_OnLoad;
+
+		Java_java_awt_CheckboxMenuItem_initIDs;
+		Java_java_awt_Color_initIDs;
+		Java_java_awt_FontMetrics_initIDs;
+		Java_java_awt_image_BufferedImage_initIDs;
+		Java_sun_awt_image_DataBufferNative_getElem;
+		Java_sun_awt_image_DataBufferNative_setElem;
+		Java_java_awt_image_ColorModel_initIDs;
+		Java_java_awt_image_ComponentSampleModel_initIDs;
+		Java_java_awt_image_IndexColorModel_initIDs;
+		Java_java_awt_image_Kernel_initIDs;
+		Java_java_awt_image_Raster_initIDs;
+		Java_java_awt_image_SampleModel_initIDs;
+		Java_java_awt_Label_initIDs;
+		Java_java_awt_MenuBar_initIDs;
+		Java_java_awt_ScrollPaneAdjustable_initIDs;
+		Java_java_awt_Toolkit_initIDs;
+		Java_java_awt_TrayIcon_initIDs;
+                Java_sun_awt_DebugSettings_setCTracingOn__Z; 
+                Java_sun_awt_DebugSettings_setCTracingOn__ZLjava_lang_String_2; 
+                Java_sun_awt_DebugSettings_setCTracingOn__ZLjava_lang_String_2I; 
+		Java_sun_awt_image_ByteComponentRaster_initIDs;
+		Java_sun_awt_image_GifImageDecoder_initIDs;
+		Java_sun_awt_image_GifImageDecoder_parseImage;
+		Java_sun_awt_image_Image_initIDs;
+		Java_sun_awt_image_ImageRepresentation_initIDs;
+		Java_sun_awt_image_ImageRepresentation_setDiffICM;
+		Java_sun_awt_image_ImageRepresentation_setICMpixels;
+		Java_sun_awt_image_ImagingLib_convolveBI;
+		Java_sun_awt_image_ImagingLib_convolveRaster;
+		Java_sun_awt_image_ImagingLib_init;
+		Java_sun_awt_image_ImagingLib_transformBI;
+		Java_sun_awt_image_ImagingLib_transformRaster;
+		Java_sun_awt_image_IntegerComponentRaster_initIDs;
+		Java_sun_awt_image_ShortComponentRaster_initIDs;
+		Java_sun_java2d_pipe_SpanClipRenderer_eraseTile;
+		Java_sun_java2d_pipe_SpanClipRenderer_fillTile;
+                Java_sun_java2d_pipe_ShapeSpanIterator_addSegment;
+                Java_sun_java2d_pipe_ShapeSpanIterator_moveTo;
+                Java_sun_java2d_pipe_ShapeSpanIterator_lineTo;
+                Java_sun_java2d_pipe_ShapeSpanIterator_quadTo;
+                Java_sun_java2d_pipe_ShapeSpanIterator_curveTo;
+                Java_sun_java2d_pipe_ShapeSpanIterator_closePath;
+                Java_sun_java2d_pipe_ShapeSpanIterator_pathDone;
+                Java_sun_java2d_pipe_ShapeSpanIterator_getNativeConsumer;
+                Java_sun_java2d_pipe_ShapeSpanIterator_appendPoly;
+                Java_sun_java2d_pipe_ShapeSpanIterator_dispose;
+                Java_sun_java2d_pipe_ShapeSpanIterator_getNativeIterator;
+                Java_sun_java2d_pipe_ShapeSpanIterator_getPathBox;
+                Java_sun_java2d_pipe_ShapeSpanIterator_initIDs;
+                Java_sun_java2d_pipe_ShapeSpanIterator_intersectClipBox;
+                Java_sun_java2d_pipe_ShapeSpanIterator_nextSpan;
+                Java_sun_java2d_pipe_ShapeSpanIterator_setNormalize;
+                Java_sun_java2d_pipe_ShapeSpanIterator_setOutputAreaXYXY;
+                Java_sun_java2d_pipe_ShapeSpanIterator_setRule;
+                Java_sun_java2d_pipe_ShapeSpanIterator_skipDownTo;
+
+		Java_java_awt_Dimension_initIDs;
+		Java_java_awt_event_MouseEvent_initIDs;
+		Java_java_awt_image_DataBufferInt_initIDs;
+		Java_java_awt_image_SinglePixelPackedSampleModel_initIDs;
+		Java_java_awt_Rectangle_initIDs;
+		Java_sun_awt_image_BufImgSurfaceData_getSurfaceData;
+		Java_sun_awt_image_BufImgSurfaceData_initIDs;
+		Java_sun_awt_image_BufImgSurfaceData_initRaster;
+		Java_sun_awt_image_BufImgSurfaceData_setSurfaceData;
+                Java_sun_awt_image_BufImgSurfaceData_freeNativeICMData;
+		Java_sun_awt_image_BytePackedRaster_initIDs;
+		Java_sun_awt_image_ImagingLib_lookupByteBI;
+		Java_sun_awt_image_ImagingLib_lookupByteRaster;
+		Java_sun_java2d_SurfaceData_initIDs;
+		Java_sun_java2d_SurfaceData_isOpaqueGray;
+		Java_sun_java2d_Disposer_initIDs;
+		Java_sun_java2d_DefaultDisposerRecord_invokeNativeDispose;
+		Java_sun_java2d_loops_BlitBg_BlitBg;
+		Java_sun_java2d_loops_Blit_Blit;
+		Java_sun_java2d_loops_ScaledBlit_Scale;
+		Java_sun_java2d_loops_DrawLine_DrawLine;
+		Java_sun_java2d_loops_DrawPolygons_DrawPolygons;
+		Java_sun_java2d_loops_DrawRect_DrawRect;
+		Java_sun_java2d_loops_FillRect_FillRect;
+		Java_sun_java2d_loops_FillSpans_FillSpans;
+		Java_sun_java2d_loops_GraphicsPrimitiveMgr_initIDs;
+		Java_sun_java2d_loops_GraphicsPrimitiveMgr_registerNativeLoops;
+		Java_sun_java2d_loops_MaskBlit_MaskBlit;
+		Java_sun_java2d_loops_MaskFill_MaskFill;
+		Java_sun_java2d_loops_MaskFill_FillAAPgram;
+		Java_sun_java2d_loops_MaskFill_DrawAAPgram;
+                Java_sun_java2d_pipe_BufferedRenderPipe_fillSpans;
+		Java_sun_java2d_pipe_SpanClipRenderer_initIDs;
+		sun_awt_image_GifImageDecoder_initIDs;
+
+		# libmawt entry points
+		SurfaceData_InitOps;
+		SurfaceData_ThrowInvalidPipeException;
+                Region_GetBounds;
+                Region_GetInfo;
+                Region_StartIteration;
+                Region_CountIterationRects;
+                Region_NextIteration;
+                Region_EndIteration;
+                GrPrim_CompGetXorInfo;
+                GrPrim_CompGetAlphaInfo;
+		img_makePalette;
+		initInverseGrayLut;
+		make_dither_arrays;
+		make_uns_ordered_dither_array;
+
+		# variables exported to libmawt
+		std_img_oda_red;
+		std_img_oda_blue;
+		std_img_oda_green;
+		std_odas_computed;
+		g_CMpDataID;
+		colorValueID;
+                jvm;
+
+		# CDE private entry point
+                # This is in awt_LoadLibrary.c and falls through to libmawt.
+                # Evidently CDE needs this for backward compatability.
+		Java_sun_awt_motif_XsessionWMcommand;
+
+		# Java Plugin
+                # This is in awt_LoadLibrary.c and falls through to libmawt.
+                # Evidently plugin needs this for backward compatability.
+		getAwtLockFunctions;
+		getAwtData;
+		getAwtDisplay;
+
+		# libfontmanager entry points
+		AWTIsHeadless;
+		GrPrim_Sg2dGetCompInfo;
+		GrPrim_Sg2dGetClip;
+		GetNativePrim;
+		SurfaceData_IntersectBounds;
+		SurfaceData_GetOps;
+		Disposer_AddRecord;
+		GrPrim_Sg2dGetEaRGB;
+		GrPrim_Sg2dGetPixel;
+		GrPrim_Sg2dGetLCDTextContrast;
+
+		#Java_sun_awt_motif_MComponentPeer_restoreFocus;
+		Java_sun_awt_DefaultMouseInfoPeer_fillPointWithCoords;
+		Java_sun_awt_DefaultMouseInfoPeer_isWindowUnderMouse;
+		Java_java_awt_AWTEvent_nativeSetSource;
+		Java_java_awt_Checkbox_initIDs;
+		Java_java_awt_Component_initIDs;
+		Java_java_awt_Dialog_initIDs;
+		Java_java_awt_Font_initIDs;
+		Java_sun_awt_KeyboardFocusManagerPeerImpl_clearNativeGlobalFocusOwner;
+                Java_sun_awt_KeyboardFocusManagerPeerImpl_getNativeFocusOwner;
+                Java_sun_awt_KeyboardFocusManagerPeerImpl_getNativeFocusedWindow;
+                Java_java_awt_KeyboardFocusManager_initIDs;
+		Java_java_awt_Menu_initIDs;
+		Java_java_awt_MenuComponent_initIDs;
+		Java_java_awt_MenuItem_initIDs;
+		Java_java_awt_Scrollbar_initIDs;
+		Java_java_awt_ScrollPane_initIDs;
+		Java_java_awt_TextArea_initIDs;
+		Java_sun_awt_FontDescriptor_initIDs;
+		#Java_sun_awt_motif_MButtonPeer_create;
+		#Java_sun_awt_motif_MButtonPeer_setLabel;
+		#Java_sun_awt_motif_MCanvasPeer_create;
+		#Java_sun_awt_motif_MCanvasPeer_initIDs;
+		#Java_sun_awt_motif_MCanvasPeer_resetTargetGC;
+		#Java_sun_awt_motif_MCheckboxMenuItemPeer_pSetState;
+		#Java_sun_awt_motif_MCheckboxPeer_create;
+		#Java_sun_awt_motif_MCheckboxPeer_setCheckboxGroup;
+		#Java_sun_awt_motif_MCheckboxPeer_setLabel;
+		#Java_sun_awt_motif_MCheckboxPeer_pSetState;
+		#Java_sun_awt_motif_MCheckboxPeer_pGetState;
+		#Java_sun_awt_motif_MChoicePeer_addItem;
+		#Java_sun_awt_motif_MChoicePeer_appendItems;
+		#Java_sun_awt_motif_MChoicePeer_create;
+		#Java_sun_awt_motif_MChoicePeer_pReshape;
+		#Java_sun_awt_motif_MChoicePeer_remove;
+		#Java_sun_awt_motif_MChoicePeer_removeAll;
+		#Java_sun_awt_motif_MChoicePeer_setBackground;
+		#Java_sun_awt_motif_MChoicePeer_pSelect;
+		#Java_sun_awt_motif_MChoicePeer_setFont;
+		#Java_sun_awt_motif_MChoicePeer_setForeground;
+		#Java_sun_awt_motif_MComponentPeer_addNativeDropTarget;
+		#Java_sun_awt_motif_MComponentPeer_createBackBuffer;
+		#Java_sun_awt_motif_MComponentPeer_destroyBackBuffer;
+		#Java_sun_awt_motif_MComponentPeer_getNativeColor;
+		#Java_sun_awt_motif_MComponentPeer_getWindow;
+		#Java_sun_awt_motif_MComponentPeer_pDisable;
+		#Java_sun_awt_motif_MComponentPeer_pDispose;
+		#Java_sun_awt_motif_MComponentPeer_pEnable;
+		#Java_sun_awt_motif_MComponentPeer_pGetLocationOnScreen;
+		#Java_sun_awt_motif_MComponentPeer_pGetLocationOnScreen2;
+		#Java_sun_awt_motif_MComponentPeer_pHide;
+		#Java_sun_awt_motif_MComponentPeer_pInitialize;
+		#Java_sun_awt_motif_MComponentPeer_pMakeCursorVisible;
+		#Java_sun_awt_motif_MComponentPeer_pReshape;
+		#Java_sun_awt_motif_MComponentPeer_pShow;
+		#Java_sun_awt_motif_MComponentPeer_removeNativeDropTarget;
+		#Java_sun_awt_motif_MComponentPeer_swapBuffers;
+		#Java_sun_awt_motif_MComponentPeer_pSetBackground;
+		#Java_sun_awt_motif_MComponentPeer_pSetFont;
+                #Java_sun_awt_motif_MComponentPeer_processSynchronousLightweightTransfer;
+                #Java_sun_awt_motif_MComponentPeer__1requestFocus;
+		#Java_sun_awt_motif_MCheckboxMenuItemPeer_getState;
+		#Java_sun_awt_motif_MComponentPeer_pSetForeground;
+		#Java_sun_awt_motif_MDragSourceContextPeer_startDrag;
+		#Java_sun_awt_motif_MDragSourceContextPeer_setNativeCursor;
+		#Java_sun_awt_motif_MDropTargetContextPeer_addTransfer;
+		#Java_sun_awt_motif_MDropTargetContextPeer_dropDone;
+		#Java_sun_awt_motif_MDropTargetContextPeer_startTransfer;
+		#Java_sun_awt_motif_X11DragSourceContextPeer_startDrag;
+		#Java_sun_awt_motif_X11DragSourceContextPeer_setNativeCursor;
+		#Java_sun_awt_motif_X11DropTargetContextPeer_sendResponse;
+		#Java_sun_awt_motif_X11DropTargetContextPeer_dropDone;
+		#Java_sun_awt_motif_X11DropTargetContextPeer_getData;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_NEFcreate;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_pShowImpl;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_pReshapePrivate;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_getBoundsPrivate;
+		#Java_sun_awt_motif_MFramePeer_pSetIconImage___3B_3I_3SII;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_requestXEmbedFocus;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_isXEmbedApplicationActive;
+		#Java_sun_awt_motif_MEmbeddedFramePeer_isXEmbedActive;
+		#Java_sun_awt_motif_MEmbeddedFrame_getWidget;
+		#Java_sun_awt_motif_MEmbeddedFrame_mapWidget;
+		#Java_sun_awt_motif_MFileDialogPeer_create;
+		#Java_sun_awt_motif_MFileDialogPeer_pDispose;
+		#Java_sun_awt_motif_MFileDialogPeer_pHide;
+		#Java_sun_awt_motif_MFileDialogPeer_pReshape;
+		#Java_sun_awt_motif_MFileDialogPeer_pShow;
+		#Java_sun_awt_motif_MFileDialogPeer_setFileEntry;
+		#Java_sun_awt_motif_MFileDialogPeer_setFont;
+		#Java_sun_awt_motif_MFramePeer_pGetIconSize;
+		#Java_sun_awt_motif_MGlobalCursorManager_cacheInit;
+		#Java_sun_awt_motif_MGlobalCursorManager_findComponentAt;
+		#Java_sun_awt_motif_MGlobalCursorManager_findHeavyweightUnderCursor;
+		#Java_sun_awt_motif_MGlobalCursorManager_getCursorPos;
+		#Java_sun_awt_motif_MGlobalCursorManager_getLocationOnScreen;
+		#Java_sun_awt_motif_MLabelPeer_create;
+		#Java_sun_awt_motif_MLabelPeer_setAlignment;
+		#Java_sun_awt_motif_MLabelPeer_setText;
+		#Java_sun_awt_motif_MListPeer_addItem;
+		#Java_sun_awt_motif_MListPeer_create;
+		#Java_sun_awt_motif_MListPeer_delItems;
+		#Java_sun_awt_motif_MListPeer_deselect;
+		#Java_sun_awt_motif_MListPeer_isSelected;
+		#Java_sun_awt_motif_MListPeer_makeVisible;
+		#Java_sun_awt_motif_MListPeer_select;
+		#Java_sun_awt_motif_MListPeer_setMultipleSelections;
+		#Java_sun_awt_motif_MMenuBarPeer_create;
+		#Java_sun_awt_motif_MMenuItemPeer_createMenuItem;
+		#Java_sun_awt_motif_MMenuItemPeer_pDisable;
+		#Java_sun_awt_motif_MMenuItemPeer_pDispose;
+		#Java_sun_awt_motif_MMenuItemPeer_pEnable;
+		#Java_sun_awt_motif_MMenuItemPeer_pSetLabel;
+		#Java_sun_awt_motif_MMenuPeer_createMenu;
+		#Java_sun_awt_motif_MMenuPeer_createSubMenu;
+		#Java_sun_awt_motif_MMenuPeer_pDispose;
+		#Java_sun_awt_motif_MPopupMenuPeer_createMenu;
+		#Java_sun_awt_motif_MPopupMenuPeer_pDispose;
+		#Java_sun_awt_motif_MPopupMenuPeer_pShow;
+		#Java_sun_awt_motif_MRobotPeer_getRGBPixelsImpl;
+		#Java_sun_awt_motif_MRobotPeer_keyPressImpl;
+		#Java_sun_awt_motif_MRobotPeer_keyReleaseImpl;
+		#Java_sun_awt_motif_MRobotPeer_mouseMoveImpl;
+		#Java_sun_awt_motif_MRobotPeer_mousePressImpl;
+		#Java_sun_awt_motif_MRobotPeer_mouseReleaseImpl;
+		#Java_sun_awt_motif_MRobotPeer_mouseWheelImpl;
+		#Java_sun_awt_motif_MRobotPeer_setup;
+		#Java_sun_awt_motif_MScrollbarPeer_create;
+		#Java_sun_awt_motif_MScrollbarPeer_setLineIncrement;
+		#Java_sun_awt_motif_MScrollbarPeer_setPageIncrement;
+		#Java_sun_awt_motif_MScrollbarPeer_pSetValues;
+		#Java_sun_awt_motif_MScrollPanePeer_create;
+		#Java_sun_awt_motif_MScrollPanePeer_pGetBlockIncrement;
+		#Java_sun_awt_motif_MScrollPanePeer_pGetScrollbarSpace;
+		#Java_sun_awt_motif_MScrollPanePeer_pGetShadow;
+		#Java_sun_awt_motif_MScrollPanePeer_pInsets;
+		#Java_sun_awt_motif_MScrollPanePeer_pSetIncrement;
+		#Java_sun_awt_motif_MScrollPanePeer_pSetScrollChild;
+		#Java_sun_awt_motif_MScrollPanePeer_setScrollPosition;
+		#Java_sun_awt_motif_MTextAreaPeer_initIDs;
+		#Java_sun_awt_motif_MTextAreaPeer_pCreate;
+		#Java_sun_awt_motif_MTextAreaPeer_getCaretPosition;
+		#Java_sun_awt_motif_MTextAreaPeer_getExtraHeight;
+		#Java_sun_awt_motif_MTextAreaPeer_getExtraWidth;
+		#Java_sun_awt_motif_MTextAreaPeer_getSelectionEnd;
+		#Java_sun_awt_motif_MTextAreaPeer_getSelectionStart;
+		#Java_sun_awt_motif_MTextAreaPeer_getText;
+		#Java_sun_awt_motif_MTextAreaPeer_insert;
+		#Java_sun_awt_motif_MTextAreaPeer_pMakeCursorVisible;
+		#Java_sun_awt_motif_MTextAreaPeer_pSetEditable;
+		#Java_sun_awt_motif_MTextAreaPeer_pShow2;
+		#Java_sun_awt_motif_MTextAreaPeer_replaceRange;
+		#Java_sun_awt_motif_MTextAreaPeer_select;
+		#Java_sun_awt_motif_MTextAreaPeer_setCaretPosition;
+		#Java_sun_awt_motif_MTextAreaPeer_setFont;
+		#Java_sun_awt_motif_MTextAreaPeer_setText;
+		#Java_sun_awt_motif_MTextAreaPeer_setTextBackground;
+		#Java_sun_awt_motif_MTextFieldPeer_initIDs;
+		#Java_sun_awt_motif_MTextFieldPeer_pCreate;
+		#Java_sun_awt_motif_MTextFieldPeer_getCaretPosition;
+		#Java_sun_awt_motif_MTextFieldPeer_getSelectionEnd;
+		#Java_sun_awt_motif_MTextFieldPeer_getSelectionStart;
+		#Java_sun_awt_motif_MTextFieldPeer_getText;
+		#Java_sun_awt_motif_MTextFieldPeer_insertReplaceText;
+		#Java_sun_awt_motif_MTextFieldPeer_preDispose;
+		#Java_sun_awt_motif_MTextFieldPeer_pSetEditable;
+		#Java_sun_awt_motif_MTextFieldPeer_select;
+		#Java_sun_awt_motif_MTextFieldPeer_setCaretPosition;
+		#Java_sun_awt_motif_MTextFieldPeer_setEchoChar;
+		#Java_sun_awt_motif_MTextFieldPeer_setFont;
+		#Java_sun_awt_motif_MTextFieldPeer_setText;
+		Java_sun_awt_motif_MToolkit_beep;
+		Java_sun_awt_motif_MToolkit_getLockingKeyStateNative;
+		Java_sun_awt_motif_MToolkit_getMulticlickTime;
+                Java_sun_awt_motif_MToolkit_getNumMouseButtons;
+		Java_sun_awt_motif_MToolkit_getScreenHeight;
+		Java_sun_awt_motif_MToolkit_getScreenResolution;
+		Java_sun_awt_motif_MToolkit_getScreenWidth;
+		Java_sun_awt_motif_MToolkit_init;
+		Java_sun_awt_motif_MToolkit_isDynamicLayoutSupportedNative;
+		Java_sun_awt_motif_MToolkit_isFrameStateSupported;
+		Java_sun_awt_motif_MToolkit_loadSystemColors;
+		Java_sun_awt_motif_MToolkit_makeColorModel;
+		Java_sun_awt_motif_MToolkit_run;
+		Java_sun_awt_motif_MToolkit_sync;
+                Java_sun_awt_motif_MToolkit_isAlwaysOnTopSupported;
+		Java_sun_awt_motif_MWindowAttributes_initIDs;
+		#Java_sun_awt_motif_MWindowPeer_pDispose;
+		#Java_sun_awt_motif_MWindowPeer_pHide;
+		#Java_sun_awt_motif_MWindowPeer_pReshape;
+		#Java_sun_awt_motif_MWindowPeer_pSetTitle;
+		#Java_sun_awt_motif_MWindowPeer_pShow;
+		#Java_sun_awt_motif_MWindowPeer_setResizable;
+		#Java_sun_awt_motif_MWindowPeer_toBack;
+		#Java_sun_awt_motif_MWindowPeer_addTextComponentNative;
+		#Java_sun_awt_motif_MWindowPeer_getState;
+		#Java_sun_awt_motif_MWindowPeer_pSetIMMOption;
+		#Java_sun_awt_motif_MWindowPeer_pSetMenuBar;
+		#Java_sun_awt_motif_MWindowPeer_pShowModal;
+		#Java_sun_awt_motif_MWindowPeer_removeTextComponentNative;
+		#Java_sun_awt_motif_MWindowPeer_setSaveUnder;
+		#Java_sun_awt_motif_MWindowPeer_setState;
+		#Java_sun_awt_motif_MWindowPeer_resetTargetGC;
+		#Java_sun_awt_motif_MWindowPeer_registerX11DropTarget;
+		#Java_sun_awt_motif_MWindowPeer_unregisterX11DropTarget;
+                #Java_sun_awt_motif_MWindowPeer_updateAlwaysOnTop;
+		#Java_sun_awt_motif_X11CustomCursor_cacheInit;
+		#Java_sun_awt_motif_X11CustomCursor_createCursor;
+		#Java_sun_awt_motif_X11CustomCursor_queryBestCursor;
+		Java_sun_awt_motif_X11FontMetrics_bytesWidth;
+		Java_sun_awt_motif_X11FontMetrics_getMFCharsWidth;
+		Java_sun_awt_motif_X11FontMetrics_init;
+		Java_sun_awt_X11InputMethod_disposeXIC;
+		Java_sun_awt_X11InputMethod_isCompositionEnabledNative;
+		Java_sun_awt_X11InputMethod_resetXIC;
+		Java_sun_awt_X11InputMethod_setCompositionEnabledNative;
+		Java_sun_awt_X11InputMethod_turnoffStatusWindow;
+		#Java_sun_awt_motif_MInputMethod_openXIMNative;
+		#Java_sun_awt_motif_MInputMethod_configureStatusAreaNative;
+		#Java_sun_awt_motif_MInputMethod_createXICNative;
+		#Java_sun_awt_motif_MInputMethod_reconfigureXICNative;
+		#Java_sun_awt_motif_MInputMethod_setXICFocusNative;
+		#Java_sun_awt_motif_X11Clipboard_getClipboardData;
+		#Java_sun_awt_motif_X11Clipboard_getClipboardFormats;
+		#Java_sun_awt_motif_X11Clipboard_registerClipboardViewer;
+		#Java_sun_awt_motif_X11Clipboard_unregisterClipboardViewer;
+		#Java_sun_awt_motif_X11Selection_init;
+		#Java_sun_awt_motif_X11Selection_pGetSelectionOwnership;
+		#Java_sun_awt_motif_X11Selection_clearNativeContext;
+		Java_sun_awt_SunToolkit_closeSplashScreen;
+		Java_sun_awt_PlatformFont_initIDs;
+		Java_sun_awt_X11GraphicsConfig_init;
+		Java_sun_awt_X11GraphicsConfig_dispose;
+		Java_sun_awt_X11GraphicsConfig_pGetBounds;
+		Java_sun_awt_X11GraphicsConfig_getNumColors;
+		Java_sun_awt_X11GraphicsConfig_getXResolution;
+		Java_sun_awt_X11GraphicsConfig_getYResolution;
+                Java_sun_awt_X11GraphicsConfig_isTranslucencyCapable;
+		Java_sun_awt_X11GraphicsDevice_isDBESupported;
+		Java_sun_awt_X11GraphicsDevice_getDisplay;
+		Java_sun_awt_X11GraphicsDevice_getDoubleBufferVisuals;
+		Java_sun_awt_X11GraphicsDevice_getNumConfigs;
+		Java_sun_awt_X11GraphicsDevice_initIDs;
+                Java_sun_awt_X11GraphicsDevice_initXrandrExtension;
+                Java_sun_awt_X11GraphicsDevice_enterFullScreenExclusive;
+                Java_sun_awt_X11GraphicsDevice_exitFullScreenExclusive;
+                Java_sun_awt_X11GraphicsDevice_getCurrentDisplayMode;
+                Java_sun_awt_X11GraphicsDevice_enumDisplayModes;
+                Java_sun_awt_X11GraphicsDevice_configDisplayMode;
+                Java_sun_awt_X11GraphicsDevice_resetNativeData;
+		Java_sun_awt_X11GraphicsEnvironment_checkShmExt;
+		Java_sun_awt_X11GraphicsEnvironment_getDefaultScreenNum;
+		Java_sun_awt_X11GraphicsEnvironment_getDisplayString;
+		Java_sun_awt_X11GraphicsEnvironment_getNumScreens;
+		Java_sun_awt_X11GraphicsEnvironment_initDisplay;
+		Java_sun_awt_X11GraphicsEnvironment_pRunningXinerama;
+		Java_sun_awt_X11GraphicsEnvironment_getXineramaCenterPoint;
+		Java_sun_awt_X11GraphicsEnvironment_initXRender;
+        
+        
+
+		Java_java_awt_AWTEvent_initIDs;
+		Java_java_awt_Button_initIDs;
+		Java_java_awt_Container_initIDs;
+		Java_java_awt_Cursor_finalizeImpl;
+		Java_java_awt_Cursor_initIDs;
+		Java_java_awt_Event_initIDs;
+		Java_java_awt_event_InputEvent_initIDs;
+		Java_java_awt_event_KeyEvent_initIDs;
+		Java_java_awt_FileDialog_initIDs;
+		Java_java_awt_Frame_initIDs;
+		Java_java_awt_Insets_initIDs;
+		Java_java_awt_TextField_initIDs;
+		Java_java_awt_Window_initIDs;
+		#Java_sun_awt_motif_MCheckboxPeer_getIndicatorSize;
+		#Java_sun_awt_motif_MCheckboxPeer_getSpacing;
+		#Java_sun_awt_motif_MChoicePeer_freeNativeData;
+		#Java_sun_awt_motif_MComponentPeer_getComponents_1NoClientCode;
+		#Java_sun_awt_motif_MComponentPeer_getParent_1NoClientCode;
+		#Java_sun_awt_motif_MComponentPeer_initIDs;
+		#Java_sun_awt_motif_MComponentPeer_nativeHandleEvent;
+		#Java_sun_awt_motif_MComponentPeer_pSetCursor;
+		#Java_sun_awt_motif_MComponentPeer_pSetInnerForeground;
+		#Java_sun_awt_motif_MComponentPeer_pSetScrollbarBackground;
+		#Java_sun_awt_motif_MComponentPeer_setTargetBackground;
+		#Java_sun_awt_motif_MDataTransferer_dragQueryFile;
+		#Java_sun_awt_motif_MDataTransferer_getAtomForTarget;
+		#Java_sun_awt_motif_MDataTransferer_getTargetNameForAtom;
+		#Java_sun_awt_motif_MFileDialogPeer_insertReplaceFileDialogText;
+		Java_sun_awt_motif_MFontPeer_initIDs;
+		#Java_sun_awt_motif_MListPeer_setBackground;
+		#Java_sun_awt_motif_MMenuBarPeer_initIDs;
+		#Java_sun_awt_motif_MMenuBarPeer_pDispose;
+		#Java_sun_awt_motif_MMenuItemPeer_getParent_1NoClientCode;
+		#Java_sun_awt_motif_MMenuItemPeer_initIDs;
+		#Java_sun_awt_motif_MMenuItemPeer_pSetShortcut;
+		#Java_sun_awt_motif_MPopupMenuPeer_initIDs;
+		#Java_sun_awt_motif_MScrollbarPeer_initIDs;
+		#Java_sun_awt_motif_MScrollPanePeer_initIDs;
+		#Java_sun_awt_motif_MTextAreaPeer_pSetCursor;
+		Java_sun_awt_motif_MToolkit_shutdown;
+		#Java_sun_awt_motif_MWindowPeer_initIDs;
+		#Java_sun_awt_motif_MWindowPeer_pCreate;
+		#Java_sun_awt_motif_MWindowPeer_wrapInSequenced;
+		Java_sun_awt_motif_X11FontMetrics_initIDs;
+		#Java_sun_awt_X11InputMethod_initIDs;
+		Java_sun_awt_motif_X11OffScreenImage_updateBitmask;
+		#Java_sun_awt_motif_X11Selection_initIDs;
+		Java_sun_awt_motif_MToolkitThreadBlockedHandler_enter;
+		Java_sun_awt_motif_MToolkitThreadBlockedHandler_exit;
+		Java_sun_awt_X11GraphicsConfig_init;
+		Java_sun_awt_X11GraphicsConfig_initIDs;
+		Java_sun_awt_X11GraphicsConfig_makeColorModel;
+		Java_sun_awt_X11GraphicsDevice_getConfigVisualId;
+		Java_sun_awt_X11PMBlitLoops_Blit;
+		Java_sun_awt_X11PMBlitBgLoops_nativeBlitBg;
+		Java_sun_awt_X11Renderer_devFillSpans;
+		Java_sun_awt_X11Renderer_doDrawArc;
+		Java_sun_awt_X11Renderer_doDrawLine;
+		Java_sun_awt_X11Renderer_doDrawOval;
+		Java_sun_awt_X11Renderer_doDrawPoly;
+		Java_sun_awt_X11Renderer_doDrawRect;
+		Java_sun_awt_X11Renderer_doDrawRoundRect;
+		Java_sun_awt_X11Renderer_doFillArc;
+		Java_sun_awt_X11Renderer_doFillOval;
+		Java_sun_awt_X11Renderer_doFillPoly;
+		Java_sun_awt_X11Renderer_doFillRect;
+		Java_sun_awt_X11Renderer_doFillRoundRect;
+		Java_sun_awt_X11Renderer_devCopyArea;
+		Java_sun_awt_X11SurfaceData_initIDs;
+		Java_sun_awt_X11SurfaceData_initOps;
+		Java_sun_awt_X11SurfaceData_initSurface;
+		Java_sun_awt_X11SurfaceData_isDgaAvailable;
+		Java_sun_awt_X11SurfaceData_setInvalid;
+		Java_sun_awt_X11SurfaceData_flushNativeSurface;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_initXEmbedServer;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_destroyXEmbedServer;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_isXEmbedActive;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_initDispatching;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_endDispatching;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_embedChild;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_childDestroyed;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_getEmbedPreferredSize;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_getEmbedMinimumSize;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_getClientBounds;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_notifyChildEmbedded;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_detachChild;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_forwardKeyEvent;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_getAWTKeyCodeForKeySym;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_sendMessage__I;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_sendMessage__IJJJ;
+                #Java_sun_awt_motif_MEmbedCanvasPeer_getWindow;       
+                #Java_sun_awt_motif_MEmbedCanvasPeer_forwardEventToEmbedded;       
+                #Java_sun_awt_motif_GrabbedKey_initKeySymAndModifiers;
+                #Java_sun_awt_motif_MEmbeddedFramePeer_traverseOut;
+		awt_display;
+		awt_lock;
+		awt_Lock;
+		awt_Unlock;
+	        awt_GetDrawingSurface;
+	        awt_FreeDrawingSurface;
+	        awt_GetComponent;
+
+		X11SurfaceData_GetOps;
+		getDefaultConfig;
+                Java_sun_font_FontConfigManager_getFontConfig;
+                Java_sun_font_FontConfigManager_getFontConfigAASettings;
+		Java_sun_awt_X11FontManager_getFontPathNative;
+		Java_sun_font_SunFontManager_populateFontFileNameMap;
+
+		# CDE private entry point
+		Java_sun_awt_motif_XsessionWMcommand;
+
+		# Java Plugin
+		getAwtLockFunctions;
+		getAwtData;
+		getAwtDisplay;
+		
+		# libfontmanager entry points
+		AWTIsHeadless;
+		AWTCountFonts;
+                AWTLoadFont;
+                AWTFreeFont;
+                AWTFontMinByte1;
+                AWTFontMaxByte1;
+                AWTFontMinCharOrByte2;
+                AWTFontMaxCharOrByte2;
+                AWTFontDefaultChar;
+                AWTFontPerChar;
+                AWTFontMaxBounds;
+                AWTFontTextExtents16;
+                AWTFreeChar;
+                AWTFontGenerateImage;
+                AWTCharAdvance;
+                AWTCharLBearing;
+                AWTCharRBearing;
+                AWTCharAscent;
+                AWTCharDescent;
+                AWTDrawGlyphList;
+                AccelGlyphCache_RemoveAllCellInfos;
+
+	local:
+		*;
+};
+
--- a/make/sun/awt/mawt.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/awt/mawt.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -169,7 +169,7 @@
 OTHER_LDLIBS = -lXt -lXext $(LIBXTST) $(LIBXMU) -lX11 -lXi
 endif
 
-ifeq ($(PLATFORM), linux)
+ifneq (,$(findstring $(PLATFORM), linux macosx))
 OTHER_CFLAGS += -DMLIB_NO_LIBSUNMATH
 # XXX what is this define below? Isn't it motif-related?
 OTHER_CFLAGS += -DXMSTRINGDEFINES=1
@@ -180,7 +180,7 @@
 # !HEADLESS
 
 OTHER_LDLIBS += $(JVMLIB) $(LIBCXX) \
-                -lawt $(LIBM) -ldl
+                -lawt $(LIBM) $(LIBDL)
 
 #
 # Sun CC with -Xa misdefines __STDC__ to 0 (zero).
@@ -223,16 +223,35 @@
         -I$(PLATFORM_SRC)/native/$(PKGDIR) \
         $(EVENT_MODEL)
 
+ifeq ($(PLATFORM), macosx)
+CPPFLAGS += -I$(CUPS_HEADERS_PATH)
+
+ifndef HEADLESS
+CPPFLAGS += -I$(MOTIF_DIR)/include \
+            -I$(OPENWIN_HOME)/include 
+LDFLAGS  += -L$(MOTIF_LIB) -L$(OPENWIN_LIB)
+
+endif # !HEADLESS
+endif # PLATFORM
+
 ifeq ($(PLATFORM), linux)
   # Checking for the X11/extensions headers at the additional location
   CPPFLAGS += -I$(firstword $(wildcard $(OPENWIN_HOME)/include/X11/extensions) \
                         $(wildcard /usr/include/X11/extensions))
 endif
 
+ifeq ($(PLATFORM), macosx))
+  CPPFLAGS += -I$(OPENWIN_HOME)/include/X11/extensions \
+              -I$(OPENWIN_HOME)/include 
+endif
+
 ifeq ($(PLATFORM), solaris)
   CPPFLAGS += -I$(OPENWIN_HOME)/include/X11/extensions
 endif
 
+ifeq ($(PLATFORM), macosx)
+  CPPFLAGS += -DX11_PATH=\"$(X11_PATH)\" -DPACKAGE_PATH=\"$(PACKAGE_PATH)\"
+endif
 
 LDFLAGS += -L$(LIBDIR)/$(LIBARCH)/$(TSOBJDIR) \
 	   $(AWT_RUNPATH)
--- a/make/sun/cmm/lcms/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/cmm/lcms/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -93,7 +93,11 @@
 	$(RM) $(OBJDIR)/cmm.h
 
 else
-OTHER_LDLIBS = $(LIBM) -lawt -L$(LIBDIR)/$(LIBARCH)/xawt 
+ifeq ($(PLATFORM), macosx)
+OTHER_LDLIBS = $(LIBM) -lawt -L$(LIBDIR)/xawt
+else
+OTHER_LDLIBS = $(LIBM) -lawt -L$(LIBDIR)/$(LIBARCH)/xawt
+endif
 CPPFLAGS += -I$(SHARE_SRC)/native/sun/java2d \
             -I$(SHARE_SRC)/native/sun/awt/debug
 endif
--- a/make/sun/font/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/font/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -172,6 +172,15 @@
 # Libraries to link, and other C flags.
 #
 
+ifeq ($(PLATFORM), macosx))
+OTHER_INCLUDES += -I$(X11_PATH)/include
+OTHER_LDLIBS  += -lawt $(LIBM) $(LIBCXX)
+ ifeq ($(OS_VENDOR),Apple)
+   # XXXDARWIN Match BSD/Linux behavior -- the mawt.dylib symbols will
+   # be available at runtime.
+   OTHER_LDLIBS += -undefined dynamic_lookup
+ endif
+else
 ifeq ($(PLATFORM), solaris)
   # Note that on Solaris, fontmanager is built against the headless library.
   LDFLAGS      += -L$(LIBDIR)/$(LIBARCH)/headless
@@ -182,11 +191,16 @@
     OTHER_LDLIBS  += -Wl,-Bstatic -lgcc_eh -Wl,-Bdynamic
   endif                           
 endif
+endif
 
 endif # PLATFORM
 
 # set up compile flags..
 
+ifeq ($(PLATFORM), macosx))
+CPPFLAGS += -I$(CLASSHDRDIR)
+endif
+
 CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR) \
             -I$(SHARE_SRC)/native/$(PKGDIR)/layout \
 	    -I$(SHARE_SRC)/native/sun/awt/image/cvutils \
--- a/make/sun/headless/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/headless/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -28,7 +28,12 @@
 NO_ROBOT = true
 MOTIF_VERSION = none
 MOTIF_VERSION_STRING=none
+
+ifeq ($(PLATFORM), macosx)
+LIB_LOCATION = $(LIBDIR)/headless
+else
 LIB_LOCATION = $(LIBDIR)/$(LIBARCH)/headless
+endif
 
 PACKAGE = sun.awt
 LIBRARY = mawt
--- a/make/sun/image/generic/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/image/generic/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -70,6 +70,6 @@
 OTHER_CFLAGS += -D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES
 
 ifneq ($(PLATFORM), windows)
-	OTHER_LDLIBS = $(LIBM) -ldl
+	OTHER_LDLIBS = $(LIBM) $(LIBDL)
 endif
 
--- a/make/sun/image/vis/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/image/vis/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -68,5 +68,5 @@
 CFLAGS += $(CFLAGS_$(ARCH)) $(INLINE) -I$(PLATFORM_SRC)/native/sun/awt/medialib -I$(SHARE_SRC)/native/sun/awt/medialib
 
 OTHER_CFLAGS += -D__USE_J2D_NAMES -D__MEDIALIB_OLD_NAMES
-OTHER_LDLIBS = $(LIBM) -ldl
+OTHER_LDLIBS = $(LIBM) $(LIBDL)
 
--- a/make/sun/jawt/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/jawt/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -35,6 +35,8 @@
 #
 ifeq ($(PLATFORM), windows)
 FILES_cpp = jawt.cpp
+else ifeq ($(PLATFORM), macosx) # PLATFORM
+FILES_objc = jawt.m
 else # PLATFORM
 FILES_c = jawt.c
 endif # PLATFORM
@@ -108,6 +110,7 @@
 	    -I$(SHARE_SRC)/native/$(PKGDIR)/../dc/path \
             -I$(PLATFORM_SRC)/native/$(PKGDIR)/../jdga \
 	    $(EVENT_MODEL)
+
 #
 # Libraries to link in.
 #
@@ -128,8 +131,13 @@
   endif
 endif # PLATFORM
 
+ifeq ($(PLATFORM), macosx)
+vpath %.m   $(call NativeSrcDirList,,native/sun/awt)
+OTHER_LDLIBS = -llwawt -L$(LIBDIR)/lwawt -Xlinker -rpath -Xlinker @loader_path/lwawt \
+               -framework Cocoa
 endif # PLATFORM
 
+endif # PLATFORM
 
 #
 # Lets not remove any class files.
--- a/make/sun/jdga/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/jdga/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -55,7 +55,7 @@
 vpath %.c   $(PLATFORM_SRC)/native/$(PKGDIR)
 
 ifneq ($(PLATFORM), windows)
-  LDLIBS =  -ldga -lX11 -ldl -lc
+  LDLIBS =  -ldga -lX11 $(LIBDL) -lc
 
   CPPFLAGS += \
 	-I$(SHARE_SRC)/javavm/export \
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/lwawt/FILES_c_macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,100 @@
+#
+# Copyright (c) 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.
+#
+
+FILES_objc = \
+        awt.m \
+        ApplicationDelegate.m \
+        CFRetainedResource.m \
+        CGLGraphicsConfig.m \
+        CGLSurfaceData.m \
+        CGLLayer.m \
+        CGraphicsConfig.m \
+        CGraphicsDevice.m \
+        CGraphicsEnv.m \
+        CCharToGlyphMapper.m \
+        CSystemColors.m \
+        AWTFont.m \
+        CGGlyphOutlines.m \
+        CGGlyphImages.m \
+        CoreTextSupport.m \
+        AWTStrike.m \
+        InitIDs.m \
+        AWTEvent.m \
+        AWTView.m \
+        AWTWindow.m \
+	AWTSurfaceLayers.m \
+        CCursorManager.m \
+        CClipboard.m \
+        CDataTransferer.m \
+        CDragSource.m \
+        CDragSourceContextPeer.m \
+        CDropTarget.m \
+        CDropTargetContextPeer.m \
+        CInputMethod.m \
+				CDesktopPeer.m \
+        OSVersion.m \
+        DnDUtilities.m \
+        CFileDialog.m \
+        CImage.m \
+        CMenu.m \
+        CMenuBar.m \
+        CMenuComponent.m \
+        CMenuItem.m \
+        CPopupMenu.m \
+        CRobot.m \
+        CTrayIcon.m \
+        CWrapper.m \
+        JavaAccessibilityAction.m \
+        JavaAccessibilityUtilities.m \
+        JavaComponentAccessibility.m \
+        JavaTextAccessibility.m \
+        LWCToolkit.m \
+        GeomUtilities.m \
+        CPrinterJob.m \
+        PrintModel.m \
+        PrinterSurfaceData.m \
+        PrinterView.m \
+        QuartzSurfaceData.m \
+        QuartzRenderer.m \
+        CTextPipe.m \
+        ImageSurfaceData.m \
+        awt_DrawingSurface.m
+
+FILES_c = \
+        OGLBlitLoops.c \
+        OGLBufImgOps.c \
+        OGLContext.c \
+        OGLFuncs.c \
+        OGLMaskBlit.c \
+        OGLMaskFill.c \
+        OGLPaints.c \
+        OGLRenderQueue.c \
+        OGLRenderer.c \
+        OGLSurfaceData.c \
+        OGLTextRenderer.c \
+        OGLVertexCache.c \
+        AccelGlyphCache.c \
+        CUPSfuncs.c
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/lwawt/FILES_export_macosx.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,279 @@
+#
+# Copyright (c) 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.
+#
+
+# FILES_export definitions for Mac OS X
+
+FILES_export = \
+        com/apple/eawt/Application.java \
+        com/apple/eawt/_AppDockIconHandler.java \
+        com/apple/eawt/_AppEventHandler.java \
+        com/apple/eawt/_AppEventLegacyHandler.java \
+        com/apple/eawt/_AppMenuBarHandler.java \
+        com/apple/eawt/_AppMiscHandlers.java \
+        com/apple/eawt/event/GestureHandler.java \
+        com/apple/eawt/FullScreenAdapter.java \
+        com/apple/eawt/FullScreenHandler.java \
+        com/apple/eawt/FullScreenListener.java \
+        com/apple/eawt/FullScreenUtilities.java \
+        sun/font/FontManager.java \
+        sun/awt/image/ImageRepresentation.java \
+        sun/awt/image/GifImageDecoder.java \
+        sun/awt/image/NativeLibLoader.java \
+        sun/java2d/CRenderer.java \
+        sun/java2d/CompositeCRenderer.java \
+        sun/java2d/DataBufferNIOInt.java \
+        sun/java2d/IntegerNIORaster.java \
+        sun/java2d/OSXSurfaceData.java \
+        sun/java2d/OSXOffScreenSurfaceData.java \
+        sun/java2d/loops/Blit.java \
+        sun/java2d/loops/BlitBg.java \
+        sun/java2d/loops/ScaledBlit.java \
+        sun/java2d/loops/TransformBlit.java \
+        sun/java2d/loops/FillRect.java \
+        sun/java2d/loops/FillSpans.java \
+        sun/java2d/loops/FillParallelogram.java \
+        sun/java2d/loops/DrawParallelogram.java \
+        sun/java2d/loops/DrawGlyphList.java \
+        sun/java2d/loops/DrawGlyphListAA.java \
+        sun/java2d/loops/DrawGlyphListLCD.java \
+        sun/java2d/loops/DrawLine.java \
+        sun/java2d/loops/DrawRect.java \
+        sun/java2d/loops/DrawPolygons.java \
+        sun/java2d/loops/DrawPath.java \
+        sun/java2d/loops/FillPath.java \
+        sun/java2d/loops/MaskBlit.java \
+        sun/java2d/loops/MaskFill.java \
+        sun/java2d/loops/TransformHelper.java \
+        sun/java2d/loops/GraphicsPrimitiveMgr.java \
+        sun/java2d/loops/GraphicsPrimitive.java \
+        sun/java2d/pipe/hw/AccelSurface.java \
+        sun/java2d/pipe/hw/AccelDeviceEventNotifier.java \
+        sun/java2d/pipe/hw/ContextCapabilities.java \
+        sun/awt/image/ImagingLib.java \
+        sun/java2d/SurfaceData.java \
+        sun/java2d/SunGraphics2D.java \
+        sun/awt/KeyboardFocusManagerPeerImpl.java \
+        sun/awt/image/BufImgSurfaceData.java \
+        sun/awt/image/DataBufferNative.java \
+        \
+        sun/awt/CGraphicsConfig.java \
+        sun/awt/CGraphicsDevice.java \
+        sun/awt/CGraphicsEnvironment.java \
+        sun/font/CCharToGlyphMapper.java \
+        sun/font/CFont.java \
+        sun/font/CFontConfiguration.java \
+        sun/font/CFontManager.java \
+        sun/font/CStrike.java \
+        sun/font/CStrikeDisposer.java \
+        sun/java2d/BackBufferCapsProvider.java \
+        sun/java2d/MacosxSurfaceManagerFactory.java \
+        sun/lwawt/LWButtonPeer.java \
+        sun/lwawt/LWCanvasPeer.java \
+        sun/lwawt/LWCheckboxPeer.java \
+        sun/lwawt/LWChoicePeer.java \
+        sun/lwawt/LWComponentPeer.java \
+        sun/lwawt/LWContainerPeer.java \
+        sun/lwawt/LWCursorManager.java \
+        sun/lwawt/LWKeyboardFocusManagerPeer.java \
+        sun/lwawt/LWLabelPeer.java \
+        sun/lwawt/LWListPeer.java \
+        sun/lwawt/LWMouseInfoPeer.java \
+        sun/lwawt/LWPanelPeer.java \
+        sun/lwawt/LWRepaintArea.java \
+        sun/lwawt/LWScrollBarPeer.java \
+        sun/lwawt/LWScrollPanePeer.java \
+        sun/lwawt/LWTextComponentPeer.java \
+        sun/lwawt/LWTextFieldPeer.java \
+        sun/lwawt/LWToolkit.java \
+        sun/lwawt/LWWindowPeer.java \
+        sun/lwawt/PlatformWindow.java \
+        sun/lwawt/SelectionClearListener.java \
+        sun/lwawt/macosx/CPrinterDevice.java \
+        sun/lwawt/macosx/CPrinterDialog.java \
+        sun/lwawt/macosx/CPrinterDialogPeer.java \
+        sun/lwawt/macosx/CPrinterGraphics.java \
+        sun/lwawt/macosx/CPrinterGraphicsConfig.java \
+        sun/lwawt/macosx/CPrinterJob.java \
+        sun/lwawt/macosx/CPrinterJobDialog.java \
+        sun/lwawt/macosx/CPrinterPageDialog.java \
+        sun/lwawt/macosx/CPrinterSurfaceData.java \
+        sun/lwawt/macosx/CTextPipe.java \
+        sun/lwawt/macosx/CDesktopPeer.java \
+        sun/java2d/CRenderer.java \
+        sun/lwawt/macosx/EventDispatchAccess.java \
+        sun/lwawt/macosx/NSPrintInfo.java \
+        sun/lwawt/macosx/CAccessibility.java \
+        sun/lwawt/macosx/CAccessible.java \
+        sun/lwawt/macosx/CFRetainedResource.java \
+        sun/lwawt/macosx/CCheckboxMenuItem.java \
+        sun/lwawt/macosx/CClipboard.java \
+        sun/lwawt/macosx/CDataTransferer.java \
+        sun/lwawt/macosx/CDragSourceContextPeer.java \
+        sun/lwawt/macosx/CMouseDragGestureRecognizer.java \
+        sun/lwawt/macosx/CDropTarget.java \
+        sun/lwawt/macosx/CDropTargetContextPeer.java \
+        sun/lwawt/macosx/CCursorManager.java \
+        sun/lwawt/macosx/CFileDialog.java \
+        sun/lwawt/macosx/CImage.java \
+        sun/lwawt/macosx/CMenu.java \
+        sun/lwawt/macosx/CMenuBar.java \
+        sun/lwawt/macosx/CMenuComponent.java \
+        sun/lwawt/macosx/CMenuItem.java \
+        sun/lwawt/macosx/CMouseInfoPeer.java \
+        sun/lwawt/macosx/CPlatformView.java \
+        sun/lwawt/macosx/CPlatformWindow.java \
+        sun/lwawt/macosx/CPlatformComponent.java \
+        sun/lwawt/macosx/CEmbeddedFrame.java \
+        sun/lwawt/macosx/CPlatformEmbeddedFrame.java \
+        sun/lwawt/macosx/CPlatformResponder.java \
+        sun/lwawt/macosx/CPopupMenu.java \
+        sun/lwawt/macosx/CRobot.java \
+        sun/lwawt/macosx/CSystemTray.java \
+        sun/lwawt/macosx/CTrayIcon.java \
+        sun/lwawt/macosx/CWrapper.java \
+        sun/lwawt/macosx/CocoaConstants.java \
+        sun/lwawt/macosx/LWCToolkit.java \
+        sun/lwawt/macosx/CInputMethod.java \
+        sun/lwawt/macosx/CInputMethodDescriptor.java \
+        sun/lwawt/macosx/event/NSEvent.java \
+        \
+        sun/awt/DebugSettings.java \
+        sun/awt/EmbeddedFrame.java \
+        sun/awt/PlatformFont.java \
+        sun/awt/FontDescriptor.java \
+        sun/awt/NativeLibLoader.java \
+        sun/awt/CharsetString.java \
+        sun/awt/SunHints.java \
+        sun/java2d/pipe/BufferedContext.java \
+        sun/java2d/pipe/BufferedMaskBlit.java \
+        sun/java2d/pipe/BufferedOpCodes.java \
+        sun/java2d/pipe/BufferedMaskBlit.java \
+        sun/java2d/pipe/BufferedPaints.java \
+        sun/java2d/pipe/BufferedRenderPipe.java \
+        sun/java2d/pipe/BufferedTextPipe.java \
+        sun/java2d/pipe/RenderBuffer.java \
+        sun/java2d/pipe/ShapeSpanIterator.java \
+        sun/java2d/pipe/SpanClipRenderer.java \
+        sun/java2d/pipe/RegionIterator.java \
+        sun/awt/image/IntegerComponentRaster.java \
+        sun/java2d/cmm/CMSManager.java \
+        sun/java2d/cmm/PCMM.java \
+        sun/java2d/cmm/ColorTransform.java \
+        sun/awt/datatransfer/DataTransferer.java \
+        sun/awt/dnd/SunDragSourceContextPeer.java \
+        sun/java2d/opengl/OGLBlitLoops.java \
+        sun/java2d/opengl/OGLContext.java \
+        sun/java2d/opengl/OGLMaskFill.java \
+        sun/java2d/opengl/OGLPaints.java \
+        sun/java2d/opengl/OGLRenderer.java \
+        sun/java2d/opengl/OGLRenderQueue.java \
+        sun/java2d/opengl/OGLSurfaceData.java \
+        sun/java2d/opengl/OGLTextRenderer.java \
+        sun/java2d/opengl/CGLGraphicsConfig.java \
+        sun/java2d/opengl/CGLSurfaceData.java \
+        sun/java2d/opengl/CGLLayer.java \
+        sun/awt/ExtendedKeyCodes.java 
+
+FILES_export2 = \
+        java/awt/AlphaComposite.java \
+        java/awt/MouseInfo.java \
+        java/awt/Cursor.java \
+        java/awt/Graphics.java \
+        java/awt/Color.java \
+        java/awt/Image.java \
+        java/awt/Rectangle.java \
+        java/awt/Event.java \
+        java/awt/Font.java \
+        java/awt/Insets.java \
+        java/awt/Point.java \
+        java/awt/FontMetrics.java \
+        java/awt/Toolkit.java \
+        java/awt/Component.java \
+        java/awt/Container.java \
+        java/awt/Canvas.java \
+        java/awt/Button.java \
+        java/awt/List.java \
+        java/awt/Adjustable.java \
+        java/awt/Scrollbar.java \
+        java/awt/ScrollPane.java \
+        java/awt/ScrollPaneAdjustable.java \
+        java/awt/Window.java \
+        java/awt/TextField.java \
+        java/awt/Label.java \
+        java/awt/Choice.java \
+        java/awt/TextArea.java \
+        java/awt/MenuBar.java \
+        java/awt/Menu.java \
+        java/awt/MenuComponent.java \
+        java/awt/PopupMenu.java \
+        java/awt/Dialog.java \
+        java/awt/FileDialog.java \
+        java/awt/MenuItem.java \
+        java/awt/Checkbox.java \
+        java/awt/CheckboxMenuItem.java \
+        java/awt/CheckboxGroup.java \
+        java/awt/Frame.java \
+        java/awt/Transparency.java \
+        java/awt/AWTException.java \
+        java/awt/AWTEvent.java \
+        java/awt/AWTKeyStroke.java \
+        java/awt/KeyboardFocusManager.java \
+        java/awt/Dimension.java \
+        java/awt/SystemColor.java \
+        java/awt/TrayIcon.java \
+        java/awt/DisplayMode.java \
+        java/awt/color/ColorSpace.java \
+        java/awt/color/ICC_Profile.java \
+        java/awt/geom/PathIterator.java \
+        java/awt/image/AffineTransformOp.java \
+        java/awt/image/ImageConsumer.java \
+        java/awt/image/ImageObserver.java \
+        java/awt/image/BufferedImage.java \
+        java/awt/image/ColorModel.java \
+        java/awt/image/ConvolveOp.java \
+        java/awt/image/DirectColorModel.java \
+        java/awt/image/IndexColorModel.java \
+        java/awt/image/DataBuffer.java \
+        java/awt/datatransfer/Transferable.java \
+        java/awt/datatransfer/DataFlavor.java \
+        java/awt/datatransfer/UnsupportedFlavorException.java \
+        java/awt/datatransfer/Clipboard.java \
+        java/awt/datatransfer/ClipboardOwner.java \
+        java/awt/datatransfer/StringSelection.java \
+        java/awt/event/AdjustmentEvent.java \
+        java/awt/event/KeyEvent.java \
+        java/awt/event/MouseEvent.java \
+        java/awt/event/MouseWheelEvent.java \
+        java/awt/event/FocusEvent.java \
+        java/awt/event/InputEvent.java \
+        java/awt/event/WindowEvent.java \
+        java/awt/event/NativeLibLoader.java \
+        java/awt/peer/ComponentPeer.java \
+        java/awt/dnd/DnDConstants.java \
+        sun/awt/CausedFocusEvent.java \
+        java/awt/print/PageFormat.java \
+        java/awt/print/Pageable.java \
+        java/awt/print/Printable.java \
+        java/awt/BasicStroke.java
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/lwawt/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,114 @@
+#
+# Copyright (c) 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 = ../..
+MODULE  = awt
+PACKAGE = sun.lwawt
+LIBRARY = lwawt
+PRODUCT = sun
+
+LIB_LOCATION = $(LIBDIR)/lwawt
+
+include $(BUILDDIR)/common/Defs.gmk
+
+#
+# Files
+#
+include FILES_c_macosx.gmk
+include FILES_export_macosx.gmk
+AUTO_FILES_JAVA_DIRS = sun/awt sun/font sun/lwawt sun/lwawt/macosx sun/java2d sun/java2d/opengl com/apple/eawt
+
+#
+# Rules.
+#
+# include $(BUILDDIR)/common/Mapfile-vers.gmk
+include $(BUILDDIR)/common/Library.gmk
+
+#
+# Add to the ambient vpath to pick up files in subdirectories
+#
+vpath %.c   $(SHARE_SRC)/native/sun/awt/debug
+vpath %.c   $(SHARE_SRC)/native/sun/awt/image
+vpath %.c   $(SHARE_SRC)/native/sun/awt/image/gif
+vpath %.c   $(SHARE_SRC)/native/sun/awt/image/cvutils
+vpath %.c   $(SHARE_SRC)/native/sun/awt/shell
+vpath %.c   $(SHARE_SRC)/native/sun/java2d
+vpath %.c   $(SHARE_SRC)/native/sun/java2d/loops
+vpath %.c   $(SHARE_SRC)/native/sun/java2d/pipe
+vpath %.c   $(SHARE_SRC)/native/sun/java2d/opengl
+vpath %.c   $(SHARE_SRC)/native/sun/awt/medialib
+vpath %.c   $(SHARE_SRC)/native/sun/awt/utility
+vpath %.c   $(SHARE_SRC)/native/sun/font
+vpath %.c   $(call NativeSrcDirList,,native/sun/awt)
+
+vpath %.cpp $(SHARE_SRC)/native/sun/image
+
+vpath %.m   $(call NativeSrcDirList,,native/sun/awt)
+vpath %.m   $(call NativeSrcDirList,,native/sun/font)
+vpath %.m   $(call NativeSrcDirList,,native/sun/java2d)
+vpath %.m   $(call NativeSrcDirList,,native/sun/java2d/opengl)
+
+OTHER_LDLIBS += \
+	-lawt -lmlib_image -losxapp $(JVMLIB) $(LIBM) \
+	-framework Accelerate \
+	-framework ApplicationServices \
+	-framework AudioToolbox \
+	-framework Carbon \
+	-framework Cocoa \
+	-framework Security \
+	-framework ExceptionHandling \
+	-framework JavaNativeFoundation \
+	-framework JavaRuntimeSupport \
+	-framework OpenGL \
+        -framework QuartzCore
+CPPFLAGS += \
+        -I$(CLASSHDRDIR) \
+        -I$(SHARE_SRC)/native/sun/awt/debug \
+        -I$(SHARE_SRC)/native/sun/awt/image/cvutils \
+        -I$(SHARE_SRC)/native/sun/java2d \
+	-I$(SHARE_SRC)/native/sun/java2d/loops \
+	-I$(SHARE_SRC)/native/sun/awt/image/cvutils \
+	-I$(SHARE_SRC)/native/sun/awt/image \
+	-I$(SHARE_SRC)/native/sun/font \
+	-I$(SHARE_SRC)/native/sun/java2d/pipe \
+	-I$(SHARE_SRC)/native/sun/java2d/opengl \
+	-I$(SHARE_SRC)/native/sun/dc/path \
+	-I$(SHARE_SRC)/native/sun/dc/doe \
+	-I$(SHARE_SRC)/native/sun/awt/alphacomposite \
+        -I$(SHARE_SRC)/native/sun/awt/medialib \
+        -I$(SHARE_SRC)/native/sun/awt \
+        $(call NativeSrcDirList,-I,/native/sun/awt) \
+        $(call NativeSrcDirList,-I,/native/sun/osxapp) \
+        $(call NativeSrcDirList,-I,/native/sun/font) \
+	$(call NativeSrcDirList,-I,/native/sun/java2d) \
+	$(call NativeSrcDirList,-I,/native/sun/java2d/opengl)
+
+ifeq ($(MILESTONE), internal)
+  CPPFLAGS += -DINTERNAL_BUILD
+endif
+
+clean clobber::
+
+.PHONY:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/sun/osxapp/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,75 @@
+#
+# Copyright (c) 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 = ../..
+LIBRARY = osxapp
+PRODUCT = sun
+include $(BUILDDIR)/common/Defs.gmk
+
+#
+# Files
+#
+FILES_objc = \
+	NSApplicationAWT.m \
+	QueuingApplicationDelegate.m \
+	PropertiesUtilities.m \
+	ThreadUtilities.m
+
+#
+# Rules.
+#
+include $(BUILDDIR)/common/Library.gmk
+
+#
+# Add to the ambient vpath to pick up files in subdirectories
+#
+vpath %.m   $(call NativeSrcDirList,,native/sun/osxapp)
+
+# TODO: perhaps not all of the below frameworks are required
+OTHER_LDLIBS += \
+	-framework Accelerate \
+	-framework ApplicationServices \
+	-framework AudioToolbox \
+	-framework Carbon \
+	-framework Cocoa \
+	-framework Security \
+	-framework ExceptionHandling \
+	-framework JavaNativeFoundation \
+	-framework JavaRuntimeSupport \
+	-framework OpenGL \
+	-framework IOSurface \
+	-framework QuartzCore
+
+CPPFLAGS += \
+        $(call NativeSrcDirList,-I,/native/sun/osxapp)
+
+
+ifeq ($(MILESTONE), internal)
+  CPPFLAGS += -DINTERNAL_BUILD
+endif
+
+clean clobber::
+
+.PHONY:
--- a/make/sun/security/ec/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/security/ec/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -192,7 +192,7 @@
   ifeq ($(PLATFORM), windows)
     OTHER_LDLIBS += $(JVMLIB)
   else
-    OTHER_LDLIBS = -ldl $(JVMLIB) $(LIBCXX)
+    OTHER_LDLIBS = $(LIBDL) $(JVMLIB) $(LIBCXX)
   endif
 
   include $(BUILDDIR)/common/Mapfile-vers.gmk
--- a/make/sun/security/jgss/wrapper/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/security/jgss/wrapper/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -72,5 +72,5 @@
 # Libraries to link
 #
 ifneq ($(PLATFORM), windows)
-  OTHER_LDLIBS = -ldl $(JVMLIB)
+  OTHER_LDLIBS = $(LIBDL) $(JVMLIB)
 endif
--- a/make/sun/security/krb5/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/security/krb5/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -33,6 +33,12 @@
 #
 AUTO_FILES_JAVA_DIRS = sun/security/krb5
 
+ifeq ($(PLATFORM), macosx)
+FILES_export = sun/security/krb5/Credentials.java
+FILES_c = nativeccache.c
+LIBRARY = osxkrb5
+endif # PLATFORM
+
 ifeq ($(PLATFORM), windows)
 #
 # Java files that define native methods
@@ -52,8 +58,12 @@
 #
 # Find native code
 #
-vpath %.c \
-  $(PLATFORM_SRC)/native/sun/security/krb5
+ifeq ($PLATFORM), macosx)
+  vpath %.c $(call NativeSrcDirList,,native/sun/security/krb5)
+else
+  vpath %.c \
+    $(PLATFORM_SRC)/native/sun/security/krb5
+endif
 
 JGSS_NATIVE_SRC=$(PLATFORM_SRC)/native/sun/security/krb5
 JGSS_NATIVE_DIR_EXISTS := $(shell if [ -d $(JGSS_NATIVE_SRC) ] ; then echo true; else echo false; fi)
@@ -65,6 +75,8 @@
   ifeq ($(JGSS_NATIVE_DIR_EXISTS), true)
     include $(BUILDDIR)/common/Library.gmk
   endif
+else ifeq ($(PLATFORM), macosx)
+  include $(BUILDDIR)/common/Library.gmk
 else
 include $(BUILDDIR)/common/Classes.gmk
 endif # PLATFORM
@@ -74,8 +86,10 @@
 #
 ifeq ($(PLATFORM), windows)
   OTHER_LDLIBS = $(JVMLIB)
+else ifeq ($(PLATFORM), macosx)
+  OTHER_LDLIBS = $(LIBDL) $(JVMLIB) -framework Kerberos
 else
-  OTHER_LDLIBS = -ldl $(JVMLIB)
+  OTHER_LDLIBS = $(LIBDL) $(JVMLIB)
 endif
 
 build:
--- a/make/sun/security/pkcs11/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/security/pkcs11/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -159,7 +159,7 @@
 ifeq ($(PLATFORM), windows)
   OTHER_LDLIBS = $(JVMLIB)
 else
-  OTHER_LDLIBS = -ldl $(JVMLIB)
+  OTHER_LDLIBS = $(LIBDL) $(JVMLIB)
 endif
 
 # Other config files
--- a/make/sun/security/smartcardio/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/security/smartcardio/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -75,6 +75,6 @@
 ifeq ($(PLATFORM), windows)
   OTHER_LDLIBS = $(JVMLIB) winscard.lib
 else
-  OTHER_LDLIBS = -ldl $(JVMLIB)
+  OTHER_LDLIBS = $(LIBDL) $(JVMLIB)
   OTHER_CFLAGS = -D__sun_jdk
 endif
--- a/make/sun/splashscreen/FILES_c.gmk	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/splashscreen/FILES_c.gmk	Thu Feb 02 13:39:04 2012 -0800
@@ -49,18 +49,6 @@
 	dgif_lib.c \
 	gif_err.c \
 	gifalloc.c \
-	compress.c \
-	deflate.c \
-	gzio.c \
-	infback.c \
-	inffast.c \
-	inflate.c \
-	inftrees.c \
-	trees.c \
-	uncompr.c \
-	zadler32.c \
-	zcrc32.c \
-	zutil.c \
 	jcomapi.c \
 	jdapimin.c \
 	jdapistd.c \
@@ -106,3 +94,18 @@
 	jfdctfst.c \
 	jfdctint.c
 
+ifneq ($(SYSTEM_ZLIB),true)
+  FILES_c += \
+	compress.c \
+	deflate.c \
+	gzio.c \
+	infback.c \
+	inffast.c \
+	inflate.c \
+	inftrees.c \
+	trees.c \
+	uncompr.c \
+	zadler32.c \
+	zcrc32.c \
+	zutil.c
+endif
--- a/make/sun/splashscreen/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/splashscreen/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -61,10 +61,37 @@
 
 CFLAGS += -DSPLASHSCREEN
 
-ifneq ($(PLATFORM), windows)
+ifeq ($(PLATFORM), macosx)
+  CFLAGS += -DWITH_MACOSX
+
+  # CFLAGS and CPPFLAGS are added when linking as well, so we use VARIANT
+  # instead to specify that we're actually compiling objective-c code here
+  CFLAGS_$(VARIANT)/java_awt_SplashScreen.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_gfx_impl.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_gif.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_impl.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_jpeg.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_png.o = -x objective-c
+  CFLAGS_$(VARIANT)/splashscreen_sys.o = -x objective-c
+
+  OTHER_CFLAGS += -F/System/Library/Frameworks/ApplicationServices.framework/Frameworks
+  CPPFLAGS += -I/System/Library/Frameworks/AppKit.framework/Versions/C/Headers
+  OTHER_LDLIBS += $(LIBM) -lpthread -liconv -losxapp \
+				  -framework ApplicationServices \
+				  -framework Foundation \
+				  -framework Cocoa \
+				  -framework JavaNativeFoundation
+else ifneq ($(PLATFORM), windows)
   CFLAGS += -DWITH_X11
-  CPPFLAGS += -I$(OPENWIN_HOME)/include -I$(OPENWIN_HOME)/include/X11/extensions
-  OTHER_LDLIBS += -L$(OPENWIN_LIB) -lX11 -lXext $(LIBM) -lpthread
+  ifeq ($(PLATFORM), macosx))
+    OTHER_LDLIBS += -liconv
+    CPPFLAGS += -I$(OPENWIN_HOME)/include \
+                -I$(OPENWIN_HOME)/include/X11/extensions
+    OTHER_LDLIBS += -L$(OPENWIN_LIB) -lX11 -lXext $(LIBM) -pthread
+  else
+    CPPFLAGS += -I$(OPENWIN_HOME)/include -I$(OPENWIN_HOME)/include/X11/extensions
+    OTHER_LDLIBS += -L$(OPENWIN_LIB) -lX11 -lXext $(LIBM) -lpthread
+  endif
 else # PLATFORM
   CFLAGS += -DWITH_WIN32
   OTHER_LDLIBS += kernel32.lib user32.lib gdi32.lib delayimp.lib /DELAYLOAD:user32.dll
@@ -77,13 +104,30 @@
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)/splashscreen
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)/giflib
-vpath %.c   $(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+ifneq ($(SYSTEM_ZLIB),true)
+  vpath %.c   $(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+endif
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)/libpng
 vpath %.c   $(SHARE_SRC)/native/$(PKGDIR)/image/jpeg
-vpath %.c   $(PLATFORM_SRC)/native/$(PKGDIR)/splashscreen
+ifneq ($(PLATFORM), macosx)
+  vpath %.c   $(PLATFORM_SRC)/native/$(PKGDIR)/splashscreen
+else
+  vpath %.m   $(call NativeSrcDirList,,native/$(PKGDIR)/splashscreen)
+endif
 
-CPPFLAGS += -I$(PLATFORM_SRC)/native/$(PKGDIR)/splashscreen -I$(SHARE_SRC)/native/$(PKGDIR)/splashscreen
-CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR)/image/jpeg -I$(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+ifneq ($(PLATFORM), macosx)
+  CPPFLAGS += -I$(PLATFORM_SRC)/native/$(PKGDIR)/splashscreen
+else
+  CPPFLAGS += $(call NativeSrcDirList,-I,native/$(PKGDIR)/splashscreen)
+  CPPFLAGS += $(call NativeSrcDirList,-I,/native/sun/osxapp)
+endif
+CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR)/splashscreen
+CPPFLAGS += -I$(SHARE_SRC)/native/$(PKGDIR)/image/jpeg
+ifneq ($(SYSTEM_ZLIB),true)
+  CPPFLAGS += -I$(SHARE_SRC)/native/java/util/zip/zlib-$(ZLIB_VERSION)
+else
+  OTHER_LDLIBS += -lz
+endif
 
 # Shun the less than portable MMX assembly code in pnggccrd.c,
 # and use alternative implementations in C.
--- a/make/sun/tracing/dtrace/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/tracing/dtrace/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -55,7 +55,7 @@
 FILES_export = $(FILES_java)
 
 ifeq ($(PLATFORM), linux)
-OTHER_LDLIBS += -ldl
+OTHER_LDLIBS += $(LIBDL)
 endif
 
 #
--- a/make/sun/xawt/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/sun/xawt/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -27,8 +27,13 @@
 PACKAGE = sun.awt.X11
 LIBRARY = mawt
 LIBRARY_OUTPUT = xawt
+PRODUCT = sun
+
+ifeq ($(PLATFORM), macosx)
+LIB_LOCATION = $(LIBDIR)/xawt
+else
 LIB_LOCATION = $(LIBDIR)/$(LIBARCH)/xawt
-PRODUCT = sun
+endif
 
 include $(BUILDDIR)/common/Defs.gmk
 
@@ -58,6 +63,11 @@
 dummy := $(shell $(MKDIR) -p $(LIB_LOCATION))
 endif
 
+ifeq ($(PLATFORM), macosx))
+LDFLAGS += -pthread
+dummy := $(shell $(MKDIR) -p $(LIB_LOCATION))
+endif
+
 # Since this library will be living in a subdirectory below the other libraries
 #   we need to add an extra runpath so that libraries in the upper directory
 #   are found at runtime.
@@ -92,7 +102,7 @@
 vpath %.c   $(PLATFORM_SRC)/native/sun/java2d/opengl
 vpath %.c   $(PLATFORM_SRC)/native/sun/java2d/x11
 
-OTHER_LDLIBS = $(LIBM) -lawt -lXext -lX11 -lXrender -ldl \
+OTHER_LDLIBS = $(LIBM) -lawt -lXext -lX11 -lXrender $(LIBDL) \
                    $(LDFLAGS_COMMON) $(AWT_RUNPATH) $(OTHER_LDFLAGS) -lXtst -lXi
 
 ifeq  ($(PLATFORM), solaris)
@@ -163,6 +173,10 @@
  endif
 endif
 
+ifeq ($(PLATFORM), macosx)
+  CPPFLAGS += -DX11_PATH=\"$(X11_PATH)\" -DPACKAGE_PATH=\"$(PACKAGE_PATH)\"
+endif
+
 ifeq ($(MILESTONE), internal)
   CPPFLAGS += -DINTERNAL_BUILD
 endif
@@ -207,6 +221,13 @@
 
 else # !solaris
 
+ifeq ($(PLATFORM), macosx)
+CFLAGS_32=-arch i386
+SIZERS = $(SIZER).32 $(SIZER).64
+SIZERS_C = $(SIZER_32_C) $(SIZER_64_C)
+SIZES = $(WRAPPER_GENERATOR_DIR)/sizes.32 $(WRAPPER_GENERATOR_DIR)/sizes.64
+CFLAGS_64=-arch x86_64
+else # !macosx
 ifeq ($(ARCH_DATA_MODEL), 32)
 SIZERS = $(SIZER).32
 SIZERS_C = $(SIZER_32_C)
@@ -216,7 +237,7 @@
 SIZERS_C = $(SIZER_64_C)
 SIZES = $(WRAPPER_GENERATOR_DIR)/sizes.64
 endif # 32
-
+endif # !macosx
 endif # solaris
 
 # XXX Hack for 6185483 - use hard-coded sizes.
--- a/make/tools/freetypecheck/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/tools/freetypecheck/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -49,8 +49,12 @@
   # Add runtime lib search path to ensure test will be runnable
   ifeq ($(PLATFORM), solaris)
     FT_LD_OPTIONS += -R $(FREETYPE_LIB_PATH) -lfreetype
-  else #linux
+  else 
+    ifeq ($(PLATFORM), macosx)
+      FT_LD_OPTIONS += -lfreetype -lz
+    else # linux
       FT_LD_OPTIONS += -Wl,-rpath -Wl,$(FREETYPE_LIB_PATH) -lfreetype
+    endif
   endif
 endif
 FT_OPTIONS += -I$(FREETYPE_HEADERS_PATH)
--- a/make/tools/reorder/Makefile	Fri Jan 27 16:48:41 2012 -0800
+++ b/make/tools/reorder/Makefile	Thu Feb 02 13:39:04 2012 -0800
@@ -185,11 +185,11 @@
 
 # This library 'libmcount.so' also used by hotspot reordering.
 $(OBJDIR)/libmcount.so : $(MCOUNT_OBJ)
-	$(CC) -G -mt -zdefs -o $@ $^ -ldl -lelf $(EXTRA_LIBS)
+	$(CC) -G -mt -zdefs -o $@ $^ $(LIBDL) -lelf $(EXTRA_LIBS)
 
 # This library 'libmcount.so' also used by hotspot reordering.
 $(OBJDIR)/remove_mcount : remove_mcount.c
-	$(CC) -g -o $@ $^ -ldl -lelf $(EXTRA_LIBS)
+	$(CC) -g -o $@ $^ $(LIBDL) -lelf $(EXTRA_LIBS)
 
 
 # Reorder libraries.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/make/tools/sharing/classlist.macosx	Thu Feb 02 13:39:04 2012 -0800
@@ -0,0 +1,2406 @@
+java/lang/Object
+java/lang/String
+java/io/Serializable
+java/lang/Comparable
+java/lang/CharSequence
+java/lang/Class
+java/lang/reflect/GenericDeclaration
+java/lang/reflect/Type
+java/lang/reflect/AnnotatedElement
+java/lang/Cloneable
+java/lang/ClassLoader
+java/lang/System
+java/lang/Throwable
+java/lang/Error
+java/lang/ThreadDeath
+java/lang/Exception
+java/lang/RuntimeException
+java/security/ProtectionDomain
+java/security/AccessControlContext
+java/lang/ClassNotFoundException
+java/lang/NoClassDefFoundError
+java/lang/LinkageError
+java/lang/ClassCastException
+java/lang/ArrayStoreException
+java/lang/VirtualMachineError
+java/lang/OutOfMemoryError
+java/lang/StackOverflowError
+java/lang/IllegalMonitorStateException
+java/lang/ref/Reference
+java/lang/ref/SoftReference
+java/lang/ref/WeakReference
+java/lang/ref/FinalReference
+java/lang/ref/PhantomReference
+java/lang/ref/Finalizer
+java/lang/Thread
+java/lang/Runnable
+java/lang/ThreadGroup
+java/lang/Thread$UncaughtExceptionHandler
+java/util/Properties
+java/util/Hashtable
+java/util/Map
+java/util/Dictionary
+java/lang/reflect/AccessibleObject
+java/lang/reflect/Field
+java/lang/reflect/Member
+java/lang/reflect/Method
+java/lang/reflect/Constructor
+sun/reflect/MagicAccessorImpl
+sun/reflect/MethodAccessorImpl
+sun/reflect/MethodAccessor
+sun/reflect/ConstructorAccessorImpl
+sun/reflect/ConstructorAccessor
+sun/reflect/DelegatingClassLoader
+sun/reflect/ConstantPool
+sun/reflect/UnsafeStaticFieldAccessorImpl
+sun/reflect/UnsafeFieldAccessorImpl
+sun/reflect/FieldAccessorImpl
+sun/reflect/FieldAccessor
+java/util/Vector
+java/util/List
+java/util/Collection
+java/lang/Iterable
+java/util/RandomAccess
+java/util/AbstractList
+java/util/AbstractCollection
+java/lang/StringBuffer
+java/lang/AbstractStringBuilder
+java/lang/Appendable
+java/lang/StackTraceElement
+java/nio/Buffer
+java/lang/Boolean
+java/lang/Character
+java/lang/Float
+java/lang/Number
+java/lang/Double
+java/lang/Byte
+java/lang/Short
+java/lang/Integer
+java/lang/Long
+java/lang/NullPointerException
+java/lang/ArithmeticException
+java/io/ObjectStreamField
+java/lang/String$CaseInsensitiveComparator
+java/util/Comparator
+java/lang/RuntimePermission
+java/security/BasicPermission
+java/security/Permission
+java/security/Guard
+sun/misc/SoftCache
+java/util/AbstractMap
+java/lang/ref/ReferenceQueue
+java/lang/ref/ReferenceQueue$Null
+java/lang/ref/ReferenceQueue$Lock
+java/util/HashMap
+java/lang/annotation/Annotation
+java/util/HashMap$Entry
+java/util/Map$Entry
+java/security/AccessController
+java/lang/reflect/ReflectPermission
+sun/reflect/ReflectionFactory$GetReflectionFactoryAction
+java/security/PrivilegedAction
+java/util/Stack
+sun/reflect/ReflectionFactory
+java/lang/ref/Reference$Lock
+java/lang/ref/Reference$ReferenceHandler
+java/lang/ref/Finalizer$FinalizerThread
+java/util/Hashtable$EmptyEnumerator
+java/util/Enumeration
+java/util/Hashtable$EmptyIterator
+java/util/Iterator
+java/util/Hashtable$Entry
+java/nio/charset/Charset
+sun/nio/cs/StandardCharsets
+sun/nio/cs/FastCharsetProvider
+java/nio/charset/spi/CharsetProvider
+sun/nio/cs/StandardCharsets$Aliases
+sun/util/PreHashedMap
+sun/nio/cs/StandardCharsets$Classes
+sun/nio/cs/StandardCharsets$Cache
+java/lang/ThreadLocal
+java/util/concurrent/atomic/AtomicInteger
+sun/misc/Unsafe
+java/lang/NoSuchMethodError
+java/lang/IncompatibleClassChangeError
+sun/reflect/Reflection
+java/util/Collections
+java/util/Collections$EmptySet
+java/util/AbstractSet
+java/util/Set
+java/util/Collections$EmptyList
+java/util/Collections$EmptyMap
+java/util/Collections$ReverseComparator
+java/util/Collections$SynchronizedMap
+java/lang/Class$3
+java/lang/reflect/Modifier
+java/lang/reflect/ReflectAccess
+sun/reflect/LangReflectAccess
+java/util/Arrays
+java/lang/Math
+sun/nio/cs/US_ASCII
+sun/nio/cs/HistoricallyNamedCharset
+sun/misc/VM
+java/lang/StringCoding
+java/lang/ThreadLocal$ThreadLocalMap
+java/lang/ThreadLocal$ThreadLocalMap$Entry
+java/lang/StringCoding$StringDecoder
+sun/nio/cs/US_ASCII$Decoder
+java/nio/charset/CharsetDecoder
+java/nio/charset/CodingErrorAction
+java/nio/ByteBuffer
+java/nio/HeapByteBuffer
+java/nio/Bits
+java/nio/ByteOrder
+java/nio/CharBuffer
+java/lang/Readable
+java/nio/HeapCharBuffer
+java/nio/charset/CoderResult
+java/nio/charset/CoderResult$1
+java/nio/charset/CoderResult$Cache
+java/nio/charset/CoderResult$2
+sun/misc/Version
+java/io/FileInputStream
+java/io/InputStream
+java/io/Closeable
+java/io/FileDescriptor
+java/io/FileOutputStream
+java/io/OutputStream
+java/io/Flushable
+java/io/BufferedInputStream
+java/io/FilterInputStream
+java/util/concurrent/atomic/AtomicReferenceFieldUpdater
+java/util/concurrent/atomic/AtomicReferenceFieldUpdater$AtomicReferenceFieldUpdaterImpl
+sun/reflect/misc/ReflectUtil
+java/io/PrintStream
+java/io/FilterOutputStream
+java/io/BufferedOutputStream
+java/io/OutputStreamWriter
+java/io/Writer
+sun/nio/cs/StreamEncoder
+sun/security/action/GetPropertyAction
+sun/nio/cs/US_ASCII$Encoder
+java/nio/charset/CharsetEncoder
+sun/nio/cs/Surrogate$Parser
+sun/nio/cs/Surrogate
+java/io/BufferedWriter
+java/lang/Runtime
+java/io/File
+java/io/FileSystem
+java/io/UnixFileSystem
+java/io/ExpiringCache
+java/io/ExpiringCache$1
+java/util/LinkedHashMap
+java/util/LinkedHashMap$Entry
+java/lang/StringBuilder
+java/io/File$1
+sun/misc/JavaIODeleteOnExitAccess
+sun/misc/SharedSecrets
+java/lang/ClassLoader$3
+java/lang/StringCoding$StringEncoder
+java/io/ExpiringCache$Entry
+java/lang/ClassLoader$NativeLibrary
+java/lang/Terminator
+java/lang/Terminator$1
+sun/misc/SignalHandler
+sun/misc/Signal
+sun/misc/NativeSignalHandler
+java/io/Console
+java/io/Console$1
+sun/misc/JavaIOAccess
+java/io/Console$1$1
+java/lang/Shutdown
+java/util/ArrayList
+java/lang/Shutdown$Lock
+java/lang/ApplicationShutdownHooks
+java/util/IdentityHashMap
+sun/misc/OSEnvironment
+java/lang/System$2
+sun/misc/JavaLangAccess
+java/lang/Compiler
+java/lang/Compiler$1
+sun/misc/Launcher
+sun/misc/Launcher$Factory
+java/net/URLStreamHandlerFactory
+sun/misc/Launcher$ExtClassLoader
+java/net/URLClassLoader
+java/security/SecureClassLoader
+sun/security/util/Debug
+java/net/URLClassLoader$7
+sun/misc/JavaNetAccess
+java/util/StringTokenizer
+sun/misc/Launcher$ExtClassLoader$1
+java/security/PrivilegedExceptionAction
+sun/misc/MetaIndex
+java/io/BufferedReader
+java/io/Reader
+java/io/FileReader
+java/io/InputStreamReader
+sun/nio/cs/StreamDecoder
+java/lang/reflect/Array
+sun/net/www/ParseUtil
+java/util/BitSet
+java/io/ObjectStreamClass
+java/net/URL
+java/util/Locale
+java/util/concurrent/ConcurrentHashMap
+java/util/concurrent/ConcurrentMap
+java/util/concurrent/ConcurrentHashMap$Segment
+java/util/concurrent/locks/ReentrantLock
+java/util/concurrent/locks/Lock
+java/util/concurrent/locks/ReentrantLock$NonfairSync
+java/util/concurrent/locks/ReentrantLock$Sync
+java/util/concurrent/locks/AbstractQueuedSynchronizer
+java/util/concurrent/locks/AbstractOwnableSynchronizer
+java/util/concurrent/locks/AbstractQueuedSynchronizer$Node
+java/util/concurrent/ConcurrentHashMap$HashEntry
+java/lang/CharacterDataLatin1
+java/net/Parts
+sun/net/www/protocol/file/Handler
+java/net/URLStreamHandler
+java/lang/Class$1
+sun/reflect/ReflectionFactory$1
+sun/reflect/NativeConstructorAccessorImpl
+sun/reflect/DelegatingConstructorAccessorImpl
+java/util/HashSet
+sun/misc/URLClassPath
+sun/net/www/protocol/jar/Handler
+sun/misc/Launcher$AppClassLoader
+sun/misc/Launcher$AppClassLoader$1
+java/lang/SystemClassLoaderAction
+java/net/URLClassLoader$1
+sun/misc/URLClassPath$3
+sun/misc/URLClassPath$JarLoader
+sun/misc/URLClassPath$Loader
+java/security/PrivilegedActionException
+sun/misc/URLClassPath$FileLoader
+sun/misc/URLClassPath$FileLoader$1
+sun/misc/Resource
+sun/nio/ByteBuffered
+java/security/CodeSource
+java/security/Permissions
+java/security/PermissionCollection
+sun/net/www/protocol/file/FileURLConnection
+sun/net/www/URLConnection
+java/net/URLConnection
+java/net/UnknownContentHandler
+java/net/ContentHandler
+sun/net/www/MessageHeader
+java/io/FilePermission
+java/io/FilePermission$1
+sun/security/provider/PolicyFile
+java/security/Policy
+java/security/Policy$UnsupportedEmptyCollection
+java/io/FilePermissionCollection
+java/security/AllPermission
+java/security/UnresolvedPermission
+java/security/BasicPermissionCollection
+java/security/Principal
+java/security/cert/Certificate
+java/util/AbstractList$Itr
+java/util/IdentityHashMap$KeySet
+java/util/IdentityHashMap$KeyIterator
+java/util/IdentityHashMap$IdentityHashMapIterator
+java/io/DeleteOnExitHook
+java/util/LinkedHashSet
+java/util/HashMap$KeySet
+java/util/LinkedHashMap$KeyIterator
+java/util/LinkedHashMap$LinkedHashIterator
+java/awt/Frame
+java/awt/MenuContainer
+java/awt/Window
+javax/accessibility/Accessible
+java/awt/Container
+java/awt/Component
+java/awt/image/ImageObserver
+java/lang/InterruptedException
+java/awt/Label
+java/util/logging/Logger
+java/util/logging/Handler
+java/util/logging/Level
+java/util/logging/LogManager
+java/util/logging/LogManager$1
+java/beans/PropertyChangeSupport
+java/util/logging/LogManager$LogNode
+java/util/logging/LoggingPermission
+java/util/logging/LogManager$Cleaner
+java/util/logging/LogManager$RootLogger
+java/util/logging/LogManager$2
+java/util/Properties$LineReader
+java/util/Hashtable$Enumerator
+java/beans/PropertyChangeEvent
+java/util/EventObject
+java/awt/Component$AWTTreeLock
+sun/awt/DebugHelper
+sun/awt/NativeLibLoader
+sun/security/action/LoadLibraryAction
+java/awt/GraphicsEnvironment
+java/awt/GraphicsEnvironment$1
+java/lang/ProcessEnvironment
+java/lang/ProcessEnvironment$Variable
+java/lang/ProcessEnvironment$ExternalData
+java/lang/ProcessEnvironment$Value
+java/lang/ProcessEnvironment$StringEnvironment
+java/util/Collections$UnmodifiableMap
+sun/awt/DebugHelperStub
+java/awt/Toolkit
+java/awt/Toolkit$3
+sun/util/CoreResourceBundleControl
+java/util/ResourceBundle$Control
+java/util/Arrays$ArrayList
+java/util/Collections$UnmodifiableRandomAccessList
+java/util/Collections$UnmodifiableList
+java/util/Collections$UnmodifiableCollection
+java/util/ResourceBundle
+java/util/ResourceBundle$1
+java/util/ResourceBundle$RBClassLoader
+java/util/ResourceBundle$RBClassLoader$1
+java/util/ResourceBundle$CacheKey
+java/util/ResourceBundle$LoaderReference
+java/util/ResourceBundle$CacheKeyReference
+java/util/ResourceBundle$SingleFormatControl
+sun/awt/resources/awt
+java/util/ListResourceBundle
+java/awt/Toolkit$1
+java/io/FileNotFoundException
+java/io/IOException
+java/awt/event/KeyEvent
+java/awt/event/InputEvent
+java/awt/event/ComponentEvent
+java/awt/AWTEvent
+java/awt/event/NativeLibLoader
+java/util/WeakHashMap
+java/util/WeakHashMap$Entry
+java/awt/Component$DummyRequestFocusController
+sun/awt/RequestFocusController
+java/awt/LayoutManager
+java/awt/LightweightDispatcher
+java/awt/event/AWTEventListener
+java/util/EventListener
+java/awt/Dimension
+java/awt/geom/Dimension2D
+java/util/concurrent/atomic/AtomicBoolean
+java/awt/ComponentOrientation
+java/awt/Component$2
+java/lang/NoSuchMethodException
+sun/awt/AppContext
+sun/awt/AppContext$1
+sun/awt/AppContext$2
+sun/awt/MostRecentKeyValue
+java/awt/Cursor
+sun/awt/X11GraphicsEnvironment
+sun/java2d/SunGraphicsEnvironment
+sun/java2d/FontSupport
+sun/awt/DisplayChangedListener
+sun/java2d/SunGraphicsEnvironment$TTFilter
+java/io/FilenameFilter
+sun/java2d/SunGraphicsEnvironment$T1Filter
+sun/awt/X11GraphicsEnvironment$1
+sun/awt/SunToolkit
+sun/awt/WindowClosingSupport
+sun/awt/WindowClosingListener
+sun/awt/ComponentFactory
+sun/awt/InputMethodSupport
+java/util/concurrent/locks/AbstractQueuedSynchronizer$ConditionObject
+java/util/concurrent/locks/Condition
+sun/awt/AWTAutoShutdown
+sun/awt/AWTAutoShutdown$PeerMap
+sun/awt/SunToolkit$6
+java/awt/Dialog$ModalExclusionType
+java/lang/Enum
+java/awt/Dialog
+java/awt/Dialog$ModalityType
+java/awt/ModalEventFilter
+java/awt/EventFilter
+sun/reflect/UnsafeFieldAccessorFactory
+sun/reflect/UnsafeQualifiedStaticObjectFieldAccessorImpl
+sun/reflect/UnsafeQualifiedStaticFieldAccessorImpl
+sun/awt/SunDisplayChanger
+sun/java2d/SunGraphicsEnvironment$1
+java/io/StreamTokenizer
+sun/font/FontManager
+sun/font/FileFont
+sun/font/PhysicalFont
+sun/font/Font2D
+sun/font/CompositeFont
+java/util/HashMap$Values
+java/util/HashMap$ValueIterator
+java/util/HashMap$HashIterator
+sun/font/FontManager$1
+java/awt/Font
+java/awt/geom/AffineTransform
+sun/font/AttributeValues
+sun/font/EAttribute
+java/text/AttributedCharacterIterator$Attribute
+java/lang/Class$4
+sun/reflect/NativeMethodAccessorImpl
+sun/reflect/DelegatingMethodAccessorImpl
+java/awt/font/TextAttribute
+java/lang/Integer$IntegerCache
+sun/font/TrueTypeFont
+java/awt/font/FontRenderContext
+java/awt/RenderingHints
+sun/awt/SunHints
+sun/awt/SunHints$Key
+java/awt/RenderingHints$Key
+sun/awt/SunHints$Value
+sun/awt/SunHints$LCDContrastKey
+sun/font/Type1Font
+java/awt/geom/Point2D$Float
+java/awt/geom/Point2D
+sun/font/StrikeMetrics
+java/awt/geom/Rectangle2D$Float
+java/awt/geom/Rectangle2D
+java/awt/geom/RectangularShape
+java/awt/Shape
+java/awt/geom/GeneralPath
+java/awt/geom/Path2D$Float
+java/awt/geom/Path2D
+sun/font/CharToGlyphMapper
+sun/font/PhysicalStrike
+sun/font/FontStrike
+sun/font/GlyphList
+sun/font/StrikeCache
+sun/java2d/Disposer
+sun/java2d/Disposer$1
+sun/font/StrikeCache$1
+sun/font/FontManager$FontRegistrationInfo
+sun/awt/motif/MFontConfiguration
+sun/awt/FontConfiguration
+sun/awt/FontDescriptor
+java/util/Scanner
+java/util/regex/Pattern
+java/util/regex/Pattern$8
+java/util/regex/Pattern$Node
+java/util/regex/Pattern$LastNode
+java/util/regex/Pattern$GroupHead
+java/util/regex/Pattern$CharPropertyNames
+java/util/regex/Pattern$CharPropertyNames$1
+java/util/regex/Pattern$CharPropertyNames$CharPropertyFactory
+java/util/regex/Pattern$CharPropertyNames$2
+java/util/regex/Pattern$CharPropertyNames$5
+java/util/regex/Pattern$CharPropertyNames$3
+java/util/regex/Pattern$CharPropertyNames$6
+java/util/regex/Pattern$CharPropertyNames$CloneableProperty
+java/util/regex/Pattern$CharProperty
+java/util/regex/Pattern$CharPropertyNames$4
+java/util/regex/Pattern$CharPropertyNames$7
+java/util/regex/Pattern$CharPropertyNames$8
+java/util/regex/Pattern$CharPropertyNames$9
+java/util/regex/Pattern$CharPropertyNames$10
+java/util/regex/Pattern$CharPropertyNames$11
+java/util/regex/Pattern$CharPropertyNames$12
+java/util/regex/Pattern$CharPropertyNames$13
+java/util/regex/Pattern$CharPropertyNames$14
+java/util/regex/Pattern$CharPropertyNames$15
+java/util/regex/Pattern$CharPropertyNames$16
+java/util/regex/Pattern$CharPropertyNames$17
+java/util/regex/Pattern$CharPropertyNames$18
+java/util/regex/Pattern$CharPropertyNames$19
+java/util/regex/Pattern$CharPropertyNames$20
+java/util/regex/Pattern$CharPropertyNames$21
+java/util/regex/Pattern$Curly
+java/util/regex/Pattern$Slice
+java/util/regex/Pattern$Begin
+java/util/regex/Pattern$First
+java/util/regex/Pattern$Start
+java/util/regex/Pattern$TreeInfo
+java/util/regex/Pattern$All
+java/util/regex/Pattern$BitClass
+java/util/regex/Pattern$BmpCharProperty
+java/util/regex/Pattern$6
+java/util/regex/Pattern$CharProperty$1
+java/util/regex/Pattern$10
+sun/nio/ch/FileChannelImpl
+java/nio/channels/FileChannel
+java/nio/channels/ByteChannel
+java/nio/channels/ReadableByteChannel
+java/nio/channels/Channel
+java/nio/channels/WritableByteChannel
+java/nio/channels/GatheringByteChannel
+java/nio/channels/ScatteringByteChannel
+java/nio/channels/spi/AbstractInterruptibleChannel
+java/nio/channels/InterruptibleChannel
+sun/nio/ch/Util
+sun/nio/ch/IOUtil
+sun/nio/ch/FileDispatcher
+sun/nio/ch/NativeDispatcher
+sun/nio/ch/Reflect
+java/nio/MappedByteBuffer
+sun/nio/ch/Reflect$1
+sun/nio/ch/NativeThreadSet
+java/nio/channels/Channels
+java/util/Scanner$1
+sun/misc/LRUCache
+java/util/regex/Matcher
+java/util/regex/MatchResult
+java/text/NumberFormat
+java/text/Format
+java/text/spi/NumberFormatProvider
+java/util/spi/LocaleServiceProvider
+sun/util/LocaleServiceProviderPool
+sun/util/LocaleServiceProviderPool$1
+java/util/ServiceLoader
+java/util/ServiceLoader$LazyIterator
+java/util/ServiceLoader$1
+java/util/HashMap$EntrySet
+java/util/LinkedHashMap$EntryIterator
+sun/misc/Launcher$1
+sun/misc/URLClassPath$2
+java/lang/ClassLoader$2
+sun/misc/URLClassPath$1
+java/net/URLClassLoader$3
+sun/misc/CompoundEnumeration
+sun/misc/URLClassPath$JarLoader$1
+sun/misc/FileURLMapper
+java/net/URLClassLoader$3$1
+sun/util/resources/LocaleData
+sun/util/resources/LocaleData$1
+sun/util/resources/LocaleData$LocaleDataResourceBundleControl
+sun/util/LocaleDataMetaInfo
+sun/text/resources/FormatData
+java/util/ResourceBundle$BundleReference
+sun/text/resources/FormatData_en
+sun/text/resources/FormatData_en_US
+java/text/DecimalFormatSymbols
+java/text/spi/DecimalFormatSymbolsProvider
+java/util/Currency
+java/util/Currency$1
+java/util/CurrencyData
+java/util/spi/CurrencyNameProvider
+sun/util/resources/CurrencyNames
+sun/util/resources/LocaleNamesBundle
+sun/util/resources/OpenListResourceBundle
+sun/util/resources/CurrencyNames_en_US
+java/text/DecimalFormat
+java/text/FieldPosition
+java/text/DigitList
+java/math/RoundingMode
+java/util/regex/Pattern$GroupTail
+java/util/regex/Pattern$Ctype
+java/util/regex/Pattern$Ques
+java/util/regex/Pattern$GroupCurly
+java/util/regex/Pattern$5
+java/util/regex/Pattern$Loop
+java/util/regex/Pattern$Prolog
+java/util/regex/Pattern$9
+java/util/regex/Pattern$BranchConn
+java/util/regex/Pattern$Branch
+java/nio/channels/spi/AbstractInterruptibleChannel$1
+sun/nio/ch/Interruptible
+sun/nio/ch/NativeThread
+sun/nio/ch/DirectBuffer
+java/nio/DirectByteBuffer
+java/nio/DirectByteBuffer$Deallocator
+sun/misc/Cleaner
+sun/nio/ch/IOStatus
+java/util/regex/ASCII
+java/io/DataInputStream
+java/io/DataInput
+java/lang/Short$ShortCache
+java/util/HashMap$KeyIterator
+sun/font/CompositeFontDescriptor
+sun/font/Font2DHandle
+sun/font/FontFamily
+java/awt/GraphicsDevice
+sun/awt/X11GraphicsDevice
+sun/awt/X11GraphicsConfig
+java/awt/GraphicsConfiguration
+java/awt/ImageCapabilities
+sun/java2d/x11/X11SurfaceData
+sun/java2d/SurfaceData
+java/awt/Transparency
+sun/java2d/DisposerTarget
+sun/java2d/InvalidPipeException
+java/lang/IllegalStateException
+sun/java2d/NullSurfaceData
+sun/java2d/loops/SurfaceType
+sun/awt/image/PixelConverter
+sun/awt/image/PixelConverter$Xrgb
+sun/awt/image/PixelConverter$Argb
+sun/awt/image/PixelConverter$ArgbPre
+sun/awt/image/PixelConverter$Xbgr
+sun/awt/image/PixelConverter$Rgba
+sun/awt/image/PixelConverter$RgbaPre
+sun/awt/image/PixelConverter$Ushort565Rgb
+sun/awt/image/PixelConverter$Ushort555Rgb
+sun/awt/image/PixelConverter$Ushort555Rgbx
+sun/awt/image/PixelConverter$Ushort4444Argb
+sun/awt/image/PixelConverter$ByteGray
+sun/awt/image/PixelConverter$UshortGray
+sun/awt/image/PixelConverter$Rgbx
+sun/awt/image/PixelConverter$Bgrx
+sun/awt/image/PixelConverter$ArgbBm
+java/awt/image/ColorModel
+java/awt/image/DirectColorModel
+java/awt/image/PackedColorModel
+java/awt/color/ColorSpace
+java/awt/color/ICC_Profile
+sun/awt/color/ProfileDeferralInfo
+sun/awt/color/ProfileDeferralMgr
+java/awt/color/ICC_ProfileRGB
+java/awt/color/ICC_Profile$1
+sun/awt/color/ProfileActivator
+java/awt/color/ICC_ColorSpace
+sun/java2d/pipe/NullPipe
+sun/java2d/pipe/PixelDrawPipe
+sun/java2d/pipe/PixelFillPipe
+sun/java2d/pipe/ShapeDrawPipe
+sun/java2d/pipe/TextPipe
+sun/java2d/pipe/DrawImagePipe
+java/awt/image/IndexColorModel
+sun/java2d/pipe/LoopPipe
+sun/java2d/pipe/OutlineTextRenderer
+sun/java2d/pipe/SolidTextRenderer
+sun/java2d/pipe/GlyphListLoopPipe
+sun/java2d/pipe/GlyphListPipe
+sun/java2d/pipe/AATextRenderer
+sun/java2d/pipe/LCDTextRenderer
+sun/java2d/pipe/AlphaColorPipe
+sun/java2d/pipe/CompositePipe
+sun/java2d/pipe/PixelToShapeConverter
+sun/java2d/pipe/TextRenderer
+sun/java2d/pipe/SpanClipRenderer
+sun/java2d/pipe/Region
+sun/java2d/pipe/RegionIterator
+sun/java2d/pipe/DuctusShapeRenderer
+sun/java2d/pipe/DuctusRenderer
+sun/java2d/pipe/AlphaPaintPipe
+sun/java2d/pipe/SpanShapeRenderer$Composite
+sun/java2d/pipe/SpanShapeRenderer
+sun/java2d/pipe/GeneralCompositePipe
+sun/java2d/pipe/DrawImage
+sun/java2d/loops/RenderCache
+sun/java2d/loops/RenderCache$Entry
+sun/java2d/loops/XORComposite
+java/awt/Composite
+sun/font/X11TextRenderer
+sun/java2d/loops/GraphicsPrimitive
+sun/java2d/x11/X11PMBlitLoops
+sun/java2d/loops/Blit
+sun/java2d/loops/GraphicsPrimitiveMgr
+sun/java2d/loops/CompositeType
+sun/java2d/SunGraphics2D
+sun/awt/ConstrainableGraphics
+java/awt/Graphics2D
+java/awt/Graphics
+java/awt/Color
+java/awt/Paint
+java/awt/AlphaComposite
+sun/java2d/loops/BlitBg
+sun/java2d/loops/ScaledBlit
+sun/java2d/loops/FillRect
+sun/java2d/loops/FillSpans
+sun/java2d/loops/DrawLine
+sun/java2d/loops/DrawRect
+sun/java2d/loops/DrawPolygons
+sun/java2d/loops/DrawPath
+sun/java2d/loops/FillPath
+sun/java2d/loops/MaskBlit
+sun/java2d/loops/MaskFill
+sun/java2d/loops/DrawGlyphList
+sun/java2d/loops/DrawGlyphListAA
+sun/java2d/loops/DrawGlyphListLCD
+sun/java2d/loops/TransformHelper
+java/awt/BasicStroke
+java/awt/Stroke
+sun/misc/PerformanceLogger
+sun/misc/PerformanceLogger$TimeData
+sun/java2d/pipe/ValidatePipe
+sun/java2d/loops/CustomComponent
+sun/java2d/loops/GraphicsPrimitiveProxy
+sun/java2d/loops/GeneralRenderer
+sun/java2d/loops/GraphicsPrimitiveMgr$1
+sun/java2d/loops/GraphicsPrimitiveMgr$2
+sun/java2d/x11/X11PMBlitLoops$DelegateBlitLoop
+sun/java2d/x11/X11PMBlitBgLoops
+sun/java2d/x11/X11SurfaceData$LazyPipe
+sun/awt/X11GraphicsConfig$X11GCDisposerRecord
+sun/java2d/DisposerRecord
+java/awt/BorderLayout
+java/awt/LayoutManager2
+java/awt/Rectangle
+java/awt/Toolkit$2
+sun/awt/X11/XToolkit
+sun/awt/X11/XConstants
+sun/awt/UNIXToolkit
+java/util/TreeMap
+java/util/NavigableMap
+java/util/SortedMap
+sun/awt/X11/XlibWrapper
+sun/awt/X11/XUtilConstants
+sun/awt/X11/XProtocolConstants
+sun/awt/X11/XCursorFontConstants
+sun/awt/X11/XlibWrapper$1
+sun/awt/X11/XToolkit$4
+sun/awt/X11/XModifierKeymap
+sun/awt/X11/XWrapperBase
+sun/awt/X11/Native
+sun/awt/X11/Native$1
+java/awt/EventQueue
+sun/awt/X11/XToolkit$7
+java/util/EmptyStackException
+java/lang/reflect/InvocationTargetException
+java/awt/EventDispatchThread
+java/awt/event/PaintEvent
+java/awt/event/MouseEvent
+sun/awt/PeerEvent
+java/awt/event/InvocationEvent
+java/awt/ActiveEvent
+java/awt/EventQueueItem
+sun/awt/X11/XToolkit$1
+sun/awt/X11/XToolkit$XErrorHandler
+sun/awt/X11/XToolkit$5
+sun/awt/X11/XEventDispatcher
+sun/awt/SunToolkit$ModalityListenerList
+sun/awt/ModalityListener
+sun/awt/SunToolkit$1
+java/util/MissingResourceException
+java/awt/Queue
+sun/awt/PostEventQueue
+java/util/LinkedList
+java/util/Deque
+java/util/Queue
+java/util/AbstractSequentialList
+java/util/LinkedList$Entry
+sun/awt/X11/AwtScreenData
+sun/awt/X11/XWM
+sun/awt/X11/MWMConstants
+sun/awt/X11/XAtom
+java/awt/Insets
+sun/awt/X11/XWM$1
+sun/awt/X11/XWM$2
+sun/awt/X11/XSetWindowAttributes
+sun/awt/X11/XErrorEvent
+sun/awt/X11/XNETProtocol
+sun/awt/X11/XStateProtocol
+sun/awt/X11/XLayerProtocol
+sun/awt/X11/XProtocol
+sun/awt/X11/XProtocol$1
+sun/awt/X11/WindowPropertyGetter
+sun/awt/X11/UnsafeXDisposerRecord
+sun/awt/X11/XPropertyCache
+sun/awt/X11/XWINProtocol
+sun/awt/X11/XAtomList
+sun/awt/X11/XToolkit$3
+sun/awt/X11/XAnyEvent
+sun/awt/X11/IXAnyEvent
+java/awt/Window$WindowDisposerRecord
+java/awt/KeyboardFocusManager
+java/awt/KeyEventDispatcher
+java/awt/KeyEventPostProcessor
+java/awt/AWTKeyStroke
+java/awt/AWTKeyStroke$1
+java/awt/DefaultKeyboardFocusManager
+java/awt/DefaultFocusTraversalPolicy
+java/awt/ContainerOrderFocusTraversalPolicy
+java/awt/FocusTraversalPolicy
+java/awt/MutableBoolean
+java/util/Collections$UnmodifiableSet
+sun/awt/HeadlessToolkit
+sun/awt/X11/XKeyboardFocusManagerPeer
+java/awt/peer/KeyboardFocusManagerPeer
+sun/awt/X11/XKeyboardFocusManagerPeer$1
+sun/awt/X11/XFramePeer
+java/awt/peer/FramePeer
+java/awt/peer/WindowPeer
+java/awt/peer/ContainerPeer
+java/awt/peer/ComponentPeer
+sun/awt/X11/XDecoratedPeer
+sun/awt/X11/XWindowPeer
+sun/awt/X11/XPanelPeer
+java/awt/peer/PanelPeer
+sun/awt/X11/XCanvasPeer
+java/awt/peer/CanvasPeer
+sun/awt/X11/XComponentPeer
+java/awt/dnd/peer/DropTargetPeer
+sun/awt/X11/XWindow
+sun/awt/X11ComponentPeer
+sun/awt/X11/XBaseWindow
+sun/awt/X11/XCreateWindowParams
+java/lang/Long$LongCache
+sun/awt/X11/XBaseWindow$InitialiseState
+sun/awt/X11/XBaseWindow$StateLock
+sun/awt/X11/AwtGraphicsConfigData
+sun/awt/X11/XVisualInfo
+java/awt/SystemColor
+sun/awt/X11/MotifColorUtilities
+java/lang/StrictMath
+sun/awt/X11/XRepaintArea
+sun/awt/RepaintArea
+sun/awt/X11/XWindowAttributesData
+java/util/concurrent/locks/LockSupport
+sun/awt/X11/WindowDimensions
+java/awt/Point
+java/util/TreeMap$Entry
+sun/nio/cs/UTF_8
+sun/nio/cs/Unicode
+sun/nio/cs/UTF_8$Encoder
+sun/nio/cs/UTF_8$Decoder
+sun/nio/cs/Surrogate$Generator
+sun/awt/X11/XPropertyEvent
+sun/awt/X11/XDropTargetEventProcessor
+sun/awt/X11/XDragSourceContextPeer
+sun/awt/X11/XDragSourceProtocolListener
+sun/awt/dnd/SunDragSourceContextPeer
+java/awt/dnd/peer/DragSourceContextPeer
+sun/awt/X11/XAwtState