another signedness warning
[tetrinet.git] / Makefile
blobf4c112f3b01e494dca0a59fa21e375cfa87a694c
1 ######## Configuration area
3 # Your C compiler
4 CC = cc
6 # The passed compilation flags
7 CFLAGS = -O2 -I/usr/include/ncurses -g -Wall -fno-builtin-log
9 # Whether to enable IPv6 support
10 IPV6 = 1
12 # Whether to have builtin server in the tetrinet client (available through
13 # -server argument) (tetrinet-server will be built always regardless this)
14 # BUILTIN_SERVER = 1
16 # If you experience random delays and server freezes when accepting new
17 # clients, enable this.
18 # NO_BRUTE_FORCE_DECRYPTION = 1
21 ######## End of configuration area
24 OBJS = sockets.o tetrinet.o tetris.o tty.o
26 ifdef IPV6
27 CFLAGS += -DHAVE_IPV6
28 endif
29 ifdef BUILTIN_SERVER
30 CFLAGS += -DBUILTIN_SERVER
31 OBJS += server.o
32 endif
33 ifdef NO_BRUTE_FORCE_DECRYPTION
34 CFLAGS += -DNO_BRUTE_FORCE_DECRYPTION
35 endif
38 ########
41 all: tetrinet tetrinet-server
43 install: all
44 cp -p tetrinet tetrinet-server /usr/games
46 clean:
47 rm -f tetrinet tetrinet-server *.o
49 spotless: clean
51 binonly:
52 rm -f *.[cho] Makefile
53 rm -rf CVS/
56 ########
59 tetrinet: $(OBJS)
60 $(CC) -o $@ $(OBJS) -lncurses
62 tetrinet-server: server.c sockets.c tetrinet.c tetris.c server.h sockets.h tetrinet.h tetris.h
63 $(CC) $(CFLAGS) -o $@ -DSERVER_ONLY server.c sockets.c tetrinet.c tetris.c
65 .c.o:
66 $(CC) $(CFLAGS) -c $<
68 server.o: server.c tetrinet.h tetris.h server.h sockets.h
69 sockets.o: sockets.c sockets.h tetrinet.h
70 tetrinet.o: tetrinet.c tetrinet.h io.h server.h sockets.h tetris.h
71 tetris.o: tetris.c tetris.h tetrinet.h io.h sockets.h
72 tty.o: tty.c tetrinet.h tetris.h io.h
74 tetrinet.h: io.h