shellutils-inst.xml 996 B

123456789101112131415161718192021222324252627282930
  1. <sect2>
  2. <title>Installation of Sh-utils</title>
  3. <para>Install Shellutils by running the following commands:</para>
  4. <para><screen><userinput>./configure --prefix=/usr &amp;&amp;
  5. make &amp;&amp;
  6. make install &amp;&amp;
  7. cd /usr/bin &amp;&amp;
  8. mv basename date echo false hostname /bin &amp;&amp;
  9. mv pwd sleep stty su test true uname /bin &amp;&amp;
  10. mv chroot ../sbin</userinput></screen></para>
  11. </sect2>
  12. <sect2>
  13. <title>FHS compliance notes</title>
  14. <para>There is a command installed in this package which is named test. It is
  15. often used in shell scripts to evaluate conditions, but is more often
  16. encountered in the form of <command>[ condition ]</command>. These brackets
  17. are built into the bash interpreter, but the FHS dictates that there should be a
  18. <filename>[</filename> binary. We create that in this way, while still in the
  19. <filename class="directory">/bin</filename> directory:</para>
  20. <para><screen><userinput>cd /bin &amp;&amp;
  21. ln -sf test [</userinput></screen></para>
  22. </sect2>