diff options
author | Zac Medico <zmedico@gentoo.org> | 2009-03-23 05:49:17 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2009-03-23 05:49:17 +0000 |
commit | 1243f8021a2f0b3ed5cdb2060d67f6d3905e3d4e (patch) | |
tree | 34b534f403a583e8852290a9ceb7af5399a92cc4 | |
parent | 1dd427fcc0ec6cca8ba5dd308ad59ec5195f8a44 (diff) | |
download | portage-1243f8021a2f0b3ed5cdb2060d67f6d3905e3d4e.tar.gz portage-1243f8021a2f0b3ed5cdb2060d67f6d3905e3d4e.tar.bz2 portage-1243f8021a2f0b3ed5cdb2060d67f6d3905e3d4e.zip |
When calling doebuild() to spawn the 'depend' phase, just call config.setcpv()
since that should be enough (no need for separate reset or reload calls).
svn path=/main/trunk/; revision=13170
-rw-r--r-- | pym/_emerge/__init__.py | 2 | ||||
-rw-r--r-- | pym/portage/__init__.py | 6 | ||||
-rw-r--r-- | pym/portage/dbapi/porttree.py | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index bee4dc5a0..17fec42d1 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -3027,7 +3027,7 @@ class EbuildMetadataPhase(SubProcess): def _start(self): settings = self.settings - settings.reset() + settings.setcpv(self.cpv) ebuild_path = self.ebuild_path debug = settings.get("PORTAGE_DEBUG") == "1" master_fd = None diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 21f671b43..f56c64471 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -5045,14 +5045,14 @@ def doebuild_environment(myebuild, mydo, myroot, mysettings, debug, use_cache, m tmpdir = mysettings["PORTAGE_TMPDIR"] if mycpv != mysettings.mycpv: - # Reload env.d variables and reset any previous settings. - mysettings.reload() - mysettings.reset() if mydo == 'depend': # Don't pass in mydbapi here since the resulting aux_get # call would lead to infinite 'depend' phase recursion. mysettings.setcpv(mycpv) else: + # Reload env.d variables and reset any previous settings. + mysettings.reload() + mysettings.reset() mysettings.setcpv(mycpv, mydb=mydbapi) # config.reset() might have reverted a change made by the caller, diff --git a/pym/portage/dbapi/porttree.py b/pym/portage/dbapi/porttree.py index 93730e9c3..077715239 100644 --- a/pym/portage/dbapi/porttree.py +++ b/pym/portage/dbapi/porttree.py @@ -417,7 +417,7 @@ class portdbapi(dbapi): writemsg("doregen: %s %s\n" % (doregen, mycpv), 2) writemsg("Generating cache entry(0) for: "+str(myebuild)+"\n", 1) - self.doebuild_settings.reset() + self.doebuild_settings.setcpv(mycpv) mydata = {} myret = doebuild(myebuild, "depend", self.doebuild_settings["ROOT"], self.doebuild_settings, |