From 53f820a855cc9c817424c4705ca6f7b72b63e31e Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Tue, 27 Jul 2010 13:19:00 -0700 Subject: [PATCH] Make the world-candidate package set attribute default to False, since [usersets] is the only one for which it is True in the default config. --- cnf/sets/portage.conf | 12 +----------- doc/config/sets.docbook | 2 -- pym/portage/sets/__init__.py | 8 ++++---- pym/portage/sets/base.py | 2 +- 4 files changed, 6 insertions(+), 18 deletions(-) diff --git a/cnf/sets/portage.conf b/cnf/sets/portage.conf index 87280cef6..2a66512e7 100644 --- a/cnf/sets/portage.conf +++ b/cnf/sets/portage.conf @@ -7,18 +7,15 @@ # Not much that could be changed for world, so better leave it alone [world] class = portage.sets.base.DummyPackageSet -world-candidate = False packages = @selected @system # Not much that could be changed for world, so better leave it alone [selected] class = portage.sets.files.WorldSelectedSet -world-candidate = False # Same as for world, though later portage versions might use a different class [system] class = portage.sets.profiles.PackagesSystemSet -world-candidate = False # For security there are multiple classes available, but differences are # rather small (normally there should be no visible difference): @@ -29,7 +26,6 @@ world-candidate = False # - SecuritySet: include all GLSAs [security] class = portage.sets.security.NewAffectedSet -world-candidate = False # A superset of the classic world target, a set created # by this class contains SLOT atoms to match all installed packages. Note that @@ -37,7 +33,6 @@ world-candidate = False # uninstallation of blocked packages. [installed] class = portage.sets.dbapi.EverythingSet -world-candidate = False # The following treats all files in /etc/portage/sets as a package set called # '$filename'. @@ -45,40 +40,35 @@ world-candidate = False class = portage.sets.files.StaticFileSet multiset = true directory = %(PORTAGE_CONFIGROOT)setc/portage/sets +world-candidate = True # Set to rebuild all packages that need a preserved lib that only remains due # to FEATURES=preserve-libs [preserved-rebuild] class = portage.sets.libs.PreservedLibraryConsumerSet -world-candidate = False # Installed ebuilds that inherit from known live eclasses. [live-rebuild] class = portage.sets.dbapi.VariableSet -world-candidate = False variable = INHERITED includes = bzr cvs darcs git mercurial subversion tla # Installed packages that own files inside /lib/modules. [module-rebuild] class = portage.sets.dbapi.OwnerSet -world-candidate = False files = %(ROOT)slib/modules # Binary packages that have a different build time from a currently # installed package of the exact same version. [rebuilt-binaries] class = portage.sets.dbapi.RebuiltBinaries -world-candidate = False # Installed packages for which the highest visible ebuild # version is lower than the currently installed version. [downgrade] class = portage.sets.dbapi.DowngradeSet -world-candidate = False # Installed packages for which there are no visible ebuilds # corresponding to the same $CATEGORY/$PN:$SLOT. [unavailable] class = portage.sets.dbapi.UnavailableSet -world-candidate = False diff --git a/doc/config/sets.docbook b/doc/config/sets.docbook index edded8937..866261f3f 100644 --- a/doc/config/sets.docbook +++ b/doc/config/sets.docbook @@ -70,13 +70,11 @@ # The classic world set [world] class = portage.sets.base.DummyPackageSet - world-candidate = False packages = @selected @system # The selected set [selected] class = portage.sets.files.WorldSelectedSet - world-candidate = False # The classic system set [system] diff --git a/pym/portage/sets/__init__.py b/pym/portage/sets/__init__.py index ab9869cee..dc6661480 100644 --- a/pym/portage/sets/__init__.py +++ b/pym/portage/sets/__init__.py @@ -113,8 +113,8 @@ class SetConfig(object): self.errors.append(_("Redefinition of set '%s' (sections: '%s', '%s')") % (x, self.psets[x].creator, sname)) newsets[x].creator = sname if parser.has_option(sname, "world-candidate") and \ - not parser.getboolean(sname, "world-candidate"): - newsets[x].world_candidate = False + parser.getboolean(sname, "world-candidate"): + newsets[x].world_candidate = True self.psets.update(newsets) else: self.errors.append(_("Section '%(section)s' is configured as multiset, but '%(class)s' " @@ -132,8 +132,8 @@ class SetConfig(object): self.psets[setname] = setclass.singleBuilder(optdict, self.settings, self.trees) self.psets[setname].creator = sname if parser.has_option(sname, "world-candidate") and \ - not parser.getboolean(sname, "world-candidate"): - self.psets[setname].world_candidate = False + parser.getboolean(sname, "world-candidate"): + self.psets[setname].world_candidate = True except SetConfigError as e: self.errors.append(_("Configuration error in section '%s': %s") % (sname, str(e))) continue diff --git a/pym/portage/sets/base.py b/pym/portage/sets/base.py index f54c5436f..f2e745157 100644 --- a/pym/portage/sets/base.py +++ b/pym/portage/sets/base.py @@ -26,7 +26,7 @@ class PackageSet(object): self._loading = False self.errors = [] self._nonatoms = set() - self.world_candidate = True + self.world_candidate = False def __contains__(self, atom): self._load() -- 2.26.2