[6370fa6] | 1 | <sect2>
|
---|
| 2 | <title>Command explanations</title>
|
---|
| 3 |
|
---|
[f065b089] | 4 | <para><userinput>patch -Np1 -i ../gcc-&gcc-patch-version;.patch:</userinput>
|
---|
[1fda654] | 5 | This new patch deals with incorrect handling of weak symbols, the
|
---|
| 6 | over-optimization of calls to those weak symbols, an atexit issue and
|
---|
| 7 | the __dso_handle symbol required for atexit's proper function.</para>
|
---|
[a0994c1] | 8 |
|
---|
[f065b089] | 9 | <para><userinput>make BOOT_LDFLAGS=-static:</userinput>
|
---|
| 10 | This is the equivalent to make LDFLAGS=-static as we use with other
|
---|
| 11 | packages to compile them statically.</para>
|
---|
| 12 |
|
---|
[f03a32d4] | 13 | <para><userinput>--prefix=/usr:</userinput> This is NOT a typo. GCC hard
|
---|
[f36a666] | 14 | codes some paths while compiling and so we need to pass /usr as the
|
---|
| 15 | prefix during ./configure. We pass the real install prefix during the
|
---|
| 16 | make install command later.</para>
|
---|
| 17 |
|
---|
[b822811] | 18 | <para><userinput>--enable-languages=c,c++:</userinput> This only builds the C
|
---|
[6370fa6] | 19 | and C++ compilers and not the other available compilers as they are, on
|
---|
[13dd793] | 20 | the average, not often used. If those other compilers are needed,
|
---|
[b822811] | 21 | the --enable-languages parameter can be omitted.</para>
|
---|
[6370fa6] | 22 |
|
---|
[c90f09c] | 23 | <para><userinput>--enable-threads=posix:</userinput> This enables C++
|
---|
| 24 | exception handling for multithreaded code.</para>
|
---|
| 25 |
|
---|
[45714a7] | 26 | <para><userinput>ln -sf ../usr/bin/cpp:</userinput> This
|
---|
[2f86e05] | 27 | creates the $LFS/lib/cpp symlink. Some packages explicitly try to find
|
---|
[b822811] | 28 | cpp in /lib.</para>
|
---|
[6370fa6] | 29 |
|
---|
[45714a7] | 30 | <para><userinput>ln -sf ../bin/cpp:</userinput> This
|
---|
[6370fa6] | 31 | creates the $LFS/usr/lib/cpp symlink as there are packages that expect
|
---|
[b822811] | 32 | cpp to be in /usr/lib.</para>
|
---|
[6370fa6] | 33 |
|
---|
[5fb9eb8] | 34 | <para><userinput>rmdir $LFS/usr/*-gnu/include</userinput> and
|
---|
| 35 | <userinput>rmdir $LFS/usr/*-gnu</userinput>: These directories are created
|
---|
| 36 | as empty directories by GCC and serve absolutely no purpose whatsoever.
|
---|
| 37 | It's related to cross-compilers but that doesn't apply to us and it's
|
---|
| 38 | considered a bug in GCC that you can't turn that off, especially since they
|
---|
| 39 | end up being empty directories. So we remove them manually.</para>
|
---|
[6370fa6] | 40 | </sect2>
|
---|
| 41 |
|
---|