diff options
Diffstat (limited to 'examples/hello_calc2/Makefile')
-rw-r--r-- | examples/hello_calc2/Makefile | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/examples/hello_calc2/Makefile b/examples/hello_calc2/Makefile new file mode 100644 index 0000000..098b5af --- /dev/null +++ b/examples/hello_calc2/Makefile @@ -0,0 +1,30 @@ +PROG = calc + +SRCS = lex.l parser.y + +YHEADER = 1 +YPREFIX = calc_ +LPREFIX = calc_ + +MKC_CHECK_BUILTINS = prog_bison prog_flex + +YACC = ${BUILTIN.prog_bison} -y +LEX = ${BUILTIN.prog_flex} +LEXLIB = -lfl + +lex.o: parser.h + +.include <mkc.configure.mk> + +.if empty(BUILTIN.prog_flex) +MKC_ERR_MSG += "Cannot find flex, good bye!" +.endif + +.if empty(BUILTIN.prog_bison) +MKC_ERR_MSG += "Cannot find bison, good bye!" +.endif + +LDADD += -lm + +.include "test.mk" +.include <mkc.prog.mk> |