diff options
author | Zac Medico <zmedico@gentoo.org> | 2011-07-13 18:24:49 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2011-07-13 18:24:49 -0700 |
commit | 224cb2be2a11270941742a8b08390767b0056d6c (patch) | |
tree | ced6ae5c26c5da8d551afcb37627e0a642569ff2 | |
parent | d85b7e5ceb8a1585b8b8a8e4383dc6de5450e616 (diff) | |
download | portage-224cb2be2a11270941742a8b08390767b0056d6c.tar.gz portage-224cb2be2a11270941742a8b08390767b0056d6c.tar.bz2 portage-224cb2be2a11270941742a8b08390767b0056d6c.zip |
doebuild: discard cached manifest when necessary
When we call digestgen(), it can regenerate our distfiles digests and
we don't wan to cache stale values in this case.
-rw-r--r-- | pym/portage/package/ebuild/doebuild.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/pym/portage/package/ebuild/doebuild.py b/pym/portage/package/ebuild/doebuild.py index 8e7515c98..e63c0e5a3 100644 --- a/pym/portage/package/ebuild/doebuild.py +++ b/pym/portage/package/ebuild/doebuild.py @@ -478,6 +478,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, noiselevel=-1) return 1 + global _doebuild_manifest_cache mf = None if "strict" in features and \ "digest" not in features and \ @@ -485,7 +486,7 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, mydo not in ("digest", "manifest", "help") and \ not portage._doebuild_manifest_exempt_depend: # Always verify the ebuild checksums before executing it. - global _doebuild_manifest_cache, _doebuild_broken_ebuilds + global _doebuild_broken_ebuilds if myebuild in _doebuild_broken_ebuilds: return 1 @@ -793,14 +794,20 @@ def doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, try: if mydo == "manifest": + mf = None + _doebuild_manifest_cache = None return not digestgen(mysettings=mysettings, myportdb=mydbapi) elif mydo == "digest": + mf = None + _doebuild_manifest_cache = None return not digestgen(mysettings=mysettings, myportdb=mydbapi) elif mydo != 'fetch' and \ "digest" in mysettings.features: # Don't do this when called by emerge or when called just # for fetch (especially parallel-fetch) since it's not needed # and it can interfere with parallel tasks. + mf = None + _doebuild_manifest_cache = None digestgen(mysettings=mysettings, myportdb=mydbapi) except PermissionDenied as e: writemsg(_("!!! Permission Denied: %s\n") % (e,), noiselevel=-1) |