United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-7142950 jdk7u cannot bootstrap Mac OS build [macosx]
JDK-7142950 : jdk7u cannot bootstrap Mac OS build [macosx]

Details
Type:
Bug
Submit Date:
2012-02-06
Status:
Closed
Updated Date:
2012-03-19
Project Name:
JDK
Resolved Date:
2012-03-19
Component:
infrastructure
OS:
os_x
Sub-Component:
build
CPU:
unknown
Priority:
P4
Resolution:
Fixed
Affected Versions:
7
Fixed Versions:
7u4 (b13)

Related Reports
Relates:

Sub Tasks

Description
The current 7u-dev build cannot be used as a bootstrap for itself on Mac OS X. The build fails if
-buildenv SKIP_BOOT_CYCLE=false is specified on JPRT command line. 

More significantly, if people start to use our promoted builds as bootstrap then that will fail in
all situations.
Also, change build to take macos jvm.cfg from the macos source tree rather than solaris.

                                    

Comments
EVALUATION

The fix renames the macos occurences of x86_64 to amd64 to be x86_64

It also takes jvm.cfg from the macos tree as opposed to the solaris tree, which is where it
is currently (mistakenly) coming from.

Finally, it fixes the top level control makefile to understand the mac os image directory structure
                                     
2012-02-06
SUGGESTED FIX

diff -r 1a35342a99f4 -r 5ff313614d0d make/common/Defs-macosx.gmk
--- a/make/common/Defs-macosx.gmk	Mon Feb 06 02:18:10 2012 -0800
+++ b/make/common/Defs-macosx.gmk	Mon Feb 06 02:29:57 2012 -0800
@@ -51,6 +51,7 @@
 
 ifndef PLATFORM_SRC
   PLATFORM_SRC = $(BUILDDIR)/../src/solaris
+  PLATFORM_SRC_MACOS = $(BUILDDIR)/../src/macosx
 endif # PLATFORM_SRC
 
 # BSD build pulls its platform sources from the solaris tree.
@@ -104,10 +105,10 @@
 
 # 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
+#    This should be the default on X86, but ia64 and x86_64 may not have this
 #    as the default.
-CFLAGS_REQUIRED_amd64   += -m64 -fno-omit-frame-pointer -D_LITTLE_ENDIAN
-LDFLAGS_COMMON_amd64    += -m64
+CFLAGS_REQUIRED_x86_64  += -m64 -fno-omit-frame-pointer -D_LITTLE_ENDIAN
+LDFLAGS_COMMON_x86_64   += -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
@@ -161,7 +162,7 @@
 PIC_CODE_SMALL = -fpic
 GLOBAL_KPIC = $(PIC_CODE_LARGE)
 CFLAGS_COMMON   += $(GLOBAL_KPIC) $(GCC_WARNINGS)
-ifeq ($(ARCH), amd64)
+ifeq ($(ARCH), x86_64)
  CFLAGS_COMMON += -pipe
 endif
 
diff -r 1a35342a99f4 -r 5ff313614d0d make/common/shared/Platform.gmk
--- a/make/common/shared/Platform.gmk	Mon Feb 06 02:18:10 2012 -0800
+++ b/make/common/shared/Platform.gmk	Mon Feb 06 02:29:57 2012 -0800
@@ -262,7 +262,7 @@
                     echo sparc \
                     ;; \
                 x86_64) \
-                    echo amd64 \
+                    echo x86_64 \
                     ;; \
                 "Power Macintosh") \
                     echo ppc \
diff -r 1a35342a99f4 -r 5ff313614d0d make/java/jvm/Makefile
--- a/make/java/jvm/Makefile	Mon Feb 06 02:18:10 2012 -0800
+++ b/make/java/jvm/Makefile	Mon Feb 06 02:29:57 2012 -0800
@@ -60,6 +60,12 @@
 JVMCFG_ARCH = $(ARCH)
 endif
 
+ifeq ($(PLATFORM), macosx)
+JVMCFG_SRC = $(PLATFORM_SRC_MACOS)/bin/$(JVMCFG_ARCH)/jvm.cfg
+else
+JVMCFG_SRC = $(PLATFORM_SRC)/bin/$(JVMCFG_ARCH)/jvm.cfg
+endif
+
 ifdef BUILD_CLIENT_ONLY
 $(JVMCFG)::
 	$(MKDIR) -p $(JVMCFG_DIR)
@@ -72,7 +78,7 @@
 	$(ECHO) "-native ERROR">>$(JVMCFG)
 	$(ECHO) "-green ERROR">>$(JVMCFG)
 else
-$(JVMCFG): $(PLATFORM_SRC)/bin/$(JVMCFG_ARCH)/jvm.cfg
+$(JVMCFG): $(JVMCFG_SRC)
 	$(install-file)
 endif
 
diff -r 1a35342a99f4 -r 5ff313614d0d src/macosx/bin/universal/jvm.cfg
--- a/src/macosx/bin/universal/jvm.cfg	Mon Feb 06 02:18:10 2012 -0800
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,38 +0,0 @@
-# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# This code is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License version 2 only, as
-# published by the Free Software Foundation.  Oracle designates this
-# particular file as subject to the "Classpath" exception as provided
-# by Oracle in the LICENSE file that accompanied this code.
-#
-# This code is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
-# version 2 for more details (a copy is included in the LICENSE file that
-# accompanied this code).
-#
-# You should have received a copy of the GNU General Public License version
-# 2 along with this work; if not, write to the Free Software Foundation,
-# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
-#
-# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
-# or visit www.oracle.com if you need additional information or have any
-# questions.
-#
-# List of JVMs that can be used as an option to java, javac, etc.
-# Order is important -- first in this list is the default JVM.
-# NOTE that this both this file and its format are UNSUPPORTED and
-# WILL GO AWAY in a future release.
-#
-# You may also select a JVM in an arbitrary location with the
-# "-XXaltjvm=<jvm_dir>" option, but that too is unsupported
-# and may not be available in a future release.
-#
--server KNOWN
--client KNOWN
--hotspot ERROR
--classic WARN
--native ERROR
--green ERROR
diff -r 1a35342a99f4 -r 5ff313614d0d src/macosx/bin/x86_64/jvm.cfg
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/macosx/bin/x86_64/jvm.cfg	Mon Feb 06 02:29:57 2012 -0800
@@ -0,0 +1,38 @@
+# Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
+# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+#
+# This code is free software; you can redistribute it and/or modify it
+# under the terms of the GNU General Public License version 2 only, as
+# published by the Free Software Foundation.  Oracle designates this
+# particular file as subject to the "Classpath" exception as provided
+# by Oracle in the LICENSE file that accompanied this code.
+#
+# This code is distributed in the hope that it will be useful, but WITHOUT
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+# version 2 for more details (a copy is included in the LICENSE file that
+# accompanied this code).
+#
+# You should have received a copy of the GNU General Public License version
+# 2 along with this work; if not, write to the Free Software Foundation,
+# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+#
+# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+# or visit www.oracle.com if you need additional information or have any
+# questions.
+#
+# List of JVMs that can be used as an option to java, javac, etc.
+# Order is important -- first in this list is the default JVM.
+# NOTE that this both this file and its format are UNSUPPORTED and
+# WILL GO AWAY in a future release.
+#
+# You may also select a JVM in an arbitrary location with the
+# "-XXaltjvm=<jvm_dir>" option, but that too is unsupported
+# and may not be available in a future release.
+#
+-server KNOWN
+-client KNOWN
+-hotspot ERROR
+-classic WARN
+-native ERROR
+-green ERROR
                                     
2012-02-06



Hardware and Software, Engineered to Work Together