From ccab148f1310b3cadffb99005941e39fa932d295 Mon Sep 17 00:00:00 2001 From: Teddy Date: Mon, 24 Mar 2014 12:40:12 +0800 Subject: AST construction for expressions --- Makefile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index b6eeb33..4cf057a 100644 --- a/Makefile +++ b/Makefile @@ -3,12 +3,18 @@ all: cibic run: ./cibic -cibic: lex.yy.c cibic.tab.c - gcc -o cibic lex.yy.c cibic.tab.c +cibic: lex.yy.o cibic.tab.o ast.o + gcc -o cibic lex.yy.o cibic.tab.o ast.o +lex.yy.o: lex.yy.c + gcc -c lex.yy.c +cibic.tab.o: cibic.tab.c + gcc -c cibic.tab.c +ast.o: ast.c + gcc -c ast.c -g lex.yy.c: cibic.l flex cibic.l cibic.tab.c: cibic.y bison -d cibic.y clean: - rm -f cibic lex.yy.c cibic.tab.c + rm -f cibic lex.yy.c cibic.tab.c *.o -- cgit v1.2.3-70-g09d2