source: chapter08/findutils.xml

trunk
Last change on this file was 9c73d911, checked in by Xi Ruoyao <xry111@…>, 3 months ago

Remove -v from "chown -R tester" commands

It does no good: normally we have -v for chown so once it no longer has
an effect we can know, but in this case these chown commands will never
have no effect. And a huge amount of output with -v wastes the server
storage and bandwidth (for both the server and the people reading the
build logs).

  • Property mode set to 100644
File size: 5.1 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-system-findutils" role="wrap">
9 <?dbhtml filename="findutils.html"?>
10
11 <sect1info condition="script">
12 <productname>findutils</productname>
13 <productnumber>&findutils-version;</productnumber>
14 <address>&findutils-url;</address>
15 </sect1info>
16
17 <title>Findutils-&findutils-version;</title>
18
19 <indexterm zone="ch-system-findutils">
20 <primary sortas="a-Findutils">Findutils</primary>
21 </indexterm>
22
23 <sect2 role="package">
24 <title/>
25
26 <para>The Findutils package contains programs to find files. Programs
27 are provided to search through all the files in a directory tree and to
28 create, maintain, and search a database (often faster than the recursive
29 find, but unreliable unless the database has been updated recently).
30 Findutils also supplies the <command>xargs</command> program, which
31 can be used to run a specified command on each file selected by a search.</para>
32
33 <segmentedlist>
34 <segtitle>&buildtime;</segtitle>
35 <segtitle>&diskspace;</segtitle>
36
37 <seglistitem>
38 <seg>&findutils-fin-sbu;</seg>
39 <seg>&findutils-fin-du;</seg>
40 </seglistitem>
41 </segmentedlist>
42
43 </sect2>
44
45 <sect2 role="installation">
46 <title>Installation of Findutils</title>
47
48 <para>Prepare Findutils for compilation:</para>
49
50<!-- no longer needed with gcc13
51<screen><userinput remap="configure">case $(uname -m) in
52 i?86) TIME_T_32_BIT_OK=yes ./configure - -prefix=/usr - -localstatedir=/var/lib/locate ;;
53 x86_64) ./configure - -prefix=/usr - -localstatedir=/var/lib/locate ;;
54esac</userinput></screen>
55-->
56 <screen><userinput remap="configure">./configure --prefix=/usr --localstatedir=/var/lib/locate</userinput></screen>
57
58 <variablelist>
59 <title>The meaning of the configure options:</title>
60<!--
61 <varlistentry>
62 <term><command>TIME_32_BIT_OK=yes</command></term>
63 <listitem>
64 <para>This setting is needed for building on a 32 bit system.</para>
65 </listitem>
66 </varlistentry>
67-->
68 <varlistentry>
69 <term><parameter>--localstatedir</parameter></term>
70 <listitem>
71 <para>This option moves the <command>locate</command>
72 database to <filename class="directory">/var/lib/locate</filename>,
73 which is the FHS-compliant location.</para>
74 </listitem>
75 </varlistentry>
76
77 </variablelist>
78
79 <para>Compile the package:</para>
80
81<screen><userinput remap="make">make</userinput></screen>
82
83 <para>To test the results, issue:</para>
84
85<screen><userinput remap="test">chown -R tester .
86su tester -c "PATH=$PATH make check"</userinput></screen>
87
88 <para>Install the package:</para>
89
90<screen><userinput remap="install">make install</userinput></screen>
91
92 </sect2>
93
94 <sect2 id="contents-findutils" role="content">
95 <title>Contents of Findutils</title>
96
97 <segmentedlist>
98 <segtitle>Installed programs</segtitle>
99 <segtitle>Installed directory</segtitle>
100
101 <seglistitem>
102 <seg>find, locate, updatedb, and xargs</seg>
103 <seg>/var/lib/locate</seg>
104 </seglistitem>
105
106 </segmentedlist>
107
108 <variablelist>
109 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
110 <?dbfo list-presentation="list"?>
111 <?dbhtml list-presentation="table"?>
112
113 <varlistentry id="find">
114 <term><command>find</command></term>
115 <listitem>
116 <para>Searches given directory trees for files matching the specified
117 criteria</para>
118 <indexterm zone="ch-system-findutils find">
119 <primary sortas="b-find">find</primary>
120 </indexterm>
121 </listitem>
122 </varlistentry>
123
124 <varlistentry id="locate">
125 <term><command>locate</command></term>
126 <listitem>
127 <para>Searches through a database of file names and reports the names
128 that contain a given string or match a given pattern</para>
129 <indexterm zone="ch-system-findutils locate">
130 <primary sortas="b-locate">locate</primary>
131 </indexterm>
132 </listitem>
133 </varlistentry>
134
135 <varlistentry id="updatedb">
136 <term><command>updatedb</command></term>
137 <listitem>
138 <para>Updates the <command>locate</command> database; it scans the
139 entire file system (including other file systems that are currently
140 mounted, unless told not to) and puts every file name it finds into
141 the database</para>
142 <indexterm zone="ch-system-findutils updatedb">
143 <primary sortas="b-updatedb">updatedb</primary>
144 </indexterm>
145 </listitem>
146 </varlistentry>
147
148 <varlistentry id="xargs">
149 <term><command>xargs</command></term>
150 <listitem>
151 <para>Can be used to apply a given command to a list of files</para>
152 <indexterm zone="ch-system-findutils xargs">
153 <primary sortas="b-xargs">xargs</primary>
154 </indexterm>
155 </listitem>
156 </varlistentry>
157
158 </variablelist>
159
160 </sect2>
161
162</sect1>
Note: See TracBrowser for help on using the repository browser.