RFR: JDK-8201536 configure fails compiler check due to bad -m32 flag

Erik Joelsson erik.joelsson at oracle.com
Thu Apr 19 20:19:45 UTC 2018


Looks good.

/Erik


On 2018-04-19 12:17, Magnus Ihse Bursie wrote:
> This is intended to be a proper fix for the -m32/-m64 compiler flag on 
> unsupported platforms regression due to my previous flag refactoring.
>
> Here's my analysis of the old code, from the bug report:
>
> The old code set the -m<bits> flag in these cases:
> if OS is solaris or aix,
> or if OS_TYPE is unix and build_type is reduced
>
> While this captures incorrect aspects of the situation, it has worked 
> without complaints. I think what it *really* tries to do is:
> * We can only run reduced builds on platforms where we can set the 
> -m<bits> flag.
> * xlc and sunstudio compilers needs to have -m<bits> (or -q<bits> in 
> the case of xlc) to function properly. I assume this also means it's 
> always supported for those compilers on the platforms we support there.
>
> For clang/gcc, the flag applies to x86, sparc and ppc. Maybe we should 
> just set it on x86, but then again, it won't hurt to set it on all 
> these three architectures.
>
> In theory, this means that reduced builds should be able to be 
> supported on all platforms that support sunstudio and xlc. However, 
> these are, afaik: solaris-sparcv9, solaris-x86_64, aix-ppc64, 
> aix-s390x, where we do not support a 32-bit variant anyway. I do not 
> know if there is an aix-x86 and aix-x86_64? If so, we should be able 
> to do a reduced build for aix-x86_64.
>
> So in practice, reduced builds are supported only for clang/gcc on 
> x86_64. (And Windows, which uses a different mechanism.)
>
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-8201536
> WebRev: 
> http://cr.openjdk.java.net/~ihse/JDK-8201536-fix-m64-cflag/webrev.01
>
> /Magnus
>



More information about the build-dev mailing list