diff options
author | Zac Medico <zmedico@gentoo.org> | 2011-09-12 21:56:48 -0700 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2011-09-12 21:56:48 -0700 |
commit | 7bd285079a6b66fbf7548d040af800ce0b51f0ae (patch) | |
tree | 287d97874532e4da3bb51577ff6eed60e72ed718 | |
parent | 48a2edbf0f0677cc97bae388cc391b563c8e4859 (diff) | |
download | portage-7bd285079a6b66fbf7548d040af800ce0b51f0ae.tar.gz portage-7bd285079a6b66fbf7548d040af800ce0b51f0ae.tar.bz2 portage-7bd285079a6b66fbf7548d040af800ce0b51f0ae.zip |
ebuild(1): avoid "Location not set for repo" msgs
When overriding PORTDIR_OVERLAY, we can avoid "Location not set for
repository" messages if we include the original PORTDIR_OVERLAY paths
in the overridden setting.
-rwxr-xr-x | bin/ebuild | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/bin/ebuild b/bin/ebuild index 92105bbbd..1408dd32e 100755 --- a/bin/ebuild +++ b/bin/ebuild @@ -134,13 +134,19 @@ vdb_path = os.path.realpath(os.path.join(portage.settings['EROOT'], VDB_PATH)) # Make sure that portdb.findname() returns the correct ebuild. if ebuild_portdir != vdb_path and \ ebuild_portdir not in portage.portdb.porttrees: + portdir_overlay = os.environ.get("PORTDIR_OVERLAY") + if portdir_overlay is None: + portdir_overlay = portage.settings.get("PORTDIR_OVERLAY") + if portdir_overlay is None: + portdir_overlay = "" if sys.hexversion >= 0x3000000: os.environ["PORTDIR_OVERLAY"] = \ - os.environ.get("PORTDIR_OVERLAY","") + \ + portdir_overlay + \ " " + _shell_quote(ebuild_portdir) else: os.environ["PORTDIR_OVERLAY"] = \ - os.environ.get("PORTDIR_OVERLAY","") + \ + _unicode_encode(portdir_overlay, + encoding=_encodings['content'], errors='strict') + \ " " + _unicode_encode(_shell_quote(ebuild_portdir), encoding=_encodings['content'], errors='strict') |