Le 24/04/2012 02:38, Andrew Benton a écrit :
> If you only add --with-native-system-header-dir=/tools/include to the
> second pass of gcc then you will still need --without-ppl and
> --without-cloog for the second pass of gcc.
>
> I get a build failure if I try to build without
> --with-native-system-header-dir=/tools/include in the first pass of gcc
> as the first, cross gcc is still searching /usr/include and so
Amazing,

It does not for me:
----------------------------
lfs@<host>:~$ echo main'(){}' | x86_64-lfs-linux-gnu-gcc -B /tools/lib 
-v -xc -
Reading specs from 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/specs
COLLECT_GCC=x86_64-lfs-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.0/lto-wrapper
Target: x86_64-lfs-linux-gnu
Configured with: ../gcc-4.7.0/configure --target=x86_64-lfs-linux-gnu 
--prefix=/tools --disable-nls --disable-shared --disable-multilib 
--disable-decimal-float --disable-threads --disable-libmudflap 
--disable-libssp --disable-libgomp --disable-libquadmath 
--enable-languages=c 
--with-mpfr-include=/mnt/lfs/sources/gcc-build/../gcc-4.7.0/mpfr/src 
--with-mpfr-lib=/mnt/lfs/sources/gcc-build/mpfr/src/.libs
Thread model: single
gcc version 4.7.0 (GCC)
COLLECT_GCC_OPTIONS='-B' '/tools/lib' '-v' '-mtune=generic' '-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.0/cc1 
-quiet -v -iprefix 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/ -isystem 
/tools/include - -quiet -dumpbase - -mtune=generic -march=x86-64 
-auxbase - -version -o /tmp/cccRNuvH.s
GNU C (GCC) version 4.7.0 (x86_64-lfs-linux-gnu)
         compiled by GNU C version 4.6.3, GMP version 5.0.4, MPFR 
version 3.1.0, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/sys-include"
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/include"
ignoring duplicate directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/include"
ignoring duplicate directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/include-fixed"
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/sys-include"
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
  /tools/include
  /mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/include
  /mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/include-fixed
End of search list.
GNU C (GCC) version 4.7.0 (x86_64-lfs-linux-gnu)
         compiled by GNU C version 4.6.3, GMP version 5.0.4, MPFR 
version 3.1.0, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 57342ec071cb444fb4cdf2d6275be122
COLLECT_GCC_OPTIONS='-B' '/tools/lib' '-v' '-mtune=generic' '-march=x86-64'
  
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/bin/as
 --64 -o /tmp/ccWwgVYh.o /tmp/cccRNuvH.s
COMPILER_PATH=/tools/lib/:/mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.0/:/mnt/lfs/tools/bin/../libexec/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/bin/
LIBRARY_PATH=/tools/lib/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/:/mnt/lfs/tools/bin/../lib/gcc/:/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/lib/
COLLECT_GCC_OPTIONS='-B' '/tools/lib' '-v' '-mtune=generic' '-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-lfs-linux-gnu/4.7.0/collect2 
--eh-frame-hdr -m elf_x86_64 -dynamic-linker 
/tools/lib64/ld-linux-x86-64.so.2 /tools/lib/crt1.o /tools/lib/crti.o 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/crtbegin.o 
-L/tools/lib -L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0 
-L/mnt/lfs/tools/bin/../lib/gcc 
-L/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/../../../../x86_64-lfs-linux-gnu/lib
 
/tmp/ccWwgVYh.o -lgcc -lc -lgcc 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-lfs-linux-gnu/4.7.0/crtend.o 
/tools/lib/crtn.o
-------------------------------
For testing, I installed all the development libraries of cloog and ppl 
on the host (Debian), and run the current SVN trunk build instructions 
until gcc-pass2, just removing --without-ppl --without-cloog. I built 
without problem. But now:
-----------------------
lfs@b07-cluster:~$ echo main'(){}' | x86_64-unknown-linux-gnu-gcc -v -xc -
Using built-in specs.
COLLECT_GCC=x86_64-unknown-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/mnt/lfs/tools/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.7.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with: ../gcc-4.7.0/configure --prefix=/tools 
--with-local-prefix=/tools --enable-clocale=gnu --enable-shared 
--enable-threads=posix --enable-__cxa_atexit --enable-languages=c,c++ 
--disable-libstdcxx-pch --disable-multilib --disable-bootstrap 
--disable-libgomp 
--with-mpfr-include=/mnt/lfs/sources/gcc-build/../gcc-4.7.0/mpfr/src 
--with-mpfr-lib=/mnt/lfs/sources/gcc-build/mpfr/src/.libs
Thread model: posix
gcc version 4.7.0 (GCC)
COLLECT_GCC_OPTIONS='-v' '-mtune=generic' '-march=x86-64'
  /mnt/lfs/tools/bin/../libexec/gcc/x86_64-unknown-linux-gnu/4.7.0/cc1 
-quiet -v -iprefix 
/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/ - -quiet 
-dumpbase - -mtune=generic -march=x86-64 -auxbase - -version -o 
/tmp/ccFk7MXR.s
GNU C (GCC) version 4.7.0 (x86_64-unknown-linux-gnu)
         compiled by GNU C version 4.7.0, GMP version 5.0.4, MPFR 
version 3.1.0, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../x86_64-unknown-linux-gnu/include"
ignoring duplicate directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/include"
ignoring duplicate directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/include-fixed"
ignoring nonexistent directory 
"/mnt/lfs/tools/bin/../lib/gcc/../../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../x86_64-unknown-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
  /mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/include
  /mnt/lfs/tools/bin/../lib/gcc/x86_64-unknown-linux-gnu/4.7.0/include-fixed
  /tools/include
  /usr/include
End of search list.
[snip]
------------------------------
/usr/include appears only after pass2.

Regards
Pierre

-- 
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to