summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2012-02-27 12:43:49 (GMT)
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-02-28 12:27:53 (GMT)
commit126f634207cd11f8e4b0324b90613b76193ca8d2 (patch)
tree60a78a422051164059f0f3b6cce40e59de7f4090
parent93d157b7245182d88395b2e361db28528dd3af19 (diff)
downloadpoky-126f634207cd11f8e4b0324b90613b76193ca8d2.tar.gz
image_types: Refactor compression code into a generic compression solution
The current approach of adding each different compressed image type doesn't scale. This patch changes the code so compressed images for each form are automatically available using the form <type>.<compression type> in IMAGE_FSTYPES. This doesn't change any existing externally visible behaviour and the image generation process becomes more efficient as a result too. (From OE-Core rev: b7e4ed41ee480f00b7265341e9e2d2c2b9135143) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/image.bbclass4
-rw-r--r--meta/classes/image_types.bbclass131
2 files changed, 68 insertions, 67 deletions
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 54ab157..4db55ff 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -75,9 +75,7 @@ inherit image-${IMAGE_TYPE}
75 75
76python () { 76python () {
77 deps = d.getVarFlag('do_rootfs', 'depends') or "" 77 deps = d.getVarFlag('do_rootfs', 'depends') or ""
78 for type in (d.getVar('IMAGE_FSTYPES', True) or "").split(): 78 deps += imagetypes_getdepends(d)
79 for dep in ((d.getVar('IMAGE_DEPENDS_%s' % type) or "").split() or []):
80 deps += " %s:do_populate_sysroot" % dep
81 for dep in (d.getVar('EXTRA_IMAGEDEPENDS', True) or "").split(): 79 for dep in (d.getVar('EXTRA_IMAGEDEPENDS', True) or "").split():
82 deps += " %s:do_populate_sysroot" % dep 80 deps += " %s:do_populate_sysroot" % dep
83 d.setVarFlag('do_rootfs', 'depends', deps) 81 d.setVarFlag('do_rootfs', 'depends', deps)
diff --git a/meta/classes/image_types.bbclass b/meta/classes/image_types.bbclass
index 3b26162..74071c1 100644
--- a/meta/classes/image_types.bbclass
+++ b/meta/classes/image_types.bbclass
@@ -2,7 +2,21 @@ def get_imagecmds(d):
2 cmds = "\n" 2 cmds = "\n"
3 old_overrides = d.getVar('OVERRIDES', 0) 3 old_overrides = d.getVar('OVERRIDES', 0)
4 4
5 alltypes = d.getVar('IMAGE_FSTYPES', True).split()
5 types = d.getVar('IMAGE_FSTYPES', True).split() 6 types = d.getVar('IMAGE_FSTYPES', True).split()
7 ctypes = d.getVar('COMPRESSIONTYPES', True).split()
8 cimages = {}
9
10 # Filter out all the compressed images from types
11 for type in types:
12 for ctype in ctypes:
13 if type.endswith("." + ctype):
14 basetype = type.rsplit(".", 1)[0]
15 types[types.index(type)] = basetype
16 if type not in cimages:
17 cimages[basetype] = []
18 cimages[basetype].append(ctype)
19
6 # Live images will be processed via inheriting bbclass and 20 # Live images will be processed via inheriting bbclass and
7 # does not get processed here. 21 # does not get processed here.
8 # live images also depend on ext3 so ensure its present 22 # live images also depend on ext3 so ensure its present
@@ -11,11 +25,24 @@ def get_imagecmds(d):
11 types.append("ext3") 25 types.append("ext3")
12 types.remove("live") 26 types.remove("live")
13 27
28 cmds += " rm -f ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.*"
14 for type in types: 29 for type in types:
30 ccmd = []
31 subimages = []
15 localdata = bb.data.createCopy(d) 32 localdata = bb.data.createCopy(d)
16 localdata.setVar('OVERRIDES', '%s:%s' % (type, old_overrides)) 33 localdata.setVar('OVERRIDES', '%s:%s' % (type, old_overrides))
17 bb.data.update_data(localdata) 34 bb.data.update_data(localdata)
18 localdata.setVar('type', type) 35 localdata.setVar('type', type)
36 if type in cimages:
37 for ctype in cimages[type]:
38 ccmd.append("\t" + localdata.getVar("COMPRESS_CMD_" + ctype, True))
39 subimages.append(type + "." + ctype)
40 if type not in alltypes:
41 ccmd.append(localdata.expand("\trm ${IMAGE_NAME}.rootfs.${type}"))
42 else:
43 subimages.append(type)
44 localdata.setVar('ccmd', "\n".join(ccmd))
45 localdata.setVar('subimages', " ".join(subimages))
19 cmd = localdata.getVar("IMAGE_CMD", True) 46 cmd = localdata.getVar("IMAGE_CMD", True)
20 localdata.setVar('cmd', cmd) 47 localdata.setVar('cmd', cmd)
21 cmds += localdata.getVar("runimagecmd", True) 48 cmds += localdata.getVar("runimagecmd", True)
@@ -25,10 +52,36 @@ runimagecmd () {
25 # Image generation code for image type ${type} 52 # Image generation code for image type ${type}
26 ROOTFS_SIZE=`du -ks ${IMAGE_ROOTFS}|awk '{base_size = ($1 * ${IMAGE_OVERHEAD_FACTOR}); OFMT = "%.0f" ; print ((base_size > ${IMAGE_ROOTFS_SIZE} ? base_size : ${IMAGE_ROOTFS_SIZE}) + ${IMAGE_ROOTFS_EXTRA_SPACE}) }'` 53 ROOTFS_SIZE=`du -ks ${IMAGE_ROOTFS}|awk '{base_size = ($1 * ${IMAGE_OVERHEAD_FACTOR}); OFMT = "%.0f" ; print ((base_size > ${IMAGE_ROOTFS_SIZE} ? base_size : ${IMAGE_ROOTFS_SIZE}) + ${IMAGE_ROOTFS_EXTRA_SPACE}) }'`
27 ${cmd} 54 ${cmd}
55 # Now create the needed compressed versions
28 cd ${DEPLOY_DIR_IMAGE}/ 56 cd ${DEPLOY_DIR_IMAGE}/
29 rm -f ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.${type} 57 ${ccmd}
30 ln -s ${IMAGE_NAME}.rootfs.${type} ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.${type} 58 # And create the symlinks
31} 59 for type in ${subimages}; do
60 ln -s ${IMAGE_NAME}.rootfs.$type ${DEPLOY_DIR_IMAGE}/${IMAGE_LINK_NAME}.$type
61 done
62}
63
64def imagetypes_getdepends(d):
65 def adddep(depstr, deps):
66 for i in (depstr or "").split():
67 if i not in deps:
68 deps.append(i)
69
70 deps = []
71 ctypes = d.getVar('COMPRESSIONTYPES', True).split()
72 for type in (d.getVar('IMAGE_FSTYPES', True) or "").split():
73 basetype = type
74 for ctype in ctypes:
75 if type.endswith("." + ctype):
76 basetype = type.rsplit(".", 1)[0]
77 adddep(d.getVar("COMPRESS_DEPENDS_%s" % ctype, True), deps)
78 break
79 adddep(d.getVar('IMAGE_DEPENDS_%s' % basetype, True) , deps)
80
81 depstr = ""
82 for dep in deps:
83 depstr += " " + dep + ":do_populate_sysroot"
84 return depstr
32 85
33 86
34XZ_COMPRESSION_LEVEL ?= "-e -9" 87XZ_COMPRESSION_LEVEL ?= "-e -9"
@@ -46,40 +99,11 @@ IMAGE_CMD_ext2 () {
46 mv ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext2 ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext2 99 mv ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext2 ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext2
47 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN} 100 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
48} 101}
49IMAGE_CMD_ext2.gz () {
50 rm -rf ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN} && mkdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
51 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext2
52 gzip -f -9 ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext2
53 mv ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext2.gz ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext2.gz
54 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
55}
56IMAGE_CMD_ext2.bz2 () {
57 rm -rf ${DEPLOY_DIR_IMAGE}/tmp.gz && mkdir ${DEPLOY_DIR_IMAGE}/tmp.gz
58 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2
59 bzip2 -f -9 ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2
60 mv ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2.bz2 ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext2.bz2
61 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz
62}
63IMAGE_CMD_ext2.lzma () {
64 rm -rf ${DEPLOY_DIR_IMAGE}/tmp.gz && mkdir ${DEPLOY_DIR_IMAGE}/tmp.gz
65 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2
66 lzma -f -7 ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2
67 mv ${DEPLOY_DIR_IMAGE}/tmp.gz/${IMAGE_NAME}.rootfs.ext2.lzma ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext2.lzma
68 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz
69}
70 102
71IMAGE_CMD_ext3 () { 103IMAGE_CMD_ext3 () {
72 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext3 104 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext3
73 tune2fs -j ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext3 105 tune2fs -j ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext3
74} 106}
75IMAGE_CMD_ext3.gz () {
76 rm -rf ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN} && mkdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
77 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext3
78 tune2fs -j ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext3
79 gzip -f -9 ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext3
80 mv ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext3.gz ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext3.gz
81 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
82}
83 107
84oe_mkext4fs () { 108oe_mkext4fs () {
85 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} $1 109 genext2fs -b $ROOTFS_SIZE -i 4096 -d ${IMAGE_ROOTFS} ${EXTRA_IMAGECMD} $1
@@ -97,13 +121,6 @@ oe_mkext4fs () {
97IMAGE_CMD_ext4 () { 121IMAGE_CMD_ext4 () {
98 oe_mkext4fs ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext4 122 oe_mkext4fs ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext4
99} 123}
100IMAGE_CMD_ext4.gz () {
101 rm -rf ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN} && mkdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
102 oe_mkext4fs ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext4
103 gzip -f -9 ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext4
104 mv ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}/${IMAGE_NAME}.rootfs.ext4.gz ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext4.gz
105 rmdir ${DEPLOY_DIR_IMAGE}/tmp.gz-${PN}
106}
107 124
108IMAGE_CMD_btrfs () { 125IMAGE_CMD_btrfs () {
109 mkfs.btrfs -b `expr ${ROOTFS_SIZE} \* 1024` ${EXTRA_IMAGECMD} -r ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.btrfs 126 mkfs.btrfs -b `expr ${ROOTFS_SIZE} \* 1024` ${EXTRA_IMAGECMD} -r ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.btrfs
@@ -112,9 +129,6 @@ IMAGE_CMD_btrfs () {
112IMAGE_CMD_squashfs = "mksquashfs ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.squashfs ${EXTRA_IMAGECMD} -noappend" 129IMAGE_CMD_squashfs = "mksquashfs ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.squashfs ${EXTRA_IMAGECMD} -noappend"
113IMAGE_CMD_squashfs-lzma = "mksquashfs-lzma ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.squashfs-lzma ${EXTRA_IMAGECMD} -noappend" 130IMAGE_CMD_squashfs-lzma = "mksquashfs-lzma ${IMAGE_ROOTFS} ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.squashfs-lzma ${EXTRA_IMAGECMD} -noappend"
114IMAGE_CMD_tar = "cd ${IMAGE_ROOTFS} && tar -cvf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.tar ." 131IMAGE_CMD_tar = "cd ${IMAGE_ROOTFS} && tar -cvf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.tar ."
115IMAGE_CMD_tar.gz = "cd ${IMAGE_ROOTFS} && tar -zcvf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.tar.gz ."
116IMAGE_CMD_tar.bz2 = "cd ${IMAGE_ROOTFS} && tar -jcvf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.tar.bz2 ."
117IMAGE_CMD_tar.xz = "cd ${IMAGE_ROOTFS} && tar --xz -cvf ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.tar.xz ."
118 132
119CPIO_TOUCH_INIT () { 133CPIO_TOUCH_INIT () {
120 if [ ! -L ${IMAGE_ROOTFS}/init ] 134 if [ ! -L ${IMAGE_ROOTFS}/init ]
@@ -126,18 +140,6 @@ IMAGE_CMD_cpio () {
126 ${CPIO_TOUCH_INIT} 140 ${CPIO_TOUCH_INIT}
127 cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio) 141 cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio)
128} 142}
129IMAGE_CMD_cpio.gz () {
130 ${CPIO_TOUCH_INIT}
131 cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc | gzip -c -9 >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio.gz)
132}
133IMAGE_CMD_cpio.xz () {
134 ${CPIO_TOUCH_INIT}
135 cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc | xz -c ${XZ_COMPRESSION_LEVEL} --check=${XZ_INTEGRITY_CHECK} > ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio.xz) ${EXTRA_IMAGECMD}
136}
137IMAGE_CMD_cpio.lzma () {
138 ${CPIO_TOUCH_INIT}
139 cd ${IMAGE_ROOTFS} && (find . | cpio -o -H newc | xz --format=lzma -c ${XZ_COMPRESSION_LEVEL} --check=${XZ_INTEGRITY_CHECK} >${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.cpio.lzma) ${EXTRA_IMAGECMD}
140}
141 143
142UBI_VOLNAME ?= "${MACHINE}-rootfs" 144UBI_VOLNAME ?= "${MACHINE}-rootfs"
143 145
@@ -159,9 +161,7 @@ EXTRA_IMAGECMD = ""
159EXTRA_IMAGECMD_jffs2 ?= "--pad --little-endian --eraseblock=0x40000" 161EXTRA_IMAGECMD_jffs2 ?= "--pad --little-endian --eraseblock=0x40000"
160# Change these if you want default genext2fs behavior (i.e. create minimal inode number) 162# Change these if you want default genext2fs behavior (i.e. create minimal inode number)
161EXTRA_IMAGECMD_ext2 ?= "-i 8192" 163EXTRA_IMAGECMD_ext2 ?= "-i 8192"
162EXTRA_IMAGECMD_ext2.gz ?= "-i 8192"
163EXTRA_IMAGECMD_ext3 ?= "-i 8192" 164EXTRA_IMAGECMD_ext3 ?= "-i 8192"
164EXTRA_IMAGECMD_ext3.gz ?= "-i 8192"
165EXTRA_IMAGECMD_btrfs ?= "" 165EXTRA_IMAGECMD_btrfs ?= ""
166 166
167IMAGE_DEPENDS = "" 167IMAGE_DEPENDS = ""
@@ -169,22 +169,25 @@ IMAGE_DEPENDS_jffs2 = "mtd-utils-native"
169IMAGE_DEPENDS_sum.jffs2 = "mtd-utils-native" 169IMAGE_DEPENDS_sum.jffs2 = "mtd-utils-native"
170IMAGE_DEPENDS_cramfs = "cramfs-native" 170IMAGE_DEPENDS_cramfs = "cramfs-native"
171IMAGE_DEPENDS_ext2 = "genext2fs-native" 171IMAGE_DEPENDS_ext2 = "genext2fs-native"
172IMAGE_DEPENDS_ext2.gz = "genext2fs-native"
173IMAGE_DEPENDS_ext2.bz2 = "genext2fs-native"
174IMAGE_DEPENDS_ext2.lzma = "genext2fs-native xz-native"
175IMAGE_DEPENDS_ext3 = "genext2fs-native e2fsprogs-native" 172IMAGE_DEPENDS_ext3 = "genext2fs-native e2fsprogs-native"
176IMAGE_DEPENDS_ext3.gz = "genext2fs-native e2fsprogs-native"
177IMAGE_DEPENDS_ext4 = "genext2fs-native e2fsprogs-native" 173IMAGE_DEPENDS_ext4 = "genext2fs-native e2fsprogs-native"
178IMAGE_DEPENDS_ext4.gz = "genext2fs-native e2fsprogs-native"
179IMAGE_DEPENDS_btrfs = "btrfs-tools-native" 174IMAGE_DEPENDS_btrfs = "btrfs-tools-native"
180IMAGE_DEPENDS_squashfs = "squashfs-tools-native" 175IMAGE_DEPENDS_squashfs = "squashfs-tools-native"
181IMAGE_DEPENDS_squashfs-lzma = "squashfs-lzma-tools-native" 176IMAGE_DEPENDS_squashfs-lzma = "squashfs-lzma-tools-native"
182IMAGE_DEPENDS_tar.xz = "tar-native xz-native"
183IMAGE_DEPENDS_cpio.lzma = "xz-native"
184IMAGE_DEPENDS_cpio.xz = "xz-native"
185IMAGE_DEPENDS_ubi = "mtd-utils-native" 177IMAGE_DEPENDS_ubi = "mtd-utils-native"
186IMAGE_DEPENDS_ubifs = "mtd-utils-native" 178IMAGE_DEPENDS_ubifs = "mtd-utils-native"
187IMAGE_DEPENDS_vmdk = "qemu-native" 179IMAGE_DEPENDS_vmdk = "qemu-native"
188 180
189# This variable is available to request which values are suitable for IMAGE_FSTYPES 181# This variable is available to request which values are suitable for IMAGE_FSTYPES
190IMAGE_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" 182IMAGE_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"
183
184COMPRESSIONTYPES = "gz bz2 lzma xz"
185COMPRESS_CMD_lzma = "lzma -k -f -7 ${IMAGE_NAME}.rootfs.${type}"
186COMPRESS_CMD_gz = "gzip -f -9 -c ${IMAGE_NAME}.rootfs.${type} > ${IMAGE_NAME}.rootfs.${type}.gz"
187COMPRESS_CMD_bz2 = "bzip2 -k ${IMAGE_NAME}.rootfs.${type}"
188COMPRESS_CMD_xz = "xz -k -c ${XZ_COMPRESSION_LEVEL} --check=${XZ_INTEGRITY_CHECK} ${IMAGE_NAME}.rootfs.${type}"
189COMPRESS_DEPENDS_lzma = "xz-native"
190COMPRESS_DEPENDS_gz = ""
191COMPRESS_DEPENDS_bz2 = ""
192COMPRESS_DEPENDS_xz = "xz-native"
193