grep.xml 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. <?xml version="1.0" encoding="ISO-8859-1"?>
  2. <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
  3. <!ENTITY % general-entities SYSTEM "../general.ent">
  4. %general-entities;
  5. ]>
  6. <sect1 id="ch-system-grep" role="wrap">
  7. <title>Grep-&grep-version;</title>
  8. <?dbhtml filename="grep.html"?>
  9. <indexterm zone="ch-system-grep"><primary sortas="a-Grep">Grep</primary></indexterm>
  10. <sect2 role="package"><title/>
  11. <para>The Grep package contains programs for searching through files.</para>
  12. <segmentedlist>
  13. <segtitle>&buildtime;</segtitle>
  14. <segtitle>&diskspace;</segtitle>
  15. <seglistitem><seg>0.1 SBU</seg><seg>4.5 MB</seg></seglistitem>
  16. </segmentedlist>
  17. <segmentedlist>
  18. <segtitle>&dependencies;</segtitle>
  19. <seglistitem><seg>Bash, Binutils, Coreutils,
  20. Diffutils, GCC, Gettext, Glibc, Make, Sed, and Texinfo</seg></seglistitem>
  21. </segmentedlist>
  22. </sect2>
  23. <sect2 role="installation">
  24. <title>Installation of Grep</title>
  25. <para>The current Grep package has many bugs, especially in the support of
  26. multibyte locales. RedHat fixed some of them with the following patch:</para>
  27. <screen><userinput>patch -Np1 -i ../&grep-fixes-patch;</userinput></screen>
  28. <para>In order for the tests added by this patch to pass, the permissions for
  29. the test file have to be changed:</para>
  30. <screen><userinput>chmod +x tests/fmbtest.sh</userinput></screen>
  31. <para>Prepare Grep for compilation:</para>
  32. <screen><userinput>./configure --prefix=/usr --bindir=/bin</userinput></screen>
  33. <para>Compile the package:</para>
  34. <screen><userinput>make</userinput></screen>
  35. <para>To test the results, issue:
  36. <userinput>make check</userinput>.</para>
  37. <para>Install the package:</para>
  38. <screen><userinput>make install</userinput></screen>
  39. </sect2>
  40. <sect2 id="contents-grep" role="content"><title>Contents of Grep</title>
  41. <segmentedlist>
  42. <segtitle>Installed programs</segtitle>
  43. <seglistitem><seg>egrep (link to grep), fgrep (link to grep), and grep</seg></seglistitem>
  44. </segmentedlist>
  45. <variablelist><bridgehead renderas="sect3">Short Descriptions</bridgehead>
  46. <?dbfo list-presentation="list"?>
  47. <?dbhtml list-presentation="table"?>
  48. <varlistentry id="egrep">
  49. <term><command>egrep</command></term>
  50. <listitem>
  51. <para>Prints lines matching an extended regular expression</para>
  52. <indexterm zone="ch-system-grep egrep"><primary sortas="b-egrep">egrep</primary></indexterm>
  53. </listitem>
  54. </varlistentry>
  55. <varlistentry id="fgrep">
  56. <term><command>fgrep</command></term>
  57. <listitem>
  58. <para>Prints lines matching a list of fixed strings</para>
  59. <indexterm zone="ch-system-grep fgrep"><primary sortas="b-fgrep">fgrep</primary></indexterm>
  60. </listitem>
  61. </varlistentry>
  62. <varlistentry id="grep">
  63. <term><command>grep</command></term>
  64. <listitem>
  65. <para>Prints lines matching a basic regular expression</para>
  66. <indexterm zone="ch-system-grep grep"><primary sortas="b-grep">grep</primary></indexterm>
  67. </listitem>
  68. </varlistentry>
  69. </variablelist>
  70. </sect2>
  71. </sect1>