diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-02-03 23:14:56 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-02-07 09:06:35 +0000 |
commit | 604037de4bc3826b9b7c60eb2e7efc7788363cad (patch) | |
tree | 7e8bbd7b642f4d4db7f720a578002ce182807b0d /meta/classes | |
parent | 8daab5b95157dda6854fe6bf1929f911fe3cf25e (diff) | |
download | openembedded-core-604037de4bc3826b9b7c60eb2e7efc7788363cad.tar.gz openembedded-core-604037de4bc3826b9b7c60eb2e7efc7788363cad.tar.bz2 openembedded-core-604037de4bc3826b9b7c60eb2e7efc7788363cad.tar.xz openembedded-core-604037de4bc3826b9b7c60eb2e7efc7788363cad.zip |
base.bbclass: Update after fetcher changes
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes')
-rw-r--r-- | meta/classes/base.bbclass | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index 42291557b..d8efcc0f8 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass @@ -245,7 +245,7 @@ python base_do_unpack() { localdata = bb.data.createCopy(d) bb.data.update_data(localdata) - urldata = bb.fetch.init([], localdata, True) + urldata = bb.fetch.init([], localdata) src_uri = bb.data.getVar('SRC_URI', localdata, True) if not src_uri: @@ -258,7 +258,10 @@ python base_do_unpack() { if local is None: continue local = os.path.realpath(local) - lf = bb.utils.lockfile(urldata[url].lockfile) + lockfile = urldata[url].lockfile + if lockfile: + lf = bb.utils.lockfile(urldata[url].lockfile) + if bb.fetch.__version__ == "1": ret = oe_unpack_file(local, localdata, url) else: @@ -266,7 +269,8 @@ python base_do_unpack() { ud = urldata[url] rootdir = bb.data.getVar('WORKDIR', localdata, True) ret = ud.method.unpack(ud, rootdir, localdata) - bb.utils.unlockfile(lf) + if lockfile: + bb.utils.unlockfile(lf) if not ret: raise bb.build.FuncFailed("oe_unpack_file failed with return value %s" % ret) } |