]> code.ossystems Code Review - openembedded-core.git/commitdiff
image_types: ensure .rootfs.ext3 is created before vmdk is created.
authorDexuan Cui <dexuan.cui@intel.com>
Fri, 9 Mar 2012 07:05:12 +0000 (15:05 +0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 13 Mar 2012 11:44:46 +0000 (11:44 +0000)
In the case of self-hosted-image.bb, IMAGE_FSTYPES = "vmdk", so the
variables alltypes and subimages don't contain ext3, and  .rootfs.ext3
won't be created, and finally the generated .hddimg and .vmdk don't have
an actual rootfs -- the size of the .vmdk file is only about 9MB.

[YOCTO #2067]

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
meta/classes/image_types.bbclass

index 8b820182e259b945f89a8bd2f62ca24ca742382e..e92f5190784e7b797c2c3a647049d71aa89cd69b 100644 (file)
@@ -26,13 +26,19 @@ def get_imagecmds(d):
     # Live and VMDK images will be processed via inheriting
     # bbclass and does not get processed here.
     # vmdk depend on live images also depend on ext3 so ensure its present
+    # Note: we need to ensure ext3 is in alltypes, otherwise, subimages may
+    # not contain ext3 and the .rootfs.ext3 file won't be created.
     if "vmdk" in types:
         if "ext3" not in types:
             types.append("ext3")
+        if "ext3" not in alltypes:
+            alltypes.append("ext3")
         types.remove("vmdk")
     if "live" in types:
         if "ext3" not in types:
             types.append("ext3")
+        if "ext3" not in alltypes:
+            alltypes.append("ext3")
         types.remove("live")
 
     if d.getVar('IMAGE_LINK_NAME', True):