ramips: move edimax images to the new build code
[openwrt/openwrt.git] / target / linux / ramips / image / Makefile
index 39da5e09c0a791f1a3e11af2b0c6faf3627db4e0..ea7ff7e92b4920133912f535fb2c6e2adfb6572f 100644 (file)
@@ -22,7 +22,7 @@ define Image/Build/Initramfs
        $(call Image/Build/Profile/$(PROFILE),initramfs)
 endef
 
-DEVICE_VARS += DTS IMAGE_SIZE KERNEL_SIZE
+DEVICE_VARS += DTS IMAGE_SIZE
 
 loadaddr-y := 0x80000000
 loadaddr-$(CONFIG_TARGET_ramips_rt288x) := 0x88000000
@@ -78,6 +78,11 @@ define Build/umedia-header
        fix-u-media-header -T 0x46 -B $(1) -i $@ -o $@.new && mv $@.new $@
 endef
 
+define Build/edimax-header
+       $(STAGING_DIR_HOST)/bin/mkedimaximg -i $@ -o $@.new $(1)
+       @mv $@.new $@
+endef
+
 define Build/senao-header
        $(STAGING_DIR_HOST)/bin/mksenaofw $(1) -e $@ -o $@.new
        mv $@.new $@
@@ -210,38 +215,6 @@ define BuildFirmware/DefaultDualSize/initramfs
        $(call BuildFirmware/OF/initramfs,$(1),$(2)-8M,$(3)-8M)
 endef
 
-# build Seama header images
-define BuildFirmware/Seama/squashfs
-       $(call MkImageLzmaDtb,$(2),$(3),$(5))
-       $(eval output_name=$(IMG_PREFIX)-$(2)-$(1)-sysupgrade.bin)
-       cat $(KDIR)/vmlinux-$(2).bin.lzma $(KDIR)/root.$(1) > $(KDIR)/img_$(2).$(1).tmp
-       if [ `stat -c%s "$(KDIR)/img_$(2).$(1).tmp"` -gt $(5) ]; then \
-               echo "Warning: $(KDIR)/img_$(2).$(1).tmp is too big" >&2; \
-       else \
-               dd if=$(KDIR)/vmlinux-$(2).bin.lzma of=$(KDIR)/vmlinux-$(2).bin.lzma.padded bs=64k conv=sync; \
-               ( \
-                       dd if=$(KDIR)/vmlinux-$(2).bin.lzma.padded bs=1 count=`expr \`stat -c%s $(KDIR)/vmlinux-$(2).bin.lzma.padded\` - 64`; \
-                       dd if=$(KDIR)/root.$(1) bs=64k conv=sync; \
-               ) > $(KDIR)/vmlinux-$(2).tmp; \
-               $(STAGING_DIR_HOST)/bin/seama \
-                       -i $(KDIR)/vmlinux-$(2).tmp \
-                       -m "dev=/dev/mtdblock/2" -m "type=firmware"; \
-               $(STAGING_DIR_HOST)/bin/seama \
-                       -s $(call imgname,$(1),$(2))-factory.bin \
-                       -m "signature=$(4)" \
-                       -i $(KDIR)/vmlinux-$(2).tmp.seama; \
-               dd if=$(KDIR)/vmlinux-$(2).bin.lzma.padded bs=1 count=`expr \`stat -c%s $(KDIR)/vmlinux-$(2).bin.lzma.padded\` - 64` of=$(KDIR)/vmlinux-$(2)-sysupgrade.tmp; \
-               $(STAGING_DIR_HOST)/bin/seama \
-                       -i $(KDIR)/vmlinux-$(2)-sysupgrade.tmp \
-                       -m "dev=/dev/mtdblock/2" -m "type=firmware"; \
-               ( \
-                       dd if=$(KDIR)/vmlinux-$(2)-sysupgrade.tmp.seama; \
-                       dd if=$(KDIR)/root.$(1) bs=64k conv=sync; \
-               ) > $(BIN_DIR)/$(output_name); \
-       fi
-endef
-BuildFirmware/Seama/initramfs=$(call BuildFirmware/OF/initramfs,$(1),$(2),$(3))
-
 define BuildFirmware/PorayDualSize/squashfs
        $(call BuildFirmware/DefaultDualSize/$(1),$(1),$(2),$(3))
        if [ -e "$(call sysupname,$(1),$(2)-4M)" ]; then \