[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[1770019] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[673b0d8] | 3 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 4 | %general-entities;
|
---|
| 5 | ]>
|
---|
[81fd230] | 6 | <sect1 id="ch-system-findutils" role="wrap">
|
---|
[673b0d8] | 7 | <title>Findutils-&findutils-version;</title>
|
---|
| 8 | <?dbhtml filename="findutils.html"?>
|
---|
[6370fa6] | 9 |
|
---|
[673b0d8] | 10 | <indexterm zone="ch-system-findutils"><primary sortas="a-Findutils">Findutils</primary></indexterm>
|
---|
[5888299] | 11 |
|
---|
[a001133] | 12 | <sect2 role="package"><title/>
|
---|
[acfd414] | 13 | <para>The Findutils package contains programs to find files. These programs
|
---|
[81fd230] | 14 | are provided to recursively search through a directory tree and to
|
---|
| 15 | create, maintain, and search a database (often faster than the recursive
|
---|
| 16 | find, but unreliable if the database has not been recently updated).</para>
|
---|
[673b0d8] | 17 |
|
---|
[a001133] | 18 | <segmentedlist>
|
---|
| 19 | <segtitle>&buildtime;</segtitle>
|
---|
| 20 | <segtitle>&diskspace;</segtitle>
|
---|
[92f4dc7] | 21 | <seglistitem><seg>0.1 SBU</seg><seg>9.4 MB</seg></seglistitem>
|
---|
[a001133] | 22 | </segmentedlist>
|
---|
[673b0d8] | 23 |
|
---|
[81fd230] | 24 | <segmentedlist>
|
---|
[45992ae] | 25 | <segtitle>&dependencies;</segtitle>
|
---|
[81fd230] | 26 | <seglistitem><seg>Bash, Binutils, Coreutils,
|
---|
| 27 | Diffutils, GCC, Gettext, Glibc, Grep, Make and Sed</seg></seglistitem>
|
---|
| 28 | </segmentedlist>
|
---|
[a001133] | 29 | </sect2>
|
---|
[3554fa3a] | 30 |
|
---|
[a001133] | 31 | <sect2 role="installation">
|
---|
[f4993cf] | 32 | <title>Installation of Findutils</title>
|
---|
[73aedd1d] | 33 |
|
---|
| 34 | <para>Prepare Findutils for compilation:</para>
|
---|
| 35 |
|
---|
[f684ec6c] | 36 | <screen><userinput>./configure --prefix=/usr --libexecdir=/usr/lib/findutils \
|
---|
[9dfc02f] | 37 | --localstatedir=/var/lib/locate</userinput></screen>
|
---|
[73aedd1d] | 38 |
|
---|
[06948c1] | 39 | <para>The meaning of the configure options:</para>
|
---|
| 40 |
|
---|
| 41 | <variablelist>
|
---|
| 42 | <varlistentry>
|
---|
| 43 | <term><parameter>--localstatedir</parameter></term>
|
---|
| 44 | <listitem><para>This option changes the location of the <command>locate</command>
|
---|
| 45 | database to be in <filename class="directory">/var/lib/locate</filename>, which
|
---|
| 46 | is FHS-compliant.</para></listitem>
|
---|
| 47 | </varlistentry>
|
---|
| 48 | </variablelist>
|
---|
[81fd230] | 49 |
|
---|
[73aedd1d] | 50 | <para>Compile the package:</para>
|
---|
| 51 |
|
---|
| 52 | <screen><userinput>make</userinput></screen>
|
---|
| 53 |
|
---|
[673b0d8] | 54 | <para>To test the results, issue:
|
---|
[8a5f906] | 55 | <userinput>make check</userinput>.</para>
|
---|
[73aedd1d] | 56 |
|
---|
[81fd230] | 57 | <para>Install the package:</para>
|
---|
[73aedd1d] | 58 |
|
---|
| 59 | <screen><userinput>make install</userinput></screen>
|
---|
| 60 |
|
---|
| 61 | </sect2>
|
---|
[6370fa6] | 62 |
|
---|
[c6cb3aa] | 63 | <sect2 id="contents-findutils" role="content"><title>Contents of Findutils</title>
|
---|
[673b0d8] | 64 |
|
---|
[81fd230] | 65 | <segmentedlist>
|
---|
| 66 | <segtitle>Installed programs</segtitle>
|
---|
| 67 | <seglistitem><seg>bigram, code, find, frcode, locate, updatedb, and xargs</seg></seglistitem>
|
---|
| 68 | </segmentedlist>
|
---|
| 69 |
|
---|
| 70 | <variablelist><bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 71 | <?dbfo list-presentation="list"?>
|
---|
[8f97096] | 72 | <?dbhtml list-presentation="table"?>
|
---|
[81fd230] | 73 |
|
---|
| 74 | <varlistentry id="bigram">
|
---|
| 75 | <term><command>bigram</command></term>
|
---|
| 76 | <listitem>
|
---|
| 77 | <para>Was formerly used to produce <command>locate</command> databases</para>
|
---|
| 78 | <indexterm zone="ch-system-findutils bigram"><primary sortas="b-bigram">bigram</primary></indexterm>
|
---|
| 79 | </listitem>
|
---|
| 80 | </varlistentry>
|
---|
| 81 |
|
---|
| 82 | <varlistentry id="code">
|
---|
| 83 | <term><command>code</command></term>
|
---|
| 84 | <listitem>
|
---|
| 85 | <para>Was formerly used to produce <command>locate</command>
|
---|
| 86 | databases; it is the ancestor of <command>frcode</command>.</para>
|
---|
| 87 | <indexterm zone="ch-system-findutils code"><primary sortas="b-code">code</primary></indexterm>
|
---|
| 88 | </listitem>
|
---|
| 89 | </varlistentry>
|
---|
| 90 |
|
---|
| 91 | <varlistentry id="find">
|
---|
| 92 | <term><command>find</command></term>
|
---|
| 93 | <listitem>
|
---|
| 94 | <para>Searches given directory trees for files matching the specified criteria</para>
|
---|
| 95 | <indexterm zone="ch-system-findutils find"><primary sortas="b-find">find</primary></indexterm>
|
---|
| 96 | </listitem>
|
---|
| 97 | </varlistentry>
|
---|
| 98 |
|
---|
| 99 | <varlistentry id="frcode">
|
---|
| 100 | <term><command>frcode</command></term>
|
---|
| 101 | <listitem>
|
---|
| 102 | <para>Is called by <command>updatedb</command> to compress the list of file names; it uses
|
---|
| 103 | front-compression, reducing the database size by a factor of four to
|
---|
| 104 | five.</para>
|
---|
| 105 | <indexterm zone="ch-system-findutils frcode"><primary sortas="b-frcode">frcode</primary></indexterm>
|
---|
| 106 | </listitem>
|
---|
| 107 | </varlistentry>
|
---|
| 108 |
|
---|
| 109 | <varlistentry id="locate">
|
---|
| 110 | <term><command>locate</command></term>
|
---|
| 111 | <listitem>
|
---|
| 112 | <para>Searches through a database of file names and reports the names
|
---|
| 113 | that contain a given string or match a given pattern</para>
|
---|
| 114 | <indexterm zone="ch-system-findutils locate"><primary sortas="b-locate">locate</primary></indexterm>
|
---|
| 115 | </listitem>
|
---|
| 116 | </varlistentry>
|
---|
| 117 |
|
---|
| 118 | <varlistentry id="updatedb">
|
---|
| 119 | <term><command>updatedb</command></term>
|
---|
| 120 | <listitem>
|
---|
| 121 | <para>Updates the <command>locate</command> database; it scans
|
---|
| 122 | the entire file system (including other file systems that are currently mounted,
|
---|
| 123 | unless told not to) and puts every file name it finds into the database</para>
|
---|
| 124 | <indexterm zone="ch-system-findutils updatedb"><primary sortas="b-updatedb">updatedb</primary></indexterm>
|
---|
| 125 | </listitem>
|
---|
| 126 | </varlistentry>
|
---|
| 127 |
|
---|
| 128 | <varlistentry id="xargs">
|
---|
| 129 | <term><command>xargs</command></term>
|
---|
| 130 | <listitem>
|
---|
| 131 | <para>Can be used to apply a given command to a list of files</para>
|
---|
| 132 | <indexterm zone="ch-system-findutils xargs"><primary sortas="b-xargs">xargs</primary></indexterm>
|
---|
| 133 | </listitem>
|
---|
| 134 | </varlistentry>
|
---|
| 135 | </variablelist>
|
---|
[673b0d8] | 136 |
|
---|
| 137 | </sect2>
|
---|
| 138 |
|
---|
| 139 | </sect1>
|
---|
[81fd230] | 140 |
|
---|