RFR: JDK-8075140: Solaris build of native libraries not consistently using EXTRA_CFLAGS and EXTRA_LDFLAGS
Dean Long
dean.long at oracle.com
Sat Mar 14 19:34:17 UTC 2015
On 3/13/2015 5:08 PM, David Holmes wrote:
> Hi Erik,
>
> On 14/03/2015 12:08 AM, Erik Joelsson wrote:
>> Hello,
>>
>> While working on the new Hotspot makefiles in build-infra I noticed this
>> problem. When introducing devkits for Solaris, we rely on the variables
>> EXTRA_CFLAGS, EXTRA_CXXFLAGS and EXTRA_LDFLAGS to propagate the SYSROOT
>> specific flags into the hotspot build. However, these flags aren't
>> consistently used in the Hotspot build for all the native libraries.
>>
>> This patch adds the variables to all missing compile and link command
>> lines. It also fixes an issue with saproc.so where the debug info was
>> created off one of the object files instead of the library.
>>
>> Bug: https://bugs.openjdk.java.net/browse/JDK-8075140
>> Webrev: http://cr.openjdk.java.net/~erikj/8075140/webrev.hotspot.01/
>
> For linux we primarily (only?) use these to pass cross-compilation
> flags and so everything that is compiled generally needs the same flags.
>
> Outside of cross-compilation though that doesn't necessarily hold. If
> someone uses EXTRA_CFLAGS as a general customization mechanism it
> might only be intended for the primary VM build not for secondary
> libraries like jsig, dtrace and SA.
>
> So I'm not sure that this is the right thing to do as really these
> variables are not quite what people might expect them to be. In
> general local customizations are better handled by local editing of
> the appropriate build file.
>
Related to that, I noticed that cross-compiler sysroot flags are being
included in
jdk/make/gensrc/GensrcMisc.gmk when BUILD_CC and BUILD_LD are used,
apparently because these flags get added to CFLAGS by default. Is there
such
thing as BUILD_CFLAGS that BUILD_CC should use?
dl
> David
>
>> /Erik
More information about the build-dev
mailing list