portage-2.2
-------------
+* It is now possible to use `emerge <file>` to reinstall the package that
+ installed a particular file. Package contents entries are indexed to
+ improve performance. A command such as `emerge /lib/modules` can serve
+ as a decent substitute for module-rebuild.
* Namespace sanitizing: move all portage related code into portage.* namespace,
rename portage_foo modules to portage.foo (but keep symlinks for compability)
* Add license visibility filtering (GLEP 23)
-* Enable "echo" and "save_summary" elog modules by default
-* Fix -* handling in package.keywords to work as intended (reset the accepted
- keywords list), also see RELEASE-NOTES.
* Experimental support for preserving old library files on package upgrades
based on FEATURES=preserve-libs
-* Make elog functionality available to python code
* Add support for news items (GLEP 42)
* Add support for generic package sets (also see RELEASE-NOTES)
portage-2.1.5
-==================================
+-------------
+* Blockers are now resolved automatically in many more cases
+ than before. When it's safe, blocked packages are uninstalled
+ automatically so that users are no longer inconvenienced with the
+ task. Automatically uninstalled packages are displayed in the merge
+ list, marked "uninstall" and highlighted in red. With the --tree
+ option enabled, it's possible to see which package(s) caused other
+ ones to be automatically uninstalled.
* The dependency resolver now has a feedback mechanism that helps make atom
selections more consistent with previous selections that have been added to
the graph. This solves some common cases of bug #1343.
* After the initial setup phase, the original ebuild and eclasses are no
longer needed because the same ebuild environment is reused for the
entire lifecycle of the package, including uninstallation.
+* The emerge --search action supports searching of both installed and binary packages
+ The --usepkg and --usepkgonly options control which repositories are searched.
portage-2.1.3
-------------
* PDEPEND is now installed as soon as possible so that it behaves more like
RDEPEND. This makes PDEPEND more useful for breaking the dependency cycles
that are sometimes triggered by RDEPEND and DEPEND.
+* Enable "echo" and "save_summary" elog modules by default
+* Fix -* handling in package.keywords to work as intended (reset the accepted
+ keywords list), also see RELEASE-NOTES.
+* Make elog functionality available to python code
portage-2.1.2
-------------
used without the prefix)
- they may currently only include simple and versioned atoms or other sets, use
conditionals or any-of constructs aren't possible yet
- - emerge makes no difference atm whether you pass a setname or all atoms contained
- in the set to it, this means that without options packages will be remerged if
- already installed, or in the case of --unmerge all atoms in a set will be
- unmerged even if they are depended upon by other packages. This may change in
- future versions.
- sets can be referenced either in other file-based sets or as argument to emerge, but
not in ebuilds, config files or other tools at this time.
+ - packages won't be unmerged if they are referenced by an installed package
+ set (with the exception of the world set, and installed being determined
+ by the world_sets file).
* "world" does no longer include "system" unconditionally, but you can add
- "@system" to the worldfile to restore the old state.
+ "@system" to the world_sets file to restore the old state.
portage-2.1.5
==================================
variable to be accessed by pkg_postinst when it is called. Bug #226505
tracks all issues related to this phase execution order change.
-* Blockers are now resolved automatically in many more cases
- than before. When it's safe, blocked packages are uninstalled
- automatically so that users are no longer inconvenienced with the
- task. Automatically uninstalled packages are displayed in the merge
- list, marked "uninstall" and highlighted in red. With the --tree
- option enabled, it's possible to see which package(s) caused other
- ones to be automatically uninstalled.
-
* The metadata-transfer feature is now disabled by default. This disables the
"Updating Portage cache" routine that used to run at the tail end of each
`emerge --sync` operation. If you use something like the sqlite module and
* There is no need to have a complete portage tree available when installing binary
packages or uninstalling packages, but a warning message will still be displayed if
it appears that a valid profile is not available.
-* The emerge --search action supports searching of both installed and binary packages
- The --usepkg and --usepkgonly options control which repositories are searched.
portage-2.1.3
==================================
.SH "SYNOPSIS"
.TP
.BR emerge
-[\fIoptions\fR] [\fIaction\fR] [\fIebuild\fR | \fItbz2file\fR | \fI@set\fR | \fIatom\fR] ...
+[\fIoptions\fR] [\fIaction\fR] [\fIebuild\fR | \fItbz2file\fR | \fIfile\fR | \fI@set\fR | \fIatom\fR] ...
.TP
.BR emerge
\fB\-\-sync\fR | \fB\-\-version\fR
<package>\-<version>.ebuild package\fR or \fBemerge \-\-buildpkg
[category/]<package>\fR or \fBquickpkg /var/db/pkg/<category>/<package>\fR.
.TP
+.BR file
+A \fIfile\fR must be a file or directory that has been installed by one or
+more packages. For directories that are owned by multiple packages, all
+owning packages to be selected. See the portageq(1) owners command if you
+would like to query the owners of one or more files or directories.
+.TP
.BR set
A \fIset\fR is a convenient shorthand for a large group of
packages. Two sets are currently always available: \fBsystem\fR
pkgsettings = self.pkgsettings[myroot]
args = []
onlydeps = "--onlydeps" in self.myopts
+ lookup_owners = []
for x in myfiles:
ext = os.path.splitext(x)[1]
if ext==".tbz2":
portage.writemsg(("\n\n!!! '%s' does not start with" + \
" $ROOT.\n") % x, noiselevel=-1)
return 0, []
- relative_path = x[len(myroot):]
- owner_cpv = None
- for pkg, relative_path in \
- real_vardb._owners.iter_owners([relative_path]):
- owner_cpv = pkg.mycpv
- break
-
- if owner_cpv is None:
- portage.writemsg(("\n\n!!! '%s' is not claimed " + \
- "by any package.\n") % x, noiselevel=-1)
- return 0, []
- slot = vardb.aux_get(owner_cpv, ["SLOT"])[0]
- if not slot:
- # portage now masks packages with missing slot, but it's
- # possible that one was installed by an older version
- atom = portage.cpv_getkey(owner_cpv)
- else:
- atom = "%s:%s" % (portage.cpv_getkey(owner_cpv), slot)
- args.append(AtomArg(arg=atom, atom=atom,
- root_config=root_config))
+ # Queue these up since it's most efficient to handle
+ # multiple files in a single iter_owners() call.
+ lookup_owners.append(x)
else:
if x in ("system", "world"):
x = SETPREFIX + x
args.append(AtomArg(arg=x, atom=atom,
root_config=root_config))
+ if lookup_owners:
+ relative_paths = []
+ search_for_multiple = False
+ if len(lookup_owners) > 1:
+ search_for_multiple = True
+
+ for x in lookup_owners:
+ if not search_for_multiple and os.path.isdir(x):
+ search_for_multiple = True
+ relative_paths.append(x[len(myroot):])
+
+ owners = set()
+ for pkg, relative_path in \
+ real_vardb._owners.iter_owners(relative_paths):
+ owners.add(pkg.mycpv)
+ if not search_for_multiple:
+ break
+
+ if not owners:
+ portage.writemsg(("\n\n!!! '%s' is not claimed " + \
+ "by any package.\n") % lookup_owners[0], noiselevel=-1)
+ return 0, []
+
+ for cpv in owners:
+ slot = vardb.aux_get(cpv, ["SLOT"])[0]
+ if not slot:
+ # portage now masks packages with missing slot, but it's
+ # possible that one was installed by an older version
+ atom = portage.cpv_getkey(cpv)
+ else:
+ atom = "%s:%s" % (portage.cpv_getkey(cpv), slot)
+ args.append(AtomArg(arg=atom, atom=atom,
+ root_config=root_config))
+
if "--update" in self.myopts:
# Enable greedy SLOT atoms for atoms given as arguments.
# This is currently disabled for sets since greedy SLOT
if "--quiet" not in myopts:
portage.deprecated_profile_check()
+ for root in trees:
+ if "porttree" in trees[root]:
+ db = trees[root]["porttree"].dbapi
+ paths = (db.mysettings["PORTDIR"]+" "+db.mysettings["PORTDIR_OVERLAY"]).split()
+ repos = db.getRepositories()
+ for r in repos:
+ p = db.getRepositoryPath(r)
+ try:
+ paths.remove(p)
+ except ValueError:
+ pass
+ for p in paths:
+ writemsg("WARNING: repository at %s is missing a repo_name entry\n" % p)
+
eclasses_overridden = {}
for mytrees in trees.itervalues():
def shorthelp():
print bold("emerge:")+" the other white meat (command-line interface to the Portage system)"
print bold("Usage:")
- print " "+turquoise("emerge")+" [ "+green("options")+" ] [ "+green("action")+" ] [ "+turquoise("ebuildfile")+" | "+turquoise("tbz2file")+" | "+turquoise("dependency")+" ] [ ... ]"
+ print " "+turquoise("emerge")+" [ "+green("options")+" ] [ "+green("action")+" ] [ "+turquoise("ebuild")+" | "+turquoise("tbz2")+" | "+turquoise("file")+" | "+turquoise("@set")+" | "+turquoise("atom")+" ] [ ... ]"
print " "+turquoise("emerge")+" [ "+green("options")+" ] [ "+green("action")+" ] < "+turquoise("system")+" | "+turquoise("world")+" >"
print " "+turquoise("emerge")+" < "+turquoise("--sync")+" | "+turquoise("--metadata")+" | "+turquoise("--info")+" >"
print " "+turquoise("emerge")+" "+turquoise("--resume")+" [ "+green("--pretend")+" | "+green("--ask")+" | "+green("--skipfirst")+" ]"