Make sure that doebuild gets the correct CATEGORY. See bug #137105.
authorZac Medico <zmedico@gentoo.org>
Sat, 17 Jun 2006 23:18:12 +0000 (23:18 -0000)
committerZac Medico <zmedico@gentoo.org>
Sat, 17 Jun 2006 23:18:12 +0000 (23:18 -0000)
svn path=/main/trunk/; revision=3524

bin/emerge
pym/portage.py

index f05e8d2bf12d0e9d451260d85984f3e100fdda89..a5b15211e7e7be7e9e53e5e936072016172291de 100755 (executable)
@@ -1951,6 +1951,8 @@ class depgraph:
                                        for x in mymergelist:
                                                if x[0] != "ebuild":
                                                        continue
+                                               self.pkgsettings.reset()
+                                               self.pkgsettings.setcpv(x[2])
                                                try:
                                                        ret = portage.doebuild(portage.portdb.findname(x[2]), "fetch", x[1], self.pkgsettings,
                                                                cleanup=0, fetchonly=True, tree="porttree")
index 60d28f599ea1cb04cf6053d38bc24bc26a842fda..70e7c67337a02e5fabfccd49e478ddcf4c91443b 100644 (file)
@@ -1513,6 +1513,8 @@ class config:
                self.puse = newpuse
                self.configdict["pkg"]["PKGUSE"] = self.puse[:] # For saving to PUSE file
                self.configdict["pkg"]["USE"]    = self.puse[:] # this gets appended to USE
+               # CATEGORY is essential for doebuild calls
+               self.configdict["pkg"]["CATEGORY"] = mycpv.split("/")[0]
                self.reset(keeping_pkg=1,use_cache=use_cache)
 
        def setinst(self,mycpv,mydbapi):