diff options
| author | Gary Thomas <gary@mlbassoc.com> | 2015-06-15 08:41:33 -0600 |
|---|---|---|
| committer | Otavio Salvador <otavio@ossystems.com.br> | 2015-06-15 12:12:23 -0300 |
| commit | 2fe7195eefe7167f7bc47e18c08e56c979adebdb (patch) | |
| tree | 1d5368472a0c8f3c91e51575549b3ff6cb28ae27 | |
| parent | 753cce319da4af5138fb023fecba86551aada7b9 (diff) | |
| download | meta-freescale-2fe7195eefe7167f7bc47e18c08e56c979adebdb.tar.gz | |
image_types_fsl: Fix boot.img overwrite error
Recent updates to the MSDOS tools (OE-core is now at 3.0.28) have made
it an error to overwrite an image using mkfs.vfat:
mkfs.vfat: file XXXX/tmp/work/nitrogen6x-poky-linux-gnueabi/network-demo-image/1.0-r0/boot.img already exists
mkfs.fat 3.0.28 (2015-05-16)
WARNING: exit code 1 from a shell command.
This patch fixes the problem by removing any old/stale images before
trying to create the VFAT file system images.
Change-Id: I74e02fd512b43315b29698f534192632d7780df2
Signed-off-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
| -rw-r--r-- | meta-fsl-arm/classes/image_types_fsl.bbclass | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/meta-fsl-arm/classes/image_types_fsl.bbclass b/meta-fsl-arm/classes/image_types_fsl.bbclass index 1ebcb0637..b542549da 100644 --- a/meta-fsl-arm/classes/image_types_fsl.bbclass +++ b/meta-fsl-arm/classes/image_types_fsl.bbclass | |||
| @@ -152,6 +152,7 @@ generate_imx_sdcard () { | |||
| 152 | # Create boot partition image | 152 | # Create boot partition image |
| 153 | BOOT_BLOCKS=$(LC_ALL=C parted -s ${SDCARD} unit b print \ | 153 | BOOT_BLOCKS=$(LC_ALL=C parted -s ${SDCARD} unit b print \ |
| 154 | | awk '/ 1 / { print substr($4, 1, length($4 -1)) / 1024 }') | 154 | | awk '/ 1 / { print substr($4, 1, length($4 -1)) / 1024 }') |
| 155 | rm -f ${WORKDIR}/boot.img | ||
| 155 | mkfs.vfat -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS | 156 | mkfs.vfat -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS |
| 156 | mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${MACHINE}.bin ::/${KERNEL_IMAGETYPE} | 157 | mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${MACHINE}.bin ::/${KERNEL_IMAGETYPE} |
| 157 | 158 | ||
| @@ -255,6 +256,7 @@ generate_mxs_sdcard () { | |||
| 255 | BOOT_BLOCKS=$(LC_ALL=C parted -s ${SDCARD} unit b print \ | 256 | BOOT_BLOCKS=$(LC_ALL=C parted -s ${SDCARD} unit b print \ |
| 256 | | awk '/ 2 / { print substr($4, 1, length($4 -1)) / 1024 }') | 257 | | awk '/ 2 / { print substr($4, 1, length($4 -1)) / 1024 }') |
| 257 | 258 | ||
| 259 | rm -f ${WORKDIR}/boot.img | ||
| 258 | mkfs.vfat -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS | 260 | mkfs.vfat -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS |
| 259 | mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${MACHINE}.bin ::/${KERNEL_IMAGETYPE} | 261 | mcopy -i ${WORKDIR}/boot.img -s ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${MACHINE}.bin ::/${KERNEL_IMAGETYPE} |
| 260 | if test -n "${KERNEL_DEVICETREE}"; then | 262 | if test -n "${KERNEL_DEVICETREE}"; then |
