Skip to contentSkip to conversation

a fix to 2067

PATCH Applied Dexuan Cui 2 participants 5 messages Mar 9, 2012 – Mar 13, 2012

lore
Share & tools
lore

Dexuan Cui

author
#0 lore raw

cover a fix to 2067

The following changes since commit 6bd23e0faf329f086bb4885991ce5f5d095dac56:

adt-installer: Corrected wrong environment file names. (2012-03-08 12:18:52 -0800)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib dcui/fix_2067
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dcui/fix_2067

Dexuan Cui (1):
image_types: ensure .rootfs.ext3 is created before vmdk is created.

 meta/classes/image_types.bbclass |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
Signature · 1 line
1.7.6
author
#1 lore raw

PATCH 1/1 image_types: ensure .rootfs.ext3 is created before vmdk is created.

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]

---
 meta/classes/image_types.bbclass |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
meta/classes/image_types.bbclass +6 -0
index 8b82018..e92f519 100644
@@ -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):
Signature · 1 line
1.7.6
Acked-by on v1 1/1
#2 lore raw

Re: [PATCH 1/1] image_types: ensure .rootfs.ext3 is created before vmdk is created.

Quoted 8 lines · Dexuan Cui

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]

Nice Catch!

Sau!

Quoted 28 lines
---
  meta/classes/image_types.bbclass |    6 ++++++
  1 files changed, 6 insertions(+), 0 deletions(-)
meta/classes/image_types.bbclass +6 -0
index 8b82018..e92f519 100644
@@ -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):
#3 lore raw

Re: [PATCH 1/1] image_types: ensure .rootfs.ext3 is created before vmdk is created.

Saul Wold wrote on 2012-03-09:

Quoted 6 lines · Dexuan Cui
Quoted 5 lines

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.

Quoted 7 lines
Quoted 3 lines

[YOCTO #2067]

Nice Catch!

BTW, I didn't find the bug in my previous test because I didn't build From scratch, so actually I already had a file tmp/deploy/image/self-hosted-image-qemux86.ext3, and according to bootimg.bbclass's populate(), we used it -- but we should use a new .ext3 file.

Thanks,
-- Dexuan

Applied
#4 lore raw
In reply to Dexuan Cui
Quoted 5 lines · Dexuan Cui

The following changes since commit 6bd23e0faf329f086bb4885991ce5f5d095dac56:

   adt-installer: Corrected wrong environment file names. (2012-03-08 12:18:52 -0800)

are available in the git repository at:

Quoted 9 lines
   git://git.pokylinux.org/poky-contrib dcui/fix_2067
   http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=dcui/fix_2067

Dexuan Cui (1):
image_types: ensure .rootfs.ext3 is created before vmdk is created.

  meta/classes/image_types.bbclass |    6 ++++++
  1 files changed, 6 insertions(+), 0 deletions(-)

Merged into OE-Core

Thanks
Sau!