summaryrefslogtreecommitdiff
path: root/examples/hello_lex
diff options
context:
space:
mode:
Diffstat (limited to 'examples/hello_lex')
-rw-r--r--examples/hello_lex/Makefile6
-rw-r--r--examples/hello_lex/expect.out39
-rw-r--r--examples/hello_lex/test.mk20
3 files changed, 59 insertions, 6 deletions
diff --git a/examples/hello_lex/Makefile b/examples/hello_lex/Makefile
index 211e442..e21d074 100644
--- a/examples/hello_lex/Makefile
+++ b/examples/hello_lex/Makefile
@@ -1,5 +1,7 @@
-PROG = hello_lex
-SRCS = hello_lex.l
+PROG = hello_lex
+SRCS = hello_lex.l
+
+DPSRCS = hello_lex.c
.include "test.mk"
.include <mkc.prog.mk>
diff --git a/examples/hello_lex/expect.out b/examples/hello_lex/expect.out
index 4862fd7..7e6f996 100644
--- a/examples/hello_lex/expect.out
+++ b/examples/hello_lex/expect.out
@@ -33,13 +33,50 @@
/objdir/hello_lex.test.out.tmp
/objdir/input.txt
/objdir/test.mk
-==== SHRTOUT=yes ====
+========== depend ===========
+/objdir/.depend
+/objdir/Makefile
+/objdir/_mkc_compiler_type.err
+/objdir/_mkc_compiler_type.res
+/objdir/_mkc_prog_cc.err
+/objdir/_mkc_prog_cc.res
+/objdir/_mkc_prog_lex.err
+/objdir/_mkc_prog_lex.res
+/objdir/expect.out
+/objdir/hello_lex.c
+/objdir/hello_lex.d
+/objdir/hello_lex.l
+/objdir/hello_lex.test.out.tmp
+/objdir/input.txt
+/objdir/test.mk
+==== SHRTOUT=yes depend ====
checking for compiler mmm... nnn
checking for program mmm... nnn
checking for program mmm... nnn
LEX: hello_lex.l
+DEP: hello_lex.d
+DEP: .depend
+==== SHRTOUT=yes all ====
+LEX: hello_lex.l
CC: hello_lex.c
LD: hello_lex
+/objdir/.depend
+/objdir/Makefile
+/objdir/_mkc_compiler_type.err
+/objdir/_mkc_compiler_type.res
+/objdir/_mkc_prog_cc.err
+/objdir/_mkc_prog_cc.res
+/objdir/_mkc_prog_lex.err
+/objdir/_mkc_prog_lex.res
+/objdir/expect.out
+/objdir/hello_lex
+/objdir/hello_lex.c
+/objdir/hello_lex.d
+/objdir/hello_lex.l
+/objdir/hello_lex.o
+/objdir/hello_lex.test.out.tmp
+/objdir/input.txt
+/objdir/test.mk
======= distclean ==========
/objdir/Makefile
/objdir/expect.out
diff --git a/examples/hello_lex/test.mk b/examples/hello_lex/test.mk
index ad62ff6..53acf8e 100644
--- a/examples/hello_lex/test.mk
+++ b/examples/hello_lex/test.mk
@@ -3,19 +3,20 @@ test_output:
@set -e; \
${.OBJDIR}/hello_lex < ${.CURDIR}/input.txt; \
rm -rf ${.OBJDIR}${PREFIX}; \
+ MKCATPAGES=yes; export MKCATPAGES; \
\
echo =========== all ============; \
find ${.OBJDIR} -type f | \
mkc_test_helper "${PREFIX}" "${.OBJDIR}"; \
\
echo ========= install ==========; \
- ${MAKE} ${MAKEFLAGS} install DESTDIR=${.OBJDIR} \
+ ${MAKE} ${MAKEFLAGS} install -j3 DESTDIR=${.OBJDIR} \
> /dev/null; \
find ${.OBJDIR}${PREFIX} -type f -o -type d | \
mkc_test_helper "${PREFIX}" "${.OBJDIR}"; \
\
echo ======== uninstall =========; \
- ${MAKE} ${MAKEFLAGS} uninstall DESTDIR=${.OBJDIR} > /dev/null; \
+ ${MAKE} ${MAKEFLAGS} -j4 uninstall DESTDIR=${.OBJDIR} > /dev/null; \
find ${.OBJDIR}${PREFIX} -type f | \
mkc_test_helper "${PREFIX}" "${.OBJDIR}";\
\
@@ -24,10 +25,23 @@ test_output:
find ${.OBJDIR} -type f | \
mkc_test_helper "${PREFIX}" "${.OBJDIR}";\
\
- echo ==== SHRTOUT=yes ====; \
+ echo ========== depend ===========; \
${MAKE} ${MAKEFLAGS} distclean > /dev/null; \
+ ${MAKE} ${MAKEFLAGS} depend -j4 > /dev/null; \
+ find ${.OBJDIR} -type f | \
+ mkc_test_helper "${PREFIX}" "${.OBJDIR}";\
+ \
+ echo ==== SHRTOUT=yes depend ====; \
+ ${MAKE} ${MAKEFLAGS} distclean > /dev/null; \
+ env SHRTOUT=yes ${MAKE} ${MAKEFLAGS} depend 2>&1 |\
+ mkc_test_helper2; \
+ \
+ echo ==== SHRTOUT=yes all ====; \
+ ${MAKE} ${MAKEFLAGS} clean > /dev/null; \
env MKCATPAGES=no MKHTML=no SHRTOUT=yes ${MAKE} ${MAKEFLAGS} all 2>&1 |\
mkc_test_helper2; \
+ find ${.OBJDIR} -type f | \
+ mkc_test_helper "${PREFIX}" "${.OBJDIR}";\
\
echo ======= distclean ==========; \
${MAKE} ${MAKEFLAGS} distclean DESTDIR=${.OBJDIR} > /dev/null; \