summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2015-04-28 11:49:18 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-04-29 10:58:54 +0100
commit94ed114eff4efd86698713f21036cc98aeaa1364 (patch)
treeb9dccd8ec515b9ea422af371f99b7402884aa98a
parent591e6a6dcb5710b7f60bd83ca1890b118186aa4c (diff)
downloadopenembedded-core-contrib-94ed114eff4efd86698713f21036cc98aeaa1364.tar.gz
oeqa/targetbuild: Use DL_DIR for downloads if present
This isn't a test of wget so if the files we need are present in DL_DIR, use them from there and save a bit of speed/bandwidth and skip the wget. (From OE-Core rev: dc1d83d021afd77ca8fb948dc47bbd11e3844865) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/utils/targetbuild.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/lib/oeqa/utils/targetbuild.py b/meta/lib/oeqa/utils/targetbuild.py
index eeb08ba716..d499bb1e1e 100644
--- a/meta/lib/oeqa/utils/targetbuild.py
+++ b/meta/lib/oeqa/utils/targetbuild.py
@@ -26,6 +26,11 @@ class BuildProject():
# Download self.archive to self.localarchive
def _download_archive(self):
+ dl_dir = self.d.getVar("DL_DIR", True)
+ if dl_dir and os.path.exists(os.path.join(dl_dir, self.archive)):
+ bb.utils.copyfile(os.path.join(dl_dir, self.archive), self.localarchive)
+ return
+
exportvars = ['HTTP_PROXY', 'http_proxy',
'HTTPS_PROXY', 'https_proxy',
'FTP_PROXY', 'ftp_proxy',