fix mem corruption
[oweals/gnunet.git] / src / pt / Makefile.am
1 # This Makefile.am is in the public domain
2 AM_CPPFLAGS = -I$(top_srcdir)/src/include
3
4 if MINGW
5   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
6 endif
7
8 if USE_COVERAGE
9   AM_CFLAGS = --coverage -O0
10 endif
11
12 pkgcfgdir= $(pkgdatadir)/config.d/
13
14 libexecdir= $(pkglibdir)/libexec/
15
16 plugindir = $(libdir)/gnunet
17
18 dist_pkgcfg_DATA = \
19   pt.conf
20
21 libexec_PROGRAMS = \
22   gnunet-daemon-pt
23
24 gnunet_daemon_pt_SOURCES = \
25  gnunet-daemon-pt.c
26 gnunet_daemon_pt_LDADD = \
27   $(top_builddir)/src/vpn/libgnunetvpn.la \
28   $(top_builddir)/src/cadet/libgnunetcadet.la \
29   $(top_builddir)/src/dht/libgnunetdht.la \
30   $(top_builddir)/src/dns/libgnunetdns.la \
31   $(top_builddir)/src/dns/libgnunetdnsparser.la \
32   $(top_builddir)/src/statistics/libgnunetstatistics.la \
33   $(top_builddir)/src/util/libgnunetutil.la \
34   $(GN_LIBINTL)
35
36 if HAVE_TESTING
37 if HAVE_MHD
38
39 if HAVE_LIBGNURL
40 LIB_GNURL=@LIBGNURL@
41 CPP_GNURL=@LIBGNURL_CPPFLAGS@
42 if LINUX
43  VPN_TEST = \
44  test_gnunet_vpn-4_to_6 \
45  test_gnunet_vpn-6_to_4 \
46  test_gnunet_vpn-6_over \
47  test_gnunet_vpn-4_over \
48  test_gns_vpn
49 endif
50 if MINGW
51  VPN_TEST = \
52  test_gnunet_vpn-4_to_6 \
53  test_gnunet_vpn-6_to_4 \
54  test_gnunet_vpn-6_over \
55  test_gnunet_vpn-4_over
56 endif
57 else
58 if HAVE_LIBCURL
59 LIB_GNURL=@LIBCURL@
60 CPP_GNURL=@LIBCURL_CPPFLAGS@
61 if LINUX
62  VPN_TEST = \
63  test_gnunet_vpn-4_to_6 \
64  test_gnunet_vpn-6_to_4 \
65  test_gnunet_vpn-6_over \
66  test_gnunet_vpn-4_over \
67  test_gns_vpn
68 endif
69 if MINGW
70  VPN_TEST = \
71  test_gnunet_vpn-4_to_6 \
72  test_gnunet_vpn-6_to_4 \
73  test_gnunet_vpn-6_over \
74  test_gnunet_vpn-4_over
75 endif
76 endif
77 endif
78
79 endif
80 endif
81
82 check_PROGRAMS = $(VPN_TEST)
83
84 if ENABLE_TEST_RUN
85 AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME;
86 TESTS = $(check_PROGRAMS)
87 endif
88
89 EXTRA_DIST = \
90  test_gnunet_vpn.conf \
91  test_gns_vpn.conf
92
93
94
95 test_gns_vpn_SOURCES = \
96  test_gns_vpn.c
97 test_gns_vpn_LDADD = -lmicrohttpd $(LIB_GNURL) \
98  $(top_builddir)/src/namestore/libgnunetnamestore.la \
99  $(top_builddir)/src/identity/libgnunetidentity.la \
100  $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \
101  $(top_builddir)/src/testing/libgnunettesting.la \
102  $(top_builddir)/src/util/libgnunetutil.la
103 test_gns_vpn_CPPFLAGS = \
104  $(CPP_GNURL) $(AM_CPPFLAGS)
105
106 test_gnunet_vpn_4_over_SOURCES = \
107  test_gnunet_vpn.c
108 test_gnunet_vpn_4_over_LDADD = -lmicrohttpd $(LIB_GNURL) \
109  $(top_builddir)/src/vpn/libgnunetvpn.la \
110  $(top_builddir)/src/testing/libgnunettesting.la \
111  $(top_builddir)/src/util/libgnunetutil.la
112 test_gnunet_vpn_4_over_CPPFLAGS = \
113  $(LIB_GNURL) $(AM_CPPFLAGS)
114
115 test_gnunet_vpn_6_over_SOURCES = \
116  test_gnunet_vpn.c
117 test_gnunet_vpn_6_over_LDADD = -lmicrohttpd $(LIB_GNURL) \
118  $(top_builddir)/src/vpn/libgnunetvpn.la \
119  $(top_builddir)/src/testing/libgnunettesting.la \
120  $(top_builddir)/src/util/libgnunetutil.la
121 test_gnunet_vpn_6_over_CPPFLAGS = \
122  $(CPP_GNURL) $(AM_CPPFLAGS)
123
124 test_gnunet_vpn_4_to_6_SOURCES = \
125  test_gnunet_vpn.c
126 test_gnunet_vpn_4_to_6_LDADD = -lmicrohttpd $(LIB_GNURL) \
127  $(top_builddir)/src/vpn/libgnunetvpn.la \
128  $(top_builddir)/src/testing/libgnunettesting.la \
129  $(top_builddir)/src/util/libgnunetutil.la
130 test_gnunet_vpn_4_to_6_CPPFLAGS = \
131  $(CPP_GNURL) $(AM_CPPFLAGS)
132
133 test_gnunet_vpn_6_to_4_SOURCES = \
134  test_gnunet_vpn.c
135 test_gnunet_vpn_6_to_4_LDADD = -lmicrohttpd $(LIB_GNURL) \
136  $(top_builddir)/src/vpn/libgnunetvpn.la \
137  $(top_builddir)/src/testing/libgnunettesting.la \
138  $(top_builddir)/src/util/libgnunetutil.la
139 test_gnunet_vpn_6_to_4_CPPFLAGS = \
140  $(CPP_GNURL) $(AM_CPPFLAGS)