[Python-Dev] failure: 2.1a2 on HP-UX with native compiler

Thomas Wouters thomas@xs4all.net
Wed, 14 Feb 2001 10:32:58 +0100


On Tue, Feb 13, 2001 at 06:34:11PM -0600, Charles G Waldman wrote:

> this box has both gcc and the native compiler installed, but not g++.
> I tried to configure with the command:
> otto:Python-2.1a2$ ./configure --without-gcc

> configure: error: installation or configuration problem: C++ compiler cannot create executables.

> Seems like the "--without-gcc" flag is being completely ignored!

Yes. --without-gcc is only used for the C compiler, not the C++ one. For the
C++ compiler, if you do not specify '--with-cxx=...', configure uses the
first existing program out of this list:

$CCC c++ g++ gcc CC cxx cc++ cl

The check to determine whether the chosen compiler actually works is made
later, and if it doesn't work, it won't try the next one in the list. The
solution is thus to provide a working CXX compiler using --with-cxx=<prog>.

Two questions for python-dev (in particular autoconf-god Eric -- time to
earn your pay! ;-) Is there a reason '$CXX' is not in the list of tested
C++ compilers, even before $CCC ? That would allow 

CXX=c++-compiler ./configure

to work.

As for the other question: The --without-gcc usage message seems wrong:

AC_ARG_WITH(gcc, [  --without-gcc                   never use gcc], [

Asside from '--without-gcc', you can also use '--with-gcc' and
'--with-gcc=<compiler>'. Is there a specific reason not to document that ?

-- 
Thomas Wouters <thomas@xs4all.net>

Hi! I'm a .signature virus! copy me into your .signature file to help me spread!