- unmanaged build
[strongswan.git] / Source / charon / Makefile
1 # Copyright (C) 2005 Jan Hutter, Martin Willi
2 # Hochschule fuer Technik Rapperswil
3 #
4 # This program is free software; you can redistribute it and/or modify it
5 # under the terms of the GNU General Public License as published by the
6 # Free Software Foundation; either version 2 of the License, or (at your
7 # option) any later version. See <http://www.fsf.org/copyleft/gpl.txt>.
8 #
9 # This program is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
11 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 # for more details.
13 #
14
15 BUILD_DIR= ./bin/
16
17 MAIN_DIR= ./
18
19 LIBS= -lgmp -lpthread
20
21 CFLAGS+= -DLEAK_DETECTIVE -I.
22
23 # objects is extended by each included Makefile
24 OBJS=
25
26 daemon : $(BUILD_DIR)charon
27
28 all : $(BUILD_DIR)charon $(BUILD_DIR)run_tests
29
30 doxygen :
31 doxygen doxyconfig.DoxyFile
32
33 include network/Makefile.network
34
35
36 $(BUILD_DIR)daemon.o : daemon.c daemon.h
37 $(CC) $(CFLAGS) -c -o $@ $<
38
39 OBJS+=$(BUILD_DIR)types.o
40 $(BUILD_DIR)types.o : types.c types.h
41 $(CC) $(CFLAGS) -c -o $@ $<
42
43 OBJS+=$(BUILD_DIR)definitions.o
44 $(BUILD_DIR)definitions.o : definitions.c definitions.h
45 $(CC) $(CFLAGS) -c -o $@ $<
46
47
48
49 $(BUILD_DIR)charon : $(OBJS) $(BUILD_DIR)daemon.o
50 $(CC) $(CFLAGS) $(OBJS) $(BUILD_DIR)daemon.o -o $@
51
52
53 include testcases/Makefile.testcases
54
55 $(BUILD_DIR)run_tests : $(OBJS)
56 $(CC) $(CFLAGS) $(OBJS) -o $@
57
58
59 clean :
60 rm $(OBJS) $(BUILD_DIR)charon