- $(LINUX_IMAGE) -a 0x20000 $(IMAGE)-8MB.jffs2
-
-$(BIN_DIR)/openwrt-wrt54g-jffs2.bin: $(BIN_DIR)/openwrt-generic-jffs2-4MB.trx
- PATH=$(TARGET_PATH) addpattern -2 -i $< -o $@ -g
- $(SED) "1s,^W54S,W54G," $@
-
-$(BIN_DIR)/openwrt-wrt54gs-jffs2.bin: $(BIN_DIR)/openwrt-generic-jffs2-8MB.trx
- PATH=$(TARGET_PATH) addpattern -2 -i $< -o $@ -g
-
-$(BIN_DIR)/openwrt-motorola-jffs2-4MB.bin: $(BIN_DIR)/openwrt-generic-jffs2-4MB.trx
- PATH=$(TARGET_PATH) motorola-bin $< $@
-
-$(BIN_DIR)/openwrt-motorola-jffs2-8MB.bin: $(BIN_DIR)/openwrt-generic-jffs2-8MB.trx
- PATH=$(TARGET_PATH) motorola-bin $< $@
+ $(1)/kernel-image -a 0x10000 $(1)/root.jffs2-8MB
+endef
+
+FILESYSTEMS:=jffs2-4MB jffs2-8MB
+include ../image.mk
+
+source: $(DL_DIR)/$(MTD_SOURCE)
+prepare: $(MTD_DIR)/.unpacked
+compile: $(MTD_DIR)/util/mkfs.jffs2 $(STAGING_DIR)/bin/mkfs.jffs2
+install:
+clean:
+ rm -rf $(MTD_DIR)