summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/fetch2/__init__.py
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2014-09-24 14:16:52 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-09-29 12:08:48 +0100
commit8e4e03c2a32a6fff6e07f01ed36481e6e7ee0b4a (patch)
tree1bcdaf0bf38728b0529ece37672154fb438a53ce /bitbake/lib/bb/fetch2/__init__.py
parent1f4e75143a961665cf3010e9b0c6d480bbbe022a (diff)
downloadpoky-8e4e03c2a32a6fff6e07f01ed36481e6e7ee0b4a.tar.gz
bitbake: fetch: Extend testing of subdir unpack parameter and fix
This fixes urls of the form file://some/path/file;subdir=b. It also adds in a couple of tests so we now tests these corner cases. (Bitbake rev: 46306912a96444790efa9418d934dfdd36773ba1) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bb/fetch2/__init__.py')
-rw-r--r--bitbake/lib/bb/fetch2/__init__.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py
index 68c8329e2b..87cf7e61a6 100644
--- a/bitbake/lib/bb/fetch2/__init__.py
+++ b/bitbake/lib/bb/fetch2/__init__.py
@@ -1264,6 +1264,8 @@ class FetchMethod(object):
1264 # items. So, only do so for file:// entries. 1264 # items. So, only do so for file:// entries.
1265 if urldata.type == "file" and urldata.path.find("/") != -1: 1265 if urldata.type == "file" and urldata.path.find("/") != -1:
1266 destdir = urldata.path.rsplit("/", 1)[0] 1266 destdir = urldata.path.rsplit("/", 1)[0]
1267 if urldata.parm.get('subdir') != None:
1268 destdir = urldata.parm.get('subdir') + "/" + destdir
1267 else: 1269 else:
1268 if urldata.parm.get('subdir') != None: 1270 if urldata.parm.get('subdir') != None:
1269 destdir = urldata.parm.get('subdir') 1271 destdir = urldata.parm.get('subdir')