Patchwork [bitbake-devel] wget: Only use -O option when not spidering

mail settings
Submitter Richard Purdie
Date Feb. 14, 2013, 9:33 p.m.
Message ID <1360877584.11225.122.camel@ted>
Download mbox | patch
Permalink /patch/44661/
State New
Headers show


Richard Purdie - Feb. 14, 2013, 9:33 p.m.
If we pass the -O option whilst spidering, empty files are created which is not
desired. We also need to ensure any subdirectories are created when using the
downloadfilename parameter.

Signed-off-by: Richard Purdie <>


diff --git a/bitbake/lib/bb/fetch2/ b/bitbake/lib/bb/fetch2/
index 2808df6..24eec31 100644
--- a/bitbake/lib/bb/fetch2/
+++ b/bitbake/lib/bb/fetch2/
@@ -65,7 +65,8 @@  class Wget(FetchMethod):
         basecmd = d.getVar("FETCHCMD_wget", True) or "/usr/bin/env wget -t 2 -T 30 -nv --passive-ftp --no-check-certificate"
-        if 'downloadfilename' in ud.parm:
+        if not checkonly and 'downloadfilename' in ud.parm:
+            bb.utils.mkdirhier(os.path.dirname(ud.localfile))
             basecmd += " -O ${DL_DIR}/" + ud.localfile
         if checkonly: