diff options
Diffstat (limited to 'chapter06/bzip2.xml')
-rw-r--r-- | chapter06/bzip2.xml | 202 |
1 files changed, 32 insertions, 170 deletions
diff --git a/chapter06/bzip2.xml b/chapter06/bzip2.xml index edf2f5bd4..828b7fc0f 100644 --- a/chapter06/bzip2.xml +++ b/chapter06/bzip2.xml @@ -5,7 +5,7 @@ %general-entities; ]> -<sect1 id="ch-system-bzip2" role="wrap"> +<sect1 id="ch-tools-bzip2" role="wrap"> <?dbhtml filename="bzip2.html"?> <sect1info condition="script"> @@ -16,25 +16,25 @@ <title>Bzip2-&bzip2-version;</title> - <indexterm zone="ch-system-bzip2"> + <indexterm zone="ch-tools-bzip2"> <primary sortas="a-Bzip2">Bzip2</primary> + <secondary>tools</secondary> </indexterm> <sect2 role="package"> <title/> - <para>The Bzip2 package contains programs for compressing and decompressing - files. Compressing text files with <command>bzip2</command> yields a much - better compression percentage than with the traditional - <command>gzip</command>.</para> + <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" + href="../chapter06/bzip2.xml" + xpointer="xpointer(/sect1/sect2[1]/para[1])"/> <segmentedlist> <segtitle>&buildtime;</segtitle> <segtitle>&diskspace;</segtitle> <seglistitem> - <seg>&bzip2-ch6-sbu;</seg> - <seg>&bzip2-ch6-du;</seg> + <seg>&bzip2-ch5-sbu;</seg> + <seg>&bzip2-ch5-du;</seg> </seglistitem> </segmentedlist> @@ -43,11 +43,13 @@ <sect2 role="installation"> <title>Installation of Bzip2</title> - <para>Apply a patch that will install the documentation for this package:</para> + <para>Apply a patch that will install the documentation for this + package:</para> <screen><userinput remap="pre">patch -Np1 -i ../&bzip2-docs-patch;</userinput></screen> - <para>The following command ensures installation of symbolic links are relative:</para> + <para>The following command ensures installation of symbolic links are + relative:</para> <screen><userinput remap="pre">sed -i 's@\(ln -s -f \)$(PREFIX)/bin/@\1@' Makefile</userinput></screen> @@ -55,9 +57,12 @@ <screen><userinput remap="pre">sed -i "s@(PREFIX)/man@(PREFIX)/share/man@g" Makefile</userinput></screen> - <para>Prepare Bzip2 for compilation with:</para> + <para>The Bzip2 package does not contain a <command>configure</command> + script. There are two <filename>Makefile</filename>, one for the shared + library, and the other for the static library. Since we need both, We + do the compilation in two stages. First the shared library:</para> -<screen><userinput remap="make">make -f Makefile-libbz2_so +<screen><userinput remap="make">make CC=$LFS_TGT-gcc -f Makefile-libbz2_so make clean</userinput></screen> <variablelist> @@ -76,174 +81,31 @@ make clean</userinput></screen> </variablelist> - <para>Compile and test the package:</para> + <para>Compile and test the package with:</para> -<screen><userinput remap="make">make</userinput></screen> +<screen><userinput remap="make">make CC=$LFS_TGT-gcc AR=$LFS_TGT-ar RANLIB=$LFS_TGT-ranlib</userinput></screen> - <para>Install the programs:</para> + <para>Install the package:</para> -<screen><userinput remap="install">make PREFIX=/usr install</userinput></screen> +<screen><userinput remap="install">make PREFIX=$LFS/usr install</userinput></screen> <para>Install the shared <command>bzip2</command> binary into the - <filename class="directory">/bin</filename> directory, make - some necessary symbolic links, and clean up:</para> + <filename class="directory">/bin</filename> directory, make some necessary + symbolic links, and clean up:</para> -<screen><userinput remap="install">cp -v bzip2-shared /bin/bzip2 -cp -av libbz2.so* /lib +<screen><userinput remap="install">cp -v bzip2-shared $LFS/bin/bzip2 +cp -av libbz2.so* $LFS/lib ln -sv ../../lib/libbz2.so.1.0 $LFS/usr/lib/libbz2.so -rm -v /usr/bin/{bunzip2,bzcat,bzip2} -ln -sv bzip2 /bin/bunzip2 -ln -sv bzip2 /bin/bzcat</userinput></screen> +rm -v $LFS/usr/bin/{bunzip2,bzcat,bzip2} +ln -sv bzip2 $LFS/bin/bunzip2 +ln -sv bzip2 $LFS/bin/bzcat</userinput></screen> </sect2> - <sect2 id="contents-bzip2" role="content"> - <title>Contents of Bzip2</title> - - <segmentedlist> - <segtitle>Installed programs</segtitle> - <segtitle>Installed libraries</segtitle> - <segtitle>Installed directory</segtitle> - - <seglistitem> - <seg>bunzip2 (link to bzip2), bzcat (link to bzip2), bzcmp (link to - bzdiff), bzdiff, bzegrep (link to bzgrep), bzfgrep (link to bzgrep), - bzgrep, bzip2, bzip2recover, bzless (link to bzmore), and bzmore</seg> - <seg>libbz2.{a,so}</seg> - <seg>/usr/share/doc/bzip2-&bzip2-version;</seg> - </seglistitem> - </segmentedlist> - - <variablelist> - <bridgehead renderas="sect3">Short Descriptions</bridgehead> - <?dbfo list-presentation="list"?> - <?dbhtml list-presentation="table"?> - - <varlistentry id="bunzip2"> - <term><command>bunzip2</command></term> - <listitem> - <para>Decompresses bzipped files</para> - <indexterm zone="ch-system-bzip2 bunzip2"> - <primary sortas="b-bunzip2">bunzip2</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzcat"> - <term><command>bzcat</command></term> - <listitem> - <para>Decompresses to standard output</para> - <indexterm zone="ch-system-bzip2 bzcat"> - <primary sortas="b-bzcat">bzcat</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzcmp"> - <term><command>bzcmp</command></term> - <listitem> - <para>Runs <command>cmp</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzcmp"> - <primary sortas="b-bzcmp">bzcmp</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzdiff"> - <term><command>bzdiff</command></term> - <listitem> - <para>Runs <command>diff</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzdiff"> - <primary sortas="b-bzdiff">bzdiff</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzegrep"> - <term><command>bzegrep</command></term> - <listitem> - <para>Runs <command>egrep</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzegrep"> - <primary sortas="b-bzegrep">bzegrep</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzfgrep"> - <term><command>bzfgrep</command></term> - <listitem> - <para>Runs <command>fgrep</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzfgrep"> - <primary sortas="b-bzfgrep">bzfgrep</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzgrep"> - <term><command>bzgrep</command></term> - <listitem> - <para>Runs <command>grep</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzgrep"> - <primary sortas="b-bzgrep">bzgrep</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzip2"> - <term><command>bzip2</command></term> - <listitem> - <para>Compresses files using the Burrows-Wheeler block sorting text - compression algorithm with Huffman coding; the compression rate is - better than that achieved by more conventional compressors using - <quote>Lempel-Ziv</quote> algorithms, like <command>gzip</command></para> - <indexterm zone="ch-system-bzip2 bzip2"> - <primary sortas="b-bzip2">bzip2</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzip2recover"> - <term><command>bzip2recover</command></term> - <listitem> - <para>Tries to recover data from damaged bzipped files</para> - <indexterm zone="ch-system-bzip2 bzip2recover"> - <primary sortas="b-bzip2recover">bzip2recover</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzless"> - <term><command>bzless</command></term> - <listitem> - <para>Runs <command>less</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzless"> - <primary sortas="b-bzless">bzless</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="bzmore"> - <term><command>bzmore</command></term> - <listitem> - <para>Runs <command>more</command> on bzipped files</para> - <indexterm zone="ch-system-bzip2 bzmore"> - <primary sortas="b-bzmore">bzmore</primary> - </indexterm> - </listitem> - </varlistentry> - - <varlistentry id="libbz2"> - <term><filename class="libraryfile">libbz2</filename></term> - <listitem> - <para>The library implementing lossless, block-sorting data - compression, using the Burrows-Wheeler algorithm</para> - <indexterm zone="ch-system-bzip2 libbz2"> - <primary sortas="c-libbz2">libbz2</primary> - </indexterm> - </listitem> - </varlistentry> - - </variablelist> + <sect2 role="content"> + <title/> + <para>Details on this package are located in + <xref linkend="contents-bzip2" role="."/></para> </sect2> |