building (or not) OpenJDK 7 on Mac OS X

Ray Kiddy ray at ganymede.org
Thu Dec 10 17:01:32 UTC 2009


I just wanted to update build people on this issue. There are pages on  
the wiki for building on Mac OS X 10.5.8 and on Snow Leopard. See the  
"Building from source" section of http://wikis.sun.com/display/OpenJDK/BSDPort 
. I have updated http://wikis.sun.com/display/OpenJDK/Darwin9Build  
with information from an external post of Landon Fuller's. (FYI, I  
checked with him about the copying and he was ok with it.) Since I am  
not using Snow Leopard, I am leaving that page to someone else.

If anyone _can_ build OpenJDK 1.7 on a 10.5 system, please share  
information about how they this is accomplished. I particularly like  
the way Landon structured his page. For each separate requirement, the  
page says "you need this", then "do this (or this or this)", and then  
"if that worked, you will/should see this." I have been working with  
other build system, such as for Mozilla, and the doc often leaves out  
that last step. So, if someone can build, can they report what they do  
and what they then see? I am willing to share my build logs (http://www.wykiwyk.com/openjdk/buildLogs/ 
), but at this point I can only demonstrate how not to succeed.  
Unfortunately, it is easy to find info from people like me, who cannot  
build. Is it just that the people who can build are silent?

It would be great if, one day, we could go to http://openjdk.java.net/install/ 
  and see Mac OS X binaries to install from there, in addition to the  
Solaris and Linux binaries. Making the BSD-Port more generally  
buildable will probably help that. As the largest installed base of  
Unix systems on the planet, Mac OS X can help the OpenJDK effort if  
there is some support.

Please post or update the wiki with any suggestions or questions.

cheers - ray

	refs:

	http://wikis.sun.com/display/OpenJDK/BSDPort
	http://wikis.sun.com/display/OpenJDK/Darwin9Build
	http://confluence.concord.org/display/CCTR/Build+OpenJDK+Java+1.7.0+on+Mac+OS+X+10.5
	http://www.javarants.com/2009/11/01/building-openjdk-1-7-0-for-mac-os-x-10-6-snow-leopard/
	http://openjdk.java.net/install/

	FYI, my particular build error is this. I suspect I am missing some  
minor little environment variable, but it is not obvious which. -rrk

/bin/mkdir -p /Users/ray/Projects/OpenJDK/bsd-port/build/bsd-i586/tmp/ 
java/java.lang/java/obj
rm -f /Users/ray/Projects/OpenJDK/bsd-port/build/bsd-i586/tmp/java/ 
java.lang/java/obj/.class.headers.i586
# Running javah:
/NOT-SET/re/jdk/1.7.0/promoted/latest/binaries/bsd-i586/bin/javah - 
bootclasspath /Users/ray/Projects/OpenJDK/bsd-port/build/bsd-i586/ 
classes -d /Users/ray/Projects/OpenJDK/bsd-port/build/bsd-i586/tmp/ 
java/java.lang/java/CClassHeaders/ \
		java.lang.Object java.lang.Class java.lang.Compiler java.lang.String  
java.lang.Thread java.lang.ThreadGroup java.lang.StrictMath  
java.lang.Number java.lang.Byte java.lang.Short java.lang.Integer  
java.lang.Long java.lang.Float java.lang.Double java.lang.Boolean  
java.lang.Character java.lang.System java.lang.ClassLoader  
java.lang.Runtime java.lang.SecurityManager java.lang.Shutdown  
java.lang.Package java.lang.ref.Finalizer  
java.lang.reflect.AccessibleObject java.lang.reflect.Field  
java.lang.reflect.Method java.lang.reflect.Constructor  
java.lang.reflect.InvocationTargetException java.lang.reflect.Array  
java.lang.reflect.Proxy java.security.AccessController java.util.Date  
java.util.TimeZone java.util.ResourceBundle  
java.util.concurrent.atomic.AtomicLong  
java.util.prefs.FileSystemPreferences java.io.Console  
java.io.FileDescriptor java.io.InputStream java.io.FileInputStream  
java.io.FileOutputStream java.io.PrintStream java.io.RandomAccessFile  
java.io.DataInputStream java.io.DataOutputStream java.io.File  
java.io.FileSystem java.io.UnixFileSystem java.io.ObjectInputStream  
java.io.ObjectOutputStream java.io.ObjectStreamClass  
java.lang.Throwable java.lang.NoClassDefFoundError  
java.lang.StringIndexOutOfBoundsException java.lang.OutOfMemoryError  
sun.misc.Version sun.misc.VM sun.misc.VMSupport sun.misc.Signal  
sun.misc.MessageUtils sun.misc.NativeSignalHandler sun.misc.GC  
sun.reflect.ConstantPool sun.reflect.NativeConstructorAccessorImpl  
sun.reflect.NativeMethodAccessorImpl sun.reflect.Reflection    
java.lang.ClassLoader\$NativeLibrary
make[4]: /NOT-SET/re/jdk/1.7.0/promoted/latest/binaries/bsd-i586/bin/ 
javah: Command not found
make[4]: *** [/Users/ray/Projects/OpenJDK/bsd-port/build/bsd-i586/tmp/ 
java/java.lang/java/obj/.class.headers.i586] Error 127
make[3]: *** [all] Error 1
make[2]: *** [all] Error 1
make[1]: *** [jdk-build] Error 2
make: *** [build_product_image] Error 2




More information about the build-dev mailing list