Building Java 7 on OS X Snow Leopard

Brett Hoerner bretthoerner at
Wed Oct 7 13:31:42 PDT 2009

Hi guys,

Sorry I'm adding more to this (as some of you seem to have it working
now) but I'm trying to round up the process of successfully building
Java 7 on Snow Leopard into one place so it can put on a wiki or
blogged or something.

1) clone and update your local bsd-port
2) apply John Rose's snowleopard.patch to the bsd-port hotspot [1]
3) build bsd-port with GCC 4.0 and soylatte

Am I missing anything?  I believe I am as I still have build errors,

# ---------- my build script
$ cat
#!/usr/bin/env bash
env -i PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
CC=gcc-4.0 CXX=g++-4.0 \
make \
ALT_BOOTDIR=/Users/brett/Development/java/jdk-build/soylatte16-i386-1.0.3/ \
ANT_HOME=/usr/share/ant \
NO_DOCS=true \

# ---------- John's patch applied to the tree
$ hg fstatus
M hotspot/src/cpu/x86/vm/methodHandles_x86.cpp
M hotspot/src/share/vm/classfile/javaClasses.cpp
M hotspot/src/share/vm/utilities/globalDefinitions.hpp
M hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp

# ---------- error during build
cd bsd_i486_compiler2/product && ./test_gamma
java full version "1.6.0_03-p3-landonf_19_aug_2008_14_55-b00"
# A fatal error has been detected by the Java Runtime Environment:
#  SIGBUS (0xa) at pc=0x000ccfaf, pid=36735, tid=2686592256
# JRE version: 6.0_03
# Java VM: OpenJDK Server VM (17.0-b01 mixed mode bsd-x86 )
# Problematic frame:
# V  [libjvm.dylib+0xc3faf]
# An error report file with more information is saved as:
# /Users/brett/Development/java/jdk-build/bsd-port/build/bsd-i586/hotspot/outputdir/bsd_i486_compiler2/product/hs_err_pid36735.log
# If you would like to submit a bug report, please visit:
./test_gamma: line 12: 36735 Abort trap              ./${gamma:-gamma}
-Xbatch -showversion Queens < /dev/null
make[4]: *** [product] Error 134
make[3]: *** [generic_build2] Error 2
make[2]: *** [product] Error 2
make[1]: *** [hotspot-build] Error 2
make: *** [build_product_image] Error 2

# ----------
I've attached the full error log which shows environment variables,
etc.  Are you guys using a different soylatte build or something?


-------------- next part --------------
A non-text attachment was scrubbed...
Name: hs_err_pid36735.log
Type: application/octet-stream
Size: 5353 bytes
Desc: not available
Url : 

More information about the bsd-port-dev mailing list