summaryrefslogtreecommitdiff
path: root/target/linux/brcm-2.4/image/Makefile
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2007-05-15 18:41:48 +0000
committerFelix Fietkau <nbd@openwrt.org>2007-05-15 18:41:48 +0000
commit63300d3d91376573cbe837e745483d9b20d77c17 (patch)
treef4b2b58543e5acadbb67f0832e323df46c4ac920 /target/linux/brcm-2.4/image/Makefile
parent5015ad650c5b0586beddaa7270714c532090c2c0 (diff)
downloadmtk-20170518-63300d3d91376573cbe837e745483d9b20d77c17.zip
mtk-20170518-63300d3d91376573cbe837e745483d9b20d77c17.tar.gz
mtk-20170518-63300d3d91376573cbe837e745483d9b20d77c17.tar.bz2
Fix broadcom squashfs images:
We switched over to appending the jffs2 eof mark to the squashfs images, but since the squashfs is not always aligned to eraseblocksize, the eof mark landed in the wrong place. This commit adds an extra flag to the trx utility that can append extra data to a partition with alignment. This is used to place the jffs2 eof mark at the right offset. SVN-Revision: 7253
Diffstat (limited to 'target/linux/brcm-2.4/image/Makefile')
-rw-r--r--target/linux/brcm-2.4/image/Makefile16
1 files changed, 7 insertions, 9 deletions
diff --git a/target/linux/brcm-2.4/image/Makefile b/target/linux/brcm-2.4/image/Makefile
index 6515d13..46c660f 100644
--- a/target/linux/brcm-2.4/image/Makefile
+++ b/target/linux/brcm-2.4/image/Makefile
@@ -19,6 +19,9 @@ define Image/Prepare
TARGET="$(KDIR)" \
clean install
echo -ne "\\x00" >> $(KDIR)/loader.gz
+ rm -f $(KDIR)/fs_mark
+ touch $(KDIR)/fs_mark
+ $(call prepare_generic_squashfs,$(KDIR)/fs_mark)
endef
ifneq ($(KERNEL),2.4)
@@ -41,22 +44,17 @@ define Image/Build/USR
endef
define trxalign/jffs2-128k
--a 0x20000
+-a 0x20000 -f $(KDIR)/root.$(1)
endef
define trxalign/jffs2-64k
--a 0x10000
+-a 0x10000 -f $(KDIR)/root.$(1)
endef
define trxalign/squashfs
--a 1024
-endef
-
-define Image/Build/squashfs
- $(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
+-a 1024 -f $(KDIR)/root.$(1) -a 0x10000 -A $(KDIR)/fs_mark
endef
define Image/Build
- $(call Image/Build/$(1))
- $(STAGING_DIR)/bin/trx -o $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).trx -f $(KDIR)/loader.gz -f $(KDIR)/vmlinux.lzma $(call trxalign/$(1)) -f $(KDIR)/root.$(1)
+ $(STAGING_DIR)/bin/trx -o $(BIN_DIR)/openwrt-$(BOARD)-$(KERNEL)-$(1).trx -f $(KDIR)/loader.gz -f $(KDIR)/vmlinux.lzma $(call trxalign/$(1),$(1))
ifneq ($(1),jffs2-128k)
$(call Image/Build/CyberTAN,$(1),wrt54g3g,W54F,2.01.1,$(patsubst jffs2-%,jffs2,$(1)))
$(call Image/Build/CyberTAN,$(1),wrt54g,W54G,4.60.1,$(patsubst jffs2-%,jffs2,$(1)))