From 188abf0a7f910caba9d75fc570fdf962472f9355 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Mon, 4 Dec 2006 01:55:29 +0000 Subject: [PATCH] For `ebuild --force digest`, exempt the depend phase from Manifest checks. svn path=/main/trunk/; revision=5169 --- bin/ebuild | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/bin/ebuild b/bin/ebuild index da405db07..0860f089b 100755 --- a/bin/ebuild +++ b/bin/ebuild @@ -88,22 +88,26 @@ def discard_digests(myebuild, mysettings, mydbapi): upstream has changed the identity of the distfiles and the user would otherwise have to manually remove the Manifest and files/digest-* files in order to ensure correct results.""" - pkgdir = os.path.dirname(myebuild) - fetchlist_dict = portage.FetchlistDict(pkgdir, mysettings, mydbapi) - cat, pkg = pkgdir.split(os.sep)[-2:] - cpv = cat + "/" + os.path.basename(myebuild)[:-7] - from portage_manifest import Manifest - mf = Manifest(pkgdir, mysettings["DISTDIR"], - fetchlist_dict=fetchlist_dict) - mf.create(requiredDistfiles=None, - assumeDistHashesSometimes=True, assumeDistHashesAlways=True) - distfiles = fetchlist_dict[cpv] - for myfile in distfiles: - try: - del mf.fhashdict["DIST"][myfile] - except KeyError: - pass - mf.write() + try: + portage._doebuild_manifest_exempt_depend += 1 + pkgdir = os.path.dirname(myebuild) + fetchlist_dict = portage.FetchlistDict(pkgdir, mysettings, mydbapi) + cat, pkg = pkgdir.split(os.sep)[-2:] + cpv = cat + "/" + os.path.basename(myebuild)[:-7] + from portage_manifest import Manifest + mf = Manifest(pkgdir, mysettings["DISTDIR"], + fetchlist_dict=fetchlist_dict) + mf.create(requiredDistfiles=None, + assumeDistHashesSometimes=True, assumeDistHashesAlways=True) + distfiles = fetchlist_dict[cpv] + for myfile in distfiles: + try: + del mf.fhashdict["DIST"][myfile] + except KeyError: + pass + mf.write() + finally: + portage._doebuild_manifest_exempt_depend -= 1 for arg in pargs: try: -- 2.26.2