[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
| 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
|
---|
| 3 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 4 | %general-entities;
|
---|
| 5 | ]>
|
---|
[a001133] | 6 | <sect1 id="ch-system-findutils" xreflabel="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/>
|
---|
[673b0d8] | 13 | <para>The Findutils package contains programs to find files. Processes
|
---|
| 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>
|
---|
| 17 |
|
---|
[a001133] | 18 | <segmentedlist>
|
---|
| 19 | <segtitle>&buildtime;</segtitle>
|
---|
| 20 | <segtitle>&diskspace;</segtitle>
|
---|
| 21 | <seglistitem><seg>0.2 SBU</seg><seg>7.5 MB</seg></seglistitem>
|
---|
| 22 | </segmentedlist>
|
---|
[673b0d8] | 23 |
|
---|
[a001133] | 24 | <segmentedlist>
|
---|
| 25 | <segtitle>Findutils installation depends on</segtitle>
|
---|
| 26 | <seglistitem><seg>Bash, Binutils, Coreutils,
|
---|
| 27 | Diffutils, GCC, Gettext, Glibc, Grep, Make, Sed</seg></seglistitem>
|
---|
| 28 | </segmentedlist>
|
---|
| 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 |
|
---|
[2a264e0b] | 36 | <screen><userinput>./configure --prefix=/usr --libexecdir=/usr/lib/locate \
|
---|
[9dfc02f] | 37 | --localstatedir=/var/lib/locate</userinput></screen>
|
---|
[73aedd1d] | 38 |
|
---|
[2a264e0b] | 39 | <para>The localstatedir directive above changes the location of the locate
|
---|
[9dfc02f] | 40 | database to be in /var/lib/locate, which is FHS-compliant.</para>
|
---|
[73aedd1d] | 41 |
|
---|
| 42 | <para>Compile the package:</para>
|
---|
| 43 |
|
---|
| 44 | <screen><userinput>make</userinput></screen>
|
---|
| 45 |
|
---|
[673b0d8] | 46 | <para>To test the results, issue:
|
---|
[8a5f906] | 47 | <userinput>make check</userinput>.</para>
|
---|
[73aedd1d] | 48 |
|
---|
[673b0d8] | 49 | <para>Now install the package:</para>
|
---|
[73aedd1d] | 50 |
|
---|
| 51 | <screen><userinput>make install</userinput></screen>
|
---|
| 52 |
|
---|
| 53 | </sect2>
|
---|
[6370fa6] | 54 |
|
---|
[5888299] | 55 |
|
---|
[c6cb3aa] | 56 | <sect2 id="contents-findutils" role="content"><title>Contents of Findutils</title>
|
---|
[673b0d8] | 57 |
|
---|
[c6cb3aa] | 58 | <segmentedlist>
|
---|
| 59 | <segtitle>Installed programs</segtitle>
|
---|
| 60 | <seglistitem><seg>bigram, code, find, frcode, locate, updatedb and xargs</seg></seglistitem>
|
---|
| 61 | </segmentedlist>
|
---|
[673b0d8] | 62 |
|
---|
[c6cb3aa] | 63 | <variablelist><title>Short descriptions</title>
|
---|
[673b0d8] | 64 |
|
---|
[c6cb3aa] | 65 | <varlistentry>
|
---|
| 66 | <term id="bigram"><command>bigram</command></term>
|
---|
| 67 | <listitem>
|
---|
[673b0d8] | 68 | <indexterm zone="ch-system-findutils bigram"><primary sortas="b-bigram">bigram</primary></indexterm>
|
---|
[c6cb3aa] | 69 | <para>was formerly used to produce locate databases.</para>
|
---|
| 70 | </listitem>
|
---|
| 71 | </varlistentry>
|
---|
[673b0d8] | 72 |
|
---|
[c6cb3aa] | 73 | <varlistentry>
|
---|
| 74 | <term id="code"><command>code</command></term>
|
---|
| 75 | <listitem>
|
---|
[673b0d8] | 76 | <indexterm zone="ch-system-findutils code"><primary sortas="b-code">code</primary></indexterm>
|
---|
[c6cb3aa] | 77 | <para>was formerly used to produce locate
|
---|
[673b0d8] | 78 | databases. It is the ancestor of frcode.</para>
|
---|
[c6cb3aa] | 79 | </listitem>
|
---|
| 80 | </varlistentry>
|
---|
[6370fa6] | 81 |
|
---|
[c6cb3aa] | 82 | <varlistentry>
|
---|
| 83 | <term id="find"><command>find</command></term>
|
---|
| 84 | <listitem>
|
---|
[673b0d8] | 85 | <indexterm zone="ch-system-findutils find"><primary sortas="b-find">find</primary></indexterm>
|
---|
[c6cb3aa] | 86 | <para>searches given directory trees for files matching the specified criteria.</para>
|
---|
| 87 | </listitem>
|
---|
| 88 | </varlistentry>
|
---|
[673b0d8] | 89 |
|
---|
[c6cb3aa] | 90 | <varlistentry>
|
---|
| 91 | <term id="frcode"><command>frcode</command></term>
|
---|
| 92 | <listitem>
|
---|
[673b0d8] | 93 | <indexterm zone="ch-system-findutils frcode"><primary sortas="b-frcode">frcode</primary></indexterm>
|
---|
[c6cb3aa] | 94 | <para>is called by updatedb to compress the list of file names. It uses
|
---|
| 95 | front-compression, reducing the database size by a factor of 4 to 5.</para>
|
---|
| 96 | </listitem>
|
---|
| 97 | </varlistentry>
|
---|
| 98 |
|
---|
| 99 | <varlistentry>
|
---|
| 100 | <term id="locate"><command>locate</command></term>
|
---|
| 101 | <listitem>
|
---|
[673b0d8] | 102 | <indexterm zone="ch-system-findutils locate"><primary sortas="b-locate">locate</primary></indexterm>
|
---|
[c6cb3aa] | 103 | <para>searches through a database of file names,
|
---|
[673b0d8] | 104 | and reports the names that contain a given string or match a given pattern.</para>
|
---|
[c6cb3aa] | 105 | </listitem>
|
---|
| 106 | </varlistentry>
|
---|
[673b0d8] | 107 |
|
---|
[c6cb3aa] | 108 | <varlistentry>
|
---|
| 109 | <term id="updatedb"><command>updatedb</command></term>
|
---|
| 110 | <listitem>
|
---|
[673b0d8] | 111 | <indexterm zone="ch-system-findutils updatedb"><primary sortas="b-updatedb">updatedb</primary></indexterm>
|
---|
[c6cb3aa] | 112 | <para>updates the locate database. It scans
|
---|
[673b0d8] | 113 | the entire file system (including other file systems that are currently mounted,
|
---|
| 114 | unless told not to) and puts every file name it finds in the database.</para>
|
---|
[c6cb3aa] | 115 | </listitem>
|
---|
| 116 | </varlistentry>
|
---|
[673b0d8] | 117 |
|
---|
[c6cb3aa] | 118 | <varlistentry>
|
---|
| 119 | <term id="xargs"><command>xargs</command></term>
|
---|
| 120 | <listitem>
|
---|
[673b0d8] | 121 | <indexterm zone="ch-system-findutils xargs"><primary sortas="b-xargs">xargs</primary></indexterm>
|
---|
[c6cb3aa] | 122 | <para>can be used to apply a given command to a list of files.</para>
|
---|
| 123 | </listitem>
|
---|
| 124 | </varlistentry>
|
---|
| 125 | </variablelist>
|
---|
[673b0d8] | 126 |
|
---|
| 127 | </sect2>
|
---|
| 128 |
|
---|
| 129 | </sect1>
|
---|