uboot-at91: fix DTC command not found.
[openwrt/openwrt.git] / target / linux / at91 / image / sama5.mk
index 5960f40a3baa21ed8d585be8115e981bb2754572..fd7a53421eb4f0895e1c615d5fc840a89196e0b8 100644 (file)
@@ -4,6 +4,7 @@ FAT32_BLOCKS:=$(shell echo \
   $$(($(AT91_SD_BOOT_PARTSIZE)*1024*1024/$(FAT32_BLOCK_SIZE))))
 
 define Build/at91-sdcard
+  $(if $(findstring ext4,$@), \
   rm -f $@.boot
   mkfs.fat -C $@.boot $(FAT32_BLOCKS)
 
@@ -30,7 +31,7 @@ define Build/at91-sdcard
 
   gzip -nc9 $@.img > $@
 
-  rm -f $@.img $@.boot
+  rm -f $@.img $@.boot )
 endef
 
 define Device/evaluation-sdimage