bzip2.xml 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
  3. <!ENTITY % general-entities SYSTEM "../general.ent">
  4. %general-entities;
  5. ]>
  6. <sect1 id="ch-system-bzip2" role="wrap">
  7. <title>Bzip2-&bzip2-version;</title>
  8. <?dbhtml filename="bzip2.html"?>
  9. <indexterm zone="ch-system-bzip2"><primary sortas="a-Bzip2">Bzip2</primary></indexterm>
  10. <sect2 role="package"><title/>
  11. <para>The Bzip2 package contains programs for compressing and decompressing
  12. files. Compressing text files with <command>bzip2</command> yields a much better
  13. compression percentage than with the traditional <command>gzip</command>.</para>
  14. <segmentedlist>
  15. <segtitle>&buildtime;</segtitle>
  16. <segtitle>&diskspace;</segtitle>
  17. <seglistitem><seg>0.1 SBU</seg><seg>3.9 MB</seg></seglistitem>
  18. </segmentedlist>
  19. <segmentedlist>
  20. <segtitle>&dependencies;</segtitle>
  21. <seglistitem><seg>Bash, Binutils, Coreutils, Diffutils,
  22. GCC, Glibc, and Make</seg></seglistitem>
  23. </segmentedlist>
  24. </sect2>
  25. <sect2 role="installation">
  26. <title>Installation of Bzip2</title>
  27. <para>Apply a patch to install the documentation for this package:</para>
  28. <screen><userinput>patch -Np1 -i ../&bzip2-docs-patch;</userinput></screen>
  29. <para>The <command>bzgrep</command> command does not escape '|' and '&amp;' in
  30. filenames passed to it. This allows arbitrary commands to be executed with the
  31. privileges of the user running <command>bzgrep</command>. Apply the following to
  32. address this:</para>
  33. <screen><userinput>patch -Np1 -i ../&bzip2-bzgrep-patch;</userinput></screen>
  34. <para>Prepare Bzip2 for compilation with:</para>
  35. <screen><userinput>make -f Makefile-libbz2_so
  36. make clean</userinput></screen>
  37. <para>The <parameter>-f</parameter> flag will cause Bzip2 to be built
  38. using a different <filename>Makefile</filename> file, in this case the
  39. <filename>Makefile-libbz2_so</filename> file, which creates a dynamic
  40. <filename class="libraryfile">libbz2.so</filename> library and links the Bzip2
  41. utilities against it.</para>
  42. <para>Compile and test the package:</para>
  43. <screen><userinput>make</userinput></screen>
  44. <para>If reinstalling Bzip2, perform
  45. <userinput>rm -vf /usr/bin/bz*</userinput> first, otherwise the following
  46. <command>make install</command> will fail.</para>
  47. <para>Install the programs:</para>
  48. <screen><userinput>make install</userinput></screen>
  49. <para>Install the shared <command>bzip2</command> binary into the
  50. <filename class="directory">/bin</filename> directory, make
  51. some necessary symbolic links, and clean up:</para>
  52. <screen><userinput>cp -v bzip2-shared /bin/bzip2
  53. cp -av libbz2.so* /lib
  54. ln -sv ../../lib/libbz2.so.1.0 /usr/lib/libbz2.so
  55. rm -v /usr/bin/{bunzip2,bzcat,bzip2}
  56. ln -sv bzip2 /bin/bunzip2
  57. ln -sv bzip2 /bin/bzcat</userinput></screen>
  58. <beginpage/>
  59. </sect2>
  60. <sect2 id="contents-bzip2" role="content"><title>Contents of Bzip2</title>
  61. <segmentedlist>
  62. <segtitle>Installed programs</segtitle>
  63. <segtitle>Installed libraries</segtitle>
  64. <seglistitem><seg>bunzip2 (link to bzip2), bzcat (link to bzip2), bzcmp, bzdiff,
  65. bzegrep, bzfgrep, bzgrep, bzip2, bzip2recover, bzless, and bzmore</seg>
  66. <seg>libbz2.[a,so]</seg></seglistitem>
  67. </segmentedlist>
  68. <variablelist><bridgehead renderas="sect3">Short Descriptions</bridgehead>
  69. <?dbfo list-presentation="list"?>
  70. <?dbhtml list-presentation="table"?>
  71. <varlistentry id="bunzip2">
  72. <term><command>bunzip2</command></term>
  73. <listitem>
  74. <para>Decompresses bzipped files</para>
  75. <indexterm zone="ch-system-bzip2 bunzip2"><primary sortas="b-bunzip2">bunzip2</primary></indexterm>
  76. </listitem>
  77. </varlistentry>
  78. <varlistentry id="bzcat">
  79. <term><command>bzcat</command></term>
  80. <listitem>
  81. <para>Decompresses to standard output</para>
  82. <indexterm zone="ch-system-bzip2 bzcat"><primary sortas="b-bzcat">bzcat</primary></indexterm>
  83. </listitem>
  84. </varlistentry>
  85. <varlistentry id="bzcmp">
  86. <term><command>bzcmp</command></term>
  87. <listitem>
  88. <para>Runs <command>cmp</command> on bzipped files</para>
  89. <indexterm zone="ch-system-bzip2 bzcmp"><primary sortas="b-bzcmp">bzcmp</primary></indexterm>
  90. </listitem>
  91. </varlistentry>
  92. <varlistentry id="bzdiff">
  93. <term><command>bzdiff</command></term>
  94. <listitem>
  95. <para>Runs <command>diff</command> on bzipped files</para>
  96. <indexterm zone="ch-system-bzip2 bzdiff"><primary sortas="b-bzdiff">bzdiff</primary></indexterm>
  97. </listitem>
  98. </varlistentry>
  99. <varlistentry id="bzgrep">
  100. <term><command>bzgrep</command></term>
  101. <listitem>
  102. <para>Runs <command>grep</command> on bzipped files</para>
  103. <indexterm zone="ch-system-bzip2 bzgrep"><primary sortas="b-bzgrep">bzgrep</primary></indexterm>
  104. </listitem>
  105. </varlistentry>
  106. <varlistentry id="bzegrep">
  107. <term><command>bzegrep</command></term>
  108. <listitem>
  109. <para>Runs <command>egrep</command> on bzipped files</para>
  110. <indexterm zone="ch-system-bzip2 bzegrep"><primary sortas="b-bzegrep">bzegrep</primary></indexterm>
  111. </listitem>
  112. </varlistentry>
  113. <varlistentry id="bzfgrep">
  114. <term><command>bzfgrep</command></term>
  115. <listitem>
  116. <para>Runs <command>fgrep</command> on bzipped files</para>
  117. <indexterm zone="ch-system-bzip2 bzfgrep"><primary sortas="b-bzfgrep">bzfgrep</primary></indexterm>
  118. </listitem>
  119. </varlistentry>
  120. <varlistentry id="bzip2">
  121. <term><command>bzip2</command></term>
  122. <listitem>
  123. <para>Compresses files using the Burrows-Wheeler block sorting text
  124. compression algorithm with Huffman coding; the compression rate is
  125. better than that achieved by more conventional compressors using
  126. <quote>Lempel-Ziv</quote> algorithms, like <command>gzip</command></para>
  127. <indexterm zone="ch-system-bzip2 bzip2"><primary sortas="b-bzip2">bzip2</primary></indexterm>
  128. </listitem>
  129. </varlistentry>
  130. <varlistentry id="bzip2recover">
  131. <term><command>bzip2recover</command></term>
  132. <listitem>
  133. <para>Tries to recover data from damaged bzipped files</para>
  134. <indexterm zone="ch-system-bzip2 bzip2recover"><primary sortas="b-bzip2recover">bzip2recover</primary></indexterm>
  135. </listitem>
  136. </varlistentry>
  137. <varlistentry id="bzless">
  138. <term><command>bzless</command></term>
  139. <listitem>
  140. <para>Runs <command>less</command> on bzipped files</para>
  141. <indexterm zone="ch-system-bzip2 bzless"><primary sortas="b-bzless">bzless</primary></indexterm>
  142. </listitem>
  143. </varlistentry>
  144. <varlistentry id="bzmore">
  145. <term><command>bzmore</command></term>
  146. <listitem>
  147. <para>Runs <command>more</command> on bzipped files</para>
  148. <indexterm zone="ch-system-bzip2 bzmore"><primary sortas="b-bzmore">bzmore</primary></indexterm>
  149. </listitem>
  150. </varlistentry>
  151. <varlistentry id="libbz2">
  152. <term><filename class="libraryfile">libbz2*</filename></term>
  153. <listitem>
  154. <para>The library implementing lossless, block-sorting data
  155. compression, using the Burrows-Wheeler algorithm</para>
  156. <indexterm zone="ch-system-bzip2 libbz2"><primary sortas="c-libbz2*">libbz2*</primary></indexterm>
  157. </listitem>
  158. </varlistentry>
  159. </variablelist>
  160. </sect2>
  161. </sect1>