does not compile due to api changes ...
[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   DO_W32_HELPER = gnunet-gns-helper-service-w32
12   DO_W32_NSP = libw32nsp.la
13   DO_W32_NSPTOOLS = w32nsp-install w32nsp-uninstall w32nsp-resolve
14   DO_W32_HS_CONF = gns-helper-service-w32.conf
15 endif
16
17 if USE_COVERAGE
18   AM_CFLAGS = --coverage -O0
19 endif
20
21 pkgcfgdir= $(pkgdatadir)/config.d/
22
23 plugindir = $(libdir)/gnunet
24
25 pkgcfg_DATA = \
26   gns.conf \
27   $(DO_W32_HS_CONF)
28
29 lib_LTLIBRARIES = \
30   $(DO_W32_NSP) \
31   libgnunetgns.la
32
33 if HAVE_MHD
34  DO_FCFSD=gnunet-gns-fcfsd
35 if HAVE_GNUTLS
36  DO_PROXY=gnunet-gns-proxy
37 endif
38 endif
39
40 bin_PROGRAMS = \
41   gnunet-service-gns \
42   $(DO_FCFSD) \
43         $(DO_PROXY) \
44   $(DO_W32_HELPER) \
45   $(DO_W32_NSPTOOLS) \
46   gnunet-gns \
47   gnunet-dns2gns
48
49 bin_SCRIPTS=gnunet-gns-proxy-setup-ca
50
51 check_PROGRAMS = \
52   test_gns_simple_shorten \
53   test_gns_simple_get_authority \
54   test_gns_simple_lookup \
55   test_gns_simple_delegated_lookup \
56   test_gns_simple_mx_lookup \
57   test_gns_simple_srv_lookup \
58   test_gns_simple_zkey_lookup \
59   test_gns_dht_delegated_lookup \
60   test_gns_pseu_shorten \
61   test_gns_max_queries \
62   test_gns_cname_lookup \
63   test_gns_ns_lookup \
64   test_gns_revocation \
65   test_gns_proxy
66 #test_gns_dht_three_peers
67   
68
69
70 #  test_gns_simple_lookup
71 #  test_gns_simple_delegated_lookup
72 #  test_gns_dht_delegated_lookup
73
74
75 plugin_LTLIBRARIES = \
76   libgnunet_plugin_block_gns.la
77
78 test_gns_proxy_SOURCES = \
79   test_gns_proxy.c
80 test_gns_proxy_LDADD = -lmicrohttpd @LIBCURL@ \
81   $(top_builddir)/src/util/libgnunetutil.la \
82   $(top_builddir)/src/namestore/libgnunetnamestore.la \
83   $(top_builddir)/src/gns/libgnunetgns.la \
84   $(top_builddir)/src/testing/libgnunettesting.la
85 test_gns_proxy_DEPENDENCIES = \
86   $(top_builddir)/src/util/libgnunetutil.la \
87   $(top_builddir)/src/namestore/libgnunetnamestore.la \
88   $(top_builddir)/src/gns/libgnunetgns.la \
89   $(top_builddir)/src/testing/libgnunettesting.la
90
91 test_gns_dht_three_peers_SOURCES = \
92   test_gns_dht_three_peers.c
93 test_gns_dht_three_peers_LDADD = \
94   $(top_builddir)/src/util/libgnunetutil.la \
95   $(top_builddir)/src/namestore/libgnunetnamestore.la \
96   $(top_builddir)/src/gns/libgnunetgns.la \
97   $(top_builddir)/src/testing/libgnunettesting.la \
98   $(top_builddir)/src/testbed/libgnunettestbed.la
99 test_gns_dht_three_peers_DEPENDENCIES = \
100   $(top_builddir)/src/util/libgnunetutil.la \
101   $(top_builddir)/src/namestore/libgnunetnamestore.la \
102   $(top_builddir)/src/gns/libgnunetgns.la \
103   $(top_builddir)/src/testing/libgnunettesting.la \
104   $(top_builddir)/src/testbed/libgnunettestbed.la
105
106 test_gns_simple_lookup_SOURCES = \
107   test_gns_simple_lookup.c
108 test_gns_simple_lookup_LDADD = \
109   $(top_builddir)/src/util/libgnunetutil.la \
110   $(top_builddir)/src/namestore/libgnunetnamestore.la \
111   $(top_builddir)/src/gns/libgnunetgns.la \
112   $(top_builddir)/src/testing/libgnunettesting.la
113 test_gns_simple_lookup_DEPENDENCIES = \
114   $(top_builddir)/src/util/libgnunetutil.la \
115   $(top_builddir)/src/namestore/libgnunetnamestore.la \
116   $(top_builddir)/src/gns/libgnunetgns.la \
117   $(top_builddir)/src/testing/libgnunettesting.la
118
119 test_gns_simple_delegated_lookup_SOURCES = \
120   test_gns_simple_delegated_lookup.c
121 test_gns_simple_delegated_lookup_LDADD = \
122   $(top_builddir)/src/util/libgnunetutil.la \
123   $(top_builddir)/src/namestore/libgnunetnamestore.la \
124   $(top_builddir)/src/gns/libgnunetgns.la \
125   $(top_builddir)/src/testing/libgnunettesting.la
126 test_gns_simple_delegated_lookup_DEPENDENCIES = \
127   $(top_builddir)/src/util/libgnunetutil.la \
128   $(top_builddir)/src/namestore/libgnunetnamestore.la \
129   $(top_builddir)/src/gns/libgnunetgns.la \
130   $(top_builddir)/src/testing/libgnunettesting.la
131
132 test_gns_simple_mx_lookup_SOURCES = \
133   test_gns_simple_mx_lookup.c
134 test_gns_simple_mx_lookup_LDADD = \
135   $(top_builddir)/src/util/libgnunetutil.la \
136   $(top_builddir)/src/namestore/libgnunetnamestore.la \
137   $(top_builddir)/src/gns/libgnunetgns.la \
138   $(top_builddir)/src/testing/libgnunettesting.la
139 test_gns_simple_mx_lookup_DEPENDENCIES = \
140   $(top_builddir)/src/util/libgnunetutil.la \
141   $(top_builddir)/src/namestore/libgnunetnamestore.la \
142   $(top_builddir)/src/gns/libgnunetgns.la \
143   $(top_builddir)/src/testing/libgnunettesting.la
144
145 test_gns_simple_srv_lookup_SOURCES = \
146   test_gns_simple_srv_lookup.c
147 test_gns_simple_srv_lookup_LDADD = \
148   $(top_builddir)/src/util/libgnunetutil.la \
149   $(top_builddir)/src/namestore/libgnunetnamestore.la \
150   $(top_builddir)/src/gns/libgnunetgns.la \
151   $(top_builddir)/src/testing/libgnunettesting.la
152 test_gns_simple_srv_lookup_DEPENDENCIES = \
153   $(top_builddir)/src/util/libgnunetutil.la \
154   $(top_builddir)/src/namestore/libgnunetnamestore.la \
155   $(top_builddir)/src/gns/libgnunetgns.la \
156   $(top_builddir)/src/testing/libgnunettesting.la
157
158 test_gns_simple_zkey_lookup_SOURCES = \
159   test_gns_simple_zkey_lookup.c
160 test_gns_simple_zkey_lookup_LDADD = \
161   $(top_builddir)/src/util/libgnunetutil.la \
162   $(top_builddir)/src/namestore/libgnunetnamestore.la \
163   $(top_builddir)/src/gns/libgnunetgns.la \
164   $(top_builddir)/src/testing/libgnunettesting.la
165 test_gns_simple_zkey_lookup_DEPENDENCIES = \
166   $(top_builddir)/src/util/libgnunetutil.la \
167   $(top_builddir)/src/namestore/libgnunetnamestore.la \
168   $(top_builddir)/src/gns/libgnunetgns.la \
169   $(top_builddir)/src/testing/libgnunettesting.la
170
171 test_gns_dht_delegated_lookup_SOURCES = \
172   test_gns_dht_delegated_lookup.c
173 test_gns_dht_delegated_lookup_LDADD = \
174   $(top_builddir)/src/util/libgnunetutil.la \
175   $(top_builddir)/src/namestore/libgnunetnamestore.la \
176   $(top_builddir)/src/dht/libgnunetdht.la \
177   $(top_builddir)/src/gns/libgnunetgns.la \
178   $(top_builddir)/src/testing/libgnunettesting.la
179 test_gns_dht_delegated_lookup_DEPENDENCIES = \
180   $(top_builddir)/src/util/libgnunetutil.la \
181   $(top_builddir)/src/namestore/libgnunetnamestore.la \
182   $(top_builddir)/src/dht/libgnunetdht.la \
183   $(top_builddir)/src/gns/libgnunetgns.la \
184   $(top_builddir)/src/testing/libgnunettesting.la
185
186 test_gns_simple_shorten_SOURCES = \
187   test_gns_simple_shorten.c
188 test_gns_simple_shorten_LDADD = \
189   $(top_builddir)/src/util/libgnunetutil.la \
190   $(top_builddir)/src/namestore/libgnunetnamestore.la \
191   $(top_builddir)/src/gns/libgnunetgns.la \
192   $(top_builddir)/src/testing/libgnunettesting.la
193 test_gns_simple_shorten_DEPENDENCIES = \
194   $(top_builddir)/src/util/libgnunetutil.la \
195   $(top_builddir)/src/namestore/libgnunetnamestore.la \
196   $(top_builddir)/src/gns/libgnunetgns.la \
197   $(top_builddir)/src/testing/libgnunettesting.la
198
199 test_gns_simple_get_authority_SOURCES = \
200   test_gns_simple_get_authority.c
201 test_gns_simple_get_authority_LDADD = \
202   $(top_builddir)/src/util/libgnunetutil.la \
203   $(top_builddir)/src/namestore/libgnunetnamestore.la \
204   $(top_builddir)/src/gns/libgnunetgns.la \
205   $(top_builddir)/src/testing/libgnunettesting.la
206 test_gns_simple_get_authority_DEPENDENCIES = \
207   $(top_builddir)/src/util/libgnunetutil.la \
208   $(top_builddir)/src/namestore/libgnunetnamestore.la \
209   $(top_builddir)/src/gns/libgnunetgns.la \
210   $(top_builddir)/src/testing/libgnunettesting.la
211
212
213 test_gns_pseu_shorten_SOURCES = \
214   test_gns_pseu_shorten.c
215 test_gns_pseu_shorten_LDADD = \
216   $(top_builddir)/src/util/libgnunetutil.la \
217   $(top_builddir)/src/namestore/libgnunetnamestore.la \
218   $(top_builddir)/src/dht/libgnunetdht.la \
219   $(top_builddir)/src/gns/libgnunetgns.la \
220   $(top_builddir)/src/testing/libgnunettesting.la
221 test_gns_pseu_shorten_DEPENDENCIES = \
222   $(top_builddir)/src/util/libgnunetutil.la \
223   $(top_builddir)/src/namestore/libgnunetnamestore.la \
224   $(top_builddir)/src/dht/libgnunetdht.la \
225   $(top_builddir)/src/gns/libgnunetgns.la \
226   $(top_builddir)/src/testing/libgnunettesting.la
227
228
229 test_gns_max_queries_SOURCES = \
230   test_gns_max_queries.c
231 test_gns_max_queries_LDADD = \
232   $(top_builddir)/src/util/libgnunetutil.la \
233   $(top_builddir)/src/namestore/libgnunetnamestore.la \
234   $(top_builddir)/src/gns/libgnunetgns.la \
235   $(top_builddir)/src/testing/libgnunettesting.la
236 test_gns_max_queries_DEPENDENCIES = \
237   $(top_builddir)/src/util/libgnunetutil.la \
238   $(top_builddir)/src/namestore/libgnunetnamestore.la \
239   $(top_builddir)/src/gns/libgnunetgns.la \
240   $(top_builddir)/src/testing/libgnunettesting.la
241
242 test_gns_cname_lookup_SOURCES = \
243   test_gns_cname_lookup.c
244 test_gns_cname_lookup_LDADD = \
245   $(top_builddir)/src/util/libgnunetutil.la \
246   $(top_builddir)/src/namestore/libgnunetnamestore.la \
247   $(top_builddir)/src/gns/libgnunetgns.la \
248   $(top_builddir)/src/testing/libgnunettesting.la
249 test_gns_cname_lookup_DEPENDENCIES = \
250   $(top_builddir)/src/util/libgnunetutil.la \
251   $(top_builddir)/src/namestore/libgnunetnamestore.la \
252   $(top_builddir)/src/gns/libgnunetgns.la \
253   $(top_builddir)/src/testing/libgnunettesting.la
254
255
256 test_gns_ns_lookup_SOURCES = \
257   test_gns_ns_lookup.c
258 test_gns_ns_lookup_LDADD = \
259   $(top_builddir)/src/util/libgnunetutil.la \
260   $(top_builddir)/src/namestore/libgnunetnamestore.la \
261   $(top_builddir)/src/gns/libgnunetgns.la \
262   $(top_builddir)/src/testing/libgnunettesting.la
263 test_gns_ns_lookup_DEPENDENCIES = \
264   $(top_builddir)/src/util/libgnunetutil.la \
265   $(top_builddir)/src/namestore/libgnunetnamestore.la \
266   $(top_builddir)/src/gns/libgnunetgns.la \
267   $(top_builddir)/src/testing/libgnunettesting.la
268
269
270 test_gns_revocation_SOURCES = \
271   test_gns_revocation.c
272 test_gns_revocation_LDADD = \
273   $(top_builddir)/src/util/libgnunetutil.la \
274   $(top_builddir)/src/namestore/libgnunetnamestore.la \
275   $(top_builddir)/src/gns/libgnunetgns.la \
276   $(top_builddir)/src/testing/libgnunettesting.la
277 test_gns_revocation_DEPENDENCIES = \
278   $(top_builddir)/src/util/libgnunetutil.la \
279   $(top_builddir)/src/namestore/libgnunetnamestore.la \
280   $(top_builddir)/src/gns/libgnunetgns.la \
281   $(top_builddir)/src/testing/libgnunettesting.la
282
283
284 gnunet_gns_SOURCES = \
285  gnunet-gns.c
286 gnunet_gns_LDADD = \
287   $(top_builddir)/src/gns/libgnunetgns.la \
288   $(top_builddir)/src/util/libgnunetutil.la \
289   $(top_builddir)/src/namestore/libgnunetnamestore.la \
290   $(GN_LIBINTL)
291 gnunet_gns_DEPENDENCIES = \
292   libgnunetgns.la
293
294 gnunet_dns2gns_SOURCES = \
295  gnunet-dns2gns.c
296 gnunet_dns2gns_LDADD = \
297   $(top_builddir)/src/gns/libgnunetgns.la \
298   $(top_builddir)/src/util/libgnunetutil.la \
299   $(top_builddir)/src/namestore/libgnunetnamestore.la \
300   $(top_builddir)/src/dns/libgnunetdnsparser.la \
301         $(top_builddir)/src/dns/libgnunetdnsstub.la \
302   $(GN_LIBINTL)
303 gnunet_dns2gns_DEPENDENCIES = \
304   libgnunetgns.la
305
306 gnunet_gns_proxy_SOURCES = \
307  gnunet-gns-proxy.c gns_proxy_proto.h 
308 gnunet_gns_proxy_LDADD = -lmicrohttpd -lcurl -lgnutls \
309   $(top_builddir)/src/gns/libgnunetgns.la \
310   $(top_builddir)/src/util/libgnunetutil.la \
311   $(GN_LIBINTL)
312 gnunet_gns_proxy_DEPENDENCIES = \
313   libgnunetgns.la
314
315 gnunet_gns_helper_service_w32_SOURCES = \
316   gnunet-gns-helper-service-w32.c
317 gnunet_gns_helper_service_w32_LDADD = \
318   $(top_builddir)/src/gns/libgnunetgns.la \
319   $(top_builddir)/src/util/libgnunetutil.la \
320   $(GN_LIBINTL)
321 gnunet_gns_helper_service_w32_DEPENDENCIES = \
322   libgnunetgns.la
323
324 w32nsp_install_SOURCES = \
325   w32nsp-install.c
326 w32nsp_install_LDADD = -lws2_32
327
328 w32nsp_uninstall_SOURCES = \
329   w32nsp-uninstall.c
330 w32nsp_uninstall_LDADD = -lws2_32
331
332 w32nsp_resolve_SOURCES = \
333   w32nsp-resolve.c
334 w32nsp_resolve_LDADD = -lws2_32
335
336 gnunet_service_gns_SOURCES = \
337  gnunet-service-gns.c \
338  gnunet-service-gns_resolver.c gnunet-service-gns_resolver.h \
339  gnunet-service-gns_interceptor.c gnunet-service-gns_interceptor.h 
340 gnunet_service_gns_LDADD = \
341   -lm \
342   $(top_builddir)/src/statistics/libgnunetstatistics.la \
343   $(top_builddir)/src/util/libgnunetutil.la \
344         $(top_builddir)/src/dns/libgnunetdns.la \
345         $(top_builddir)/src/dns/libgnunetdnsparser.la \
346         $(top_builddir)/src/dht/libgnunetdht.la \
347         $(top_builddir)/src/namestore/libgnunetnamestore.la \
348         $(top_builddir)/src/vpn/libgnunetvpn.la \
349   $(GN_LIBINTL)
350 gnunet_service_gns_DEPENDENCIES = \
351   $(top_builddir)/src/statistics/libgnunetstatistics.la \
352   $(top_builddir)/src/util/libgnunetutil.la \
353         $(top_builddir)/src/dns/libgnunetdns.la \
354         $(top_builddir)/src/dns/libgnunetdnsparser.la \
355         $(top_builddir)/src/dht/libgnunetdht.la \
356         $(top_builddir)/src/namestore/libgnunetnamestore.la \
357         $(top_builddir)/src/vpn/libgnunetvpn.la
358
359
360 gnunet_gns_fcfsd_SOURCES = \
361  gnunet-gns-fcfsd.c 
362 gnunet_gns_fcfsd_LDADD = -lmicrohttpd \
363   $(top_builddir)/src/util/libgnunetutil.la \
364   $(top_builddir)/src/namestore/libgnunetnamestore.la \
365   $(GN_LIBINTL)
366 gnunet_gns_fcfsd_DEPENDENCIES = \
367   $(top_builddir)/src/util/libgnunetutil.la \
368   $(top_builddir)/src/namestore/libgnunetnamestore.la
369
370 libw32nsp_la_SOURCES = \
371   w32nsp.c
372 libw32nsp_la_LIBADD = \
373   -lole32 -lws2_32
374 libw32nsp_la_LDFLAGS = \
375   -export-symbols $(top_srcdir)/src/gns/w32nsp.def \
376   $(GN_LIB_LDFLAGS)
377
378 libgnunetgns_la_SOURCES = \
379  gns_api.c gns.h
380 libgnunetgns_la_LIBADD = \
381  $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \
382  $(top_builddir)/src/namestore/libgnunetnamestore.la
383 libgnunetgns_la_LDFLAGS = \
384   $(GN_LIB_LDFLAGS)
385 libgnunetgns_la_DEPENDENCIES = \
386  $(top_builddir)/src/util/libgnunetutil.la \
387  $(top_builddir)/src/namestore/libgnunetnamestore.la
388
389 libgnunet_plugin_block_gns_la_SOURCES = \
390   plugin_block_gns.c
391 libgnunet_plugin_block_gns_la_LIBADD = \
392   $(top_builddir)/src/util/libgnunetutil.la \
393   $(top_builddir)/src/block/libgnunetblock.la \
394   $(top_builddir)/src/namestore/libgnunetnamestore.la
395 libgnunet_plugin_block_gns_la_LDFLAGS = \
396   $(GN_PLUGIN_LDFLAGS)
397 libgnunet_plugin_block_gns_la_DEPENDENCIES = \
398   $(top_builddir)/src/util/libgnunetutil.la \
399   $(top_builddir)/src/block/libgnunetblock.la \
400   $(top_builddir)/src/namestore/libgnunetnamestore.la
401
402 #Build stub api
403 #libgnunetnamestore_la_SOURCES = \
404 # namestore_stub_api.c
405 #libgnunetnamestore_la_LIBADD = \
406 # $(top_builddir)/src/util/libgnunetutil.la $(XLIB)
407 #libgnunetnamestore_la_LDFLAGS = \
408 #  $(GN_LIB_LDFLAGS)
409 #libgnunetnamestore_la_DEPENDENCIES = \
410 # $(top_builddir)/src/util/libgnunetutil.la
411
412 if ENABLE_TEST_RUN
413 if LINUX
414 TESTS = $(check_PROGRAMS)
415 endif
416 endif
417
418 EXTRA_DIST = \
419   test_gns_defaults.conf \
420   test_gns_simple_lookup.conf \
421   test_gns_dht_default.conf \
422         zonefiles/188JSUMKEF25GVU8TTV0PBNNN8JVCPUEDFV1UHJJU884JD25V0T0.zkey \
423         zonefiles/OEFL7A4VEF1B40QLEMTG5D8G1CN6EN16QUSG5R2DT71GRJN34LSG.zkey \
424         zonefiles/test_zonekey
425