]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/blob - tools/regression/filemon/Makefile
MFC: r242137: Iterate rather than use recursion. We can blow out the
[FreeBSD/stable/9.git] / tools / regression / filemon / Makefile
1 # $FreeBSD$
2
3 BINS=   \
4         filemontest \
5         timed-forkb
6
7 bins: filemontest timed-forkb
8 all: bins
9
10 NO_MAN=
11
12 WARNS?= 6
13 CFLAGS+= -I${.CURDIR}/../../../sys
14
15 # Should be "WITHOUT_CTF=" below, but stupid infastrurture fails:
16 # "/usr/share/mk/bsd.own.mk", line 489: WITH_CTF and WITHOUT_CTF can't both be set.
17 WITHOUT_CDDL=
18
19 CLEANFILES+=    ${BINS}
20
21 tests: bins
22         kldstat | grep filemon
23         ${MAKE} test
24         ./timed-forkb
25         @echo "filemon(4) tests passed."
26
27 # Cannot use .OBJDIR -- 'filemontest' expects 'test_script.sh' in .
28 #FILEMONTEST32= filemontest32
29 test: filemontest clean-test
30 .for BIN in filemontest ${FILEMONTEST32}
31         cd ${.CURDIR} ; \
32                 for A in 1 2 3 4 5 6 7 8 9 0; do \
33                 for B in 1 2 3 4 5 6 7 8 9 0; do \
34                 for C in 1 2 3 4 5 6 7 8 9 0; do \
35                         test -x ${BIN} && ${.OBJDIR}/${BIN} ;\
36                 done ;\
37                 done ;\
38                 done
39         @cd ${.CURDIR} ; set +e ; egrep '(Start|Stop) .*\.' filemon_log.* | \
40             grep -q -v '\.[0-9][0-9][0-9][0-9][0-9][0-9]$$' || echo "Time stamp format OK"
41 .endfor
42
43 clean-test:
44         cd ${.CURDIR} ; rm -f filemon_log.*
45
46 .include <bsd.prog.mk>