Solaris compiler setup ?

Erik Joelsson erik.joelsson at oracle.com
Thu Aug 9 00:58:10 PDT 2012


Comparing your log to mine, this is what happens:

configure:10112: checking whether CC accepts -g
configure:10132: CC -c -g  conftest.cpp >&5
configure:10132: $? = 0
configure:10173: result: yes
configure:10329: checking for gcc
configure:10345: found /usr/local/bin/gcc
configure:10356: result: gcc
configure:10381: checking for Objective C compiler version
configure:10390: gcc --version >&5
gcc (GCC) 3.4.6
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


So for some reason, autoconf wants to find gcc too and on my system it 
happens to be there. I will look into it.

/Erik

On 2012-08-09 06:39, David Holmes wrote:
> When I run configure on Solaris it can't find the "needed compilers".
>
> checking if this is a cross compile... no
> checking for cl... no
> checking for cc... cc
> checking whether the C compiler works... yes
> checking for C compiler default output file name... a.out
> checking for suffix of executables...
> checking whether we are cross compiling... no
> checking for suffix of object files... o
> checking whether we are using the GNU C compiler... no
> checking whether cc accepts -g... yes
> checking for cc option to accept ISO C89... none needed
> `tty`: Ambiguous
> checking for cl... no
> checking for CC... CC
> checking whether we are using the GNU C++ compiler... no
> checking whether CC accepts -g... yes
> `tty`: Ambiguous
> configure: error: Could not find the needed compilers!
>
> It finds CC, which is in my path at:
>
> /java/devtools/i386/SUNWspro/SS12u1/bin/CC
>
> What is it looking for? config.log shows:
>
> configure:10084: checking whether we are using the GNU C++ compiler
> configure:10103: CC -c   conftest.cpp >&5
> "conftest.cpp", line 14: Error: choke is not defined.
> 1 Error(s) detected.
> configure:10103: $? = 1
> configure: failed program was:
> | /* confdefs.h */
> | #define PACKAGE_NAME "openjdk"
> | #define PACKAGE_TARNAME "openjdk"
> | #define PACKAGE_VERSION "jdk8"
> | #define PACKAGE_STRING "openjdk jdk8"
> | #define PACKAGE_BUGREPORT "build-dev at openjdk.java.net"
> | #define PACKAGE_URL ""
> | /* end confdefs.h.  */
> |
> | int
> | main ()
> | {
> | #ifndef __GNUC__
> |        choke me
> | #endif
> |
> |   ;
> |   return 0;
> | }
> configure:10112: result: no
> configure:10121: checking whether CC accepts -g
> configure:10141: CC -c -g  conftest.cpp >&5
> configure:10141: $? = 0
> configure:10182: result: yes
> configure:10280: error: Could not find the needed compilers!
>
> ??
>
> Thanks,
> David



More information about the build-infra-dev mailing list