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