removed tundev stuff
[netsniff-ng.git] / src / curvetun / Makefile
blobc9c99fe66587bb4de30bc03410f88b6e53c9fed5
2 # Makefile for curvetun
3 # Author: Daniel Borkmann
6 include ../definitions.mk
8 INCLUDE = -I..
9 CFLAGS += -DTARGETNAME="\"curvetun\""
10 LIBS = -lgcrypt
12 core-objs = curvetun.o
13 lib-objs = xmalloc.o \
14 strlcpy.o \
15 aes256ctr.o \
16 curves.o \
17 ecc.o \
18 numtheory.o \
19 protocol.o \
20 serialize.o \
21 stun.o \
22 netdev.o
24 # tlsf.o \
26 target = curvetun
28 all: clean gen-version build doc
29 debug: all
30 deploy: all strip
32 gen-version:
33 @cd .. && cat ../VERSION | xargs ./gen_build_info.pl
35 build: $(lib-objs) $(core-objs)
36 @$(LD) $(target) $(core-objs) $(lib-objs) $(LIBS)
38 strip:
39 @strip $(target)
41 doc:
42 @cd ../../Documentation && make clean
43 @cd ../../Documentation && make curvetun
44 @cp ../../Documentation/man/* .
45 @cp ../../Documentation/pdf/* .
46 @cp ../../Documentation/html/* .
48 %.o: ../%.c
49 @$(CC) $(CFLAGS) $(INCLUDE) $<
51 clean:
52 @rm *.o *~ $(target) ../version.h *.gz *.pdf *.html *.8 *.css > \
53 /dev/null 2>&1 || true
55 install:
56 @install -D $(target) $(DESTDIR)/$(BINDIR)/$(target)
57 @install -D $(target).8.gz $(DESTDIR)/usr/share/man/man8/$(target).8.gz
59 uninstall:
60 @rm $(DESTDIR)/$(BINDIR)/$(target) || true
61 @rm $(DESTDIR)/usr/share/man/man8/$(target).8.gz || true
63 help:
64 @echo 'Cleaning targets:'
65 @echo ' clean - Remove generated files'
66 @echo 'Building targets:'
67 @echo ' all - Build curvetun (default)'
68 @echo ' debug - Build curvetun for debugging _only_'
69 @echo ' deploy - Build curvetun for productive use'
70 @echo 'Setup targets:'
71 @echo ' install - Install curvetun'
72 @echo ' uninstall - Uninstall curvetun'
73 @echo 'Other targets:'
74 @echo ' help - Print this help'