1 | <sect2><title> </title><para> </para></sect2>
|
---|
2 |
|
---|
3 | <sect2>
|
---|
4 | <title>Installation of Gawk</title>
|
---|
5 |
|
---|
6 | <para>Before installing the Gawk package you have to apply a patch,
|
---|
7 | which fixes the following issues:</para>
|
---|
8 |
|
---|
9 | <itemizedlist>
|
---|
10 | <listitem><para>Gawk's default location for libexecdir is <filename
|
---|
11 | class="directory">$prefix/libexecdir/awk</filename>. This location doesn't
|
---|
12 | comply with FHS (which never mentions a directory called
|
---|
13 | libexecdir).</para></listitem>
|
---|
14 |
|
---|
15 | <listitem><para>The patch allows us to pass
|
---|
16 | <emphasis>--libexecdir</emphasis> to the configure script (without gawk
|
---|
17 | tacking on /awk to the end), so that we can use a more appropriate location
|
---|
18 | for gawk's libexecdir (<filename class="directory">/usr/bin</filename> in
|
---|
19 | the book).</para></listitem>
|
---|
20 |
|
---|
21 | <listitem><para>The default data directory for gawk is <filename
|
---|
22 | class="directory">$prefix/share/awk</filename>. A package specific
|
---|
23 | directory should be named using the package and version (like gawk-3.1.1
|
---|
24 | instead of awk) because there may be more than one awk interpreter on a
|
---|
25 | system (and more than one version of gawk). The patch changes this to
|
---|
26 | <filename class="directory">$prefix/share/gawk-3.1.1</filename> to be more
|
---|
27 | correct.</para></listitem>
|
---|
28 |
|
---|
29 | <listitem><para>The patch ensures that this directory (<filename
|
---|
30 | class="directory">$prefix/share/gawk-3.1.1</filename>) is removed along
|
---|
31 | with its contents on a make uninstall.</para></listitem>
|
---|
32 | </itemizedlist>
|
---|
33 |
|
---|
34 | <para><screen><userinput>patch -Np1 -i ../gawk-&gawk-patch-version;.patch</userinput></screen></para>
|
---|
35 |
|
---|
36 | <para>Prepare Gawk to be compiled:</para>
|
---|
37 |
|
---|
38 | <para><screen><userinput>./configure --prefix=/usr --libexecdir=/usr/bin</userinput></screen></para>
|
---|
39 |
|
---|
40 | <para>Continue with compiling the package:</para>
|
---|
41 |
|
---|
42 | <para><screen><userinput>make</userinput></screen></para>
|
---|
43 |
|
---|
44 | <para>Finish installing the package:</para>
|
---|
45 |
|
---|
46 | <para><screen><userinput>make install</userinput></screen></para>
|
---|
47 |
|
---|
48 | <para><screen><userinput>rm /bin/awk</userinput></screen></para>
|
---|
49 |
|
---|
50 | </sect2>
|
---|
51 |
|
---|