[PATCH FOR REVIEW]: Make source/target options explicit for MakeDeps and jvmti

John Coomes John.Coomes at sun.com
Tue Aug 18 10:37:31 PDT 2009

Daniel D. Daugherty (Daniel.Daugherty at Sun.COM) wrote:
> Andrew,
> A couple of comments:
> - if you specify '-source 6', then '-target 6' is implied
>   so you don't really need both
> - I would prefer to see a top-level macro that defines the
>   bootstrap tools javac option and then have the various
>   Makefiles use that macro. Something in make/defs.make:
>   or something like that.

+1 on the top-level macro.  In HotSpot, I would call it JAVAC_FLAGS or
COMPILE_JAVAC_FLAGS, and add it to the COMPILE.JAVAC macro (spelled
COMPILE_JAVAC on windows) so that every compilation uses it.  Then
fewer places need to be touched.

Also, please leave the default value empty.  On platforms that need
it, it can be set on the command line or in the environment.
Specifying a value requires periodic maintenance.  Yes, the period is
long, but it's a pain when the build breaks because of some stale
value in a makefile.

> Which repo are you targeting for this change?

I'd suggest hotspot-rt.

Note that all hotspot changes have to be built on all platforms before
being pushed; we have an automated system called jprt that does builds
and tests on the various platforms.  Unfortunately, it isn't available
externally.  Sync up with the latest hotspot-rt and then contact me
privately with a patch or your repo location and I'll run it through.

> Yes, I see that SA uses '-source 1.4' in each platform makefile.
> That should be fixed also, but that's another issue...

Sigh.  Stale values in makefiles ...


> > Andrew John Hughes wrote:
> > The makeDeps and jvmti bootstrap tools are built without explicit
> > source and target options.
> >
> > This webrev:
> >
> > http://cr.openjdk.java.net/~andrew/ecj/03/webrev.01/
> >
> > sets them to 6 explicitly. The change has to be replicated three
> > times, because for some reason, the javac invocations are in
> > platform-specific makefiles.  I've tested the change successfully on
> > GNU/Linux, where it allows ecj to be used as javac.  ecj defaults to
> > <1.5 and thus otherwise fails to build.  I've assumed that the same
> > changes are applicable for Solaris and Windows, and that the source
> > and target options don't have to be written in Latin or something to
> > work on these platforms.
> >
> > Is this ok to push?
> >
> > Thanks,
> >   

More information about the hotspot-dev mailing list