- disable unix
[oweals/gnunet.git] / src / dht / Makefile.am
1 INCLUDES = -I$(top_srcdir)/src/include
2 if MINGW
3  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols -lole32 -lshell32 -liconv -lstdc++ -lcomdlg32 -lgdi32
4 endif
5
6 plugindir = $(libdir)/gnunet
7
8 pkgcfgdir= $(pkgdatadir)/config.d/
9
10 pkgcfg_DATA = \
11   dht.conf 
12
13 if HAVE_ZLIB
14  ZLIB_LNK = -lz
15 endif
16
17 if USE_COVERAGE
18   AM_CFLAGS = --coverage -O0
19   XLIB = -lgcov
20 endif
21
22 lib_LTLIBRARIES = \
23  libgnunetdht.la 
24
25 libgnunetdht_la_SOURCES = \
26   dht_api.c dht.h 
27 libgnunetdht_la_LIBADD = \
28   $(top_builddir)/src/util/libgnunetutil.la \
29   $(XLIB)
30 libgnunetdht_la_LDFLAGS = \
31   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
32   -version-info 1:0:1
33
34
35 plugin_LTLIBRARIES = \
36   libgnunet_plugin_block_dht.la 
37
38 libgnunet_plugin_block_dht_la_SOURCES = \
39   plugin_block_dht.c
40 libgnunet_plugin_block_dht_la_LIBADD = \
41   $(top_builddir)/src/hello/libgnunethello.la \
42   $(top_builddir)/src/block/libgnunetblock.la \
43   $(top_builddir)/src/util/libgnunetutil.la 
44 libgnunet_plugin_block_dht_la_LDFLAGS = \
45  $(GN_PLUGIN_LDFLAGS)
46 libgnunet_plugin_block_dht_la_DEPENDENCIES = \
47   $(top_builddir)/src/block/libgnunetblock.la 
48
49
50
51 bin_PROGRAMS = \
52  gnunet-service-dht \
53  gnunet-dht-monitor \
54  gnunet-dht-get \
55  gnunet-dht-put
56
57 gnunet_service_dht_SOURCES = \
58  gnunet-service-dht.c gnunet-service-dht.h \
59  gnunet-service-dht_clients.c gnunet-service-dht_clients.h \
60  gnunet-service-dht_datacache.c gnunet-service-dht_datacache.h \
61  gnunet-service-dht_hello.c gnunet-service-dht_hello.h \
62  gnunet-service-dht_nse.c gnunet-service-dht_nse.h \
63  gnunet-service-dht_neighbours.c gnunet-service-dht_neighbours.h \
64  gnunet-service-dht_routing.c gnunet-service-dht_routing.h 
65 gnunet_service_dht_LDADD = \
66   $(top_builddir)/src/statistics/libgnunetstatistics.la \
67   $(top_builddir)/src/core/libgnunetcore.la \
68   $(top_builddir)/src/nse/libgnunetnse.la \
69   $(top_builddir)/src/ats/libgnunetats.la \
70   $(top_builddir)/src/transport/libgnunettransport.la \
71   $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \
72   $(top_builddir)/src/hello/libgnunethello.la \
73   $(top_builddir)/src/block/libgnunetblock.la \
74   $(top_builddir)/src/datacache/libgnunetdatacache.la \
75   $(top_builddir)/src/util/libgnunetutil.la \
76   -lm
77
78 gnunet_dht_get_SOURCES = \
79  gnunet-dht-get.c         
80 gnunet_dht_get_LDADD = \
81   $(top_builddir)/src/dht/libgnunetdht.la \
82   $(top_builddir)/src/core/libgnunetcore.la \
83   $(top_builddir)/src/util/libgnunetutil.la 
84 gnunet_dht_get_DEPENDENCIES = \
85   libgnunetdht.la                             
86
87 gnunet_dht_put_SOURCES = \
88  gnunet-dht-put.c         
89 gnunet_dht_put_LDADD = \
90   $(top_builddir)/src/dht/libgnunetdht.la \
91   $(top_builddir)/src/core/libgnunetcore.la \
92   $(top_builddir)/src/util/libgnunetutil.la 
93 gnunet_dht_put_DEPENDENCIES = \
94   libgnunetdht.la                             
95
96 gnunet_dht_monitor_SOURCES = \
97  gnunet-dht-monitor.c         
98 gnunet_dht_monitor_LDADD = \
99   $(top_builddir)/src/dht/libgnunetdht.la \
100   $(top_builddir)/src/core/libgnunetcore.la \
101   $(top_builddir)/src/util/libgnunetutil.la 
102 gnunet_dht_monitor_DEPENDENCIES = \
103   libgnunetdht.la                             
104
105
106 check_PROGRAMS = \
107  test_dht_api \
108  test_dht_twopeer \
109  test_dht_twopeer_put_get \
110  test_dht_twopeer_get_put \
111  test_dht_twopeer_path_tracking \
112  test_dht_multipeer \
113  test_dht_line \
114  test_dht_2dtorus \
115  test_dht_monitor
116
117 if ENABLE_TEST_RUN
118 TESTS = test_dht_api $(check_SCRIPTS) \
119  test_dht_twopeer \
120  test_dht_twopeer_put_get \
121  test_dht_twopeer_get_put \
122  test_dht_twopeer_path_tracking \
123  test_dht_multipeer  \
124  test_dht_line \
125  test_dht_2dtorus \
126  test_dht_monitor
127 endif
128
129 test_dht_api_SOURCES = \
130  test_dht_api.c
131 test_dht_api_LDADD = \
132  $(top_builddir)/src/util/libgnunetutil.la \
133  $(top_builddir)/src/hello/libgnunethello.la \
134  $(top_builddir)/src/dht/libgnunetdht.la
135 test_dht_api_DEPENDENCIES = \
136   libgnunetdht.la                           
137
138 test_dht_twopeer_SOURCES = \
139  test_dht_twopeer.c
140 test_dht_twopeer_LDADD = \
141  $(top_builddir)/src/util/libgnunetutil.la \
142  $(top_builddir)/src/testing/libgnunettesting.la \
143  $(top_builddir)/src/dht/libgnunetdht.la    
144 test_dht_twopeer_DEPENDENCIES = \
145   libgnunetdht.la                           
146
147 test_dht_twopeer_put_get_SOURCES = \
148  test_dht_twopeer_put_get.c
149 test_dht_twopeer_put_get_LDADD = \
150  $(top_builddir)/src/util/libgnunetutil.la \
151  $(top_builddir)/src/testing/libgnunettesting.la \
152  $(top_builddir)/src/dht/libgnunetdht.la   
153
154 test_dht_twopeer_get_put_SOURCES = \
155  test_dht_twopeer_get_put.c
156 test_dht_twopeer_get_put_LDADD = \
157  $(top_builddir)/src/util/libgnunetutil.la \
158  $(top_builddir)/src/testing/libgnunettesting.la \
159  $(top_builddir)/src/dht/libgnunetdht.la   
160
161 test_dht_twopeer_path_tracking_SOURCES = \
162  test_dht_twopeer_path_tracking.c
163 test_dht_twopeer_path_tracking_LDADD = \
164  $(top_builddir)/src/util/libgnunetutil.la \
165  $(top_builddir)/src/testing/libgnunettesting.la \
166  $(top_builddir)/src/dht/libgnunetdht.la   
167
168 test_dht_multipeer_SOURCES = \
169  test_dht_multipeer.c
170 test_dht_multipeer_LDADD = \
171  $(top_builddir)/src/util/libgnunetutil.la \
172  $(top_builddir)/src/statistics/libgnunetstatistics.la \
173  $(top_builddir)/src/testing/libgnunettesting.la \
174  $(top_builddir)/src/dht/libgnunetdht.la  
175 test_dht_multipeer_DEPENDENCIES = \
176   libgnunetdht.la                           
177
178 test_dht_2dtorus_SOURCES = \
179  test_dht_topo.c
180 test_dht_2dtorus_LDADD = \
181  $(top_builddir)/src/util/libgnunetutil.la \
182  $(top_builddir)/src/testing/libgnunettesting.la \
183  $(top_builddir)/src/dht/libgnunetdht.la
184 test_dht_2dtorus_DEPENDENCIES = \
185   libgnunetdht.la
186
187 test_dht_line_SOURCES = \
188  test_dht_topo.c
189 test_dht_line_LDADD = \
190  $(top_builddir)/src/util/libgnunetutil.la \
191  $(top_builddir)/src/testing/libgnunettesting.la \
192  $(top_builddir)/src/dht/libgnunetdht.la
193 test_dht_line_DEPENDENCIES = \
194   libgnunetdht.la
195
196 test_dht_monitor_SOURCES = test_dht_monitor.c
197 test_dht_monitor_LDADD = \
198  $(top_builddir)/src/util/libgnunetutil.la \
199  $(top_builddir)/src/testing/libgnunettesting.la \
200  $(top_builddir)/src/dht/libgnunetdht.la
201 test_dht_monitor_DEPENDENCIES = \
202   libgnunetdht.la
203
204 EXTRA_DIST = \
205   $(check_SCRIPTS) \
206   test_dht_api_data.conf \
207   test_dht_api_peer1.conf \
208   test_dht_twopeer_data.conf \
209   test_dht_multipeer_data.conf \
210   test_dht_2dtorus.conf \
211   test_dht_line.conf \
212   multipeer_topo.dat
213
214 check_SCRIPTS = \
215   test_dht_tools.sh