summaryrefslogtreecommitdiffstats
path: root/lib/bb/fetch2
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2012-06-14 13:57:53 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-06-14 13:57:59 +0100
commit95c0595d66b3f8a5f0716662ba2a878600f312ea (patch)
tree11114ddd57bef1af97c2b2dab3db2e9d61de7765 /lib/bb/fetch2
parentaf2133a04e1f4b22b181adf9c71f89c439bb88cf (diff)
downloadbitbake-95c0595d66b3f8a5f0716662ba2a878600f312ea.tar.gz
fetch2/local: Ensure quoting is handled correctly from the url
The commit 420eb112a4f (fetch2: quote/unquote url paths) caused a regression since local file urls containing quoted characters are no longer being handled correctly. This fixes things so the url is dequoted correctly, fixing various fetcher failures with recipes like "gtk+". [YOCTO #2558] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/fetch2')
-rw-r--r--lib/bb/fetch2/local.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/bb/fetch2/local.py b/lib/bb/fetch2/local.py
index a0ed4442f..1f4ec371a 100644
--- a/lib/bb/fetch2/local.py
+++ b/lib/bb/fetch2/local.py
@@ -26,6 +26,7 @@ BitBake build tools.
# Based on functions from the base bb module, Copyright 2003 Holger Schurig
import os
+import urllib
import bb
import bb.utils
from bb import data
@@ -40,7 +41,7 @@ class Local(FetchMethod):
def urldata_init(self, ud, d):
# We don't set localfile as for this fetcher the file is already local!
- ud.basename = os.path.basename(ud.url.split("://")[1].split(";")[0])
+ ud.basename = os.path.basename(urllib.unquote(ud.url.split("://")[1].split(";")[0]))
return
def localpath(self, url, urldata, d):
@@ -49,6 +50,7 @@ class Local(FetchMethod):
"""
path = url.split("://")[1]
path = path.split(";")[0]
+ path = urllib.unquote(path)
newpath = path
if path[0] != "/":
filespath = data.getVar('FILESPATH', d, True)