modify makefile
This commit is contained in:
parent
31535a0574
commit
9d012b2c6c
14
Makefile
14
Makefile
@ -1,6 +1,8 @@
|
|||||||
CC = gcc
|
CC = gcc
|
||||||
CFLAGS = -lm -Wall -O2
|
CFLAGS = -lm -Wall -O2
|
||||||
Bin = server client p-server p-client
|
ServerBin = server p-server
|
||||||
|
ClientBin = client p-client
|
||||||
|
Bin = $(ServerBin) $(ClientBin)
|
||||||
|
|
||||||
all:
|
all:
|
||||||
make $(Bin)
|
make $(Bin)
|
||||||
@ -17,6 +19,14 @@ p-server: socket_wrapper.o p-server.c
|
|||||||
p-client: socket_wrapper.o p-client.c
|
p-client: socket_wrapper.o p-client.c
|
||||||
$(CC) -o p-client p-client.c socket_wrapper.o $(CFLAGS)
|
$(CC) -o p-client p-client.c socket_wrapper.o $(CFLAGS)
|
||||||
|
|
||||||
.PHONY: clean
|
.PHONY: clean moveall
|
||||||
clean:
|
clean:
|
||||||
rm *.o $(Bin)
|
rm *.o $(Bin)
|
||||||
|
rm $(addprefix client_test/,$(ClientBin))
|
||||||
|
rm $(addprefix server_test/,$(ServerBin))
|
||||||
|
|
||||||
|
moveall:
|
||||||
|
mv client client_test/client
|
||||||
|
mv p-client client_test/p-client
|
||||||
|
mv server server_test/server
|
||||||
|
mv p-server server_test/p-server
|
Loading…
Reference in New Issue
Block a user