-ensure external symbols have proper prefix for conversation service
[oweals/gnunet.git] / src / gns / Makefile.am
1 AM_CPPFLAGS = -I$(top_srcdir)/src/include
2
3 if HAVE_GLIBCNSS
4 if INSTALL_NSS
5 NSS_SUBDIR = nss
6 endif
7 endif
8
9 SUBDIRS = . $(NSS_SUBDIR)
10
11 EXTRA_DIST = \
12   test_gns_defaults.conf \
13   test_gns_simple_lookup.conf \
14   test_gns_dht_default.conf \
15   gns-helper-service-w32.conf \
16   gnunet-gns-proxy-setup-ca \
17   zonefiles/J7POEUT41A8PBFS7KVVDRF88GBOU4HK8PSU5QKVLVE3R9T91E99G.zkey \
18   zonefiles/OEFL7A4VEF1B40QLEMTG5D8G1CN6EN16QUSG5R2DT71GRJN34LSG.zkey \
19   zonefiles/test_zonekey \
20   $(check_SCRIPTS)
21
22 if MINGW
23   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
24   DO_W32_HELPER = gnunet-gns-helper-service-w32
25   DO_W32_NSP = libw32nsp.la
26   DO_W32_NSPTOOLS = w32nsp-install w32nsp-uninstall w32nsp-resolve
27   DO_W32_HS_CONF = gns-helper-service-w32.conf
28 endif
29 USE_VPN = $(top_builddir)/src/vpn/libgnunetvpn.la
30
31 if USE_COVERAGE
32   AM_CFLAGS = --coverage -O0
33 endif
34
35 pkgcfgdir = $(pkgdatadir)/config.d/
36
37 libexecdir= $(pkglibdir)/libexec/
38
39 plugindir = $(libdir)/gnunet
40
41 pkgcfg_DATA = \
42   gns.conf \
43   $(DO_W32_HS_CONF)
44
45 lib_LTLIBRARIES = \
46   $(DO_W32_NSP) \
47   libgnunetgns.la
48
49
50 if HAVE_MHD
51 if HAVE_GNUTLS
52 if HAVE_LIBCURL
53 # DO_PROXY=gnunet-gns-proxy
54 endif
55 endif
56 endif
57
58 libexec_PROGRAMS = \
59   gnunet-service-gns \
60   $(DO_W32_HELPER) \
61   gnunet-dns2gns 
62 #  $(DO_PROXY) 
63
64 bin_PROGRAMS = \
65   $(DO_W32_NSPTOOLS) \
66   gnunet-gns 
67
68 bin_SCRIPTS = gnunet-gns-proxy-setup-ca
69
70 plugin_LTLIBRARIES = \
71   libgnunet_plugin_block_gns.la
72
73 gnunet_gns_SOURCES = \
74  gnunet-gns.c
75 gnunet_gns_LDADD = \
76   $(top_builddir)/src/gns/libgnunetgns.la \
77   $(top_builddir)/src/namestore/libgnunetnamestore.la \
78   $(top_builddir)/src/identity/libgnunetidentity.la \
79   $(top_builddir)/src/util/libgnunetutil.la \
80   $(GN_LIBINTL)
81 gnunet_gns_DEPENDENCIES = \
82   $(top_builddir)/src/namestore/libgnunetnamestore.la \
83   $(top_builddir)/src/identity/libgnunetidentity.la \
84   $(top_builddir)/src/util/libgnunetutil.la \
85   libgnunetgns.la
86
87 gnunet_dns2gns_SOURCES = \
88  gnunet-dns2gns.c
89 gnunet_dns2gns_LDADD = \
90   $(top_builddir)/src/gns/libgnunetgns.la \
91   $(top_builddir)/src/util/libgnunetutil.la \
92   $(top_builddir)/src/identity/libgnunetidentity.la \
93   $(top_builddir)/src/namestore/libgnunetnamestore.la \
94   $(top_builddir)/src/dns/libgnunetdnsparser.la \
95   $(top_builddir)/src/dns/libgnunetdnsstub.la \
96   $(GN_LIBINTL)
97 gnunet_dns2gns_DEPENDENCIES = \
98   $(top_builddir)/src/util/libgnunetutil.la \
99   $(top_builddir)/src/identity/libgnunetidentity.la \
100   $(top_builddir)/src/namestore/libgnunetnamestore.la \
101   $(top_builddir)/src/dns/libgnunetdnsparser.la \
102   $(top_builddir)/src/dns/libgnunetdnsstub.la \
103   libgnunetgns.la
104
105 gnunet_gns_proxy_SOURCES = \
106  gnunet-gns-proxy.c 
107 gnunet_gns_proxy_LDADD = -lmicrohttpd -lcurl -lgnutls \
108   $(top_builddir)/src/gns/libgnunetgns.la \
109   $(top_builddir)/src/identity/libgnunetidentity.la \
110   $(top_builddir)/src/util/libgnunetutil.la \
111   $(GN_LIBINTL)
112 gnunet_gns_proxy_DEPENDENCIES = \
113   $(top_builddir)/src/identity/libgnunetidentity.la \
114   $(top_builddir)/src/util/libgnunetutil.la \
115   libgnunetgns.la
116
117 gnunet_gns_helper_service_w32_SOURCES = \
118   gnunet-gns-helper-service-w32.c
119 gnunet_gns_helper_service_w32_LDADD = \
120   $(top_builddir)/src/gns/libgnunetgns.la \
121   $(top_builddir)/src/util/libgnunetutil.la \
122   $(GN_LIBINTL)
123 gnunet_gns_helper_service_w32_DEPENDENCIES = \
124   $(top_builddir)/src/util/libgnunetutil.la \
125   libgnunetgns.la
126
127 w32nsp_install_SOURCES = \
128   w32nsp-install.c
129 w32nsp_install_LDADD = -lws2_32
130
131 w32nsp_uninstall_SOURCES = \
132   w32nsp-uninstall.c
133 w32nsp_uninstall_LDADD = -lws2_32
134
135 w32nsp_resolve_SOURCES = \
136   w32nsp-resolve.c
137 w32nsp_resolve_LDADD = -lws2_32
138
139 gnunet_service_gns_SOURCES = \
140  gnunet-service-gns.c \
141  gnunet-service-gns_resolver.c gnunet-service-gns_resolver.h \
142  gnunet-service-gns_shorten.c gnunet-service-gns_shorten.h \
143  gnunet-service-gns_interceptor.c gnunet-service-gns_interceptor.h 
144 gnunet_service_gns_LDADD = \
145   -lm \
146   $(top_builddir)/src/statistics/libgnunetstatistics.la \
147   $(top_builddir)/src/util/libgnunetutil.la \
148   $(top_builddir)/src/dns/libgnunetdns.la \
149   $(top_builddir)/src/dns/libgnunetdnsparser.la \
150   $(top_builddir)/src/dns/libgnunetdnsstub.la \
151   $(top_builddir)/src/dht/libgnunetdht.la \
152   $(top_builddir)/src/namestore/libgnunetnamestore.la \
153   $(USE_VPN) \
154   $(GN_LIBINTL)
155 gnunet_service_gns_DEPENDENCIES = \
156   $(top_builddir)/src/statistics/libgnunetstatistics.la \
157   $(top_builddir)/src/util/libgnunetutil.la \
158   $(top_builddir)/src/dns/libgnunetdns.la \
159   $(top_builddir)/src/dns/libgnunetdnsparser.la \
160   $(top_builddir)/src/dht/libgnunetdht.la \
161   $(top_builddir)/src/namestore/libgnunetnamestore.la \
162   $(USE_VPN)
163
164
165
166 libw32nsp_la_SOURCES = \
167   w32nsp.c
168 libw32nsp_la_LIBADD = \
169   -lole32 -lws2_32
170 libw32nsp_la_LDFLAGS = \
171   -export-symbols $(top_srcdir)/src/gns/w32nsp.def \
172   $(GN_LIB_LDFLAGS)
173
174 libgnunetgns_la_SOURCES = \
175  gns_api.c gns.h
176 libgnunetgns_la_LIBADD = \
177  $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \
178  $(top_builddir)/src/namestore/libgnunetnamestore.la
179 libgnunetgns_la_LDFLAGS = \
180   $(GN_LIB_LDFLAGS)
181 libgnunetgns_la_DEPENDENCIES = \
182  $(top_builddir)/src/util/libgnunetutil.la \
183  $(top_builddir)/src/namestore/libgnunetnamestore.la
184
185
186 libgnunet_plugin_block_gns_la_SOURCES = \
187   plugin_block_gns.c
188 libgnunet_plugin_block_gns_la_LIBADD = \
189   $(top_builddir)/src/util/libgnunetutil.la \
190   $(top_builddir)/src/block/libgnunetblock.la \
191   $(top_builddir)/src/namestore/libgnunetnamestore.la
192 libgnunet_plugin_block_gns_la_LDFLAGS = \
193   $(GN_PLUGIN_LDFLAGS)
194 libgnunet_plugin_block_gns_la_DEPENDENCIES = \
195   $(top_builddir)/src/util/libgnunetutil.la \
196   $(top_builddir)/src/block/libgnunetblock.la \
197   $(top_builddir)/src/namestore/libgnunetnamestore.la
198
199
200 check_SCRIPTS = \
201   test_gns_delegated_lookup.sh \
202   test_gns_lookup.sh \
203   test_gns_ipv6_lookup.sh\
204   test_gns_txt_lookup.sh\
205   test_gns_mx_lookup.sh \
206   test_gns_ns_lookup.sh \
207   test_gns_dht_lookup.sh\
208   test_gns_pseu_shorten.sh\
209   test_gns_cname_lookup.sh 
210
211 if ENABLE_TEST_RUN
212 if HAVE_SQLITE
213  TESTS = $(check_SCRIPTS)
214 endif
215 endif
216