Building with a new javac flag
Alan Bateman
Alan.Bateman at oracle.com
Tue Nov 13 13:45:21 PST 2012
On 13/11/2012 20:50, Alex Buckley wrote:
>
> The primary reason for storing parameter names in JDK8 class files is
> to help IDE vendors, so it's fine if only the JDK image has them. We
> are not making a general promise that any program will be able to find
> parameter names of core Java Java SE classes at runtime. (Again,
> please set aside concerns about footprint, compatibility, etc on this
> list.)
>
> It sounds like a ./configure option of --enable-parameters could add
> an option to JAVAC_FLAGS - you say it would affect all images? But
> Erik said "the value of the option has different defaults depending on
> jdk variant/profile".
Suppose we do "configure --enable-paramater-names && make" then this
would compile the classes and native libraries but at this point we
don't have any images, rather it's just raw classes on the file system
(no rt.jar).
A subsequent "make images" would create the j2sdk-image and j2re-image
with the rt.jar and the layout that we are used to. I think, and Erik or
David can correct me, is that the same class files end up in both
images. Subsequent stripping of debug attributes from everything in
rt.jar may happen later, at least where JRE download size is important.
So my point about the parameter names is that the same classes are used
for all images. The "profiles" build is like "images", it's really just
packaging up the already compiled bits and so would get the same class
files, assuming of course that the JDK/JRE images and profiles images
are coming from the same build.
When Erik used the term "variant" then I assume he meant the
--with-jdk-variant and --with-jvm-variant options to configure normal or
embedded, client or server VM and things like that. That's part of the
configuration. If we are compiling classes differently then I suspect it
may require a separate configuration.
>
> Where should we look at the new build, given that the parameter
> feature lives in the jdk8/tl forest?
common/makefiles in the top-level repo, and makefiles directory in each
of the other repos. Alternatively this guide:
http://openjdk.java.net/projects/build-infra/guide.html
-Alan.
More information about the build-infra-dev
mailing list