root/releases/pkgcore/0.2.4/doc/pmerge-usage.rst @ ferringb%2540gmail.com-20070214161425-06l8x7r2le6edncb

Revision ferringb%2540gmail.com-20070214161425-06l8x7r2le6edncb, 7.1 KB (checked in by Brian Harring <ferringb@…>, 2 years ago)

formatting tweak

Line 
1Portage Differences
2+++++++++++++++++++
3
4Currently portage handles all actions primarily through one script; emerge.
5pkgcore breaks this functionality down into 3 scripts: pmerge, pmaint, and
6pquery.
7
8Pmerge
9======
10
11pmerge is fairly similar to emerge in most usage instances:
12
13Basic Usage
14-----------
15
16``pmerge -us world``
17  Update world; don't try to update dependencies for already installed
18  packages.
19``pmerge -uDs world``
20  Update world, trying to update all encountered dependencies/packages.
21``pmerge -p dev-util/bzrtools``
22  Pretend to install bzrtools
23``pmerge -C \<sys-kernel/gentoo-sources-2.6.19``
24  Remove gentoo-sources less than 2.6.19
25``pmerge --clean``
26  Remove unused packages.
27
28  **Warning:** This can break your system if
29  incorrectly used. Check with --pretend before running it.
30 
31  Additionally, it currently defaults to identifying only whats
32  required for world/system; installed packages don't require their build
33  depends to be satisfied, as such --clean will identify them for removal if
34  they're not runtime depended upon.
35 
36  If you want --clean to preserve your build depends, use the -B option.
37
38
39Sets
40----
41
42Available sets are dependant upon your configuration- majority of users still
43use make.conf configuration, which has five default sets:
44
45system, world, installed, version-installed, vuln
46
47system:
48
49world:
50
51  These two are the same as in portage.
52
53
54version-installed:
55
56  versioned-installed is a set of all cpv's from the vdb. This is useful for
57  --emptytree.
58
59  Example:
60    If you have app/foo-1 and bar/dar-2 installed (and just those),
61    versioned-installed would be a set containing -app/foo-1 and -bar/dar-2.
62
63
64installed:
65
66  installed is an unversioned set, but is slotted. Unlike version-installed,
67  installed can be used for "system update". Using ``pmerge -us installed``
68  over ``pmerge -u -s system -s`` world also has the advantage that
69  dependency-orphaned packages are updated.
70
71  Example:
72    If you had app/foo-1 slot 1, app/foo-2 slot 2, installed would be a set
73    containing would be app/foo:1 app/foo:2.
74
75
76vuln:
77
78  Packages that are vulnerable to security bugs.
79
80Custom Sets
81-----------
82
83Doing this for a make.conf configuration is pretty simple. Just add a file
84to /etc/portage/sets, containing a list of atoms. The set name is the filename.
85
86Example: Making a kde set:
87  ``pquery 'kde-*/*' --no-version > /etc/portage/sets/kde-set``
88  ``pmerge -uDs kde-set``
89
90Portage Equivalents
91-------------------
92
93~~~~~~~~~~~~~~~
94New in pkgcore:
95~~~~~~~~~~~~~~~
96
97--ignore-failures:
98
99  ignore resolution/build failures, skipping to the next step.  Think of it
100  as the equiv of --skipfirst, just without the commandline interuption.
101 
102  Goes without saying, this feature should be used with care- primarily useful
103  for a long chain of non critical updates, where a failure is a non issue.
104 
105  Good example of usage is if you want to build mozilla-firefox and openoffice
106  during the night- both take a long while to build (including their deps), and
107  the user is after getting as many packages built for the targets as possible,
108  rather then having the 5th build out of 80 bail out even attempting the other
109  75.
110 
111  Long term, this feature will likely be replaced with a more fine tuned option.
112
113
114--preload-vdb-state:
115
116  This preloads the installed packages database causing the resolver to work
117  with a complete graph, disallowing actions that confict with installed
118  packages. If it's disabled, it's possible for the requested action to
119  conflict with already installed dependencies that aren't involved in the
120  graph of the requested operation.
121
122~~~~~~~~~~~~~~~~~
123Moved, in pmerge:
124~~~~~~~~~~~~~~~~~
125
126--depclean:
127
128  --clean
129
130
131--with-bdeps:
132
133  --with-built-depends
134
135~~~~~~~~~~~~~~~~~~~~
136Moved out of pmerge:
137~~~~~~~~~~~~~~~~~~~~
138
139--regen:
140
141  See regen_
142
143~~~~~~~~~~~~~~~
144No equivalents:
145~~~~~~~~~~~~~~~
146
147
148--info:
149
150  pconfig is the closest equivalent at the moment- rather verbose.
151
152--config:
153
154  This may be implemented in pmaint in the future, possible 0.3.
155
156--prune:
157
158  Currently not implemented; portages implementation of it ignores slots,
159  trying to force a max version for each package- this is problematic however
160  since it can remove needed slotted packages that are of a lesser version.
161 
162  Any package that requires slotting (automake for example) generally will
163  be screwed up by emerge --prunes behaviour.
164
165  Long term intention is to implement this functionality safely- effectively
166  try to minimize the resolved dependency graph to minimal number of packages
167  involved.
168
169--resume:
170
171--skipfirst:
172
173  Not yet implemented.
174
175--metadata:
176
177  Not implemented- pkgcore doesn't need cache localization.
178
179  If the user is after copying cache data around, pclone_cache can be used.
180
181--fetch-all-uri:
182
183  Not yet implemented.
184
185--buildpkg:
186
187  Not yet implemented.
188
189--getbinpkg:
190
191--getbinpkgonly:
192
193  Remote Binhost v1 support will not be implemented in pkgcore, instead
194  favoring the genpkgindex approach Ned Ludd (solar) has created.
195 
196  Reasoning for this comes down to two main reasons-
197
198  * design of v1 allows for collisions in the package namespace, category
199    is ignored.  Further, this collision isn't easily detectable- pulling
200    mysql-5.0 from the server may get you virtual/mysql-5.0 or dev-db/mysql-5.0
201
202  * design is god awfully slow.  To get the metadata for a binpkg from an HTTP
203    server, requires (roughly) a HEAD request (tbz2 length), ranged GET request
204    to grab the last 16 bytes for the XPAK segment start, another ranged
205    request to pull the metadata.
206   
207    That's per package.  Can cache, but the roundtrips add up quickly.
208 
209  The package namespace collision issue is the main reason why v1 support will
210  not be added to pkgcore; v2 addresses both issues thus is the route we'll go.
211
212--tree:
213
214  This is formatter dependant, it may be included in 0.3.
215
216--alphabetical:
217
218--columns:
219
220  These won't be implemented in pkgcore.
221
222--changelog:
223
224  At some point will be accessible via pquery.
225
226Regen
227-----
228
229To regenerate run ``pregen.py <repo-name> -j <# of processors>``, which scales
230around .9x linear per proc, at least through 4x for testing. This will
231probably be folded into pmaint by 0.3.
232
233Searching
234=========
235
236All search in pkgcore is done through pquery. See
237pquery-usage_ for how to use pquery.
238
239Syncing
240=======
241
242``pmaint sync <reponame>`` will sync a repository. See config doc for syncing
243info.  No reponame provided, tries to sync all repositories.
244
245Note: You should look at pmaint --help, because at some point, the 'commands'
246for pmaint will be variable and dependant upon the repositories available,
247akin to how bzr's command set changes dependant on what plugins you've enabled
248(commonly bzrtools).
249
250Quickpkg
251========
252
253``pmaint copy -s vdb -t binpkg sys-apps/portage --force`` will make a binpkg
254(like quickpkg).
255
256Note: this is not a --buildpkg equiv, as buildpkg grabs a package prior to
257any preinst mangling, so a quickpkg'ed binpkg's contents can differ from a
258binpkg built with --buildpkg.
259
260Handy backup of existing system-
261``pmaint copy -s vdb -t binpkg '*' --force``
262
263Alternatively, generating binpkgs only if they don't exist-
264``pmaint copy -s vdb -t binpkg '*' --force --ignore-existing``
265
266.. _pquery-usage: pquery-usage.rst
Note: See TracBrowser for help on using the browser.