[NEW BUG]: Configure broken on MIPS

David Holmes david.holmes at oracle.com
Fri Mar 23 05:22:03 UTC 2018


Hi Thomas,

On 23/03/2018 2:55 PM, Thomas Stüfe wrote:
> Hi David,
> 
> would it not be pragmatic to accept Ao's patch - it looks fine to me - 
> since it certainly would not make matters worse. And let Magnus follow 
> up with a cleanup change later?

Well I hope Magnus's change is forthcoming. AFAICS it's as easy to write 
this only for x86 as it is to exclude it for non x86. Honestly I don't 
know why the Aarch64 patch was done the way it was - there must be some 
subtlety here that I'm not aware of.

Ao has the fix locally and I'm assuming we don't have a large number of 
MIPS users waiting for this urgently (and they can trivially patch it 
locally anyway). Otherwise there's just more bug processing overhead.

David

> Best Regards, Thomas
> 
> On Fri, Mar 23, 2018 at 2:37 AM, David Holmes <david.holmes at oracle.com 
> <mailto:david.holmes at oracle.com>> wrote:
> 
>     On 23/03/2018 11:33 AM, Ao Qi wrote:
> 
>         So what should be the next? Is that another problem, or should the
>         MIPS broken configure be fixed together?
> 
> 
>     There should be one proper fix to cover all affected platforms.
> 
>     David
> 
> 
>         2018-03-23 5:04 GMT+08:00 David Holmes <david.holmes at oracle.com
>         <mailto:david.holmes at oracle.com>>:
> 
>             On 23/03/2018 12:13 AM, Erik Joelsson wrote:
> 
> 
>                 Hello,
> 
>                 The fix looks correct, but I'm starting to think that
>                 maybe the
>                 conditional should be inverted and instead list the
>                 architectures that
>                 actually use -m64? It seems a whole lot of them don't.
> 
> 
> 
>             Magnus indicated he was working on a better solution when he
>             put in the
>             quick-fix check for Aarch64. Yes this should only add -m64
>             on compilers and
>             platforms that support it.
> 
>             David
>             -----
> 
> 
>                 /Erik
> 
> 
>                 On 2018-03-21 23:24, Ao Qi wrote:
> 
> 
>                     Hi,
> 
>                     I found configure of
>                     http://hg.openjdk.java.net/jdk/jdk
>                     <http://hg.openjdk.java.net/jdk/jdk> was broken on
>                     MIPS.
> 
>                     the output of configure:
>                     ...
>                     configure: Using default toolchain gcc (GNU Compiler
>                     Collection)
>                     checking for gcc... /usr/bin/gcc
>                     checking resolved symbolic links for CC...
>                     /usr/bin/mips64el-linux-gnuabi64-gcc-6
>                     configure: Using gcc C compiler version 6.3.0 [gcc
>                     (Debian 6.3.0-18)
>                     6.3.0 20170516]
>                     checking whether the C compiler works... no
>                     configure: error: in `/home/loongson/aoqi/jdk':
>                     configure: error: C compiler cannot create executables
>                     See `config.log' for more details
>                     configure exiting with result code 77
>                     ...
> 
>                     the related content of config.log:
>                     ...
>                     configure:35256: checking whether the C compiler works
>                     configure:35278: /usr/bin/gcc -m64    -m64 
>                       conftest.c  >&5
>                     gcc: error: unrecognized command line option '-m64'
>                     gcc: error: unrecognized command line option '-m64'
>                     configure:35282: $? = 1
>                     configure:35320: result: no
>                     configure: failed program was:
>                     | /* confdefs.h */
>                     | #define PACKAGE_NAME "OpenJDK"
>                     | #define PACKAGE_TARNAME "openjdk"
>                     | #define PACKAGE_VERSION "jdk9"
>                     | #define PACKAGE_STRING "OpenJDK jdk9"
>                     | #define PACKAGE_BUGREPORT
>                     "build-dev at openjdk.java.net
>                     <mailto:build-dev at openjdk.java.net>"
>                     | #define PACKAGE_URL "http://openjdk.java.net"
>                     | /* end confdefs.h.  */
>                     |
>                     | int
>                     | main ()
>                     | {
>                     |
>                     |   ;
>                     |   return 0;
>                     | }
>                     configure:35325: error: in `/home/loongson/aoqi/jdk':
>                     configure:35327: error: C compiler cannot create
>                     executables
>                     See `config.log' for more details
>                     ...
> 
> 
>                     I made a small patch to pass the configure:
> 
>                     $ hg diff make/autoconf/flags.m4
>                     diff -r 3acb379b8672 make/autoconf/flags.m4
>                     --- a/make/autoconf/flags.m4 Thu Mar 22 08:09:51
>                     2018 +0800
>                     +++ b/make/autoconf/flags.m4 Thu Mar 22 12:55:00
>                     2018 +0800
>                     @@ -237,7 +237,11 @@
>                             MACHINE_FLAG="-q${OPENJDK_TARGET_CPU_BITS}"
>                           elif test "x$TOOLCHAIN_TYPE" != xmicrosoft; then
>                             if test "x$OPENJDK_TARGET_CPU" != xaarch64 &&
>                     -        test "x$OPENJDK_TARGET_CPU" != xarm; then
>                     +        test "x$OPENJDK_TARGET_CPU" != xarm &&
>                     +        test "x$OPENJDK_TARGET_CPU" != xmips &&
>                     +        test "x$OPENJDK_TARGET_CPU" != xmipsel &&
>                     +        test "x$OPENJDK_TARGET_CPU" != xmips64 &&
>                     +        test "x$OPENJDK_TARGET_CPU" != xmips64el; then
>                               MACHINE_FLAG="-m${OPENJDK_TARGET_CPU_BITS}"
>                             fi
>                           fi
> 
> 
>                     I think this is the same problem with bug 8199052
>                     and 8199152. Could
>                     someone help to review the change?
> 
>                     Thanks,
>                     Ao Qi
> 
> 
> 
> 
> 



More information about the build-dev mailing list