diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 24 |
1 files changed, 3 insertions, 21 deletions
@@ -1,22 +1,4 @@ -CC ?= gcc -CFLAGS ?= -lpthread +default: all -.PHONY: all -all: client server - -.PHONY: debug -debug: CFLAGS += -g -DDEBUG=1 -debug: server client - -.PHONY: clean -clean: - rm -rf client server *.o - -%.o: %.c - $(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@ - -client: client.o util.o - $(CC) -o $@ $^ - -server: server.o util.o evloop.o tsocket.o acceptor.o connection.o tpool.o - $(CC) -o $@ $^ +.DEFAULT: + cd src && $(MAKE) $@ |