]> code.ossystems Code Review - openembedded-core.git/commitdiff
wic: Fix bitbake_env_command for 'None' case
authorTom Zanussi <tom.zanussi@linux.intel.com>
Fri, 28 Mar 2014 21:49:02 +0000 (16:49 -0500)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sun, 30 Mar 2014 08:53:42 +0000 (09:53 +0100)
bitbake_env_command will choke if it isn't given an image, make sure
it does the right thing in that case.

Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
scripts/lib/image/engine.py

index 6cf6169482e25a911bc5dfc3192f7f0509fea8a5..0643780f1a11f5c64691f571e55740a72a565bd4 100644 (file)
@@ -65,7 +65,10 @@ def find_bitbake_env_lines(image_name):
     If image_name is empty, plugins might still be able to use the
     environment, so set it regardless.
     """
-    bitbake_env_cmd = "bitbake -e %s" % image_name
+    if image_name:
+        bitbake_env_cmd = "bitbake -e %s" % image_name
+    else:
+        bitbake_env_cmd = "bitbake -e"
     rc, bitbake_env_lines = exec_cmd(bitbake_env_cmd)
     if rc != 0:
         print "Couldn't get '%s' output." % bitbake_env_cmd