portage-2.2
-------------
-
-* Add link level dependency awareness to emerge --depclean and --prune actions
- in order to protect against uninstallation of required libraries.
+* FEATURES=preserve-libs is enabled by default.
* Add support for generic package sets (also see RELEASE-NOTES)
-* Add support for FEATURES=preserve-libs which preserves libraries when the
- sonames change during upgrade or downgrade, and the @preserved-rebuild
- package set which rebuilds consumers of preserved libraries.
-portage-2.1.11.19
+portage-2.1.11.20
-------------
* Add support for EAPI 5. Refer to the PMS EAPI Cheat Sheet, portage's html
docs installed with USE=doc, or `man 5 ebuild` for more info about EAPI 5.
+* Add support for FEATURES=preserve-libs which preserves libraries when the
+ sonames change during upgrade or downgrade, and the @preserved-rebuild
+ package set which rebuilds consumers of preserved libraries.
+* Add link level dependency awareness to emerge --depclean and --prune actions
+ in order to protect against uninstallation of required libraries. Refer to
+ the --depclean-lib-check in the emerge(1) man page.
portage-2.1.11
-------------
# DO NOT CHANGE CODE BEYOND THIS POINT - IT'S NOT NEEDED!
#
-if not portage.const._ENABLE_PRESERVE_LIBS:
- del list_preserved_libs
-
non_commands = frozenset(['elog', 'eval_atom_use',
'exithandler', 'expand_new_virt', 'main',
'usage', 'writemsg', 'writemsg_stdout'])
COLLISION_IGNORE="/lib/modules/* *.py[co]"
UNINSTALL_IGNORE="/lib/modules/*"
-# Enable preserve-libs for testing with portage versions that support it.
-# This setting is commented out for portage versions that don't support it.
-FEATURES="${FEATURES} preserve-libs"
-
# Default chunksize for binhost comms
PORTAGE_BINHOST_CHUNKSIZE="3000"
from portage import eapi_is_supported, _unicode_decode
from portage.cache.cache_errors import CacheError
from portage.const import GLOBAL_CONFIG_PATH
-from portage.const import _ENABLE_DYN_LINK_MAP, _DEPCLEAN_LIB_CHECK_DEFAULT
+from portage.const import _DEPCLEAN_LIB_CHECK_DEFAULT
from portage.dbapi.dep_expand import dep_expand
from portage.dbapi._expand_new_virt import expand_new_virt
from portage.dep import Atom
# specific packages.
msg = []
- if not _ENABLE_DYN_LINK_MAP:
+ if "preserve-libs" not in settings.features and \
+ not myopts.get("--depclean-lib-check", _DEPCLEAN_LIB_CHECK_DEFAULT) != "n":
msg.append("Depclean may break link level dependencies. Thus, it is\n")
msg.append("recommended to use a tool such as " + good("`revdep-rebuild`") + " (from\n")
msg.append("app-portage/gentoolkit) in order to detect such breakage.\n")
good = create_color_func("GOOD")
bad = create_color_func("BAD")
-from portage.const import _ENABLE_DYN_LINK_MAP
import portage.elog
import portage.util
import portage.locks
'--buildpkg' : y_or_n,
'--complete-graph' : y_or_n,
'--deep' : valid_integers,
+ '--depclean-lib-check' : y_or_n,
'--deselect' : y_or_n,
'--binpkg-respect-use' : y_or_n,
'--fail-clean' : y_or_n,
'--usepkgonly' : y_or_n,
}
- if _ENABLE_DYN_LINK_MAP:
- default_arg_opts['--depclean-lib-check'] = y_or_n
-
short_arg_opts = {
'D' : valid_integers,
'j' : valid_integers,
"action" : "store"
},
+ "--depclean-lib-check": {
+ "help" : "check for consumers of libraries before removing them",
+ "type" : "choice",
+ "choices" : true_y_or_n
+ },
+
"--deselect": {
"help" : "remove atoms/sets from the world file",
"type" : "choice",
}
- if _ENABLE_DYN_LINK_MAP:
- argument_options["--depclean-lib-check"] = {
- "help" : "check for consumers of libraries before removing them",
- "type" : "choice",
- "choices" : true_y_or_n
- }
-
from optparse import OptionParser
parser = OptionParser()
if parser.has_option("--help"):
else:
myoptions.complete_graph = None
- if _ENABLE_DYN_LINK_MAP:
- if myoptions.depclean_lib_check in true_y:
- myoptions.depclean_lib_check = True
+ if myoptions.depclean_lib_check in true_y:
+ myoptions.depclean_lib_check = True
if myoptions.exclude:
bad_atoms = _find_bad_atoms(myoptions.exclude)
parser.set("module-rebuild", "class", "portage.sets.dbapi.OwnerSet")
parser.set("module-rebuild", "files", "/lib/modules")
+ parser.remove_section("preserved-rebuild")
+ parser.add_section("preserved-rebuild")
+ parser.set("preserved-rebuild", "class", "portage.sets.libs.PreservedLibraryConsumerSet")
+
parser.remove_section("x11-module-rebuild")
parser.add_section("x11-module-rebuild")
parser.set("x11-module-rebuild", "class", "portage.sets.dbapi.OwnerSet")
"metadata-transfer", "mirror", "multilib-strict", "news",
"noauto", "noclean", "nodoc", "noinfo", "noman",
"nostrip", "notitles", "parallel-fetch", "parallel-install",
- "prelink-checksums",
+ "prelink-checksums", "preserve-libs",
"protect-owned", "python-trace", "sandbox",
"selinux", "sesandbox", "sfperms",
"sign", "skiprocheck", "split-elog", "split-log", "splitdebug",
# Private constants for use in conditional code in order to minimize the diff
# between branches.
-_ENABLE_DYN_LINK_MAP = True
_DEPCLEAN_LIB_CHECK_DEFAULT = True
-_ENABLE_PRESERVE_LIBS = True
_ENABLE_REPO_NAME_WARN = True
_ENABLE_SET_CONFIG = True
_ENABLE_INHERIT_CHECK = True
-
-
-# The definitions above will differ between branches, so it's useful to have
-# common lines of diff context here in order to avoid merge conflicts.
-
-if _ENABLE_PRESERVE_LIBS:
- SUPPORTED_FEATURES = set(SUPPORTED_FEATURES)
- SUPPORTED_FEATURES.add("preserve-libs")
- SUPPORTED_FEATURES = frozenset(SUPPORTED_FEATURES)
from portage.const import CACHE_PATH, CONFIG_MEMORY_FILE, \
PORTAGE_PACKAGE_ATOM, PRIVATE_PATH, VDB_PATH
-from portage.const import _ENABLE_DYN_LINK_MAP, _ENABLE_PRESERVE_LIBS
from portage.dbapi import dbapi
from portage.exception import CommandNotFound, \
InvalidData, InvalidLocation, InvalidPackageName, \
self._counter_path = os.path.join(self._eroot,
CACHE_PATH, "counter")
- self._plib_registry = None
- if _ENABLE_PRESERVE_LIBS:
- self._plib_registry = PreservedLibsRegistry(settings["ROOT"],
- os.path.join(self._eroot, PRIVATE_PATH,
- "preserved_libs_registry"))
-
- self._linkmap = None
- if _ENABLE_DYN_LINK_MAP:
- self._linkmap = LinkageMap(self)
+ self._plib_registry = PreservedLibsRegistry(settings["ROOT"],
+ os.path.join(self._eroot, PRIVATE_PATH, "preserved_libs_registry"))
+ self._linkmap = LinkageMap(self)
self._owners = self._owners_db(self)
self._cached_counter = None