summaryrefslogtreecommitdiff
path: root/classes
diff options
context:
space:
mode:
authorChris Larson <clarson@mvista.com>2009-02-26 15:39:59 -0800
committerChris Larson <clarson@kergoth.com>2009-03-21 20:06:32 -0700
commit630555abb7ed906d6cb4bedecc94c34db84328ea (patch)
tree415725cfa77d8fe55ec5369f6125c24969d40291 /classes
parent65530068f30a5eea3db1b7da0e85d8e23d1dce00 (diff)
base.bbclass: make oe_unpack_file of dirs use FILESPATH, not FILESDIR.
Signed-off-by: Chris Larson <clarson@mvista.com>
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)