]> www.infradead.org Git - mtd-utils.git/commitdiff
Makefile: introduce new target tests in Makefile
authorAndy Shevchenko <ext-andriy.shevchenko@nokia.com>
Thu, 7 Apr 2011 13:10:38 +0000 (16:10 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Thu, 7 Apr 2011 13:39:01 +0000 (16:39 +0300)
This patch appends Makefile to the tests subdirectory and introduces tests
target in the root Makefile.

Additionally the clean target removes temporary stuff under tests subdirectory
as well.

Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Makefile
tests/Makefile [new file with mode: 0644]

index 7ab97430c28db0f5dd9a7897bb990df6cfd279a5..1f264e93158e5293114ef2c9f1e78366ab589b8b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,7 @@ ifeq ($(WITHOUT_XATTR), 1)
 endif
 
 SUBDIRS = lib ubi-utils mkfs.ubifs
+TESTS = tests
 
 TARGETS = ftl_format flash_erase nanddump doc_loadbios \
        ftl_check mkfs.jffs2 flash_lock flash_unlock flash_info \
@@ -38,6 +39,7 @@ ifneq ($(BUILDDIR),$(CURDIR))
 endif
 endif
 endif
+       $(MAKE) -C $(TESTS) clean
 
 $(SYMLINKS):
        ln -sf ../fs/jffs2/$@ $@
@@ -59,3 +61,6 @@ install:: ${TARGETS} ${SCRIPTS}
        install -m 0755 ${TARGETS} ${SCRIPTS} ${DESTDIR}/${SBINDIR}/
        mkdir -p ${DESTDIR}/${MANDIR}/man1
        gzip -9c mkfs.jffs2.1 > ${DESTDIR}/${MANDIR}/man1/mkfs.jffs2.1.gz
+
+tests::
+       $(MAKE) -C $(TESTS)
diff --git a/tests/Makefile b/tests/Makefile
new file mode 100644 (file)
index 0000000..05b37e9
--- /dev/null
@@ -0,0 +1,8 @@
+
+SUBDIRS = checkfs fs-tests jittertest ubi-tests
+
+all clean tests: $(SUBDIRS)
+
+.PHONY: $(SUBDIRS)
+$(SUBDIRS):
+       $(MAKE) -C $@ $(MAKECMDGOALS)