summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Luther <SebastianLuther@gmx.de>2011-01-31 18:40:08 +0100
committerZac Medico <zmedico@gentoo.org>2011-01-31 13:04:50 -0800
commitdfcef19feff049004e0a7043fb980ecdc711a930 (patch)
tree10b86e3cf125946886bab4c04c72e1ba4b35e840
parent9a58a3c8a4b6d6c92fac1250379cc97e1c8070d3 (diff)
downloadportage-dfcef19feff049004e0a7043fb980ecdc711a930.tar.gz
portage-dfcef19feff049004e0a7043fb980ecdc711a930.tar.bz2
portage-dfcef19feff049004e0a7043fb980ecdc711a930.zip
Allow relative paths (starting with ./) on the cmd line
bug 352208
-rw-r--r--pym/_emerge/depgraph.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py
index a92722272..4f60a3a45 100644
--- a/pym/_emerge/depgraph.py
+++ b/pym/_emerge/depgraph.py
@@ -1634,6 +1634,13 @@ class depgraph(object):
# Queue these up since it's most efficient to handle
# multiple files in a single iter_owners() call.
lookup_owners.append(x)
+ elif x.startswith("." + os.path.sep):
+ f = os.path.abspath(x)
+ if not f.startswith(myroot):
+ portage.writemsg(("\n\n!!! '%s' (resolved from '%s') does not start with" + \
+ " $ROOT.\n") % (f, x), noiselevel=-1)
+ return 0, []
+ lookup_owners.append(f)
else:
if x in ("system", "world"):
x = SETPREFIX + x