ar71xx: generate US- and EU-specific images for the Archer C7 v2
[openwrt/openwrt.git] / include / image-commands.mk
index 790e9297ca66840ae0446b95cb13f7a7fa67b058..00cb3410e95631a7808b8a624d0ee32f0445907c 100644 (file)
@@ -7,7 +7,7 @@ define Build/uImage
        mkimage -A $(LINUX_KARCH) \
                -O linux -T kernel \
                -C $(1) -a $(KERNEL_LOADADDR) -e $(if $(KERNEL_ENTRY),$(KERNEL_ENTRY),$(KERNEL_LOADADDR)) \
-               -n '$(call toupper,$(LINUX_KARCH)) LEDE Linux-$(LINUX_VERSION)' -d $@ $@.new
+               -n '$(if $(UIMAGE_NAME),$(UIMAGE_NAME),$(call toupper,$(LINUX_KARCH)) LEDE Linux-$(LINUX_VERSION))' -d $@ $@.new
        @mv $@.new $@
 endef
 
@@ -46,6 +46,14 @@ define Build/append-dtb
        cat $@.dtb >> $@
 endef
 
+define Build/install-dtb
+       $(foreach dts,$(DEVICE_DTS), \
+               $(CP) \
+                       $(DTS_DIR)/$(dts).dtb \
+                       $(BIN_DIR)/$(IMG_PREFIX)-$(dts).dtb; \
+       )
+endef
+
 define Build/fit
        $(TOPDIR)/scripts/mkits.sh \
                -D $(DEVICE_NAME) -o $@.its -k $@ \