2002-03-09 02:54:58 +00:00
|
|
|
<sect2>
|
|
|
|
<title>Installation of Gawk</title>
|
|
|
|
|
2002-04-01 15:42:18 +01:00
|
|
|
<para>Warning: do NOT run <userinput>make uninstall</userinput> on this
|
|
|
|
package if you apply the <emphasis>sed</emphasis> fix to change the
|
|
|
|
<filename class="directory">libexec</filename> directory definition. The
|
|
|
|
<emphasis>uninstall</emphasis> rule in the <filename>Makefile</filename>
|
|
|
|
file runs a command like <userinput>rm -rf
|
|
|
|
<libexecdir>/*</userinput> Since we change the <filename
|
|
|
|
class="directory">libexec</filename> directory to <filename
|
|
|
|
class="directory">/usr/bin</filename> it'll run <userinput>rm -rf
|
|
|
|
/usr/bin/*</userinput></para>
|
|
|
|
|
2002-03-11 20:36:27 +00:00
|
|
|
<para>When installing Gawk using glibc-2.1.x on your base system,
|
|
|
|
it may be necessary to use a fix to prevent a variable name conflict. The
|
|
|
|
following commands can be used in this case. Note that these commands
|
|
|
|
can also be used for other glibc versions so if you aren't sure, then
|
|
|
|
use the first version.</para>
|
|
|
|
|
2002-03-17 17:08:01 +00:00
|
|
|
<para><screen><userinput>cp awklib/Makefile.in awklib/Makefile.in.backup &&
|
2002-03-16 22:48:08 +00:00
|
|
|
sed -e '/^datadir/s/awk/gawk/' \
|
2002-03-17 17:08:01 +00:00
|
|
|
-e '/^libexecdir/s%/awk%%' awklib/Makefile.in.backup \
|
|
|
|
> awklib/Makefile.in &&
|
2002-03-16 22:48:08 +00:00
|
|
|
export CPPFLAGS=-Dre_max_failures=re_max_failures2 &&
|
2002-03-16 23:28:17 +00:00
|
|
|
./configure --prefix=$LFS/usr --disable-nls \
|
2002-03-16 23:30:05 +00:00
|
|
|
--libexecdir=$LFS/usr/bin &&
|
2002-03-11 20:36:27 +00:00
|
|
|
unset CPPFLAGS &&
|
|
|
|
make LDFLAGS=-static &&
|
|
|
|
make install</userinput></screen></para>
|
|
|
|
|
|
|
|
<para>If you are using a newer glibc version (2.2.x), you can use the
|
|
|
|
following commands to install Gawk:</para>
|
2002-03-09 02:54:58 +00:00
|
|
|
|
2002-03-17 17:08:01 +00:00
|
|
|
<para><screen><userinput>cp awklib/Makefile.in awklib/Makefile.in.backup &&
|
2002-03-16 22:48:08 +00:00
|
|
|
sed -e '/^datadir/s/awk/gawk/' \
|
2002-03-17 17:08:01 +00:00
|
|
|
-e '/^libexecdir/s%/awk%%' awklib/Makefile.in.backup \
|
|
|
|
> awklib/Makefile.in &&
|
2002-03-16 23:28:17 +00:00
|
|
|
./configure --prefix=$LFS/usr --disable-nls \
|
2002-03-16 23:30:05 +00:00
|
|
|
--libexecdir=$LFS/usr/bin &&
|
2002-03-09 02:54:58 +00:00
|
|
|
make LDFLAGS=-static &&
|
|
|
|
make install</userinput></screen></para>
|
|
|
|
|
|
|
|
</sect2>
|
|
|
|
|