aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes/image_types.bbclass
diff options
context:
space:
mode:
authorSaul Wold <sgw@linux.intel.com>2012-02-29 23:46:21 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-03-01 15:39:55 +0000
commitaa961e112b07d42c272e01f2d69f3c139e9ae70f (patch)
tree62de0b094a9d2e3462d33d10c879c37ad7817e8c /meta/classes/image_types.bbclass
parentc051d6c59c71a5f90c2d545491facd2d131592fd (diff)
downloadopenembedded-core-contrib-aa961e112b07d42c272e01f2d69f3c139e9ae70f.tar.gz
image-vmdk: Create image_vmdk class and setup image and image_types to use it
This creates a new image_vmdk class similar to live. The image_vmdk class needs to have a hddimg created by the image-live class, so it inherits it directly. The changes to image_types is to ensure that both live and vmdk images get the ext3 tools and dependencies. Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/image_types.bbclass')
-rw-r--r--meta/classes/image_types.bbclass15
1 files changed, 9 insertions, 6 deletions
diff --git a/meta/classes/image_types.bbclass b/meta/classes/image_types.bbclass
index 5b48a09da4..f756c39fc3 100644
--- a/meta/classes/image_types.bbclass
+++ b/meta/classes/image_types.bbclass
@@ -18,9 +18,13 @@ def get_imagecmds(d):
cimages[basetype].append(ctype)
break
- # Live images will be processed via inheriting bbclass and
- # does not get processed here.
- # live images also depend on ext3 so ensure its present
+ # 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
+ if "vmdk" in types:
+ if "ext3" not in types:
+ types.append("ext3")
+ types.remove("vmdk")
if "live" in types:
if "ext3" not in types:
types.append("ext3")
@@ -75,6 +79,8 @@ def imagetypes_getdepends(d):
deps = []
ctypes = d.getVar('COMPRESSIONTYPES', True).split()
for type in (d.getVar('IMAGE_FSTYPES', True) or "").split():
+ if type == "vmdk" or type == "live":
+ type = "ext3"
basetype = type
for ctype in ctypes:
if type.endswith("." + ctype):
@@ -160,8 +166,6 @@ IMAGE_CMD_ubi () {
}
IMAGE_CMD_ubifs = "mkfs.ubifs -r ${IMAGE_ROOTFS} -o ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ubifs ${MKUBIFS_ARGS}"
-IMAGE_CMD_vmdk = "qemu-img convert -O vmdk ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.hdddirect ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.vmdk"
-
EXTRA_IMAGECMD = ""
EXTRA_IMAGECMD_jffs2 ?= "--pad --little-endian --eraseblock=0x40000"
# Change these if you want default genext2fs behavior (i.e. create minimal inode number)
@@ -181,7 +185,6 @@ IMAGE_DEPENDS_squashfs = "squashfs-tools-native"
IMAGE_DEPENDS_squashfs-lzma = "squashfs-lzma-tools-native"
IMAGE_DEPENDS_ubi = "mtd-utils-native"
IMAGE_DEPENDS_ubifs = "mtd-utils-native"
-IMAGE_DEPENDS_vmdk = "qemu-native"
# This variable is available to request which values are suitable for IMAGE_FSTYPES
IMAGE_TYPES = "jffs2 sum.jffs2 cramfs ext2 ext2.gz ext2.bz2 ext3 ext3.gz ext2.lzma btrfs live squashfs squashfs-lzma ubi tar tar.gz tar.bz2 tar.xz cpio cpio.gz cpio.xz cpio.lzma vmdk"