aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ramips
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2012-02-23 19:58:02 +0000
committerGabor Juhos <juhosg@openwrt.org>2012-02-23 19:58:02 +0000
commit6778182991fd9a6af843196347f2a5dd5ff0b305 (patch)
treeca7ba8b02ebf7a04ccaddf156ac12a057ff057ab /target/linux/ramips
parente93a3a188c03d37a5595480d9d0683de67f6d1f0 (diff)
downloadupstream-6778182991fd9a6af843196347f2a5dd5ff0b305.tar.gz
upstream-6778182991fd9a6af843196347f2a5dd5ff0b305.tar.bz2
upstream-6778182991fd9a6af843196347f2a5dd5ff0b305.zip
ramips: image: add MkImageLzma wrapper
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@30696 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/ramips')
-rw-r--r--target/linux/ramips/image/Makefile17
1 files changed, 9 insertions, 8 deletions
diff --git a/target/linux/ramips/image/Makefile b/target/linux/ramips/image/Makefile
index 29d1f25021..c5495620f4 100644
--- a/target/linux/ramips/image/Makefile
+++ b/target/linux/ramips/image/Makefile
@@ -46,6 +46,11 @@ define MkImage
-d $(2) $(3)
endef
+define MkImageLzma
+ $(call PatchKernelLzma,$(1),$(2))
+ $(call MkImage,lzma,$(KDIR)/vmlinux-$(1).bin.lzma,$(KDIR)/vmlinux-$(1).uImage)
+endef
+
define Image/BuildKernel
cp $(KDIR)/vmlinux.elf $(BIN_DIR)/$(VMLINUX).elf
cp $(KDIR)/vmlinux $(BIN_DIR)/$(VMLINUX).bin
@@ -56,8 +61,7 @@ define Image/BuildKernel
endef
define BuildFirmware/Generic
- $(call PatchKernelLzma,$(2),$(3) $($(4)))
- $(call MkImage,lzma,"$(KDIR)/vmlinux-$(2).bin.lzma","$(KDIR)/vmlinux-$(2).uImage")
+ $(call MkImageLzma,$(2),$(3) $($(4)))
if [ `stat -c%s "$(KDIR)/vmlinux-$(2).uImage"` -gt $(5) ]; then \
echo "Warning: $(KDIR)/vmlinux-$(2).uImage is too big"; \
else if [ `stat -c%s $(KDIR)/root.$(1)` -gt $(6) ]; then \
@@ -71,14 +75,12 @@ define BuildFirmware/Generic
endef
define BuildFirmware/Generic/initramfs
- $(call PatchKernelLzma,$(2),$(3) $($(4)))
- $(call MkImage,lzma,"$(KDIR)/vmlinux-$(2).bin.lzma","$(KDIR)/vmlinux-$(2).uImage")
+ $(call MkImageLzma,$(2),$(3) $($(4)))
$(CP) $(KDIR)/vmlinux-$(2).uImage $(call imgname,$(1),$(2))-uImage.bin
endef
define BuildFirmware/WL341V3
- $(call PatchKernelLzma,$(2),$(3) $($(4)))
- $(call MkImage,lzma,"$(KDIR)/vmlinux-$(2).bin.lzma","$(KDIR)/vmlinux-$(2).uImage")
+ $(call MkImageLzma,$(2),$(3) $($(4)))
if [ `stat -c%s "$(KDIR)/vmlinux-$(2).uImage"` -gt $(5) ]; then \
echo "Warning: $(KDIR)/vmlinux-$(2).uImage is too big"; \
else if [ `stat -c%s $(KDIR)/root.$(1)` -gt $(6) ]; then \
@@ -99,8 +101,7 @@ define BuildFirmware/WL341V3
endef
define BuildFirmware/Buffalo
- $(call PatchKernelLzma,$(2),board=$(3) $($(4)))
- $(call MkImage,lzma,"$(KDIR)/vmlinux-$(2).bin.lzma","$(KDIR)/vmlinux-$(2).uImage")
+ $(call MkImageLzma,$(2),board=$(3) $($(4)))
if [ `stat -c%s "$(KDIR)/vmlinux-$(2).uImage"` -gt $(5) ]; then \
echo "Warning: $(KDIR)/vmlinux-$(2).uImage is too big"; \
else if [ `stat -c%s $(KDIR)/root.$(1)` -gt $(6) ]; then \