summaryrefslogtreecommitdiff
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <rpurdie@linux.intel.com>2009-01-23 16:24:46 +0000
committerRichard Purdie <rpurdie@linux.intel.com>2009-01-23 16:24:46 +0000
commitc92acf4b05329a8c08564a2c0f7f256810c5a1d2 (patch)
tree103e0a934ddf0aa60b28172ea79ad35766766cd5 /meta
parent7b6ad5b9fb0a004cba5a5ff59004aa795ddf0a87 (diff)
downloadopenembedded-core-c92acf4b05329a8c08564a2c0f7f256810c5a1d2.tar.gz
openembedded-core-c92acf4b05329a8c08564a2c0f7f256810c5a1d2.tar.bz2
openembedded-core-c92acf4b05329a8c08564a2c0f7f256810c5a1d2.zip
image.bbclass: Use IMAGE_ROOTFS_SIZE if the image will fit into it and only add extra space if the image is too small (ported from OE by hrw)
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/image.bbclass2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index f16dcc20ff..8225980f73 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -126,7 +126,7 @@ fakeroot do_rootfs () {
${IMAGE_PREPROCESS_COMMAND}
- ROOTFS_SIZE=`du -ks ${IMAGE_ROOTFS}|awk '{print ${IMAGE_EXTRA_SPACE} + $1}'`
+ ROOTFS_SIZE=`du -ks ${IMAGE_ROOTFS}|awk '{size = ${IMAGE_EXTRA_SPACE} + $1; print (size > ${IMAGE_ROOTFS_SIZE} ? size : ${IMAGE_ROOTFS_SIZE}) }'`
${@get_imagecmds(d)}
${IMAGE_POSTPROCESS_COMMAND}