From 952cb2d6dbd1b4cd76bb7c5dd46c1053631476a3 Mon Sep 17 00:00:00 2001 From: Clyne Sullivan Date: Wed, 7 Mar 2018 15:25:07 -0500 Subject: big changes; no ints; things work better --- Makefile | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 8bca3c1..b4a7bfc 100644 --- a/Makefile +++ b/Makefile @@ -7,13 +7,17 @@ CFLAGS = -Wall -Wextra -Werror -pedantic \ -Wno-discarded-qualifiers \ -I. -fsigned-char -fno-builtin -ggdb -all: - $(CC) $(CFLAGS) -c shelpers.c - $(CC) $(CFLAGS) -c parser.c - $(CC) $(CFLAGS) -c builtins.c - $(CC) $(CFLAGS) -c stack.c - $(CC) $(CFLAGS) -c ops.c - $(CC) $(CFLAGS) -c variable.c - $(AR) r libinterp.a *.o - @rm -f *.o - #$(CC) $(CFLAGS) shell.c *.o -o shell +FILES = $(wildcard *.c) +OUTFILES = $(patsubst %.c, %.o, $(FILES)) + +all: $(OUTFILES) + @#$(CC) $(CFLAGS) *.o -o shell + @$(AR) r libinterp.a *.o + +clean: + @echo " CLEAN" + @rm -f *.o shell libinterp.a + +%.o: %.c + @echo " CC " $< + @$(CC) $(CFLAGS) -c $< -o $@ -- cgit v1.2.3