cleaning up makefile stuff for ex22

cat-town
Dan Buch 13 years ago
parent f2110a5d13
commit 316ce7f8be

@ -3,13 +3,9 @@ CFLAGS=-Wall -g -DNDEBUG
EXERCISES = $(patsubst %.c,%,$(shell ls ex*.c | egrep -v "ex(19|22)"))
all: $(EXERCISES) ex22_main
all: $(EXERCISES)
$(MAKE) -f ex19.mk
ex22_main: ex22.c ex22_main.c ex22.h
$(CC) $(CFLAGS) -c -o ex22.o ex22.c
$(CC) $(CFLAGS) ex22_main.c ex22.o -o $@
$(MAKE) -f ex22.mk
test: all
@ -19,6 +15,7 @@ test: all
clean:
rm -f $(EXERCISES)
$(MAKE) -f ex19.mk clean
$(MAKE) -f ex22.mk clean
.PHONY: all test clean

@ -0,0 +1,10 @@
all: ex22_main
ex22_main: ex22_main.o ex22.o
clean:
rm -f ex22_main ex22.o ex22_main.o
.PHONY: all clean
Loading…
Cancel
Save