From 4742dd73046c53cff7fe54deee58358c3b193206 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Wed, 30 Nov 2022 12:23:04 +0100 Subject: Add default Makefiles --- Makefiles/lex.mk | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Makefiles/lex.mk (limited to 'Makefiles/lex.mk') 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] -- cgit v1.2.3