In config.environ(), only export ED, EPREFIX, and EROOT to the ebuild
authorZac Medico <zmedico@gentoo.org>
Sun, 13 Dec 2009 03:50:12 +0000 (03:50 -0000)
committerZac Medico <zmedico@gentoo.org>
Sun, 13 Dec 2009 03:50:12 +0000 (03:50 -0000)
environment starting with EAPI 3 (so people won't write ebuilds that
are incompatible with older package managers). (trunk r15032)

svn path=/main/branches/2.1.7/; revision=15066

pym/portage/__init__.py

index 6c1350065bb9b418da80a835a2fb3114349fceb4..54d36f9e8c2eb71cc5dcd16561ad45ecff90954b 100644 (file)
@@ -3780,6 +3780,12 @@ class config(object):
                if eapi not in ("0", "1", "2", "3"):
                        mydict.pop("AA", None)
 
+               # Prefix variables are supported starting with EAPI 3.
+               if eapi in ("0", "1", "2"):
+                       mydict.pop("ED", None)
+                       mydict.pop("EPREFIX", None)
+                       mydict.pop("EROOT", None)
+
                # sandbox's bashrc sources /etc/profile which unsets ROOTPATH,
                # so we have to back it up and restore it.
                rootpath = mydict.get("ROOTPATH")