[yocto] [meta-raspberrypi] du giving non-integer result?
Khem Raj
raj.khem at gmail.com
Mon Sep 7 00:21:42 PDT 2015
> On Sep 6, 2015, at 7:40 PM, Trevor Woerner <twoerner at gmail.com> wrote:
>
> I can't explain why, but when I build "core-image-minimal" for
> MACHINE=raspberrpi2 I get the following SD creation error:
>
which shell do you use for /bin/sh
> ERROR: Error: The image creation script
> '/z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/core-image-minimal/1.0-r0/temp/create_image.rpi-sdimg'
> returned 2:
> expr: non-integer argument
> WARNING:
> /z/layerindex-master/raspi2/tmp/work/raspberrypi2-poky-linux-gnueabi/core-image-minimal/1.0-r0/temp/create_image.rpi-sdimg:1
> exit 2 from
> ROOTFS_SIZE_ALIGNED=$(expr 12288.0 + 4096 - 1)
>
>
> Looking at meta-raspberrypi/classes/sdcard_image-rpi.bbclass, line 83:
>
> ROOTFS_SIZE_ALIGNED=$(expr ${ROOTFS_SIZE} +
> ${IMAGE_ROOTFS_ALIGNMENT} - 1)
>
> which looks like the offending line. ROOTFS_SIZE seems to come from the
> line immediately above:
>
> ROOTFS_SIZE=`du -bks ${SDIMG_ROOTFS} | awk '{print $1}'`
>
> But 'du' doesn't return non-integer values, does it? When I invoke the
> host's 'du' I get the correct value:
>
> du -bks
> /z/layerindex-master/raspi2/tmp/deploy/images/raspberrypi2/core-image-minimal-raspberrypi2-20150906234844.rootfs.ext3
> | awk '{print $1}'
> 12288
>
> Does anyone have any idea why the ".0" is getting tacked on?
>
> Best regards,
> Trevor
> --
> _______________________________________________
> yocto mailing list
> yocto at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 204 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20150907/8073b8cb/attachment.pgp>
More information about the yocto
mailing list