aboutsummaryrefslogtreecommitdiffstats
path: root/classes
diff options
context:
space:
mode:
authorSamuli Piippo <samuli.piippo@qt.io>2017-05-09 17:14:48 +0300
committerSamuli Piippo <samuli.piippo@qt.io>2017-05-10 05:25:08 +0000
commit4e74c20af2b1aa98ff47398a8cb325cdd0a246c3 (patch)
tree83288cc552df7d556c882f1c5827165096c2a696 /classes
parent69c064fffc5867f243e0be4038979a16ba642025 (diff)
image_dd: remove old boot.img before trying to create it
rootfs creation failed if boot.img still existed from previous build. Change-Id: Ib85cc7dbacbc0d0cc7d0700985ad9c52a6ade0df Reviewed-by: Mikko Gronoff <mikko.gronoff@qt.io>
Diffstat (limited to 'classes')
-rw-r--r--classes/image_dd.bbclass1
1 files changed, 1 insertions, 0 deletions
diff --git a/classes/image_dd.bbclass b/classes/image_dd.bbclass
index e0addf79..e05536b2 100644
--- a/classes/image_dd.bbclass
+++ b/classes/image_dd.bbclass
@@ -73,6 +73,7 @@ IMAGE_CMD_dd() {
# Create boot partition image
BOOT_BLOCKS=$(LC_ALL=C parted -s ${IMAGE} unit b print \
| awk '/ 1 / { print substr($4, 1, length($4 -1)) / 1024 }')
+ rm -f ${WORKDIR}/boot.img
mkfs.vfat -n "${BOOTDD_VOLUME_ID}" -S 512 -C ${WORKDIR}/boot.img $BOOT_BLOCKS
do_populate_boot