summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
Diffstat (limited to 'classes')
-rw-r--r--classes/base.bbclass19
1 files changed, 11 insertions, 8 deletions
diff --git a/classes/base.bbclass b/classes/base.bbclass
index cf4b5c5e1d..caaa6b2da1 100644
--- a/classes/base.bbclass
+++ b/classes/base.bbclass
@@ -689,15 +689,18 @@ def oe_unpack_file(file, data, url = None):
cmd = '%s -a' % cmd
cmd = '%s %s' % (cmd, file)
elif os.path.isdir(file):
- filesdir = os.path.realpath(bb.data.getVar("FILESDIR", data, 1))
destdir = "."
- if file[0:len(filesdir)] == filesdir:
- destdir = file[len(filesdir):file.rfind('/')]
- destdir = destdir.strip('/')
- if len(destdir) < 1:
- destdir = "."
- elif not os.access("%s/%s" % (os.getcwd(), destdir), os.F_OK):
- os.makedirs("%s/%s" % (os.getcwd(), destdir))
+ filespath = bb.data.getVar("FILESPATH", data, 1).split(":")
+ for fp in filespath:
+ if file[0:len(fp)] == fp:
+ destdir = file[len(fp):file.rfind('/')]
+ destdir = destdir.strip('/')
+ if len(destdir) < 1:
+ destdir = "."
+ elif not os.access("%s/%s" % (os.getcwd(), destdir), os.F_OK):
+ os.makedirs("%s/%s" % (os.getcwd(), destdir))
+ break
+
cmd = 'cp -pPR %s %s/%s/' % (file, os.getcwd(), destdir)
else:
(type, host, path, user, pswd, parm) = bb.decodeurl(url)