summaryrefslogtreecommitdiff
path: root/ubi-utils/scripts/Makefile
diff options
context:
space:
mode:
authorFrank Haverkamp <haver@vnet.ibm.com>2006-06-21 15:28:37 +0200
committerFrank Haverkamp <haver@vnet.ibm.com>2006-10-31 15:06:07 +0100
commitb366fb2eb4fa3b72766e25550b5643928e581c91 (patch)
treecd4bb0e1d36c7529c80af08296b3d270a61402c7 /ubi-utils/scripts/Makefile
parentbe43152d316c90a0c04aae1ed033ceaa69edbc72 (diff)
[MTD] UBI: Enhanced example for testing.
Signed-off-by: Frank Haverkamp <haver@vnet.ibm.com>
Diffstat (limited to 'ubi-utils/scripts/Makefile')
-rw-r--r--ubi-utils/scripts/Makefile26
1 files changed, 22 insertions, 4 deletions
diff --git a/ubi-utils/scripts/Makefile b/ubi-utils/scripts/Makefile
index 6d014ea..e8850fd 100644
--- a/ubi-utils/scripts/Makefile
+++ b/ubi-utils/scripts/Makefile
@@ -21,21 +21,39 @@ dd = dd
sed = sed
bin2nand = bin2nand
ubigen = ubigen
-mkpfi = mkpfi
-pfi2bin = pfi2bin
+mkpfi = mkpfi -v
+pfi2bin = pfi2bin -v
vmlinux_bin ?= test_vmlinux.bin
rootfs_bin ?= test_rootfs.bin
spl_bin ?= test_u-boot.bin
+pdd_txt ?= pdd.txt
+
+flashtype ?= nand
+pagesize ?= 2048
compl ?= $(card)_complete
compl_pfi ?= $(compl).pfi
+compl_img ?= $(compl).img
+
+compl_nand2048_mif=$(compl).$(flashtype)$(pagesize).mif
+compl_nand2048_img=$(compl).$(flashtype)$(pagesize).img
-all: $(compl_pfi)
+all: $(compl_pfi) $(compl_nand2048_mif)
$(compl_pfi): $(vmlinux_bin) $(rootfs_bin) $(spl_bin)
$(mkpfi) -c $(mkpfi_cfg)
+# Binary data and out of band data (OOB)
+#
+$(compl_nand2048_mif): $(compl_img)
+ $(bin2nand) -p $(pagesize) -o $(compl_nand2048_mif) $<
+
+# Binary data only
+#
+$(compl_img): $(compl_pfi)
+ $(pfi2bin) -j $(pdd_txt) -o $@ $<
+
#
# Default data
#
@@ -54,4 +72,4 @@ clean:
$(RM) *.pfi *~
distclean: clean
- $(RM) *.bin
+ $(RM) *.bin *.mif *.oob *.img