autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: /lib/cpp again


From: Ralf Corsepius
Subject: Re: /lib/cpp again
Date: Thu, 05 Jul 2001 22:15:32 +0200

Peter Eisentraut wrote:
> 
> Akim Demaille writes:
> 
> > Also, (the question might have already been asked, but I confess the
> > answer escapes me): why don't we AC_CHECK_TOOL for cpp?  And then fall
> > back to /lib/cpp if available.
> 
> Because cpp is not a cross tool,
Hmm, I beg to differ. 

Actually, gcc's cpp is a real build-host native tool and by no means
target-independent:

/opt/gcc30/bin/cpp -v tmp.c
Reading specs from
/opt/gcc30/lib/gcc-lib/i486-suse-linux/3.0.1/specs
Configured with: ../configure --enable-threads=posix
--enable-long-long --prefix=/opt/gcc30 --mandir=/opt/gcc30/man
--infodir=/opt/gcc30/info --with-local-prefix=/usr/local
--enable-languages=c,c++,f77,objc,java --disable-nls --enable-shared
--with-system-zlib --host=i486-suse-linux --build=i486-suse-linux
Thread model: posix
gcc version 3.0.1 20010701 (prerelease)
 /opt/gcc30/lib/gcc-lib/i486-suse-linux/3.0.1/cpp0 -lang-c -v
-D__ELF__ -Dunix -Dlinux -D__ELF__ -D__unix__ -D__linux__ -D__unix
-D__linux -Asystem=posix -D__NO_INLINE__ -D__STDC_HOSTED__=1
-Acpu=i386 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i486__
tmp.c
GNU CPP version 3.0.1 20010701 (prerelease) (cpplib) (i386
Linux/ELF)
ignoring nonexistent directory "/opt/gcc30/i486-suse-linux/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/include
 /opt/gcc30/lib/gcc-lib/i486-suse-linux/3.0.1/include
 /usr/include
End of search list.

Note the references to the target's architecture => gcc's is by no
means a target independent tools.

> it's supposed to be platform independent.
> E.g., GCC 3.0 installs
> 
> c++
> c++filt
> cpp
> g++
> gcc
> gccbug
> gcov
> i586-pc-linux-gnu-c++
> i586-pc-linux-gnu-g++
> i586-pc-linux-gnu-gcc

Well, IMHO, installing the transformed forms of c++, g++ and gcc for
native compilers actually is a bug in gcc :) 
I already considered to file a bug report to gcc's bugzilla, but the
transformed forms normally also do not disturb ...

Ralf



reply via email to

[Prev in Thread] Current Thread [Next in Thread]