Le 22/04/2012 22:09, Jeremy Huntwork a écrit :
> On 4/22/12 3:48 PM, Pierre Labastie wrote:
>> I think the sysroot method can be simplified if using the switch above:
>> you do not even need the part:
>>
>> cp gcc/Makefile.in{,.orig}
>> sed '/^CROSS_SYSTEM_HEADER_DIR/s@= .*@= /tools/include@' \
>>        gcc/Makefile.in.orig>    gcc/Makefile.in
>> cp gcc/cppdefault.c{,.orig}
>> sed '/#define STANDARD_INCLUDE_DIR/s@"/usr/include"@0@g' \
>>        gcc/cppdefault.c.orig>    gcc/cppdefault.c
>>
>> ----------------------------------------
>> Suppressing that and adding the switch (to both gcc passes) to the
>> sysroot method,
>> I have been able to build and test that there is no differences in the
>> resulting system
>> with the SVN build (with switch).
> Nice, it looks like you're right. This is in the gcc/configure script:
>
> CROSS_SYSTEM_HEADER_DIR='$(TARGET_SYSTEM_ROOT)$${sysroot_headers_suffix}$(NATIVE_SYSTEM_HEADER_DIR)'
>
> So CROSS_SYSTEM_HEADER_DIR should get set correctly if we've already
> specified NATIVE_SYSTEM_HEADER_DIR, which is what gets set via your switch.
>
> I'll just fix up the jh branch source and give another run and compare
> results.
>
> JH
Also the doc says:
`--with-native-system-header-dir=DIRNAME'
      Specifies that DIRNAME is the directory that contains native system
      header files, rather than `/usr/include'.  This option is most
      useful if you are creating a compiler that should be isolated from
      the system as much as possible.  It is most commonly used with the
      `--with-sysroot' option and will cause GCC to search DIRNAME
      inside the system root specified by that option.
-------------------------
so it is adapted to your sysroot method...

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