This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Build problem with gcc 3.4 on Mac OS X


Davide Angelocola wrote:
checking how to run the C preprocessor... /lib/cpp
configure: error: C preprocessor "/lib/cpp" fails sanity check
$ grep cpp gcc/config.log
/Users/davang/gcc-3.4.0/gcc/configure: line 1: /lib/cpp: No such file or directory
configure:2814: /lib/cpp conftest.c

If you look at the gcc/config.log file instead of grepping it, you should see some useful info that might explain the failure.


configure will try "$CC -E" first, if this doesn't work, then I might wonder if something is wrong with the value of CC in your environment.

I don't know why /lib/cpp would be used unless perhaps you have the CPP environment variable set to it, but then that begs the question of why that environment variable is set. It should not be set normally.

$ CPP="/usr/bin/cpp" make

You may need to delete some config.cache files, and it is probably better to rerun configure than run make. Actually, it is probably best to rm -rf your entire build tree and try again, just to make sure you are getting a clean build.


I would suggest trying CPP="cc -E", or whatever $CC is set to instead of using /usr/bin/cpp directly. Or better yet, just set it to an empty string, and let configure determine which program to use as the C preprocessor.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]