mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-11-24 07:51:55 +02:00
ar71xx: allow WNDR3700 image creation to fail if kernel/rootfs too big
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@29431 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
735b44ac69
commit
71573bb739
@ -384,26 +384,24 @@ define Image/Build/Netgear
|
|||||||
if [ `stat -c%s '$(KDIR)/vmlinux-$(2).uImage.squashfs'` -gt \
|
if [ `stat -c%s '$(KDIR)/vmlinux-$(2).uImage.squashfs'` -gt \
|
||||||
`cat '$(KDIR)/$(2)_kernel_maxsize'` ]; then \
|
`cat '$(KDIR)/$(2)_kernel_maxsize'` ]; then \
|
||||||
echo "$(KDIR)/vmlinux-$(2).uImage.squashfs is too big" >& 2; \
|
echo "$(KDIR)/vmlinux-$(2).uImage.squashfs is too big" >& 2; \
|
||||||
false; \
|
else if [ `stat -c%s '$(KDIR)/root.$(1)'` -gt \
|
||||||
fi
|
|
||||||
if [ `stat -c%s '$(KDIR)/root.$(1)'` -gt \
|
|
||||||
`cat '$(KDIR)/$(2)_rootfs_maxsize'` ]; then \
|
`cat '$(KDIR)/$(2)_rootfs_maxsize'` ]; then \
|
||||||
echo "$(KDIR)/root.$(1) is too big" >& 2; \
|
echo "$(KDIR)/root.$(1) is too big" >& 2; \
|
||||||
false; \
|
else \
|
||||||
fi
|
|
||||||
( \
|
( \
|
||||||
set -e; \
|
set -e; \
|
||||||
dd if=$(KDIR)/vmlinux-$(2).uImage.squashfs \
|
dd if=$(KDIR)/vmlinux-$(2).uImage.squashfs \
|
||||||
bs=`cat '$(KDIR)/$(2)_kernel_maxsize'` conv=sync; \
|
bs=`cat '$(KDIR)/$(2)_kernel_maxsize'` conv=sync; \
|
||||||
dd if=$(KDIR)/root.$(1) bs=64k; \
|
dd if=$(KDIR)/root.$(1) bs=64k; \
|
||||||
) > $(call sysupname,$(1),$(2))
|
) > $(call sysupname,$(1),$(2)); \
|
||||||
for r in $(7) ; do \
|
for r in $(7) ; do \
|
||||||
[ -n "$$$$r" ] && dashr="-$$$$r" || dashr= ; \
|
[ -n "$$$$r" ] && dashr="-$$$$r" || dashr= ; \
|
||||||
$(STAGING_DIR_HOST)/bin/mkdniimg \
|
$(STAGING_DIR_HOST)/bin/mkdniimg \
|
||||||
-B $(6) -v OpenWrt.$(REVISION) -r "$$$$r" $(8) \
|
-B $(6) -v OpenWrt.$(REVISION) -r "$$$$r" $(8) \
|
||||||
-i $(call sysupname,$(1),$(2)) \
|
-i $(call sysupname,$(1),$(2)) \
|
||||||
-o $(call imgname,$(1),$(2))-factory$$$$dashr.img; \
|
-o $(call imgname,$(1),$(2))-factory$$$$dashr.img; \
|
||||||
done
|
done; \
|
||||||
|
fi; fi
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Image/Build/Netgear/initramfs
|
define Image/Build/Netgear/initramfs
|
||||||
|
Loading…
Reference in New Issue
Block a user