[oe-commits] [openembedded-core] 06/19: image: use du --apparent-size when calculating rootfs size

git at git.openembedded.org git at git.openembedded.org
Thu Jan 11 23:24:06 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository openembedded-core.

commit 7b36cb308eb9dd0703a812cfa44fd79c38d82947
Author: Ross Burton <ross.burton at intel.com>
AuthorDate: Thu Jan 11 15:18:34 2018 +0000

    image: use du --apparent-size when calculating rootfs size
    
    We should pass --apparent-size to du when calculating how large the rootfs is as
    otherwise we get the actual disk usage, which if the files are compressed by the
    file system (such as ZFS) may be sufficiently smaller than the space required by
    the image that construction will fail.
    
    Signed-off-by: Ross Burton <ross.burton at intel.com>
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 meta/classes/image.bbclass | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index 4531aa2..8e763e4 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -534,6 +534,7 @@ def get_rootfs_size(d):
     initramfs_maxsize = d.getVar('INITRAMFS_MAXSIZE')
 
     output = subprocess.check_output(['du', '-ks',
+                                      '--apparent-size',
                                       d.getVar('IMAGE_ROOTFS')])
     size_kb = int(output.split()[0])
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list