bash-inst.xml 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <sect2>
  2. <title>Installation of Bash</title>
  3. <para>Before you attempt to install Bash, you have to check to make sure
  4. your distribution has the <filename>/usr/lib/libcurses.a</filename> and
  5. <filename>/usr/lib/libncurses.a</filename> files. If your host
  6. distribution is an LFS system, all files will be present if you followed
  7. the instructions of the book version you read exactly.</para>
  8. <para>If both of the files are missing, you have to install the ncurses
  9. development package. This package is often call something like
  10. <emphasis>ncurses-dev</emphasis>. If this package is already installed,
  11. or you just did it, check for the two files again. Often the
  12. <filename>libcurses.a</filename> file is (still) missing. If so, then
  13. create <filename>libcurses.a</filename> as a symlink by running the
  14. following commands:</para>
  15. <para><screen><userinput>cd /usr/lib &amp;&amp;</userinput>
  16. <userinput>ln -s libncurses.a libcurses.a</userinput></screen></para>
  17. <para>Now we can continue. Install Bash by running the following
  18. commands:</para>
  19. <para><screen><userinput>./configure --enable-static-link --prefix=$LFS/usr \</userinput>
  20. <userinput>&nbsp;&nbsp;&nbsp;--bindir=$LFS/bin --with-curses &amp;&amp;</userinput>
  21. <userinput>make &amp;&amp;</userinput>
  22. <userinput>make install &amp;&amp;</userinput>
  23. <userinput>cd $LFS/bin &amp;&amp;</userinput>
  24. <userinput>ln -sf bash sh</userinput></screen></para>
  25. <para>If the make install phase ends with something along the lines of</para>
  26. <blockquote><screen>install-info: unknown option `--dir-file=/mnt/lfs/usr/info/dir'
  27. usage: install-info [--version] [--help] [--debug] [--maxwidth=nnn]
  28. [--section regexp title] [--infodir=xxx] [--align=nnn]
  29. [--calign=nnn] [--quiet] [--menuentry=xxx]
  30. [--info-dir=xxx]
  31. [--keep-old] [--description=xxx] [--test]
  32. [--remove] [--] filename
  33. make[1]: *** [install] Error 1
  34. make[1]: Leaving directory `/mnt/lfs/usr/src/bash-&bash-version;/doc'
  35. make: [install] Error 2 (ignored)</screen></blockquote>
  36. <para>then that means that you are probably using Debian, and that you have an
  37. old version of the texinfo package. This error is not severe by any means: the
  38. info pages will be installed when we recompile bash dynamically in
  39. chapter 6, so you can ignore it. You do, however, have to run the last
  40. two commands manually (the <userinput>cd $LFS/bin</userinput> and
  41. <userinput>ln -sf bash sh</userinput> commands) because they won't be
  42. executed when the error occurs.</para>
  43. </sect2>