bzip2-inst.xml 1.6 KB

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