kernel.bbclass: simplify "if image" condition
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Thu, 27 Jan 2011 02:13:30 +0000 (02:13 +0000)
committerTom Rini <tom_rini@mentor.com>
Sat, 12 Feb 2011 15:17:48 +0000 (08:17 -0700)
Anything that expands image to any false value should not set
INITRAMFS_TASK (instead of just "" or None).

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Signed-off-by: Tom Rini <tom_rini@mentor.com>
classes/kernel.bbclass

index 0d1b4ad..e22211d 100644 (file)
@@ -18,7 +18,7 @@ python __anonymous () {
        bb.data.setVar("DEPENDS", depends, d)
 
     image = bb.data.getVar('INITRAMFS_IMAGE', d, True)
-    if image != '' and image is not None:
+    if image:
         bb.data.setVar('INITRAMFS_TASK', '${INITRAMFS_IMAGE}:do_rootfs', d)
 
     machine_kernel_pr = bb.data.getVar('MACHINE_KERNEL_PR', d, True)