Building with a new javac flag
David Holmes
david.holmes at oracle.com
Tue Nov 13 03:41:49 PST 2012
On 13/11/2012 6:12 PM, Erik Joelsson wrote:
> In this case I would go with configure. This is because the value of the
> option has different defaults depending on jdk variant/profile. If it
> was a less often used parameter, something more general like
> "--with-add-javacflags=" could be used, but that only fits options that
> are always default off.
Bear in mind that we don't want to have to set this on the configure
invocation but rather be able to change the default through the custom
build files. This could either be done at configure time, or in the
custom makefiles by setting an appropriate make variable. So there is
some flexibility.
I haven't had a chance to look at where this needs to be set and am
travelling over the next few days.
David
-----
> On a sidenote, it's still possible to override configure options with
> variables in the environment or on the command line if you know the name
> of the make variable being set. I just wouldn't normally recommend it.
>
> /Erik
>
> On 2012-11-13 01:13, David Holmes wrote:
>> On 13/11/2012 7:51 AM, Alex Buckley wrote:
>>> Dear build experts,
>>>
>>> In JDK8, javac will be able to store the names/modifiers of method
>>> parameters in the class file. The names are stored only if a flag -
>>> let's say "-parameters" - is passed to javac.
>>>
>>> (I know this feels like storing debug info with -g. Please set that
>>> concern aside.)
>>>
>>> What would it take to compile JDK8 _without_ this flag when building
>>> Java SE Embedded, and _with_ this flag otherwise?
>>>
>>> (I know this will raise immediate questions about the size of
>>> non-Embedded rt.jar. Please set that concern aside.)
>>>
>>> David Holmes has suggested that javac flags are or could be expressed as
>>> a ./configure option, so that Embedded and non-Embedded build scripts
>>> can turn the -parameters flag on or off.
>>
>> But I also questioned whether it should be a configure option as you
>> can't make every possible tool flag be a configure option.
>>
>> The basic requirement is that the -parameters setting must be
>> customizable, so we need to decide the best way to achieve that.
>>
>> David
>>
>>> Alex
More information about the build-infra-dev
mailing list