diff options
author | Joseph C. Lehner <joseph.c.lehner@gmail.com> | 2017-01-27 16:10:40 +0100 |
---|---|---|
committer | Mathias Kresin <dev@kresin.me> | 2017-02-04 13:46:48 +0100 |
commit | 7d00cfe9bb693e376ac9d035e13f8ce8a5ff572c (patch) | |
tree | 347422bb10d73b805370743dc023bafd5e155457 /include | |
parent | c1eae7a7b8c272bca1a9ab489b1ceb6434021121 (diff) | |
download | upstream-7d00cfe9bb693e376ac9d035e13f8ce8a5ff572c.tar.gz upstream-7d00cfe9bb693e376ac9d035e13f8ce8a5ff572c.tar.bz2 upstream-7d00cfe9bb693e376ac9d035e13f8ce8a5ff572c.zip |
build: centralize fakeroot code
This patch moves the fakeroot code required by some devices to
`image-commands.mk`.
Create the fakeroot on the fly by using the undocumented -s (skip copy)
parameter of mkimage.
Signed-off-by: Joseph C. Lehner <joseph.c.lehner@gmail.com>
[remove unused NETGEAR_KERNEL_MAGIC, remove workarounds to have a dummy
rootfs for mkimage]
Signed-off-by: Mathias Kresin <dev@kresin.me>
Diffstat (limited to 'include')
-rw-r--r-- | include/image-commands.mk | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/include/image-commands.mk b/include/image-commands.mk index 7d124ece19..49e438954a 100644 --- a/include/image-commands.mk +++ b/include/image-commands.mk @@ -62,6 +62,18 @@ define Build/netgear-dni mv $@.new $@ endef +# append a fake/empty rootfs uImage header, to fool the bootloaders +# rootfs integrity check +define Build/append-uImage-fakeroot-hdr + rm -f $@.fakeroot + $(STAGING_DIR_HOST)/bin/mkimage \ + -A $(LINUX_KARCH) -O linux -T filesystem -C none \ + -n '$(call toupper,$(LINUX_KARCH)) LEDE fakeroot' \ + -s \ + $@.fakeroot + cat $@.fakeroot >> $@ +endef + define Build/tplink-safeloader -$(STAGING_DIR_HOST)/bin/tplink-safeloader \ -B $(TPLINK_BOARD_NAME) \ @@ -143,10 +155,6 @@ define Build/append-rootfs dd if=$(IMAGE_ROOTFS) >> $@ endef -define Build/append-file - cat "$(1)" >> "$@" -endef - define Build/append-ubi sh $(TOPDIR)/scripts/ubinize-image.sh \ $(if $(UBOOTENV_IN_UBI),--uboot-env) \ |