bzip2-inst.xml 1.5 KB

1234567891011121314151617181920212223242526272829303132
  1. <sect2>
  2. <title>Installation of Bzip2</title>
  3. <para>Install Bzip2 by running the following commands:</para>
  4. <para><screen><userinput>make -f Makefile-libbz2_so &amp;&amp;</userinput>
  5. <userinput>make bzip2recover libbz2.a &amp;&amp;</userinput>
  6. <userinput>cp bzip2-shared /bin/bzip2 &amp;&amp;</userinput>
  7. <userinput>cp bzip2recover /bin &amp;&amp;</userinput>
  8. <userinput>cp bzip2.1 /usr/share/man/man1 &amp;&amp;</userinput>
  9. <userinput>cp bzlib.h /usr/include &amp;&amp;</userinput>
  10. <userinput>cp -a libbz2.so* libbz2.a /lib &amp;&amp;</userinput>
  11. <userinput>rm /usr/lib/libbz2.a &amp;&amp;</userinput>
  12. <userinput>cd /bin &amp;&amp;</userinput>
  13. <userinput>ln -sf bzip2 bunzip2 &amp;&amp;</userinput>
  14. <userinput>ln -sf bzip2 bzcat &amp;&amp;</userinput>
  15. <userinput>cd /usr/share/man/man1 &amp;&amp;</userinput>
  16. <userinput>ln -s bzip2.1 bunzip2.1 &amp;&amp;</userinput>
  17. <userinput>ln -s bzip2.1 bzcat.1 &amp;&amp;</userinput>
  18. <userinput>ln -s bzip2.1 bzip2recover.1</userinput></screen></para>
  19. <para>Although it's not strictly a part of a basic LFS system it's worth
  20. mentioning that a patch for Tar can be downloaded which enables the tar
  21. program to compress and uncompress using bzip2/bunzip2 easily. With a
  22. plain tar a user has to use constructions like bzcat file.tar.bz|tar
  23. xv or tar --use-compress-prog=bunzip2 -xvf file.tar.bz2 to use bzip2 and
  24. bunzip2 with tar. This patch gives the -y option so a user can unpack a
  25. Bzip2 archive with tar xvfy file.tar.bz2. Applying this patch will be
  26. mentioned later on when the Tar package is re-installed.</para>
  27. </sect2>