Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 4 Jun 2007 22:53:16 -0700
From:      Greg Lewis <glewis@eyesbeyond.com>
To:        Don Lewis <truckman@freebsd.org>
Cc:        glewis@freebsd.org, vova@sw.ru, current@freebsd.org, java@freesbd.org
Subject:   Re: failed to build java/jdk15 on recent current - gcc4 issue ?
Message-ID:  <20070605055316.GA42186@misty.eyesbeyond.com>
In-Reply-To: <200706042016.l54KGBRo058608@gw.catspoiler.org>
References:  <1180976737.24934.4.camel@localhost> <200706042016.l54KGBRo058608@gw.catspoiler.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jun 04, 2007 at 01:16:11PM -0700, Don Lewis wrote:
> On  4 Jun, Vladimir Grebenschikov wrote:
> > java/jdk14 also fails to build.
> 
> I managed to rebuild jdk14 even after "make delete-old-libs" using the
> gcc34 port and bootstrapping using the Linux JDK.  I haven't yet had a
> chance to see if the plugin communicates with Firefox built with the
> system compiler or if there will be an ABI mismatch.
> 
> In the process I discovered two interesting quirks. The first is that
> there are a number of places that set $(CXX), assuming that this is c++
> compiler, and $(CPP), assuming that this is the preprocessor. This isn't
> entirely true, because the hotspot build uses $(CPP) as the c++ compiler
> (see hotspot/build/*/makefiles/adlc.make).  The linker bails out when it
> encounters a .o file that is actually just source code that has been run
> through the preprocessor. The second quirk is that overriding $(CC) in
> MAKE_ARGS isn't sufficient to get the j2se portion of the build to work,
> because j2se/make/common/Defs-bsd.gmk doesn't allow $(CC) to be
> overridden.

Agreed.  The HotSpot build is definitely quirky about allowing the
compiler to be overridden.  It actually seems to have gotten worse
in later releases (it includes a header file based on the compiler
name and it better be gcc).

> I added this to MAKE_ARGS in pkgtools.conf:
> 
>         'java/jdk14' => [
>             'WITH_LINUX_BOOTSTRAP=yes',
>             'USE_GCC=3.4',
>             'MAKE_FLAGS="CC=/usr/local/bin/gcc34 CXX=/usr/local/bin/c++34  CPP=/
> usr/local/bin/c++34"',
>         ],
> 
> and I had to apply this patch (to a patch):
[snip]

Thanks for tracking this down!  I think the other jdk* ports also have
problems respecting $(CC) and $(CXX).  

I'll get this committed to jdk14.

It would be interesting to try the jdk15 port with gcc34 (or even the
gcc42 port rather than system compiler).  There will need to be some
more hackery to try that though I believe.

-- 
Greg Lewis                          Email   : glewis@eyesbeyond.com
Eyes Beyond                         Web     : http://www.eyesbeyond.com
Information Technology              FreeBSD : glewis@FreeBSD.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070605055316.GA42186>