ref: 92a2be62fe5dfa9f749bac4313b419aa35a139a0
parent: 5410dba4f4addd56cfa9f9093fafccc38444e0de
author: ISSOtm <[email protected]>
date: Tue Dec 3 18:02:38 EST 2019
Remove lex rules from Makefile Since the RGBLINK rewrite, there have been no .l files in the whole codebase (RGBASM has the C file directly, for better and for worse) Since flex isn't used anymore, it's a good idea to remove it from the Makefile so people don't think it's a dependency.
--- a/Makefile
+++ b/Makefile
@@ -7,7 +7,7 @@
#
.SUFFIXES:
-.SUFFIXES: .h .l .y .c .o
+.SUFFIXES: .h .y .c .o
# User-defined variables
@@ -43,10 +43,8 @@
REALLDFLAGS := ${LDFLAGS} ${WARNFLAGS}
YFLAGS :=
-LFLAGS := --nounistd
YACC := yacc
-LEX := flex
RM := rm -rf
# Rules to build the RGBDS binaries
@@ -116,11 +114,10 @@
# Rules to process files
-# We want the yacc and lex invocations to pass through our rules
+# We want the yacc invocations to pass through our rules, not default ones
.y.o:
-.l.o:
-# yacc- and lex-generated C files have an accompanying header
+# yacc-generated C files have an accompanying header
.c.h:
$Qtouch $@
@@ -127,9 +124,6 @@
.y.c:
$Q${YACC} -d ${YFLAGS} -o $@ $<
-.l.c:
- $Q${LEX} ${LFLAGS} -o $@ $<
-
.c.o:
$Q${CC} ${REALCFLAGS} ${PNGCFLAGS} -c -o $@ $<
@@ -173,8 +167,8 @@
$Qinstall -m ${MANMODE} src/link/rgblink.5 ${DESTDIR}${mandir}/man5/rgblink.5
$Qinstall -m ${MANMODE} src/gfx/rgbgfx.1 ${DESTDIR}${mandir}/man1/rgbgfx.1
-# Target used to check the coding style of the whole codebase. '.y' and '.l'
-# files aren't checked, unfortunately...
+# Target used to check the coding style of the whole codebase.
+# `.y` files aren't checked, unfortunately...
checkcodebase:
$Qfor file in `git ls-files | grep -E '\.c|\.h' | grep -v '\.html'`; do \
@@ -183,8 +177,8 @@
# Target used to check the coding style of the patches from the upstream branch
# to the HEAD. Runs checkpatch once for each commit between the current HEAD and
-# the first common commit between the HEAD and origin/master. '.y' and '.l'
-# files aren't checked, unfortunately...
+# the first common commit between the HEAD and origin/master.
+# `.y` files aren't checked, unfortunately...
checkpatch:
$Qeval COMMON_COMMIT=$$(git merge-base HEAD origin/master); \