summaryrefslogtreecommitdiff
path: root/lexyacc.mk
blob: c1baf610229d161e14bcdbf187908cb5bfbe005b (plain)
1
2
3
4
5
6
7
8
9
NOERR_FLAGS = $(subst -Werror,,$(subst -Wall,,$(CFLAGS)))

%.o: %.y
	yacc -d -o$*.c $<
	$(CC) -c $(NOERR_CFLAGS) $(_LIBINCPATHS) $*.c

%.o: %.l
	flex -o$*.c $<
	$(CC) -c $(NOERR_CFLAGS) $(_LIBINCPATHS) $*.c