Discard REPLACING_VERSIONS and REPLACED_BY_VERSION when they are no
authorZac Medico <zmedico@gentoo.org>
Tue, 17 Aug 2010 17:30:12 +0000 (10:30 -0700)
committerZac Medico <zmedico@gentoo.org>
Tue, 17 Aug 2010 17:30:12 +0000 (10:30 -0700)
longer needed.

pym/portage/dbapi/vartree.py
pym/portage/package/ebuild/doebuild.py

index 6ec1d5e09939af6c040297345282d937811962b6..75784a69aecde0e06ef0e4d6d8a9c0a8408ca933 100644 (file)
@@ -3947,6 +3947,7 @@ class dblink(object):
                        dblnk.settings.backup_changes("REPLACED_BY_VERSION")
                        unmerge_rval = dblnk.unmerge(trimworld=0,
                                ldpath_mtimes=prev_mtimes, others_in_slot=others_in_slot)
+                       dblnk.settings.pop("REPLACED_BY_VERSION", None)
 
                        if unmerge_rval == os.EX_OK:
                                emerge_log(_(" >>> unmerge success: %s") % (dblnk.mycpv,))
@@ -4479,6 +4480,7 @@ class dblink(object):
                                                        self, mydbapi, myebuild, "clean")
 
                finally:
+                       self.settings.pop('REPLACING_VERSIONS', None)
                        self.vartree.dbapi.linkmap._clear_cache()
                        self.unlockdb()
                        self.vartree.dbapi._bump_mtime(self.mycpv)
index ef340375d8fab299f702132f29be34a7be13c7fb..b65425bee167a9cf6112f52c805f2933ace5b5e1 100644 (file)
@@ -771,6 +771,8 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0,
                if builddir_lock:
                        portage.locks.unlockdir(builddir_lock)
 
+               mysettings.pop("REPLACING_VERSIONS", None)
+
                # Make sure that DISTDIR is restored to it's normal value before we return!
                if "PORTAGE_ACTUAL_DISTDIR" in mysettings:
                        mysettings["DISTDIR"] = mysettings["PORTAGE_ACTUAL_DISTDIR"]