+dir825b1_mtdlayout=mtdparts=spi0.0:256k(uboot)ro,64k(config)ro,1024k(kernel),5184k(rootfs),64k(caldata)ro,6208k@0x50000(firmware)
+define Image/Build/DIR825B1
+ $(call PatchKernelLzma,$(2),$(3) $(dir825b1_mtdlayout))
+ $(call MkImageLzma,$(KDIR)/vmlinux-$(2).bin.lzma,$(call imgname,$(1),$(2)).bin)
+ if [ `stat -c%s "$(call imgname,$(1),$(2)).bin"` -gt 1048576 ]; then \
+ echo "Warning: $(KDIR)/vmlinux-$(2).bin.lzma is too big"; \
+ rm -f $(call imgname,$(1),$(2)).bin; \
+ else if [ `stat -c%s $(KDIR)/root.$(1)` -gt 5308416 ]; then \
+ echo "Warning: $(KDIR)/root.$(1) is too big"; \
+ rm -f $(call imgname,$(1),$(2)).bin; \
+ else \
+ dd if=$(KDIR)/root.$(1) of=$(call imgname,$(1),$(2)).bin bs=1k seek=1024; \
+ cp $(call imgname,$(1),$(2)).bin $(call imgname,$(1),$(2))-backup-loader.bin; \
+ echo -n "01AP94-AR7161-RT-080619-00" >> $(call imgname,$(1),$(2))-backup-loader.bin; \
+ fi; fi
+endef
+