fix Makefile
This commit is contained in:
parent
29b5b6c1f3
commit
8973390b2a
2 changed files with 70 additions and 57 deletions
19
Makefile
19
Makefile
|
|
@ -1,6 +1,6 @@
|
|||
CC = zig cc -O2
|
||||
CC = gcc
|
||||
|
||||
all: parser.tab.o lex.yy.o node.o main.o
|
||||
program: parser.tab.o lex.yy.o node.o main.o
|
||||
$(CC) ./parser.tab.o ./lex.yy.o ./node.o ./main.o -o program -lfl
|
||||
|
||||
main.o: main.c
|
||||
|
|
@ -21,6 +21,19 @@ lex.yy.o: lex.yy.c
|
|||
lex.yy.c: ./scanner.l
|
||||
flex scanner.l
|
||||
|
||||
.PHONY: clean
|
||||
.PHONY: clean test
|
||||
clean:
|
||||
rm parser.tab.c parser.tab.h parser.tab.o lex.yy.o lex.yy.c program main.o node.o
|
||||
|
||||
test: program
|
||||
@echo Test test1:
|
||||
./program test1
|
||||
@read
|
||||
@echo Test test2:
|
||||
./program test2
|
||||
@read
|
||||
@echo Test test3:
|
||||
./program test3
|
||||
@read
|
||||
@echo Test test4:
|
||||
./program test4
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue