shellutils-inst.xml 992 B

12345678910111213141516171819202122232425262728
  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. mv /usr/bin/{basename,date,echo,false,hostname} /bin &amp;&amp;
  8. mv /usr/bin/{pwd,sleep,stty,su,test,true,uname} /bin &amp;&amp;
  9. mv /usr/bin/chroot /usr/sbin</userinput></screen></para>
  10. </sect2>
  11. <sect2>
  12. <title>FHS compliance notes</title>
  13. <para>There is a command installed in this package which is named test. It is
  14. often used in shell scripts to evaluate conditions, but is more often
  15. encountered in the form of <command>[ condition ]</command>. These brackets
  16. are built into the bash interpreter, but the FHS dictates that there should be a
  17. <filename>[</filename> binary. We create that in this way, while still in the
  18. <filename class="directory">/bin</filename> directory:</para>
  19. <para><screen><userinput>ln -sf test /bin/[</userinput></screen></para>
  20. </sect2>