-fix, mhd start
[oweals/gnunet.git] / src / gns / Makefile.am
1 INCLUDES = -I$(top_srcdir)/src/include
2
3 if HAVE_GLIBCNSS
4 NSS_SUBDIR = nss
5 endif
6
7 SUBDIRS = . $(NSS_SUBDIR)
8
9 if MINGW
10   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
11 endif
12
13 if USE_COVERAGE
14   AM_CFLAGS = --coverage -O0
15 endif
16
17 pkgcfgdir= $(pkgdatadir)/config.d/
18
19 plugindir = $(libdir)/gnunet
20
21 pkgcfg_DATA = \
22   gns.conf
23
24 lib_LTLIBRARIES = \
25   libgnunetgns.la
26
27 if HAVE_MHD
28  DO_FCFSD=gnunet-gns-fcfsd
29 endif
30
31 bin_PROGRAMS = \
32   gnunet-service-gns \
33   $(DO_FCFSD) \
34   gnunet-gns \
35         gnunet-gns-proxy
36
37 #noinst_PROGRAMS = \
38 #  gnunet-gns-lookup
39
40 check_PROGRAMS = \
41   test_gns_simple_shorten \
42   test_gns_simple_get_authority \
43   test_gns_simple_lookup \
44   test_gns_simple_delegated_lookup \
45   test_gns_simple_mx_lookup \
46   test_gns_simple_zkey_lookup \
47   test_gns_dht_delegated_lookup \
48   test_gns_pseu_shorten \
49   test_gns_max_queries \
50   test_gns_dht_threepeer
51
52
53 #  test_gns_simple_lookup
54 #  test_gns_simple_delegated_lookup
55 #  test_gns_dht_delegated_lookup
56
57
58 plugin_LTLIBRARIES = \
59   libgnunet_plugin_block_gns.la
60
61 test_gns_dht_threepeer_SOURCES = \
62   test_gns_dht_threepeer.c
63 test_gns_dht_threepeer_LDADD = \
64   $(top_builddir)/src/util/libgnunetutil.la \
65   $(top_builddir)/src/namestore/libgnunetnamestore.la \
66   $(top_builddir)/src/gns/libgnunetgns.la \
67   $(top_builddir)/src/testing/libgnunettesting.la
68 test_gns_dht_threepeer_DEPENDENCIES = \
69   $(top_builddir)/src/util/libgnunetutil.la \
70   $(top_builddir)/src/namestore/libgnunetnamestore.la \
71   $(top_builddir)/src/gns/libgnunetgns.la \
72   $(top_builddir)/src/testing/libgnunettesting.la
73
74 test_gns_simple_lookup_SOURCES = \
75   test_gns_simple_lookup.c
76 test_gns_simple_lookup_LDADD = \
77   $(top_builddir)/src/util/libgnunetutil.la \
78   $(top_builddir)/src/namestore/libgnunetnamestore.la \
79   $(top_builddir)/src/gns/libgnunetgns.la \
80   $(top_builddir)/src/testing/libgnunettesting.la
81 test_gns_simple_lookup_DEPENDENCIES = \
82   $(top_builddir)/src/util/libgnunetutil.la \
83   $(top_builddir)/src/namestore/libgnunetnamestore.la \
84   $(top_builddir)/src/gns/libgnunetgns.la \
85   $(top_builddir)/src/testing/libgnunettesting.la
86
87 test_gns_simple_delegated_lookup_SOURCES = \
88   test_gns_simple_delegated_lookup.c
89 test_gns_simple_delegated_lookup_LDADD = \
90   $(top_builddir)/src/util/libgnunetutil.la \
91   $(top_builddir)/src/namestore/libgnunetnamestore.la \
92   $(top_builddir)/src/gns/libgnunetgns.la \
93   $(top_builddir)/src/testing/libgnunettesting.la
94 test_gns_simple_delegated_lookup_DEPENDENCIES = \
95   $(top_builddir)/src/util/libgnunetutil.la \
96   $(top_builddir)/src/namestore/libgnunetnamestore.la \
97   $(top_builddir)/src/gns/libgnunetgns.la \
98   $(top_builddir)/src/testing/libgnunettesting.la
99
100 test_gns_simple_mx_lookup_SOURCES = \
101   test_gns_simple_mx_lookup.c
102 test_gns_simple_mx_lookup_LDADD = \
103   $(top_builddir)/src/util/libgnunetutil.la \
104   $(top_builddir)/src/namestore/libgnunetnamestore.la \
105   $(top_builddir)/src/gns/libgnunetgns.la \
106   $(top_builddir)/src/testing/libgnunettesting.la
107 test_gns_simple_mx_lookup_DEPENDENCIES = \
108   $(top_builddir)/src/util/libgnunetutil.la \
109   $(top_builddir)/src/namestore/libgnunetnamestore.la \
110   $(top_builddir)/src/gns/libgnunetgns.la \
111   $(top_builddir)/src/testing/libgnunettesting.la
112
113 test_gns_simple_zkey_lookup_SOURCES = \
114   test_gns_simple_zkey_lookup.c
115 test_gns_simple_zkey_lookup_LDADD = \
116   $(top_builddir)/src/util/libgnunetutil.la \
117   $(top_builddir)/src/namestore/libgnunetnamestore.la \
118   $(top_builddir)/src/gns/libgnunetgns.la \
119   $(top_builddir)/src/testing/libgnunettesting.la
120 test_gns_simple_zkey_lookup_DEPENDENCIES = \
121   $(top_builddir)/src/util/libgnunetutil.la \
122   $(top_builddir)/src/namestore/libgnunetnamestore.la \
123   $(top_builddir)/src/gns/libgnunetgns.la \
124   $(top_builddir)/src/testing/libgnunettesting.la
125
126 test_gns_dht_delegated_lookup_SOURCES = \
127   test_gns_dht_delegated_lookup.c
128 test_gns_dht_delegated_lookup_LDADD = \
129   $(top_builddir)/src/util/libgnunetutil.la \
130   $(top_builddir)/src/namestore/libgnunetnamestore.la \
131   $(top_builddir)/src/dht/libgnunetdht.la \
132   $(top_builddir)/src/gns/libgnunetgns.la \
133   $(top_builddir)/src/testing/libgnunettesting.la
134 test_gns_dht_delegated_lookup_DEPENDENCIES = \
135   $(top_builddir)/src/util/libgnunetutil.la \
136   $(top_builddir)/src/namestore/libgnunetnamestore.la \
137   $(top_builddir)/src/dht/libgnunetdht.la \
138   $(top_builddir)/src/gns/libgnunetgns.la \
139   $(top_builddir)/src/testing/libgnunettesting.la
140
141 test_gns_simple_shorten_SOURCES = \
142   test_gns_simple_shorten.c
143 test_gns_simple_shorten_LDADD = \
144   $(top_builddir)/src/util/libgnunetutil.la \
145   $(top_builddir)/src/namestore/libgnunetnamestore.la \
146   $(top_builddir)/src/gns/libgnunetgns.la \
147   $(top_builddir)/src/testing/libgnunettesting.la
148 test_gns_simple_shorten_DEPENDENCIES = \
149   $(top_builddir)/src/util/libgnunetutil.la \
150   $(top_builddir)/src/namestore/libgnunetnamestore.la \
151   $(top_builddir)/src/gns/libgnunetgns.la \
152   $(top_builddir)/src/testing/libgnunettesting.la
153
154 test_gns_simple_get_authority_SOURCES = \
155   test_gns_simple_get_authority.c
156 test_gns_simple_get_authority_LDADD = \
157   $(top_builddir)/src/util/libgnunetutil.la \
158   $(top_builddir)/src/namestore/libgnunetnamestore.la \
159   $(top_builddir)/src/gns/libgnunetgns.la \
160   $(top_builddir)/src/testing/libgnunettesting.la
161 test_gns_simple_get_authority_DEPENDENCIES = \
162   $(top_builddir)/src/util/libgnunetutil.la \
163   $(top_builddir)/src/namestore/libgnunetnamestore.la \
164   $(top_builddir)/src/gns/libgnunetgns.la \
165   $(top_builddir)/src/testing/libgnunettesting.la
166
167
168 test_gns_pseu_shorten_SOURCES = \
169   test_gns_pseu_shorten.c
170 test_gns_pseu_shorten_LDADD = \
171   $(top_builddir)/src/util/libgnunetutil.la \
172   $(top_builddir)/src/namestore/libgnunetnamestore.la \
173   $(top_builddir)/src/dht/libgnunetdht.la \
174   $(top_builddir)/src/gns/libgnunetgns.la \
175   $(top_builddir)/src/testing/libgnunettesting.la
176 test_gns_pseu_shorten_DEPENDENCIES = \
177   $(top_builddir)/src/util/libgnunetutil.la \
178   $(top_builddir)/src/namestore/libgnunetnamestore.la \
179   $(top_builddir)/src/dht/libgnunetdht.la \
180   $(top_builddir)/src/gns/libgnunetgns.la \
181   $(top_builddir)/src/testing/libgnunettesting.la
182
183
184 test_gns_max_queries_SOURCES = \
185   test_gns_max_queries.c
186 test_gns_max_queries_LDADD = \
187   $(top_builddir)/src/util/libgnunetutil.la \
188   $(top_builddir)/src/namestore/libgnunetnamestore.la \
189   $(top_builddir)/src/gns/libgnunetgns.la \
190   $(top_builddir)/src/testing/libgnunettesting.la
191 test_gns_max_queries_DEPENDENCIES = \
192   $(top_builddir)/src/util/libgnunetutil.la \
193   $(top_builddir)/src/namestore/libgnunetnamestore.la \
194   $(top_builddir)/src/gns/libgnunetgns.la \
195   $(top_builddir)/src/testing/libgnunettesting.la
196
197 gnunet_gns_SOURCES = \
198  gnunet-gns.c
199 gnunet_gns_LDADD = \
200   $(top_builddir)/src/gns/libgnunetgns.la \
201   $(top_builddir)/src/util/libgnunetutil.la \
202   $(top_builddir)/src/namestore/libgnunetnamestore.la \
203   $(GN_LIBINTL)
204 gnunet_gns_DEPENDENCIES = \
205   libgnunetgns.la
206
207 gnunet_gns_proxy_SOURCES = \
208  gnunet-gns-proxy.c
209 gnunet_gns_proxy_LDADD = -lmicrohttpd \
210   $(top_builddir)/src/gns/libgnunetgns.la \
211   $(top_builddir)/src/util/libgnunetutil.la \
212   $(GN_LIBINTL)
213 gnunet_gns_proxy_DEPENDENCIES = \
214   libgnunetgns.la
215
216 gnunet_service_gns_SOURCES = \
217  gnunet-service-gns.c \
218  gnunet-service-gns_resolver.c \
219  gnunet-service-gns_interceptor.c
220 gnunet_service_gns_LDADD = \
221   $(top_builddir)/src/statistics/libgnunetstatistics.la \
222   $(top_builddir)/src/util/libgnunetutil.la \
223         $(top_builddir)/src/dns/libgnunetdns.la \
224         $(top_builddir)/src/dns/libgnunetdnsparser.la \
225         $(top_builddir)/src/dht/libgnunetdht.la \
226         $(top_builddir)/src/namestore/libgnunetnamestore.la \
227   $(GN_LIBINTL)
228 gnunet_service_gns_DEPENDENCIES = \
229   $(top_builddir)/src/statistics/libgnunetstatistics.la \
230   $(top_builddir)/src/util/libgnunetutil.la \
231         $(top_builddir)/src/dns/libgnunetdns.la \
232         $(top_builddir)/src/dns/libgnunetdnsparser.la \
233         $(top_builddir)/src/dht/libgnunetdht.la \
234         $(top_builddir)/src/namestore/libgnunetnamestore.la
235
236
237 gnunet_gns_fcfsd_SOURCES = \
238  gnunet-gns-fcfsd.c 
239 gnunet_gns_fcfsd_LDADD = -lmicrohttpd \
240   $(top_builddir)/src/util/libgnunetutil.la \
241   $(top_builddir)/src/namestore/libgnunetnamestore.la \
242   $(GN_LIBINTL)
243 gnunet_gns_fcfsd_DEPENDENCIES = \
244   $(top_builddir)/src/util/libgnunetutil.la \
245   $(top_builddir)/src/namestore/libgnunetnamestore.la
246
247
248 libgnunetgns_la_SOURCES = \
249  gns_api.c gns.h
250 libgnunetgns_la_LIBADD = \
251  $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \
252  $(top_builddir)/src/namestore/libgnunetnamestore.la
253 libgnunetgns_la_LDFLAGS = \
254   $(GN_LIB_LDFLAGS)
255 libgnunetgns_la_DEPENDENCIES = \
256  $(top_builddir)/src/util/libgnunetutil.la \
257  $(top_builddir)/src/namestore/libgnunetnamestore.la
258
259 libgnunet_plugin_block_gns_la_SOURCES = \
260   plugin_block_gns.c
261 libgnunet_plugin_block_gns_la_LIBADD = \
262   $(top_builddir)/src/util/libgnunetutil.la \
263   $(top_builddir)/src/block/libgnunetblock.la \
264   $(top_builddir)/src/namestore/libgnunetnamestore.la
265 libgnunet_plugin_block_gns_la_LDFLAGS = \
266   $(GN_PLUGIN_LDFLAGS)
267 libgnunet_plugin_block_gns_la_DEPENDENCIES = \
268   $(top_builddir)/src/util/libgnunetutil.la \
269   $(top_builddir)/src/block/libgnunetblock.la \
270   $(top_builddir)/src/namestore/libgnunetnamestore.la
271
272 #Build stub api
273 #libgnunetnamestore_la_SOURCES = \
274 # namestore_stub_api.c
275 #libgnunetnamestore_la_LIBADD = \
276 # $(top_builddir)/src/util/libgnunetutil.la $(XLIB)
277 #libgnunetnamestore_la_LDFLAGS = \
278 #  $(GN_LIB_LDFLAGS)
279 #libgnunetnamestore_la_DEPENDENCIES = \
280 # $(top_builddir)/src/util/libgnunetutil.la
281
282 if ENABLE_TEST_RUN
283 if LINUX
284 TESTS = $(check_PROGRAMS)
285 endif
286 endif
287
288 EXTRA_DIST = \
289   test_gns_simple_lookup.conf