diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-03-23 14:52:23 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-03-23 14:53:36 +0000 |
commit | 521d6b14151d3bf934b9597557f7ae46e50a3d7a (patch) | |
tree | a82ffc50da35cdb6b0a392e66d84b4bef12c46d6 /lib/bb/fetch2 | |
parent | 96e235a151fa04f5a15cd8b46f50a5852e2ba739 (diff) | |
download | bitbake-521d6b14151d3bf934b9597557f7ae46e50a3d7a.tar.gz |
bitbake/fetch2: Ensure mirror tarballs have .done stamps so we don't redownload and corrupt them
[YOCTO #2154]
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/fetch2')
-rw-r--r-- | lib/bb/fetch2/__init__.py | 1 | ||||
-rw-r--r-- | lib/bb/fetch2/git.py | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/lib/bb/fetch2/__init__.py b/lib/bb/fetch2/__init__.py index 7524fa95a..e5c4b341b 100644 --- a/lib/bb/fetch2/__init__.py +++ b/lib/bb/fetch2/__init__.py @@ -476,6 +476,7 @@ def try_mirrors(d, origud, mirrors, check = False): if not os.path.exists(ud.donestamp) or ud.method.need_update(newuri, ud, ld): ud.method.download(newuri, ud, ld) + open(ud.donestamp, 'w').close() if hasattr(ud.method,"build_mirror_data"): ud.method.build_mirror_data(newuri, ud, ld) diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py index 4e46ec8f3..61fdc4b05 100644 --- a/lib/bb/fetch2/git.py +++ b/lib/bb/fetch2/git.py @@ -214,6 +214,7 @@ class Git(FetchMethod): os.chdir(ud.clonedir) logger.info("Creating tarball of git repository") runfetchcmd("tar -czf %s %s" % (ud.fullmirror, os.path.join(".") ), d) + runfetchcmd("touch %s.done" % (ud.fullmirror), d) def unpack(self, ud, destdir, d): """ unpack the downloaded src to destdir""" |