summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pym/_emerge/__init__.py2
-rw-r--r--pym/portage/__init__.py6
-rw-r--r--pym/portage/dbapi/porttree.py2
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,