aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ipq806x/image/Makefile
diff options
context:
space:
mode:
authorJoseph C. Lehner <joseph.c.lehner@gmail.com>2017-01-27 16:10:40 +0100
committerMathias Kresin <dev@kresin.me>2017-02-04 13:46:48 +0100
commit7d00cfe9bb693e376ac9d035e13f8ce8a5ff572c (patch)
tree347422bb10d73b805370743dc023bafd5e155457 /target/linux/ipq806x/image/Makefile
parentc1eae7a7b8c272bca1a9ab489b1ceb6434021121 (diff)
downloadupstream-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 'target/linux/ipq806x/image/Makefile')
-rw-r--r--target/linux/ipq806x/image/Makefile11
1 files changed, 3 insertions, 8 deletions
diff --git a/target/linux/ipq806x/image/Makefile b/target/linux/ipq806x/image/Makefile
index 33dc31d41e..b00e197586 100644
--- a/target/linux/ipq806x/image/Makefile
+++ b/target/linux/ipq806x/image/Makefile
@@ -9,12 +9,6 @@ KERNEL_LOADADDR := 0x42208000
define Image/Prepare
$(CP) $(LINUX_DIR)/vmlinux $(KDIR)/$(IMG_PREFIX)-vmlinux.elf
- mkimage -A arm -O linux -T filesystem -C none \
- -a $(KERNEL_LOADADDR) -e $(KERNEL_LOADADDR) \
- -n 'ARM OpenWrt fakeroot' \
- -s $(KDIR_TMP)/root.dummy-uImage.tmp
- echo -ne '\xff' > $(KDIR_TMP)/root.dummy
- cat $(KDIR_TMP)/root.dummy $(KDIR_TMP)/root.dummy-uImage.tmp > $(KDIR)/root.dummy
endef
define Image/BuildKernel
@@ -64,7 +58,8 @@ define Device/DniImage
FILESYSTEMS := squashfs
KERNEL_SUFFIX := -uImage
KERNEL_INITRAMFS := kernel-bin | append-dtb | uImage none
- KERNEL = kernel-bin | append-dtb | pad-to $$$$(($$(KERNEL_SIZE)-2*64-1)) | uImage none | append-file $(KDIR)/root.dummy
+ KERNEL = kernel-bin | append-dtb | uImage none | pad-offset $$(KERNEL_SIZE) 64 | \
+ append-uImage-fakeroot-hdr
KERNEL_NAME := zImage
NETGEAR_BOARD_ID :=
NETGEAR_HW_ID :=
@@ -161,7 +156,7 @@ define Device/EA8500
BLOCKSIZE := 128k
KERNEL_SIZE := 3072k
FILESYSTEMS := squashfs
- KERNEL = kernel-bin | append-dtb | uImage none | append-file $(KDIR)/root.dummy
+ KERNEL = kernel-bin | append-dtb | uImage none | append-uImage-fakeroot-hdr
PROFILES += $$(DEVICE_NAME)
BOARD_NAME := ea8500
UBINIZE_OPTS := -E 5