1 | <sect2>
|
---|
2 | <title>Installation of Fileutils</title>
|
---|
3 |
|
---|
4 | <para>The programs from a statically linked fileutils package may cause
|
---|
5 | segmentation faults on certain systems, if your distribution has
|
---|
6 | Glibc-2.2.3 or higher installed. It also seems to happen mostly on machines
|
---|
7 | powered by an AMD CPU, but there is a case or two where an Intel system
|
---|
8 | is affected as well. If your system falls under this category, try the
|
---|
9 | following fix.</para>
|
---|
10 |
|
---|
11 | <para>Note that in some cases using these sed commands will result in
|
---|
12 | problems not being able to compile this package at all, even when your
|
---|
13 | system has an AMD CPU and has Glibc-2.2.3 (or higher) installed. If that's
|
---|
14 | the case, you'll need to remove the fileutils-&fileutils-version; directory
|
---|
15 | and unpack it again from the tarball before continuing. We believe this
|
---|
16 | may be the case when your distribution has altered Glibc-2.2.3 somehow,
|
---|
17 | but details are unavailable at the time.</para>
|
---|
18 |
|
---|
19 | <para>To fix this package to compile properly on AMD/Glibc-2.2.3
|
---|
20 | machines, run the following commands. Do <emphasis>not</emphasis>
|
---|
21 | attempt this fix if you don't have Glibc-2.2.3 installed. It will more
|
---|
22 | than likely result in all kinds of compile time problems.</para>
|
---|
23 |
|
---|
24 | <para><screen><userinput>cp lib/Makefile.in lib/Makefile.in.backup &&</userinput>
|
---|
25 | <userinput>sed -e 's/\(.*\)\(fopen-safer\.c \)\\/\1\2atexit.c \\/' \</userinput>
|
---|
26 | <userinput> -e 's/\(.*\)\(idcache\$U\.\$.*\)\\/\1\2atexit$U.$(OBJEXT) \\/' \</userinput>
|
---|
27 | <userinput> lib/Makefile.in > lib/Makefile.in~ &&</userinput>
|
---|
28 | <userinput>mv lib/Makefile.in~ lib/Makefile.in</userinput></screen></para>
|
---|
29 |
|
---|
30 | <para>Install fileutils by running the following commands:
|
---|
31 | <screen><userinput>./configure --disable-nls \</userinput>
|
---|
32 | <userinput> --prefix=$LFS/usr --libexecdir=$LFS/bin --bindir=$LFS/bin &&</userinput>
|
---|
33 | <userinput>make LDFLAGS=-static &&</userinput>
|
---|
34 | <userinput>make install &&</userinput>
|
---|
35 | <userinput>cd $LFS/usr/bin &&</userinput>
|
---|
36 | <userinput>ln -sf ../../bin/install</userinput></screen></para>
|
---|
37 |
|
---|
38 | <para>Once you have installed fileutils, you can test whether the
|
---|
39 | segmentation fault problem has been avoided by running
|
---|
40 | <userinput>$LFS/bin/ls</userinput>. If this works, then you are OK. If
|
---|
41 | not, then you need to re-do the installation using the sed commands if
|
---|
42 | you didn't use them, or without the sed commands if you did use
|
---|
43 | them.</para>
|
---|
44 |
|
---|
45 | </sect2>
|
---|
46 |
|
---|