From 0e835d9b8f97087810dddb9743aa84b6431ff3a7 Mon Sep 17 00:00:00 2001 From: Tucker Evans Date: Sat, 27 Jul 2019 12:55:31 -0400 Subject: Rename hash.* -> scope.* --- makefile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'makefile') diff --git a/makefile b/makefile index 9a2f51a..8dd5899 100644 --- a/makefile +++ b/makefile @@ -3,8 +3,8 @@ FLAGS = -g YACC = yacc LEX = lex -mypc: y.tab.o lex.yy.o tree.o hash.o node.o pc.o - $(CC) $(FLAGS) -o mypc main.o tree.o hash.o node.o y.tab.o lex.yy.o -lfl -ly +mypc: y.tab.o lex.yy.o tree.o scope.o node.o pc.o + $(CC) $(FLAGS) -o mypc main.o tree.o scope.o node.o y.tab.o lex.yy.o -lfl -ly pc.o: main.c pc.h $(CC) $(FLAGS) -c main.c @@ -12,8 +12,8 @@ pc.o: main.c pc.h tree.o: tree.c tree.h $(CC) $(FLAGS) -c tree.c -hash.o: hash.c hash.h - $(CC) $(FLAGS) -c hash.c +scope.o: scope.c scope.h + $(CC) $(FLAGS) -c scope.c node.o: node.c node.h $(CC) $(FLAGS) -c node.c -- cgit v1.1 From 60507214c098beaf3ae01a202e564bfe2f7c8364 Mon Sep 17 00:00:00 2001 From: Tucker Evans Date: Sat, 27 Jul 2019 21:08:22 -0400 Subject: Add basic scoping --- makefile | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to 'makefile') diff --git a/makefile b/makefile index 8dd5899..c429f3c 100644 --- a/makefile +++ b/makefile @@ -3,19 +3,22 @@ FLAGS = -g YACC = yacc LEX = lex -mypc: y.tab.o lex.yy.o tree.o scope.o node.o pc.o - $(CC) $(FLAGS) -o mypc main.o tree.o scope.o node.o y.tab.o lex.yy.o -lfl -ly +mypc: y.tab.o lex.yy.o tree.o scope.o node.o pc.o sem_check.o + $(CC) $(FLAGS) -o mypc main.o tree.o scope.o sem_check.o node.o y.tab.o lex.yy.o -lfl -ly -pc.o: main.c pc.h +pc.o: main.c headers $(CC) $(FLAGS) -c main.c -tree.o: tree.c tree.h +tree.o: tree.c headers $(CC) $(FLAGS) -c tree.c -scope.o: scope.c scope.h +sem_check.o: sem_check.c headers + $(CC) $(FLAGS) -c sem_check.c + +scope.o: scope.c headers $(CC) $(FLAGS) -c scope.c -node.o: node.c node.h +node.o: node.c headers $(CC) $(FLAGS) -c node.c y.tab.o: y.tab.c @@ -30,5 +33,7 @@ y.tab.c: pc.y lex.yy.c: pc.l $(LEX) -l pc.l +headers: pc.h tree.h sem_check.h y.tab.h scope.h node.h y.tab.c + clean: rm -f mypc *.o y.tab.* lex.yy.* -- cgit v1.1 From 12f50dec6a529784a360dfaec9dc562b810ae2fd Mon Sep 17 00:00:00 2001 From: Tucker Evans Date: Sat, 3 Aug 2019 17:48:44 -0400 Subject: Fix change compiler in makefile --- makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'makefile') diff --git a/makefile b/makefile index c429f3c..27d0649 100644 --- a/makefile +++ b/makefile @@ -1,4 +1,4 @@ -CC = gcc +CC = tcc FLAGS = -g YACC = yacc LEX = lex -- cgit v1.1