- Timestamp:
- 10/04/2005 07:56:35 PM (19 years ago)
- Branches:
- 10.0, 10.0-rc1, 10.1, 10.1-rc1, 11.0, 11.0-rc1, 11.0-rc2, 11.0-rc3, 11.1, 11.1-rc1, 11.2, 11.2-rc1, 11.3, 11.3-rc1, 12.0, 12.0-rc1, 12.1, 12.1-rc1, 6.3, 6.4, 6.5, 6.6, 6.7, 6.8, 7.0, 7.1, 7.2, 7.3, 7.4, 7.5, 7.5-systemd, 7.6, 7.6-systemd, 7.7, 7.7-systemd, 7.8, 7.8-systemd, 7.9, 7.9-systemd, 8.0, 8.1, 8.2, 8.3, 8.4, 9.0, 9.1, arm, bdubbs/gcc13, ml-11.0, multilib, renodr/libudev-from-systemd, s6-init, trunk, xry111/arm64, xry111/arm64-12.0, xry111/clfs-ng, xry111/lfs-next, xry111/loongarch, xry111/loongarch-12.0, xry111/loongarch-12.1, xry111/mips64el, xry111/pip3, xry111/rust-wip-20221008, xry111/update-glibc
- Children:
- 795f15c
- Parents:
- cad7b50
- Location:
- chapter05
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
chapter05/adjusting.xml
rcad7b50 r27ced84 62 62 necessary.</para></important> 63 63 64 <para>There is a possibility that some header files from the host system have 65 found their way into GCC's private include dir. This can happen as a result of 66 GCC's <quote>fixincludes</quote> process, which runs as part of the GCC build. 67 This is explained in more detail later in this chapter. Run the following commands to remove those header files (you may find it easier to copy and paste these commands, rather than typing them by hand, due to their length):</para> 64 <para>During the build process, GCC runs a script 65 (<command>fixincludes</command>) that scans the system for header files that may 66 need to be fixed (they might contain syntax errors, for example), and installs 67 the fixed versions in a private include directory. There is a possibility that, 68 as a result of this process, some header files from the host system have found 69 their way into GCC's private include dir. As the rest of this chapter only 70 requires the headers from GCC and Glibc, which have both been installed at this 71 point, any "fixed" headers can safely be removed. This helps to avoid 72 any host headers polluting the build environment. Run the following commands to 73 remove the header files in GCC's private include directory (you may find it 74 easier to copy and paste these commands, rather than typing them by hand, due to 75 their length):</para> 68 76 69 77 <!-- && used to ease copy and pasting --> -
chapter05/gcc-pass2.xml
rcad7b50 r27ced84 59 59 working.</para> 60 60 61 <para>Under normal circumstances, the GCC <command>fixincludes</command> script 62 scans the system for header files that need to be fixed (they may contain syntax 63 errors, for example). The script might find that some Glibc header files on the 64 host system need to be fixed, so fixes them and puts them in the GCC private 65 include directory. In <xref linkend="chapter-building-system"/>, after the 66 newer Glibc has been installed, this private include directory will be searched 67 before the system include directory. This may result in GCC finding the fixed 68 headers from the host system, which most likely will not match the Glibc version 69 used for the LFS system.</para> 70 71 <para>The following command adjusts where the GCC <command>fixincludes</command> 72 script searches for headers, so that it fixes only the new headers under 73 <filename class="directory">/tools</filename>, not the ones from your host 74 system.</para> 61 <para>As previously explained in <xref linkend="ch-tools-adjusting"/>, under 62 normal circumstances the GCC <command>fixincludes</command> script is run in 63 order to fix potentially broken header files. As GCC-&gcc-version; and 64 Glibc-&glibc-version; have already been installed at this point, and their 65 respective header files are known not to require fixing, the 66 <command>fixincludes</command> script is not required. As mentioned previously, 67 the script may in fact pollute the build environment by installing fixed headers 68 from the host system into GCC's private include directory. The running of the 69 <command>fixincludes</command> script can be suppressed by issuing the following 70 commands:</para> 75 71 76 72 <screen><userinput>cp -v gcc/Makefile.in{,.orig} && 77 sed 's@\(^NATIVE_SYSTEM_HEADER_DIR =\).*@\1 /tools/include@g' \ 78 gcc/Makefile.in.orig > gcc/Makefile.in</userinput></screen> 73 sed 's@\./fixinc\.sh@-c true@' gcc/Makefile.in.orig > gcc/Makefile.in</userinput></screen> 79 74 80 75 <para>The bootstrap build performed in <xref linkend="ch-tools-gcc-pass1"/>
Note:
See TracChangeset
for help on using the changeset viewer.