/[gentoo]/xml/htdocs/doc/en/gentoolkit.xml
Gentoo

Diff of /xml/htdocs/doc/en/gentoolkit.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.17 Revision 1.35
1<?xml version="1.0" encoding="UTF-8"?> 1<?xml version="1.0" encoding="UTF-8"?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/gentoolkit.xml,v 1.17 2004/10/24 22:48:37 neysx Exp $ --> 2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/gentoolkit.xml,v 1.35 2011/08/15 19:29:48 swift Exp $ -->
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
4 4
5<guide link="/doc/en/gentoolkit.xml"> 5<guide>
6<title>Gentoolkit</title> 6<title>Gentoolkit</title>
7 7
8<author title="Author"> 8<author title="Author">
9 <mail link="mbutcher@aleph-null.tv">Matt Butcher</mail> 9 <mail link="mbutcher@aleph-null.tv">Matt Butcher</mail>
10</author> 10</author>
13</author> 13</author>
14<author title="Editor"> 14<author title="Editor">
15 <mail link="erwin@gentoo.org">Erwin</mail> 15 <mail link="erwin@gentoo.org">Erwin</mail>
16</author> 16</author>
17<author title="Editor"> 17<author title="Editor">
18 <mail link="fox2mike@gmail.com">Shyam Mani</mail> 18 <mail link="fox2mike@gentoo.org">Shyam Mani</mail>
19</author> 19</author>
20<author title="Editor"> 20<author title="Editor">
21 <mail link="neysx@gentoo.org">Xavier Neys</mail> 21 <mail link="neysx@gentoo.org">Xavier Neys</mail>
22</author> 22</author>
23 23<author title="Editor">
24<!-- Licensed under GFDL --> 24 <mail link="karltk@gentoo.org">Karl Trygve</mail>
25</author>
26<author title="Editor">
27 <mail link="yoswink@gentoo.org">José Luis Rivero</mail>
28</author>
29<author title="Editor">
30 <mail link="nightmorph@gentoo.org">Joshua Saddler</mail>
31</author>
32<author title="Editor">
33 <mail link="douglasjanderson@gmail.com">Douglas Anderson</mail>
34</author>
25 35
26<abstract> 36<abstract>
27Gentoolkit is a suite of tools to ease the administration of a Gentoo system. 37Gentoolkit is a suite of tools to ease the administration of a Gentoo system.
28This document covers the basics of some of the tools present in Gentoolkit. 38This document covers the basics of some of the tools present in Gentoolkit.
29</abstract> 39</abstract>
30 40
41<!-- Licensed under GFDL -->
42
31<version>1.4</version> 43<version>4</version>
32<date>August 25, 2004</date> 44<date>2011-08-15</date>
33 45
34<chapter> 46<chapter>
35<title>Introduction</title> 47<title>Introduction</title>
36<section> 48<section>
37<title>What is Gentoolkit?</title> 49<title>What is Gentoolkit?</title>
48 60
49<note> 61<note>
50As of now, there are two versions of gentoolkit: <c>app-portage/gentoolkit</c> 62As of now, there are two versions of gentoolkit: <c>app-portage/gentoolkit</c>
51and <c>app-portage/gentoolkit-dev</c>. While the former contains administration 63and <c>app-portage/gentoolkit-dev</c>. While the former contains administration
52scripts, the latter contains scripts specific to help development on Gentoo. 64scripts, the latter contains scripts specific to help development on Gentoo.
65If you are a developer, you can have your scripts included into
66<c>gentoolkit-dev</c> by contacting the Gentoolkit maintainer. This document
53This document discusses gentoolkit only. 67discusses gentoolkit only.
54</note> 68</note>
55 69
56<p> 70<p>
57Gentoolkit contains a whole bunch of useful tools to help manage your packages 71Gentoolkit contains a whole bunch of useful tools to help manage your packages
58and keep track of what is going on in your system. Most users --&nbsp;particularly 72and keep track of what is going on in your system. Most users
59those who update systems often&nbsp;-- will benefit from having gentoolkit 73--&nbsp;particularly those who update systems often&nbsp;-- will benefit from
60installed. 74having gentoolkit installed.
61</p> 75</p>
62 76
63</body> 77</body>
64</section> 78</section>
65<section> 79<section>
75</pre> 89</pre>
76 90
77<note> 91<note>
78Many of the tools in gentoolkit reveal important information about your system 92Many of the tools in gentoolkit reveal important information about your system
79or require root privilege. For that reason, some of the programs may only be 93or require root privilege. For that reason, some of the programs may only be
80executed (or only function properly) if run by a user with root permission. 94executed (or only function properly) if run by a user with root privileges.
81</note> 95</note>
82 96
83</body> 97</body>
84</section> 98</section>
85<section> 99<section>
86<title>Finding Documentation</title> 100<title>Finding Documentation</title>
87<body> 101<body>
88 102
89<p> 103<p>
90Any documentation that a program might have (other than man pages) is stored in 104Any documentation that a program might have (other than man pages) is stored in
91<path>/usr/doc/gentoolkit-[version]/[program-name]/</path>. 105<path>/usr/share/doc/gentoolkit-[version]/[program-name]/</path>.
92</p>
93
94</body>
95</section>
96</chapter>
97
98<chapter>
99<title>Querying Package Data with qpkg</title>
100<section>
101<title>Introduction</title>
102<body>
103
104<p>
105<c>qpkg</c> is a flexible tool for determining information about installed
106ebuilds. It can provide information about what files belong to which ebuilds,
107whether multiple versions of the same package are installed and what a
108particular ebuild does. It can also be used to query some information about
109ebuilds that have not been installed.
110</p>
111
112<p>
113Calling <c>qpkg</c> with no arguments prints a list of all ebuilds with
114asterisks (*) next to the packages that are installed on the system.
115</p>
116
117<note>
118By default, <c>qpkg</c> prints output in color. To turn this off on the command
119line, use the <c>--no-color</c> or <c>-nc</c> flag.
120</note>
121
122</body>
123</section>
124<section>
125<title>Querying Package Information</title>
126<body>
127
128<p>
129One of the most common uses for <c>qpkg</c> is determining what a given package
130is. For instance, while looking through <path>net-misc</path>, I saw a package
131called <path>neon</path>. Having no idea what it was, I ran qpkg.
132</p>
133
134<pre caption="Package Information">
135# <i>qpkg -i net-misc/neon</i>
136net-misc/neon-0.24.4
137 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
138net-misc/neon-0.23.8
139 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
140net-misc/neon-0.24.6
141 HTTP and WebDAV client library [ http://www.webdav.org/neon/ ]
142net-misc/neon-0.24.5
143 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
144net-misc/neon-0.24.0
145 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
146net-misc/neon-0.21.3
147 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
148net-misc/neon-0.23.9
149 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
150net-misc/neon-0.24.7
151 HTTP and WebDAV client library [ http://www.webdav.org/neon/ ]
152net-misc/neon-0.24.2
153 HTTP and WebDAV client library [ http://www.webdav.org/neon ]
154</pre>
155
156<p>
157<c>qpkg</c> read through the ebuild files for the nine
158<path>net-misc/neon</path> ebuilds and printed out the information stored in
159DESCRIPTION and HOMEPAGE.
160</p>
161
162</body>
163</section>
164<section>
165<title>Listing Files Belonging to an Ebuild</title>
166<body>
167
168<p>
169<c>qpkg</c> can also list the files that belong to an installed ebuild. I
170know that gentoolkit installed several tools, but I don't know what they
171all are. To find out, I can do a <c>qpkg -l</c>.
172</p>
173
174<pre caption="Package File list using qpkg">
175# <i>qpkg -l app-portage/gentoolkit</i>
176app-portage/gentoolkit-0.2.0_pre8 *
177CONTENTS:
178/usr
179/usr/bin
180/usr/bin/euse
181/usr/bin/qpkg
182/usr/bin/etcat
183/usr/bin/revdep-rebuild
184/usr/bin/glsa-check
185/usr/bin/dep-clean
186/usr/bin/equery
187/usr/bin/ewhich
188/usr/bin/pkg-size
189/usr/lib
190/usr/lib/gentoolkit
191/usr/lib/gentoolkit/pym
192/usr/lib/gentoolkit/pym/glsa.py
193/usr/lib/gentoolkit/pym/gentoolkit.py
194/usr/sbin
195/usr/sbin/pkg-clean
196/usr/sbin/mkebuild
197/usr/share
198/usr/share/doc
199/usr/share/doc/gentoolkit-0.2.0_pre8
200/usr/share/doc/gentoolkit-0.2.0_pre8/NEWS
201/usr/share/doc/gentoolkit-0.2.0_pre8/TODO
202/usr/share/doc/gentoolkit-0.2.0_pre8/euse
203/usr/share/doc/gentoolkit-0.2.0_pre8/euse/TODO
204/usr/share/doc/gentoolkit-0.2.0_pre8/euse/README
205/usr/share/doc/gentoolkit-0.2.0_pre8/euse/AUTHORS
206/usr/share/doc/gentoolkit-0.2.0_pre8/euse/ChangeLog
207/usr/share/doc/gentoolkit-0.2.0_pre8/qpkg
208/usr/share/doc/gentoolkit-0.2.0_pre8/qpkg/README
209/usr/share/doc/gentoolkit-0.2.0_pre8/qpkg/AUTHORS
210/usr/share/doc/gentoolkit-0.2.0_pre8/qpkg/ChangeLog
211/usr/share/doc/gentoolkit-0.2.0_pre8/etcat
212/usr/share/doc/gentoolkit-0.2.0_pre8/etcat/README
213/usr/share/doc/gentoolkit-0.2.0_pre8/etcat/AUTHORS
214/usr/share/doc/gentoolkit-0.2.0_pre8/revdep-rebuild
215/usr/share/doc/gentoolkit-0.2.0_pre8/revdep-rebuild/TODO
216/usr/share/doc/gentoolkit-0.2.0_pre8/revdep-rebuild/README
217/usr/share/doc/gentoolkit-0.2.0_pre8/revdep-rebuild/AUTHORS
218/usr/share/doc/gentoolkit-0.2.0_pre8/README
219/usr/share/doc/gentoolkit-0.2.0_pre8/equery
220/usr/share/doc/gentoolkit-0.2.0_pre8/equery/README
221/usr/share/doc/gentoolkit-0.2.0_pre8/equery/AUTHORS
222/usr/share/doc/gentoolkit-0.2.0_pre8/AUTHORS
223/usr/share/doc/gentoolkit-0.2.0_pre8/gentoolkit
224/usr/share/doc/gentoolkit-0.2.0_pre8/gentoolkit/TODO
225/usr/share/doc/gentoolkit-0.2.0_pre8/gentoolkit/README
226/usr/share/doc/gentoolkit-0.2.0_pre8/gentoolkit/AUTHORS
227/usr/share/doc/gentoolkit-0.2.0_pre8/gentoolkit/ChangeLog
228/usr/share/doc/gentoolkit-0.2.0_pre8/ChangeLog
229/usr/share/doc/gentoolkit-0.2.0_pre8/COPYING
230/usr/share/man
231/usr/share/man/man1
232/usr/share/man/man1/revdep-rebuild.1.gz
233/usr/share/man/man1/mkebuild.1.gz
234/usr/share/man/man1/qpkg.1.gz
235/usr/share/man/man1/pkg-clean.1.gz
236/usr/share/man/man1/etcat.1.gz
237/usr/share/man/man1/ewhich.1.gz
238/usr/share/man/man1/equery.1.gz
239/usr/share/man/man1/euse.1.gz
240/usr/share/man/man1/dep-clean.1.gz
241/usr/share/man/man1/pkg-size.1.gz
242</pre>
243
244<note>
245In case you have gentoolkit-dev installed, <c>qpkg</c> will list out files for
246that as well, i.e. it displays the file list for all installed packages with
247the name gentoolkit.
248</note>
249
250</body>
251</section>
252<section>
253<title>Finding the Package That a File Came From</title>
254<body>
255
256<p>
257To find the package that a file came from, use the <c>-f</c> or
258<c>--find-file</c> flag.
259</p>
260
261<pre caption="Finding the ebuild that installed a given file">
262# <i>qpkg -f /usr/lib/mozilla</i>
263net-www/mozilla *
264</pre>
265
266</body>
267</section>
268<section>
269<title>Listing Duplicate Packages</title>
270<body>
271
272<p>
273Sometimes multiple versions of the same package may exist. <c>qpkg --dups</c>
274will print a list of duplicate packages. The existence of a duplicate package
275though may not indicate that the older version may be removed. They may fill
276different slots. To look for duplicates in the same slot, use <c>qpkg --dups
277--slot</c>. I just updated KDE from 3.0 to 3.0.2, so I have some duplicates in
278the same slot.
279</p>
280
281<pre caption="Finding duplicate packages">
282# <i>qpkg --dups --slot</i>
283app-portage/gentoolkit
284kde-base/kdeaddons
285kde-base/kdeadmin
286kde-base/kdeartwork
287kde-base/kdebase
288kde-base/kdegames
289kde-base/kdelibs
290kde-base/kdemultimedia
291kde-base/kdenetwork
292kde-base/kdetoys
293kde-base/kdeutils
294media-libs/freetype
295x11-libs/qt
296</pre>
297
298</body>
299</section>
300<section>
301<title>Verifying Package Integrity</title>
302<body>
303
304<p>
305Sometimes it is useful to check a package's integrity to know that files have
306not been replaced since they were installed. <c>qpkg</c> can verify md5 sums as
307well as install times to indicate whether files for the package might have been
308corrupted, replaced, or removed.
309</p>
310
311<p>
312To check both mtimes and md5 sums, use the <c>-c</c> flag.
313</p>
314
315<pre caption="See the Difference?">
316# <i>qpkg cdrtools -c -v</i>
317app-cdr/cdrtools-2.01_alpha25 *
318/etc/default/rscsi.dfl !mtime!
319/usr/bin/devdump !md5! !mtime!
320/usr/bin/mkisofs !md5! !mtime!
321/usr/bin/isovfy !md5! !mtime!
322/usr/bin/readcd !md5! !mtime!
323/usr/bin/cdda2wav !md5! !mtime!
324/usr/bin/cdrecord !md5! !mtime!
325/usr/bin/isodump !md5! !mtime!
326/usr/bin/isoinfo !md5! !mtime!
327/usr/lib/libfile.a !md5! !mtime!
328/usr/lib/librscg.a !md5! !mtime!
329/usr/lib/libunls.a !md5! !mtime!
330/usr/lib/libedc_ecc.a !md5! !mtime!
331/usr/lib/libdeflt.a !md5! !mtime!
332/usr/lib/libhfs.a !md5! !mtime!
333/usr/lib/libscg.a !md5! !mtime!
334/usr/lib/libparanoia.a !md5! !mtime!
335/usr/lib/libschily.a !md5! !mtime!
336/usr/sbin/rscsi !md5! !mtime!
337/usr/share/man/man1/cdrecord.1.gz !md5! !mtime!
338/usr/share/man/man1/readcd.1.gz !md5! !mtime!
339/usr/share/man/man1/cdda2wav.1.gz !md5! !mtime!
340/usr/share/man/man8/mkisofs.8.gz !md5! !mtime!
34176/150
342
343app-cdr/cdrtools-2.01_alpha37 *
3440/122
345</pre>
346
347<p>
348As you can see, I have more than one version of cdrtools installed. <c>qpkg</c>
349reports that many of the files from the older version have been changed since I
350installed it. Those packages were most likely modified when I updated from
351<path>cdrtools-2.01_alpha25</path> to <path>cdrtools-2.01_alpha37</path>. Note
352that the last two lines indicate that 0 of 122 files from <path>cdrtools-2.01
353_alpha37</path> have been changed since I installed. That is good. If any of
354them had been changed, I would be worried.
355</p>
356
357</body>
358</section>
359<section>
360<title>But Wait... There's More</title>
361<body>
362
363<p>
364<c>qpkg</c> can be used for other querying tasks that I will not cover here.
365There is a very complete man page for <c>qpkg</c>. Please read it for more
366information.
367</p> 106</p>
368 107
369</body> 108</body>
370</section> 109</section>
371</chapter> 110</chapter>
375<section> 114<section>
376<title>Introduction</title> 115<title>Introduction</title>
377<body> 116<body>
378 117
379<p> 118<p>
380<c>equery</c> is a tool that supports features that <c>qpkg</c> and <c>epm</c> 119<c>equery</c> is a tool that displays useful information about the packages on
381have but has its own set of features that make it really useful. <c>equery 120your system. <c>equery</c> is based on a system of modules.
382--help</c> gives you the full set of options. <c>equery</c> will eventually 121Every module has a shorthand name. For example, <c>equery l gcc</c> is the same
383replace <c>etcat</c> at some point of time. 122as <c>equery list gcc</c>. <c>equery --help</c> explains global options
123and lists all available modules and their shorthand names.
124<c>equery --help module</c> will display the help screen for a specific
125module. Lastly, <c>man equery</c> provides a detailed explanation of all
126available modules and options, and provides useful examples.
127</p>
128
384</p> 129<p>
130Below is a list of features that work over the majority of modules.
131</p>
132
133<pre caption="Examples of Acceptable Input">
134<comment>(Many modules require a package argument. equery accepts all emerge-like input):</comment>
135$ <i>equery --quiet list gcc</i> # <comment>package</comment>
136sys-devel/gcc-4.3.2-r3
137$ <i>equery --quiet list sys-devel/gcc</i> # <comment>category/package</comment>
138sys-devel/gcc-4.3.2-r3
139$ <i>equery --quiet list '>=sys-devel/gcc-4'</i> # <comment>atom syntax</comment>
140sys-devel/gcc-4.3.2-r3
141
142<comment>(Like emerge, equery doesn't understand partial package names):</comment>
143$ <i>equery check zilla</i>
144!!! No package found matching zilla
145
146<comment>(Unlike emerge, equery can accept shell-like globbing in the category and/or package name):</comment>
147$ <i>equery check '*zilla*'</i>
148 * Checking www-client/mozilla-firefox-3.0.14 ...
149 90 out of 90 files passed
150$ <i>equery check www-c*/*</i>
151 * Checking www-client/links-2.2 ...
152 30 out of 30 files passed
153 * Checking www-client/mozilla-firefox-3.0.14 ...
154 90 out of 90 files passed
155
156<comment>(Most equery modules take multiple input):</comment>
157$ <i>equery hasuse sse sse2</i>
158 * Searching for USE flag sse ...
159[IP-] [ ] media-libs/flac-1.2.1-r3 (0)
160[IP-] [ ] media-libs/speex-1.2_beta3_p2 (0)
161
162 * Searching for USE flag sse2 ...
163[IP-] [ ] dev-libs/openssl-0.9.8k (0)
164[IP-] [ ] x11-libs/pixman-0.16.0 (0)
165
166<comment>(A few modules also allow full regular expressions):</comment>
167$ <i>equery -q list --portage-tree --full-regex '[kr]?flickr.*'</i>
168dev-dotnet/flickrnet-bin-2.2
169dev-ruby/flickr-1.0.2-r1
170dev-ruby/flickr-1.0.2-r2
171dev-ruby/rflickr-20060201
172media-gfx/kflickr-0.6
173[...]
174</pre>
385 175
386<note> 176<note>
387Not all features listed by <c>equery --help</c> have been implemented yet. 177Globbing support replaced a number of older options in <c>equery</c>.
388Those that have not been, are mentioned clearly. 178For example, to act on all packages in a certain set, use <c>'*'</c>.
179To act on all packages in a category, use <c>'category-name/*'</c>.
389</note> 180</note>
390 181
182<warn>
183Don't forget to quote input when using special shell characters
184like asterisks or greater than/less than signs.
185</warn>
186
187<p>
188The next few sections in this document give a quick introduction to the
189different <c>equery</c> modules.
190</p>
191
391</body> 192</body>
392</section>
393<section> 193</section>
394<title>Finding out Package Sizes</title> 194<section>
195<title>Finding the Package That a File Came From with belongs (b)</title>
196<body>
197
198<pre caption="Finding the Package that Installed a Given File">
199$ <i>equery belongs -e /usr/bin/glxgears</i>
200 * Searching for /usr/bin/glxgears ...
201 x11-apps/mesa-progs-7.5.1 (/usr/bin/glxgears)
202</pre>
203
204<p>
205<c>belongs</c> can search for files matching a regular expression with the
206<c>-f</c> option. The <c>-e</c> option stops searching after it finds a match.
207Since no file on your system should be owned by two packages, this is a safe
208optimization.
209</p>
210
395<body> 211</body>
212</section>
213<section>
214<title>Viewing ChangeLog Entries with changes (c)</title>
215<body>
396 216
217<p>
218<c>changes</c> lets you view ChangeLog entries for a package version or range
219of versions. Imagine after an <c>emerge --sync</c>, you
220notice Portage is going to be upgraded and want to check what has changed:
397<p> 221</p>
222
223<pre caption="Viewing Gentoo ChangeLog Entries">
224<comment>(Show the latest installable version's entry):</comment>
225$ <i>equery changes portage</i>
226*portage-2.1.6.13 (03 May 2009)
227
228 03 May 2009; Zac Medico &lt;zmedico@gentoo.org&gt; +portage-2.1.6.13.ebuild:
229 2.1.6.13 bump. This fixes bug #268398 (document econf automatic die)
230 and bug #267104 (handle insufficient space interaction with userfetch).
231 Bug #268228 tracks all bugs fixed since 2.1.6.11.
232</pre>
233
234</body>
235</section>
236<section>
237<title>Verifying Package Integrity with check (k)</title>
238<body>
239
240<p>
241Sometimes it is useful to check a package's integrity. <c>equery</c> can
242verify MD5 sums as well as timestamps to indicate when a package might
243have been corrupted, replaced, or removed.
244</p>
245
246<pre caption="Checking Package Integrity">
247$ <i>equery check gentoolkit</i>
248 * Checking app-portage/gentoolkit-0.3.0_rc7 ...
249 71 out of 71 files passed
250</pre>
251
252</body>
253</section>
254<section>
255<title>Listing All Packages Depending on Package X with depends (d)</title>
256<body>
257
258<p>
259Ever wonder why a certain package has been installed on your system?
260<c>equery</c> can tell which packages list it as a dependency with
261<c>depends</c>. Include indirect dependencies with the <c>-D</c>
262option.
263</p>
264
265<pre caption="Looking for Packages Depending on pygtk">
266$ <i>equery depends pygtk</i>
267 * Searching for pygtk ...
268app-admin/pessulus-2.24.0 (>=dev-python/pygtk-2.6.0)
269app-editors/gedit-2.24.3 (python ? >=dev-python/pygtk-2.12)
270dev-libs/libgweather-2.24.3 (python ? >=dev-python/pygtk-2)
271dev-python/gnome-python-base-2.22.3 (>=dev-python/pygtk-2.10.3)
272dev-python/gnome-python-desktop-base-2.24.1 (>=dev-python/pygtk-2.10.3)
273[...]
274</pre>
275
276</body>
277</section>
278<section>
279<title>Getting Dependency Graphs with depgraph (g)</title>
280<body>
281
282<p>
283<c>depgraph</c> is the opposite of <c>depends</c>. You pass it a package, and
284it will find the packages <e>it</e> depends on (not that depend on it).
285When it finds a dependency, it will recursively search for all of
286<e>that</e> package's dependencies. Control how deep the tree gets with
287the <c>--depth</c> option.
288</p>
289
290<pre caption="Viewing Dependency Graph for mozilla-firefox">
291$ <i>equery depgraph mozilla-firefox</i>
292 * Searching for mozilla-firefox ...
293 * dependency graph for www-client/mozilla-firefox-2.0.0.19:
294`-- www-client/mozilla-firefox-2.0.0.19
295 `-- virtual/jre-1.6.0 (virtual/jre) [java]
296 `-- virtual/jdk-1.6.0 (virtual/jdk-1.6.0*)
297 `-- dev-java/icedtea6-bin (unable to resolve: package masked or removed)
298 `-- dev-java/sun-jdk-1.6.0.15
299 `-- dev-java/java-sdk-docs-1.6.0.10 [doc]
300 `-- app-arch/unzip-6.0-r1
301 `-- app-arch/bzip2-1.0.5-r1 [bzip2]
302 `-- sys-libs/glibc-2.9_p20081201-r2
303 `-- sys-devel/gettext-0.17 [nls]
304 `-- virtual/libiconv-0 (virtual/libiconv)
305[...]
306</pre>
307
308<p>
309Notice how <c>jre</c> is a direct dependency and <c>jdk</c> is an indirect
310dependency if the <c>java</c> USE flag is set.
311</p>
312
313</body>
314</section>
315<section>
316<title>Listing Files Installed by a Package with files (f)</title>
317<body>
318
319<p>
320<c>equery</c> can list all the files installed by an ebuild with the
321<c>files</c> module. Try <c>--tree</c> to get an easy to read directory
322layout. Use <c>--filter</c> to only find a certain type of file. For example,
323to find where executables were installed, use <c>--filter=cmd</c>, and to
324quickly find the configuration file location, try <c>--filter=conf</c>.
325</p>
326
327<pre caption="Listing Installed Files in Tree Format">
328$ <i>equery files --tree gentoolkit</i>
329 * Searching for gentoolkit ...
330 * Contents of app-portage/gentoolkit-0.3.0_rc7:
331 /etc
332 > /eclean
333 + distfiles.exclude
334 + packages.exclude
335 > /env.d
336 + 99gentoolkit-env
337 > /revdep-rebuild
338 + 99revdep-rebuild
339 /usr
340 > /bin
341 + eclean
342 + eclean-dist -> eclean
343 + eclean-pkg -> eclean
344 + epkginfo
345 + equery
346 + eread
347 + euse
348 + glsa-check
349 + revdep-rebuild
350 > /lib
351 > /python2.6
352 > /site-packages
353 > /gentoolkit
354 + gentoolkit-0.3.0_rc7-py2.6.egg-info
355 + __init__.py
356 > /equery
357 + __init__.py
358 + belongs.py
359 + changes.py
360 + check.py
361 + depends.py
362 + depgraph.py
363 + files.py
364[...]
365</pre>
366
367</body>
368</section>
369<section>
370<title>Looking for Packages that Have a Specific USE Flag with hasuse (h)</title>
371<body>
372
373<p>
374You can use <c>hasuse</c> to find out which packages have a given USE flag.
375<c>hasuse</c> won't tell you if the flag is enabled, only if the ebuild lists
376it as an option. See the EXAMPLES section of <c>hasuse</c> in the
377<c>equery</c> man page for more tip on getting that information.
378</p>
379
380<pre caption="Searching For Installed Packages that Use the qt3 or qt4 USE Flags">
381$ <i>equery hasuse qt3 qt4</i>
382 * Searching for USE flag qt3 ...
383[IP-] [ ] app-crypt/pinentry-0.7.5 (0)
384[IP-] [ ] net-dns/avahi-0.6.24-r2 (0)
385[IP-] [ ] net-wireless/wpa_supplicant-0.6.9 (0)
386
387 * Searching for USE flag qt4 ...
388[IP-] [ ] net-dns/avahi-0.6.24-r2 (0)
389[IP-] [ ] net-wireless/wpa_supplicant-0.6.9 (0)
390</pre>
391
392</body>
393</section>
394<section>
395<title>Listing Packages with list (l)</title>
396<body>
397
398<p>
399<c>list</c> is a simple, yet powerful module to list packages that are installed,
400in the Portage tree or in an overlay.
401</p>
402
403<pre caption="Listing Installed Packages with list">
404$ <i>equery list '*'</i>
405 * Searching for * ...
406[IP-] [ ] app-admin/eselect-1.2.3 (0)
407[IP-] [ ] app-admin/eselect-ctags-1.10 (0)
408[IP-] [ ] app-admin/eselect-esd-20060719 (0)
409[IP-] [ ] app-admin/eselect-fontconfig-1.0 (0)
410[IP-] [ ] app-admin/eselect-opengl-1.0.8-r1 (0)
411[IP-] [ ] app-admin/eselect-python-20090824 (0)
412[IP-] [ ] app-admin/eselect-ruby-20081227 (0)
413[IP-] [ ] app-admin/eselect-vi-1.1.5 (0)
414[IP-] [ ] app-admin/perl-cleaner-1.05 (0)
415[IP-] [ ] app-admin/pessulus-2.24.0 (0)
416[IP-] [ ] app-admin/python-updater-0.7 (0)
417[IP-] [ ] app-admin/sudo-1.7.2_p1 (0)
418[...]
419</pre>
420
421<p>
422The standard query will search installed packages for the given package name.
423Passing in '*' displays all packages in the set. In the leftmost field, we
424see that all the above packages are <c>I</c>nstalled and from the <c>P</c>ortage
425tree. They're not masked (the second field is blank), and they're all installed
426in the default slot (0).
427</p>
428
429<p>
430This time we are going to use local options to look for packages in the
431Portage tree and overlays.
432</p>
433
434<pre caption="Using Local Options with list">
435$ <i>equery list -po vim</i>
436 * Searching for vim ...
437[-P-] [ ] app-editors/vim-7.0.235 (0)
438[-P-] [ ~] app-editors/vim-7.0.243 (0)
439[-P-] [ ] app-editors/vim-7.1.123 (0)
440[-P-] [ ~] app-editors/vim-7.1.330 (0)
441[-P-] [ ] app-editors/vim-7.2 (0)
442[-P-] [ ~] app-editors/vim-7.2.108 (0)
443[IP-] [ ] app-editors/vim-7.2.182 (0)
444[-P-] [ ~] app-editors/vim-7.2.238 (0)
445[-P-] [ ~] app-editors/vim-7.2.264 (0)
446</pre>
447
448<p>
449In this example you can see version 7.2.182 is installed and there are no
450versions available from an overlay. You can see which versions are keyword
451masked by the <c>~</c> in the second field.
452</p>
453
454</body>
455</section>
456<section>
457<title>Viewing Package Metadata with meta (m)</title>
458<body>
459
460<p>
461Each package in the Portage tree provides at least some metadata about
462its maintainer, herd, etc. Read about <uri
463link="http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&amp;chap=4">Gentoo
464Metadata</uri>. The amount of useful information depends on how much package
465maintainers decide to provide. With no options, <c>meta</c> returns some basic
466useful information.
467</p>
468
469<pre caption="Getting Package Metadata with meta">
470$ <i>equery meta gnucash</i>
471 * app-office/gnucash [gentoo]
472 Herd: gnome-office (gnome-office@gentoo.org)
473 Maintainer: tove@gentoo.org (Torsten Veller)
474 Upstream: None specified
475 Location: /usr/portage/app-office/gnucash
476 Keywords: 2.2.9-r1:0: alpha amd64 ppc sparc x86
477 Keywords: 2.2.9-r2:0:
478 Keywords: 2.3.8:0:
479 Keywords: 2.3.10:0: ~alpha ~amd64 ~ppc ~sparc ~x86
480</pre>
481
482<p>
483When the maintainer provides extra information, it can be very useful:
484</p>
485
486<pre caption="Getting Long Package Descriptions with meta">
487$ <i>equery meta --description emacs</i>
488 * app-editors/emacs
489 GNU Emacs is an extensible, customizable text editor - and more. At its core
490 is an interpreter for Emacs Lisp, a dialect of the Lisp programming language
491 with extensions to support text editing. The features of GNU Emacs include:
492 * Content-sensitive editing modes, including syntax coloring, for a wide
493 variety of file types including plain text, source code, and HTML.
494 * Complete built-in documentation, including a tutorial for new users.
495 * Support for many languages and their scripts, including all the European
496 "Latin" scripts, Russian, Greek, Japanese, Chinese, Korean, Thai,
497 Vietnamese, Lao, Ethiopian, and some Indian scripts.
498 * Highly customizable, using Emacs Lisp code or a graphical customization
499 interface.
500 * A large number of extensions that add other functionality, including a
501 project planner, mail and news reader, debugger interface, calendar, and
502 more. Many of these extensions are distributed with GNU Emacs; others are
503 available separately.
504</pre>
505
506</body>
507</section>
508<section>
509<title>Finding Package Sizes with size (s)</title>
510<body>
511
512<p>
398Ever been curious to find out how much space a specific package is occupying? 513Have you ever been curious to find out how much space a specific package is
399Since a package could have its files over a number of directories, the usual 514occupying? Since a package could have its files over a number of directories,
400<c>du -hc</c> might not give you the correct figure. Not to worry, here comes 515the usual <c>du -hc</c> might not give you the correct figure. Not to worry,
401<c>equery</c> to the rescue! 516here comes <c>equery</c> to the rescue!
402</p> 517</p>
403 518
404<pre caption="Package Size"> 519<pre caption="Displaying Package Size">
405# <i>equery size openoffice-bin</i> 520$ <i>equery size openoffice-bin</i>
406* app-office/openoffice-bin-1.1.2 521 * app-office/openoffice-bin-3.1.1
407 Total Files : 2908 522 Total files : 4624
408 Total Size : 223353.31 KiB 523 Total size : 361.38 MiB
409</pre> 524</pre>
410 525
411<p>
412As you can see, <c>equery</c> prints the total space used in kilobytes and also
413lists the total number of files the package has.
414</p> 526<p>
527As you can see, <c>size</c> prints the total space used in human-readable
528units and lists the total number of files the package has. To get the
529total size in bytes, use <c>--bytes</c>.
530</p>
415 531
416</body> 532</body>
417</section>
418<section> 533</section>
419<title>Package-wise list of USE Flags</title> 534<section>
535<title>Listing Per-Package USE Flags with uses (u)</title>
420<body> 536<body>
421 537
422<p>
423<c>equery</c> can be used to give us information about what USE flags are being
424used by a specific package. It tells us what our current USE flags are for a
425package and what USE flags are available for the package.
426</p> 538<p>
539<c>equery</c>'s <c>uses</c> module can provide information about what USE
540flags are available for a specific package, and which of those flags is
541currently enabled.
542</p>
427 543
428<pre caption="Set and Unset USE Flags"> 544<pre caption="Showing Set and Unset USE Flags">
429# <i>equery uses ethereal</i> 545$ <i>equery uses gst-plugins-meta</i>
430[ Colour Code : set unset ] 546 * Searching for gst-plugins-meta ...
431[ Legend : (U) Col 1 - Current USE flags ] 547[ Legend : U - flag is set in make.conf ]
432[ : (I) Col 2 - Installed With USE flags ] 548[ : I - package is installed with flag ]
433 549[ Colors : set, unset ]
434 U I [ Found these USE variables in : net-analyzer/ethereal-0.10.6 ] 550 * Found these USE flags for media-plugins/gst-plugins-meta-0.10-r2:
435 - - adns : Adds support for the adns DNS client library 551 U I
436 + + gtk : Adds support for x11-libs/gtk+ (The GIMP Toolkit) 552 + + X : Adds support for X11
437 - - ipv6 : Adds support for IP version 6 553 - - a52 : Enables support for decoding ATSC A/52 streams used in DVD
438 - - snmp : Adds support for the Simple Network Management Protocol if available 554 + + alsa : Adds support for media-libs/alsa-lib (Advanced Linux Sound
439 + + ssl : Adds support for Secure Socket Layer connections 555 Architecture)
440 + + gtk2 : Use gtk+-2.0.0 over gtk+-1.2 in cases where a program supports both. 556 - - dvb : Adds support for DVB (Digital Video Broadcasting)
441 - - debug : Tells configure and the makefiles to build for debugging. Effects vary across packages, 557 + + dvd : Adds support for DVDs
442 but generally it will at least add -g to CFLAGS. Remember to set FEATURES=nostrip too 558 + + esd : Adds support for media-sound/esound (Enlightened Sound Daemon)
559 + + ffmpeg : Enable ffmpeg-based audio/video codec support
560 + + flac : Adds support for FLAC: Free Lossless Audio Codec
561 - - mad : Adds support for mad (high-quality mp3 decoder library and cli
562 frontend)
563 + + mpeg : Adds libmpeg3 support to various packages
564 - - mythtv : Support for retrieval from media-tv/mythtv backend
565 + + ogg : Adds support for the Ogg container format (commonly used by
566 Vorbis, Theora and flac)
567 - - oss : Adds support for OSS (Open Sound System)
568 + + theora : Adds support for the Theora Video Compression Codec
569 + + vorbis : Adds support for the OggVorbis audio codec
570 - - xv : Adds in optional support for the Xvideo extension (an X API for
571 video playback)
443</pre> 572</pre>
444 573
445<p> 574<p>
446I have installed ethereal with only the gtk, ssl and gtk2 flags set, but the 575Here, a number of USE flags are enabled in <c>gstreamer</c>'s plugin
447other USE flags for ethereal are adns, ipv6, snmp and debug. For more 576meta-package, but you can see that there are other USE flags available.
448information on USE flags, please refer to the <uri 577For more information on USE flags, please refer to the <uri
449link="/doc/en/handbook/handbook-x86.xml?part=2&amp;chap=2">USE Flags</uri> 578link="/doc/en/handbook/handbook-x86.xml?part=2&amp;chap=2">USE Flags</uri>
450chapter of the <uri link="/doc/en/handbook/">Gentoo Handbook</uri>. 579chapter of the <uri link="/doc/en/handbook/">Gentoo Handbook</uri>.
451</p> 580</p>
452 581
453</body> 582</body>
454</section> 583</section>
455<section> 584<section>
456<title>Where's the ebuild?</title> 585<title>Finding the Ebuild Path with which (w)</title>
457<body>
458
459<p>
460We can also find out which ebuild is being used for a specific package using
461<c>equery</c>. This is done my using the <c>equery which</c> command which
462displays the full path to the ebuild.
463</p>
464
465<pre caption="Displaying the ebuild path">
466# <i>equery which cdrtools</i>
467/usr/portage/app-cdr/cdrtools/cdrtools-2.01_alpha37.ebuild
468</pre>
469
470</body> 586<body>
471</section>
472<section>
473<title>Dependency Graphs</title>
474<body>
475 587
476<p>
477<c>equery</c> is capable of giving us a dependency graph for a specified package.
478The dependency graph gives a listing of all the packages that have direct and
479indirect dependencies on the package in question.
480</p> 588<p>
481 589<c>which</c> is a simple script to help you quickly find the file path to an
482<pre caption="Dependency Graph for cdrtools"> 590ebuild. If you pass an unversioned package name, <c>which</c> will return the
483# <i>equery depgraph cdrtools</i> 591path to the newest installable ebuild version, in other words, the ebuild
484Displaying dependencies for app-cdr/cdrtools-2.01_alpha37 592Portage would use if you typed <c>emerge package</c>. Pass in a versioned
485`-- app-cdr/cdrtools-2.01_alpha37 593package to get the path to that ebuild.
486 `-- sys-libs/glibc-2.3.4.20040808 (virtual/libc)
487 `-- sys-kernel/linux-headers-2.4.22 (virtual/os-headers)
488 `-- sys-apps/baselayout-1.10.4
489 `-- sys-apps/sysvinit-2.85-r1
490 `-- sys-apps/gawk-3.1.3-r1
491 `-- sys-apps/util-linux-2.12-r4
492 `-- sys-apps/sed-4.0.9
493 `-- sys-libs/ncurses-5.4-r4
494 `-- sys-apps/pam-login-3.14
495 `-- sys-libs/pam-0.77-r1
496 `-- sys-libs/cracklib-2.7-r10
497 `-- sys-apps/miscfiles-1.3-r1
498 `-- app-arch/gzip-1.3.5-r1
499 `-- sys-apps/portage-2.0.50-r10
500</pre>
501
502<p> 594</p>
503For example, while glibc may be a direct dependency for cdrtools, the linux-headers 595
504are an indirect dependency for cdrtools. 596<pre caption="Displaying the Latest Installable Ebuild Path">
597$ <i>equery which gnome</i>
598/usr/portage/gnome-base/gnome/gnome-2.26.3.ebuild
599</pre>
600
505</p> 601<p>
602Lastly, if none of the above features of <c>equery</c> have answered your
603question, try using <c>which</c> to manually search an ebuild with programs
604like <c>cat</c>, <c>less</c> or <c>grep</c>:
605</p>
606
607<pre caption="Other Useful Ways to Use which">
608$ <i>grep HOMEPAGE $(equery which gentoolkit)</i>
609HOMEPAGE="http://www.gentoo.org/proj/en/portage/tools/index.xml"
610</pre>
611
612<warn>
613Be aware that equery currently changes the format of the output if it is sent
614through a pipe. The piped format is intended to be easier to parse by tools, but
615you can also turn it off by adding the <c>--no-pipe</c> option. If you write
616scripts that employ equery, you should be aware of this.
617</warn>
506 618
507</body> 619</body>
508</section> 620</section>
509</chapter> 621</chapter>
510 622
516 628
517<p> 629<p>
518<c>euse</c> is a tool to see, set and unset USE flags at various places. For 630<c>euse</c> is a tool to see, set and unset USE flags at various places. For
519more information on USE flags, please refer to the <uri 631more information on USE flags, please refer to the <uri
520link="/doc/en/handbook/handbook-x86.xml?part=2&amp;chap=2">USE Flags</uri>. 632link="/doc/en/handbook/handbook-x86.xml?part=2&amp;chap=2">USE Flags</uri>.
521<c>euse -i</c> lists all USE flags. 633Please see <c>euse -h</c> for complete help and all options.
522</p> 634</p>
523 635
524</body> 636</body>
525</section>
526<section> 637</section>
638<section>
527<title>Reading, Setting and Unsetting USE Flags</title> 639<title>Viewing, Setting and Unsetting USE Flags</title>
528<body> 640<body>
529 641
530<p>
531The <c>euse --conf</c> command reads the current USE flags set/unset from
532make.conf.
533</p> 642<p>
534 643The <c>euse -a</c> command reads the current active USE flags and displays
535<pre caption="Viewing Current flags from make.conf"> 644them.
536# <i> euse --conf</i>
537USE setting in make.conf:
538alsa acpi apache2 cups cdr crypt cscope -doc ethereal fbcon gif gimpprint gnome
539gpm gstreamer gtk2 gtkhtml imlib imlib2 innodb -java javascript jpeg libg++ libwww
540mad md5sum mikmod mmx motif mozilla mpeg mpeg4 mysql ncurses oggvorbis odbc
541offensive opengl pam pdflib perl png python quicktime readline sdl spell sse ssl
542svga tcltk tiff truetype usb vanilla X xml2 xmms xosd xv xvid x86 zlib
543</pre>
544
545<p> 645</p>
546Setting a USE flag is done with the help of the <c>euse --enable</c> command 646
547which requires a mandatory flag name argument. If the flag is not already set, 647<note>
548<c>euse</c> appends the USE flag to the end of the current USE flag settings. 648There are 5 &quot;columns&quot; that <c>euse</c> now uses to show whether a
549In case the USE flag is invalid, there is a warning. Removing a USE flag is 649flag is set/unset and where all the flag has been set. The columns are as
550done using the <c>euse --disable</c> command. If an invalid flag is specified, 650follows -- +/-, set in the Environment, set in make.Conf, set in make.Defaults,
551the user is warned suitably. If the flag is present, it is unset with a -flag 651and set in make.Globals. The output looks like [+ECDG].
552in make.conf 652</note>
653
654<pre caption="Viewing all active USE flags">
655# <i>euse -a</i>
656X [+ CD ]
657aalib [+ ]
658acpi [+ C ]
659alsa [+ C ]
660apache2 [+ C ]
661apm [+ D ]
662avi [+ D ]
663berkdb [+ D ]
664bitmap-fonts [+ D ]
665bonobo [+ ]
666cdr [+ C ]
667crypt [+ CD ]
668cscope [+ C ]
669cups [+ CD ]
670curl [+ ]
671emboss [+ D ]
672encode [+ D ]
673esd [+ ]
674fam [+ ]
675fbcon [+ C ]
676firefox [+ C ]
677font-server [+ D ]
678foomaticdb [+ D ]
679fortran [+ D ]
680gd [+ C ]
681gdbm [+ D ]
682gif [+ CD ]
683gimpprint [+ C ]
684gnome [+ CD ]
685gphoto2 [+ ]
686gpm [+ CD ]
687gstreamer [+ C ]
688gtk [+ D ]
689gtkhtml [+ C ]
690guile [+ ]
691imagemagick [+ ]
692imlib [+ CD ]
693innodb [+ ]
694ipv6 [+ D ]
695javascript [+ C ]
696jpeg [+ CD ]
697kde [+ D ]
698ldap [+ ]
699libg++ [+ CD ]
700libwww [+ CD ]
701mad [+ CD ]
702mbox [+ C ]
703md5sum [+ C ]
704mikmod [+ CD ]
705mmx [+ C ]
706motif [+ CD ]
707mp3 [+ ]
708mpeg [+ CD ]
709mpeg4 [+ C ]
710mysql [+ C ]
711ncurses [+ CD ]
712nls [+ D ]
713nvidia [+ C ]
714odbc [+ ]
715offensive [+ ]
716ogg [+ CD ]
717opengl [+ CD ]
718oss [+ D ]
719pam [+ CD ]
720pdflib [+ CD ]
721perl [+ CD ]
722png [+ CD ]
723python [+ CD ]
724qt [+ D ]
725quicktime [+ CD ]
726readline [+ CD ]
727ruby [+ ]
728sdl [+ CD ]
729slang [+ D ]
730spell [+ CD ]
731sse [+ C ]
732ssl [+ CD ]
733svga [+ CD ]
734tcltk [+ C ]
735tcpd [+ D ]
736tiff [+ C ]
737truetype [+ CD ]
738usb [+ C ]
739vanilla [+ C ]
740x86 [+ C ]
741xml [+ ]
742xosd [+ C ]
743xv [+ CD ]
744xvid [+ C ]
745zlib [+ CD ]
746</pre>
747
553</p> 748<p>
749Similarly you can use the <c>euse -a -g</c> command to only view active global
750USE flags. The <c>euse -a -l</c> command does the same for active local USE
751flags.<c>-g</c> &amp; <c>-l</c> are suboptions to <c>euse</c> and need an
752option before them (like <c>-a</c>) to function correctly.
753</p>
554 754
755<pre caption="Viewing active local USE flags">
756# <i>euse -a -l</i>
757bitmap-fonts [+ D ]
758font-server [+ D ]
759fortran [+ D ]
760gimpprint [+ C ]
761md5sum [+ C ]
762mpeg4 [+ C ]
763nvidia [+ C ]
764offensive [+ ]
765truetype [+ CD ]
766</pre>
767
768<p>
769We can also use <c>euse</c> to set or unset use flags. The commands used for
770this are <c>euse -E flagname</c> (enable a flag) and <c>euse -D flagname</c>
771(disable a flag).
772</p>
773
774<warn>
775Do not use the <c>euse -E</c> or <c>euse -D</c> commands by themselves (without
776a flag). It will set/unset ALL USE flags in <c>/etc/make.conf</c>. Although a
777backup is kept at <path>/etc/make.conf.euse_backup</path>, please be careful
778while using <c>euse -E</c> or <c>euse -D</c>.
779</warn>
780
555<pre caption="Setting a USE Flag, 3dfx"> 781<pre caption="Setting and Unsetting USE flags">
782<comment>(Enabling a USE Flag)</comment>
556# <i>euse --enable 3dfx</i> 783# <i> euse -E 3dfx</i>
557USE setting in make.conf after enabling: 784/etc/make.conf was modified, a backup copy has been placed at /etc/make.conf.euse_backup
558alsa acpi apache2 cups cdr crypt cscope -doc ethereal fbcon gif gimpprint gnome
559gpm gstreamer gtk2 gtkhtml imlib imlib2 innodb -java javascript jpeg libg++ libwww
560mad md5sum mikmod mmx motif mozilla mpeg mpeg4 mysql ncurses oggvorbis odbc
561offensive opengl pam pdflib perl png python quicktime readline sdl spell sse ssl
562svga tcltk tiff truetype usb vanilla X xml2 xmms xosd xv xvid x86 zlib 3dfx
563</pre>
564 785
565<pre caption="Unsetting a USE Flag, 3dfx"> 786<comment>(/etc/make.conf after the command)</comment>
787USE="alsa acpi apache2 -arts cups cdr crypt cscope -doc fbcon \
788 firefox gd gif gimpprint gnome gpm gstreamer gtkhtml imlib \
789 innodb -java javascript jpeg libg++ libwww mad mbox md5sum \
790 mikmod mmx motif mpeg mpeg4 mysql ncurses nvidia \
791 ogg odbc offensive opengl pam pdflib perl png python \
792 quicktime readline sdl spell sse ssl svga tcltk tiff truetype usb \
793 vanilla X xosd xv xvid x86 zlib 3dfx"
794
795<comment>(Disabling the USE Flag)</comment>
566# <i>euse --disable 3dfx</i> 796# <i> euse -D 3dfx</i>
567USE setting in make.conf after disabling: 797/etc/make.conf was modified, a backup copy has been placed at /etc/make.conf.euse_backup
568alsa acpi apache2 cups cdr crypt cscope -doc ethereal fbcon gif gimpprint gnome 798
569gpm gstreamer gtk2 gtkhtml imlib imlib2 innodb -java javascript jpeg libg++ libwww 799<comment>(/etc/make.conf after the command)</comment>
570mad md5sum mikmod mmx motif mozilla mpeg mpeg4 mysql ncurses oggvorbis odbc 800USE="alsa acpi apache2 -arts cups cdr crypt cscope -doc fbcon \
571offensive opengl pam pdflib perl png python quicktime readline sdl spell sse ssl 801 firefox gd gif gimpprint gnome gpm gstreamer gtkhtml imlib \
572svga tcltk tiff truetype usb vanilla X xml2 xmms xosd xv xvid x86 zlib -3dfx 802 innodb -java javascript jpeg libg++ libwww mad mbox md5sum \
803 mikmod mmx motif mpeg mpeg4 mysql ncurses nvidia \
804 ogg odbc offensive opengl pam pdflib perl png python \
805 quicktime readline sdl spell sse ssl svga tcltk tiff truetype usb \
806 vanilla X xosd xv xvid x86 zlib -3dfx"
573</pre> 807</pre>
574 808
575<note> 809<note>
576<c>euse</c> does not physically remove the flag from make.conf. It just adds a 810<c>euse</c> does not physically remove the flag from make.conf. It just adds a
577- (minus) before the flag to unset it. You may have to manually clean up your 811- (minus) before the flag to unset it. You may have to manually clean up your
590 824
591<p> 825<p>
592This tool is Gentoo's Reverse Dependency rebuilder. It will scan your installed 826This tool is Gentoo's Reverse Dependency rebuilder. It will scan your installed
593ebuilds to find packages that have become broken as a result of an upgrade of a 827ebuilds to find packages that have become broken as a result of an upgrade of a
594package they depend on. It can emerge those packages for you but it can also 828package they depend on. It can emerge those packages for you but it can also
595happen that a given package does not work anymore with the currently installed 829happen that a given package does not work any more with the currently installed
596dependencies, in which case you should upgrade the broken package to a more 830dependencies, in which case you should upgrade the broken package to a more
597recent version. revdep-rebuild will pass flags to emerge which lets you use the 831recent version. revdep-rebuild will pass flags to emerge which lets you use the
598<c>--pretend</c> flag to see what is going to be emerged again before you go any 832<c>--pretend</c> flag to see what is going to be emerged again before you go any
599further. 833further.
600</p> 834</p>
601 835
602<pre caption="Running revdep-rebuild in pretend mode"> 836<pre caption="Running revdep-rebuild in pretend mode">
603# <i>revdep-rebuild -p</i> 837# <i>revdep-rebuild -p</i>
604 838
839 * Configuring search environment for revdep-rebuild
840
605Checking reverse dependencies... 841 * Checking reverse dependencies
606Packages containing binaries and libraries broken by any package update, 842 * Packages containing binaries and libraries broken by a package update
607will be recompiled. 843 * will be emerged.
608 844
609Collecting system binaries and libraries... done. 845 * Collecting system binaries and libraries
610 (/root/.revdep-rebuild.1_files) 846 * Generated new 1_files.rr
611
612Collecting complete LD_LIBRARY_PATH... done. 847 * Collecting complete LD_LIBRARY_PATH
613 (/root/.revdep-rebuild.2_ldpath) 848 * Generated new 2_ldpath.rr
614
615Checking dynamic linking consistency... 849 * Checking dynamic linking consistency
616 broken /usr/lib/ao/plugins-2/libarts.so (requires libartsc.so.0) 850[ 48% ] * broken /usr/lib/gstreamer-0.10/libgsttaglib.la (requires /usr/lib/libtag.la)
617 broken /usr/lib/kde3/libkpresenterpart.so (requires libartskde.so.1 libqtmcop.so.1 851[ 64% ] * broken /usr/lib/libgdkglext-x11-1.0.la (requires /usr/lib/libGLU.la)
618 libsoundserver_idl.so.1 libkmedia2_idl.so.1 libartsflow.so.1 libartsflow_idl.so.1 libmcop.so.1) 852[ 67% ] * broken /usr/lib/libgtkglext-x11-1.0.la (requires /usr/lib/libGLU.la)
619 broken /usr/lib/ruby/site_ruby/1.8/i686-linux/fox.so (requires libFOX-1.0.so.0) 853[ 85% ] * broken /usr/lib/python2.6/site-packages/gtk-2.0/gtk/gdkgl/_gdkgl.la (requires /usr/lib/libGLU.la)
620 broken /usr/lib/xine/plugins/1.0.0/xineplug_ao_out_arts.so (requires libartsc.so.0) 854 * broken /usr/lib/python2.6/site-packages/gtk-2.0/gtk/gtkgl/_gtkgl.la (requires /usr/lib/libGLU.la)
621 broken /usr/lib/perl5/vendor_perl/5.8.0/i686-linux/auto/SDL_perl/SDL_perl.so (requires libSDL_gfx.so.0) 855[ 97% ] * broken /usr/qt/3/lib/libqt-mt.la (requires -lpng)
622 broken /usr/lib/libloudmouth-1.so.0.0.0 (requires libgnutls.so.10) 856[ 100% ]
623 broken /usr/bin/k3b (requires libartskde.so.1 libqtmcop.so.1 libsoundserver_idl.so.1 libkmedia2_idl.so.1 857 * Generated new 3_broken.rr
624 libartsflow.so.1 libartsflow_idl.so.1 libmcop.so.1) 858 * Assigning files to packages
625 broken /usr/bin/lua (requires libhistory.so.4) 859 * /usr/lib/gstreamer-0.10/libgsttaglib.la -> media-plugins/gst-plugins-taglib
626 broken /usr/bin/lyx (requires libAiksaurus-1.0.so.0) 860 * /usr/lib/libgdkglext-x11-1.0.la -> x11-libs/gtkglext
627 broken /usr/bin/luac (requires libhistory.so.4) 861 * /usr/lib/libgtkglext-x11-1.0.la -> x11-libs/gtkglext
628 broken /usr/bin/avidemux2 (requires libartsc.so.0) 862 * /usr/lib/python2.6/site-packages/gtk-2.0/gtk/gdkgl/_gdkgl.la -> dev-python/pygtkglext
629 broken /usr/bin/pptout (requires libxml++-0.1.so.11) 863 * /usr/lib/python2.6/site-packages/gtk-2.0/gtk/gtkgl/_gtkgl.la -> dev-python/pygtkglext
630 broken /usr/bin/xml2ps (requires libxml++-0.1.so.11) 864 * /usr/qt/3/lib/libqt-mt.la -> x11-libs/qt
631 done. 865 * Generated new 4_raw.rr and 4_owners.rr
632 (/root/.revdep-rebuild.3_rebuild) 866 * Cleaning list of packages to rebuild
633 867 * Generated new 4_pkgs.rr
634Assigning files to ebuilds... done. 868 * Assigning packages to ebuilds
635 (/root/.revdep-rebuild.4_ebuilds) 869 * Generated new 4_ebuilds.rr
636
637Evaluating package order... done. 870 * Evaluating package order
638 (/root/.revdep-rebuild.5_order) 871 * Generated new 5_order.rr
639
640All prepared. Starting rebuild... 872 * All prepared. Starting rebuild
641emerge --oneshot --nodeps -p =app-cdr/k3b-0.11.14 =app-office/koffice-1.3.2 =app-office/lyx-1.3.4 \ 873emerge --oneshot --pretend dev-python/pygtkglext:0
642 =app-office/passepartout-0.2 =dev-lang/lua-5.0.2 =dev-ruby/fxruby-1.0.29 =media-libs/libao-0.8.5 \ 874media-plugins/gst-plugins-taglib:0.10
643 =media-libs/xine-lib-1_rc5-r3 =media-video/avidemux-2.0.26 =net-libs/loudmouth-0.16 875x11-libs/gtkglext:0
876x11-libs/qt:3
644 877
645These are the packages that I would merge, in order: 878These are the packages that would be merged, in order:
646 879
647Calculating dependencies ...done! 880Calculating dependencies... done!
648[ebuild R ] app-cdr/k3b-0.11.14 881[ebuild R ] media-plugins/gst-plugins-taglib-0.10.17
649[ebuild R ] app-office/koffice-1.3.2 882[ebuild R ] x11-libs/gtkglext-1.2.0
650[ebuild R ] app-office/lyx-1.3.4 883[ebuild R ] x11-libs/qt-3.3.8b-r2
651[ebuild R ] app-office/passepartout-0.2 884[ebuild R ] dev-python/pygtkglext-1.1.0
652[ebuild R ] dev-lang/lua-5.0.2
653[ebuild R ] dev-ruby/fxruby-1.0.29
654[ebuild R ] media-libs/libao-0.8.5
655[ebuild R ] media-libs/xine-lib-1_rc5-r3
656[ebuild R ] media-video/avidemux-2.0.26
657[ebuild R ] net-libs/loudmouth-0.16
658
659Now you can remove -p (or --pretend) from arguments and re-run revdep-rebuild. 885 * Now you can remove -p (or --pretend) from arguments and re-run revdep-rebuild.
660</pre> 886</pre>
661 887
662<p> 888<p>
663If you need to rebuild some packages, you may run <c>revdep-rebuild</c> without 889If you need to rebuild some packages, you may run <c>revdep-rebuild</c> without
664the <c>-p</c> flag and the listed packages will be emerged again. 890the <c>-p</c> flag and the listed packages will be emerged again.
665</p> 891</p>
666 892
667</body> 893</body>
668</section> 894</section>
669
670<section> 895<section>
671<title>glsa-check</title> 896<title>glsa-check</title>
672<body> 897<body>
673 898
674<p> 899<p>
675<c>glsa-check</c> is mainly a test tool that keeps track of the various GLSA's 900<c>glsa-check</c> is mainly a test tool that keeps track of the various GLSA's
676(Gentoo Linux Security Advisory) and will eventually be integrated into 901(Gentoo Linux Security Advisory) and will eventually be integrated into
677<c>emerge</c> and <c>equery</c>. For more information, please visit the <uri 902<c>emerge</c> and <c>equery</c>.
678link="/proj/en/portage/glsa-integration.xml">Portage GLSA Integration
679Page</uri>.
680</p> 903</p>
904
905</body>
906</section>
907<section>
908<title>eread</title>
909<body>
910
911<p>
912<c>eread</c> is a simple utility to display elog files produced by
913>=<c>portage-2.1</c>. You can set the saving of elog files by setting a couple
914of variables in <path>/etc/make.conf</path>:
915</p>
916
917<pre caption="Enabling elog in /etc/make.conf">
918PORTAGE_ELOG_CLASSES="log"
919PORTAGE_ELOG_SYSTEM="save"
920</pre>
921
922<note>
923This is just one way of saving elog messages. For more information on how
924Portage's elog system works, please refer to the appropriate page in the <uri
925link="/doc/en/handbook/handbook-x86.xml?part=3&amp;chap=1#doc_chap4">Portage
926Handbook</uri>.
927</note>
928
929<p>
930Once you've set up elog to your satisfaction, just run <c>eread</c> to view your
931log files.
932</p>
933
934<pre caption="Using eread">
935$ <i>eread</i>
936
937This is a list of portage log items. Choose a number to view that file or type
938q to quit.
939
9401) app-portage:gentoolkit-0.2.4_pre2:20070320-000256.log
9412) app-portage:gentoolkit-0.2.4_pre2:20070320-000258.log
9423) app-portage:gentoolkit-0.2.4_pre2:20070320-000319.log
9434) app-portage:gentoolkit-0.2.3:20070320-000408.log
944Choice?
945</pre>
946
947<p>
948Select a number and the file will be displayed using the paging program
949specified in the PAGER environment variable. If PAGER is not set, it will use
950<c>less</c>.
951</p>
952
953<p>
954After displaying the elog item, you will be prompted if you want to delete the
955file.
956</p>
957
958</body>
959</section>
960<section>
961<title>eclean</title>
962<body>
963
964<p>
965<c>eclean</c> is a tool to remove old source files and old binary packages from
966your system.
967</p>
968
969<p>
970When you build and install packages, the source files are downloaded and
971preserved in DISTDIR, usually <path>/usr/portage/distfiles</path>. This can
972accumulate several gigs of material over time if you don't clean it
973periodically. You can run <c>eclean-dist</c> to clean only source files from
974DISTDIR.
975</p>
976
977<p>
978You can create archives of installed packages by using <c>quickpg</c> or
979FEATURES="buildpkg". These archived packages are kept in PKGDIR, usually
980<path>/usr/portage/packages</path>. When you no longer need to keep them around,
981or if they're too old, you can run <c>eclean-pkg</c> to remove them from PKGDIR.
982It's a good way to ensure that any binary packages you have are only the latest
983versions.
984</p>
985
986<p>
987For more information on <c>eclean</c> and tips on maintaining a cruft-free
988system, please read <c>man eclean</c>.
989</p>
681 990
682</body> 991</body>
683</section> 992</section>
684</chapter> 993</chapter>
685
686</guide> 994</guide>

Legend:
Removed from v.1.17  
changed lines
  Added in v.1.35

  ViewVC Help
Powered by ViewVC 1.1.20