New build system problems
Dmitry Samersoff
dmitry.samersoff at oracle.com
Sun Feb 24 08:19:49 UTC 2013
Martin,
257 if test "x$OPENJDK_TARGET_OS" != xmacosx; then
258 # Do not probe for cc on MacOSX.
259 COMPILER_CHECK_LIST="cc $COMPILER_CHECK_LIST"
260 fi
261 if test "x$OPENJDK_TARGET_OS" == xwindows; then
262 COMPILER_CHECK_LIST="cl $COMPILER_CHECK_LIST"
263 fi
1. for windows compiler checklist become: cl cc gcc
I'm not sure we need to check for cc on windows, also gcc build on
windows is not supported. So It might be better to be more explicit:
256 COMPILER_CHECK_LIST="cc gcc"
# Overriding COMPILER_CHECK_LIST to set OS specific preferences
257 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then
258 # Do not probe for cc on MacOSX.
259 COMPILER_CHECK_LIST="gcc"
260 fi
261 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
262 COMPILER_CHECK_LIST="cl"
263 fi
2. Not all versions of test support == as equation. It's better to use
single one. and I would prefer to have quotes around xmacosx and
xwindows just for consistency. i.e.
if test "x$OPENJDK_TARGET_OS" = "xwindows";
-Dmitry
On 2013-02-24 00:05, Martin Buchholz wrote:
> Hi Erik, Tim, Kelly
>
> Here's a proposed fix for you to review:
>
> http://cr.openjdk.java.net/~martin/webrevs/openjdk8/COMPILER_CHECK_LIST/
>
> Martin
>
> On Fri, Jan 25, 2013 at 3:51 PM, Martin Buchholz <martinrb at google.com>wrote:
>
>> I was trying out the shiny new build system.
>>
>> Problem: configure is not executable - must run bash ./configure
>> It's traditional for configure scripts to be executable.
>>
>> Problem: Your life is hell if you have a non-compiler "cl" command on your
>> PATH, even on Linux.
>>
>> checking for cl... /usr/bin/cl
>> configure: Resolving CC (as /usr/bin/cl) failed, using /usr/bin/cl
>> directly.
>>
>> with subsequent failure to compile.
>>
>> Even if you specify the compiler explicitly, it doesn't help:
>>
>> CC=/usr/bin/gcc CXX=/usr/bin/g++ bash ./configure
>>
>> Of course, one can work around this by creating a "tools dir", but
>> excising the unloved cl from the configure script is tempting and effective.
>>
--
Dmitry Samersoff
Oracle Java development team, Saint Petersburg, Russia
* Give Rabbit time, and he'll always get the answer
More information about the build-dev
mailing list