aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/x86/image/Makefile
diff options
context:
space:
mode:
authorTomasz Maciej Nowak <tomek_n@o2.pl>2020-01-14 18:45:43 +0100
committerPetr Štetiar <ynezz@true.cz>2020-03-01 21:36:00 +0100
commit48873ace4e4bca9cb5de05b7e0a229c221bece34 (patch)
treecc4e9c7e0530d280cfcc36dcdc0704d627b9a4f1 /target/linux/x86/image/Makefile
parent1d8f21e3a088c6eb23426bab175dcf81403c52e2 (diff)
downloadupstream-48873ace4e4bca9cb5de05b7e0a229c221bece34.tar.gz
upstream-48873ace4e4bca9cb5de05b7e0a229c221bece34.tar.bz2
upstream-48873ace4e4bca9cb5de05b7e0a229c221bece34.zip
x86: image: cleanup before creating image
There can be some leftovers from other image recipes, if the same directory names are used and multiply image types are selected. Therefore remove directories used in the recipe, before contents for the image are prepared. Signed-off-by: Tomasz Maciej Nowak <tomek_n@o2.pl>
Diffstat (limited to 'target/linux/x86/image/Makefile')
-rw-r--r--target/linux/x86/image/Makefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index eb0db417a3..2838b3139c 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -60,6 +60,7 @@ ifneq ($(CONFIG_GRUB_IMAGES),)
define Image/Build/grub2
# left here because the image builder doesnt need these
+ rm -fR $(KDIR)/root.grub $(KDIR)/grub2
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \
@@ -93,6 +94,7 @@ ifneq ($(CONFIG_GRUB_IMAGES),)
endif
define Image/Build/iso
+ rm -fR $(KDIR)/root.grub $(KDIR)/grub2
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \