OpenJDK 7 build fails on Snow Leopard
glewis at eyesbeyond.com
Sun Oct 18 20:38:55 PDT 2009
On Sun, Oct 18, 2009 at 01:06:36PM -0700, Greg Lewis wrote:
> On Fri, Oct 02, 2009 at 06:06:01PM -0700, John Rose wrote:
> > With the current bsd-port plus unrelated MLVM patches I got a clean
> > Snow Leopard build. It passed the MLVM regression tests.
> > I had to use GCC 4.0 as Michael suggested.
> > The 4.2 compiler is offering some porting resistance. I put a patch
> > into MLVM which copes with the new "printf" warnings it generates:
> > http://hg.openjdk.java.net/mlvm/mlvm/hotspot/raw-file/f9a6cda5b465/snowleopard.patch
> Looking at the patch, it defines FORMATL32_MODIFIER for all gcc >= 4.2.
> Interestingly, FreeBSD (7.x) uses gcc 4.2.1 and doesn't have any problem
> compiling HotSpot (its my main platform). So perhaps this is overly
> broad? I'll give the patch a try and see if it causes any compile
> problems. If so then we probably want to restrict this to just MacOS X
> and not all platforms in general.
Following up my own email...
I did do a test compile without any problems on FreeBSD. Looking further
at the patch I have to wonder why the OpenJDK code is essentially doing a
mini version of the printf defines from <inttypes.h>. Thats a standard
C99 header file, so why not just use the defines there? E.g. just use
PRIdPTR instead of the JVM defining its own PTR_FORMAT.
Greg Lewis Email : glewis at eyesbeyond.com
Eyes Beyond Web : http://www.eyesbeyond.com
Information Technology FreeBSD : glewis at FreeBSD.org
More information about the bsd-port-dev