------- Comment #24 from eesrjhc at bath dot ac dot uk 2007-03-19 09:30 ------- (In reply to comment #20) > (In reply to comment #19) > ... > > this isn't enough even with building with this brand new > > gcc-4.3.0_alpha20070309. > > I'll repeat it with include of proper stdio.h, which looks in gentoo > > multilib > > like this > > > > jama gcc # cat /usr/include/stdio.h > > Ok, thanks. But then, an important question is: which (empty? not including > any > declaration of the expected facilities?!? What header is that?) stdio.h is > instead included at build time if you don't specify explicitely the path? You > should try to figure out that, whether on your system there are around (in the > build directory or elsewhere) stdio.h which in fact are not the correct one. > > In order to do that, you could proceed as follows: go the build directory of > the library and invoke by hand the same line which is failing the build of > compatibility.cc, but running only the preprocessor, with -E. You save its > output, it should tell us what a heck of wrong stdio.h is included. >
Incidentally, I have (by using a binary search, bootstapping into an empty build directory each time) found that revision 121025 builds OK, while revision 121027 fails with this problem. Doing the suggestion above, this is what I get: [EMAIL PROTECTED] $ /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/xgcc -sh ared-libgcc -B/MHz/roger/src/gcc-svn-121027/build-121027/./gcc -nostdinc++ -L/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/src -L/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs -B/usr/local/gcc-svn/x86_64-unknown-linux-gnu/bin/ -B/usr/local/gcc-svn/x86_64-unknown-linux-gnu/lib/ -isystem /usr/local/gcc-svn/x86_64-unknown-linux-gnu/include -isystem /usr/local/gcc-svn/x86_64-unknown-linux-gnu/sys-include -I/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu -I/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include -I/MHz/roger/src/gcc-svn-121027/trunk/libstdc++-v3/libsupc++ -fno-implicit-templates -Wall -Wextra -Wwrite-strings -Wcast-qual -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -O2 -D_GNU_SOURCE -c ../../../../trunk/libstdc++-v3/src/compatibility.cc -fPIC -DPIC -o .libs/compatibility.o -E -v Reading specs from /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/specs Target: x86_64-unknown-linux-gnu Configured with: ../trunk/configure --prefix=/usr/local/gcc-svn --enable-languages=c,c++ --disable-multilib Thread model: posix gcc version 4.3.0 20070121 (experimental) /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/cc1plus -E -quiet -nostdinc++ -v -I/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu -I/MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include -I/MHz/roger/src/gcc-svn-121027/trunk/libstdc++-v3/libsupc++ -iprefix /MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc/x86_64-unknown-linux-gnu/4.3.0/ -isystem /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/include -D_GNU_SOURCE -D_GNU_SOURCE -DPIC -isystem /usr/local/gcc-svn/x86_64-unknown-linux-gnu/include -isystem /usr/local/gcc-svn/x86_64-unknown-linux-gnu/sys-include ../../../../trunk/libstdc++-v3/src/compatibility.cc -o .libs/compatibility.o -mtune=generic -Wall -Wextra -Wwrite-strings -Wcast-qual -fno-implicit-templates -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -fPIC -fworking-directory -O2 ignoring nonexistent directory "/usr/local/gcc-svn/x86_64-unknown-linux-gnu/include" ignoring nonexistent directory "/usr/local/gcc-svn/x86_64-unknown-linux-gnu/sys-include" ignoring nonexistent directory "/MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc/x86_64-unknown-linux-gnu/4.3.0/include" ignoring nonexistent directory "/MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc/x86_64-unknown-linux-gnu/4.3.0/../../../../x86_64-unknown-linux-gnu/include" ignoring nonexistent directory "/MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc//include" ignoring nonexistent directory "/MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc//lib/gcc/x86_64-unknown-linux-gnu/4.3.0/include" ignoring nonexistent directory "/MHz/roger/src/gcc-svn-121027/build-121027/gcc/../lib/gcc//lib/gcc/x86_64-unknown-linux-gnu/4.3.0/../../../../x86_64-unknown-linux-gnu/include" #include "..." search starts here: #include <...> search starts here: /MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu /MHz/roger/src/gcc-svn-121027/build-121027/x86_64-unknown-linux-gnu/libstdc++-v3/include /MHz/roger/src/gcc-svn-121027/trunk/libstdc++-v3/libsupc++ /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/include /usr/local/include /usr/include End of search list. So, searching in order the directories listed above, the first occurence of stdio.h in the directory concerned is this: /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/include/stdio.h which contains this: [EMAIL PROTECTED] $ cat /MHz/roger/src/gcc-svn-121027/build-121027/./gcc/include/stdio.h /* DO NOT EDIT THIS FILE. It has been auto-edited by fixincludes from: "/usr/include/stdio.h" This had to be done to correct non-standard usages in the original, manufacturer supplied header file. */ #ifndef FIXINC_WRAP_STDIO_H_STDIO_STDARG_H #define FIXINC_WRAP_STDIO_H_STDIO_STDARG_H 1 #define __need___va_list #include <stdarg.h> /* Autogenerated by create_ml_includes() in multilib.eclass */ #ifdef __i386__ # include <gentoo-multilib/x86/stdio.h> #endif /* __i386__ */ #ifdef __x86_64__ # include <gentoo-multilib/amd64/stdio.h> #endif /* __x86_64__ */ #endif /* FIXINC_WRAP_STDIO_H_STDIO_STDARG_H */ Could this be related to the problem in http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29867 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30915