diff options
Diffstat (limited to 'Makefiles/lex.mk')
-rw-r--r-- | Makefiles/lex.mk | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Makefiles/lex.mk b/Makefiles/lex.mk new file mode 100644 index 0000000..a11b1e6 --- /dev/null +++ b/Makefiles/lex.mk @@ -0,0 +1,17 @@ +.POSIX: + +CC = cc +CFLAGS = -Wall -Wextra -Wpedantic -Werror \ + -march=native -mtune=native -O3 -flto \ + -pipe + +ALL = ${CC} ${CFLAGS} ${CPPFLAGS} ${LDLIBS} ${LDFLAGS} + +all: + flex -f -DYY_NO_INPUT --nounput puzzles.l + ${ALL} -lfl -DPART1 -o puzzle-1 lex.yy.c + ${ALL} -lfl -DPART2 -o puzzle-2 lex.yy.c + rm lex.yy.c + +clean: + rm -f puzzle-[12] |