71abf0459b9d91d7b5b7d94ae104edb23fab487a
[oweals/gnunet.git] / src / testbed / Makefile.am
1 AM_CPPFLAGS = -I$(top_srcdir)/src/include
2
3 if MINGW
4   WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols
5 endif
6
7 if USE_COVERAGE
8   AM_CFLAGS = --coverage -O0
9   XLIB = -lgcov
10 endif
11
12 if ENABLE_LL
13   ll_binaries = \
14     gnunet-testbed-mpi-spawn
15 endif
16
17 libexecdir= $(pkglibdir)/libexec/
18
19 pkgcfgdir= $(pkgdatadir)/config.d/
20
21 pkgcfg_DATA = \
22   testbed.conf
23
24 libexec_PROGRAMS = \
25   gnunet-service-testbed \
26   gnunet-helper-testbed \
27   gnunet-service-testbed-logger
28
29 bin_PROGRAMS = \
30   $(ll_binaries) \
31   gnunet-testbed-profiler
32
33 check_SCRIPTS = \
34   buildvars.py
35
36 CLEANFILES = $(check_SCRIPTS) \
37   buildvars.pyc
38
39 noinst_PROGRAMS = \
40   gnunet-service-test-barriers
41
42 gnunet_service_testbed_SOURCES = \
43   gnunet-service-testbed.h \
44   gnunet-service-testbed.c \
45   gnunet-service-testbed_links.c \
46   gnunet-service-testbed_peers.c \
47   gnunet-service-testbed_cache.c \
48   gnunet-service-testbed_oc.c \
49   gnunet-service-testbed_cpustatus.c \
50   gnunet-service-testbed_meminfo.c \
51   gnunet-service-testbed_meminfo.h \
52   gnunet-service-testbed_barriers.c \
53   gnunet-service-testbed_barriers.h
54 gnunet_service_testbed_LDADD = $(XLIB) \
55  $(top_builddir)/src/util/libgnunetutil.la \
56  $(top_builddir)/src/core/libgnunetcore.la \
57  $(top_builddir)/src/hello/libgnunethello.la \
58  $(top_builddir)/src/transport/libgnunettransport.la \
59  $(top_builddir)/src/testing/libgnunettesting.la \
60  $(top_builddir)/src/testbed/libgnunettestbed.la \
61  $(top_builddir)/src/arm/libgnunetarm.la \
62  $(LTLIBINTL) $(Z_LIBS)
63 gnunet_service_testbed_DEPENDENCIES = \
64  libgnunettestbed.la
65
66 gnunet_service_testbed_logger_SOURCES = \
67   gnunet-service-testbed-logger.c
68 gnunet_service_testbed_logger_LDADD = \
69  $(top_builddir)/src/util/libgnunetutil.la
70
71 gnunet_testbed_profiler_SOURCES = \
72   gnunet-testbed-profiler.c
73 gnunet_testbed_profiler_LDADD = $(XLIB) \
74  $(top_builddir)/src/util/libgnunetutil.la \
75  $(top_builddir)/src/testbed/libgnunettestbed.la
76 gnunet_testbed_profiler_DEPENDENCIES = \
77  libgnunettestbed.la
78
79 gnunet_helper_testbed_SOURCES = \
80   gnunet-helper-testbed.c
81 gnunet_helper_testbed_LDADD = $(XLIB) \
82  $(top_builddir)/src/util/libgnunetutil.la \
83  $(top_builddir)/src/testing/libgnunettesting.la \
84  libgnunettestbed.la \
85  $(LTLIBINTL) $(Z_LIBS)
86 gnunet_helper_testbed_DEPENDENCIES = \
87   gnunet-service-testbed.$(OBJEXT) \
88   libgnunettestbed.la
89
90 gnunet_testbed_mpi_spawn_SOURCES = gnunet_testbed_mpi_spawn.c
91 gnunet_testbed_mpi_spawn_LDADD = $(XLIB) \
92  $(top_builddir)/src/util/libgnunetutil.la \
93  $(top_builddir)/src/testbed/libgnunettestbed.la
94 gnunet_testbed_mpi_spawn_DEPENDENCIES = \
95  $(top_builddir)/src/util/libgnunetutil.la \
96  libgnunettestbed.la
97
98 lib_LTLIBRARIES = \
99   libgnunettestbed.la \
100   libgnunettestbedlogger.la
101
102 libgnunettestbed_la_SOURCES = \
103   testbed_api.c testbed_api.h testbed.h \
104   testbed_api_hosts.c testbed_api_hosts.h testbed_helper.h \
105   testbed_api_operations.c testbed_api_operations.h \
106   testbed_api_peers.c testbed_api_peers.h \
107   testbed_api_services.c \
108   testbed_api_statistics.c \
109   testbed_api_testbed.c \
110   testbed_api_test.c \
111   testbed_api_topology.c testbed_api_topology.h \
112   testbed_api_sd.c testbed_api_sd.h \
113   testbed_api_barriers.c 
114 libgnunettestbed_la_LIBADD = $(XLIB) \
115  $(top_builddir)/src/core/libgnunetcore.la \
116  $(top_builddir)/src/statistics/libgnunetstatistics.la \
117  $(top_builddir)/src/transport/libgnunettransport.la \
118  $(top_builddir)/src/hello/libgnunethello.la \
119  -lm \
120  $(top_builddir)/src/util/libgnunetutil.la \
121  $(top_builddir)/src/testing/libgnunettesting.la \
122  $(LTLIBINTL)
123 libgnunettestbed_la_LDFLAGS = \
124  $(GN_LIB_LDFLAGS) \
125  -version-info 0:0:0
126
127 libgnunettestbedlogger_la_SOURCES = \
128   testbed_logger_api.c
129 libgnunettestbedlogger_la_LIBADD = $(XLIB) \
130  $(top_builddir)/src/util/libgnunetutil.la \
131  $(LTLIBINTL)
132 libgnunettestbedlogger_la_LDFLAGS = \
133  $(GN_LIB_LDFLAGS) \
134  -version-info 0:0:0
135
136 check_PROGRAMS = \
137   test_testbed_api_hosts \
138   test_testbed_logger_api \
139   test_gnunet_helper_testbed \
140   test_testbed_api_controllerlink \
141   test_testbed_api_2peers_1controller \
142   test_testbed_api_3peers_3controllers \
143   test_testbed_api \
144   test_testbed_api_sd \
145   test_testbed_api_operations \
146   test_testbed_api_testbed_run \
147   test_testbed_api_test \
148   test_testbed_api_test_timeout \
149   test_testbed_api_peer_reconfiguration \
150   test_testbed_api_peers_manage_services \
151   test_testbed_api_topology \
152   test_testbed_api_topology_clique \
153   test_testbed_api_testbed_run_topologyrandom \
154   test_testbed_api_testbed_run_topologyline \
155   test_testbed_api_testbed_run_topologyclique \
156   test_testbed_api_testbed_run_topologyring \
157   test_testbed_api_testbed_run_topologysmallworldring \
158   test_testbed_api_testbed_run_topology2dtorus \
159   test_testbed_api_testbed_run_topologysmallworld \
160   test_testbed_api_testbed_run_topologyfromfile \
161   test_testbed_api_testbed_run_topologyscalefree \
162   test_testbed_api_testbed_run_waitforever \
163   test_testbed_api_statistics \
164   test_testbed_api_barriers
165
166 if ENABLE_TEST_RUN
167  TESTS = \
168   test_testbed_api \
169   test_testbed_logger_api \
170   test_testbed_api_sd \
171   test_testbed_api_operations \
172   test_testbed_api_hosts \
173   test_gnunet_helper_testbed \
174   test_testbed_api_2peers_1controller \
175   test_testbed_api_controllerlink \
176   test_testbed_api_3peers_3controllers \
177   test_testbed_api_testbed_run \
178   test_testbed_api_test \
179   test_testbed_api_test_timeout \
180   test_testbed_api_statistics \
181   test_testbed_api_peer_reconfiguration \
182   test_testbed_api_peers_manage_services \
183   test_testbed_api_topology \
184   test_testbed_api_topology_clique \
185   test_testbed_api_testbed_run_topologyrandom \
186   test_testbed_api_testbed_run_topologyline \
187   test_testbed_api_testbed_run_topologyclique \
188   test_testbed_api_testbed_run_topologyring \
189   test_testbed_api_testbed_run_topology2dtorus \
190   test_testbed_api_testbed_run_topologysmallworld \
191   test_testbed_api_testbed_run_topologysmallworldring \
192   test_testbed_api_testbed_run_topologyfromfile \
193   test_testbed_api_testbed_run_topologyscalefree \
194   test_testbed_api_barriers
195 endif
196
197 test_testbed_api_hosts_SOURCES = \
198  test_testbed_api_hosts.c
199 test_testbed_api_hosts_LDADD = \
200  $(top_builddir)/src/util/libgnunetutil.la \
201  libgnunettestbed.la
202
203 test_testbed_api_SOURCES = \
204  test_testbed_api.c
205 test_testbed_api_LDADD = \
206  $(top_builddir)/src/util/libgnunetutil.la \
207  $(top_builddir)/src/testing/libgnunettesting.la \
208  $(top_builddir)/src/arm/libgnunetarm.la \
209  libgnunettestbed.la
210
211 test_testbed_logger_api_SOURCES = \
212  test_testbed_logger_api.c
213 test_testbed_logger_api_LDADD = \
214  $(top_builddir)/src/util/libgnunetutil.la \
215  $(top_builddir)/src/testing/libgnunettesting.la \
216  libgnunettestbedlogger.la
217
218 test_testbed_api_sd_SOURCES = \
219  test_testbed_api_sd.c
220 test_testbed_api_sd_LDADD = \
221  $(top_builddir)/src/util/libgnunetutil.la \
222  libgnunettestbed.la
223
224 test_testbed_api_2peers_1controller_SOURCES = \
225  test_testbed_api_2peers_1controller.c
226 test_testbed_api_2peers_1controller_LDADD = \
227  $(top_builddir)/src/util/libgnunetutil.la \
228  $(top_builddir)/src/testing/libgnunettesting.la \
229  libgnunettestbed.la
230
231 test_testbed_api_3peers_3controllers_SOURCES = \
232  test_testbed_api_3peers_3controllers.c
233 test_testbed_api_3peers_3controllers_LDADD = \
234  $(top_builddir)/src/util/libgnunetutil.la \
235  $(top_builddir)/src/testing/libgnunettesting.la \
236  libgnunettestbed.la
237
238 test_testbed_api_operations_SOURCES = \
239  test_testbed_api_operations.c
240 test_testbed_api_operations_LDADD = \
241  $(top_builddir)/src/util/libgnunetutil.la \
242  libgnunettestbed.la
243
244 test_testbed_api_controllerlink_SOURCES = \
245  test_testbed_api_controllerlink.c
246 test_testbed_api_controllerlink_LDADD = \
247  $(top_builddir)/src/util/libgnunetutil.la \
248  libgnunettestbed.la
249
250 test_testbed_api_testbed_run_SOURCES = \
251  test_testbed_api_testbed_run.c
252 test_testbed_api_testbed_run_LDADD = \
253  $(top_builddir)/src/util/libgnunetutil.la \
254  libgnunettestbed.la
255
256 test_testbed_api_test_SOURCES = \
257  test_testbed_api_test.c
258 test_testbed_api_test_LDADD = \
259  $(top_builddir)/src/util/libgnunetutil.la \
260  libgnunettestbed.la
261
262 test_testbed_api_test_timeout_SOURCES = \
263  test_testbed_api_test_timeout.c
264 test_testbed_api_test_timeout_LDADD = \
265  $(top_builddir)/src/util/libgnunetutil.la \
266  libgnunettestbed.la
267
268 test_testbed_api_topology_SOURCES = \
269  test_testbed_api_topology.c
270 test_testbed_api_topology_LDADD = \
271  $(top_builddir)/src/util/libgnunetutil.la \
272  libgnunettestbed.la
273
274 test_testbed_api_topology_clique_SOURCES = \
275  test_testbed_api_topology_clique.c
276 test_testbed_api_topology_clique_LDADD = \
277  $(top_builddir)/src/util/libgnunetutil.la \
278  libgnunettestbed.la
279
280 test_gnunet_helper_testbed_SOURCES = \
281  test_gnunet_helper_testbed.c
282 test_gnunet_helper_testbed_LDADD = \
283  $(top_builddir)/src/util/libgnunetutil.la \
284  libgnunettestbed.la \
285  $(Z_LIBZ)
286
287 test_testbed_api_testbed_run_topologyrandom_SOURCES = \
288  test_testbed_api_testbed_run.c
289 test_testbed_api_testbed_run_topologyrandom_LDADD = \
290  $(top_builddir)/src/util/libgnunetutil.la \
291  libgnunettestbed.la
292
293 test_testbed_api_testbed_run_topologyline_SOURCES = \
294  test_testbed_api_testbed_run.c
295 test_testbed_api_testbed_run_topologyline_LDADD = \
296  $(top_builddir)/src/util/libgnunetutil.la \
297  libgnunettestbed.la
298
299 test_testbed_api_testbed_run_topologyclique_SOURCES = \
300  test_testbed_api_testbed_run.c
301 test_testbed_api_testbed_run_topologyclique_LDADD = \
302  $(top_builddir)/src/util/libgnunetutil.la \
303  libgnunettestbed.la
304
305 test_testbed_api_testbed_run_topologyring_SOURCES = \
306  test_testbed_api_testbed_run.c
307 test_testbed_api_testbed_run_topologyring_LDADD = \
308  $(top_builddir)/src/util/libgnunetutil.la \
309  libgnunettestbed.la
310
311 test_testbed_api_testbed_run_topologysmallworldring_SOURCES = \
312  test_testbed_api_testbed_run.c
313 test_testbed_api_testbed_run_topologysmallworldring_LDADD = \
314  $(top_builddir)/src/util/libgnunetutil.la \
315  libgnunettestbed.la
316
317 test_testbed_api_testbed_run_topology2dtorus_SOURCES = \
318  test_testbed_api_testbed_run.c
319 test_testbed_api_testbed_run_topology2dtorus_LDADD = \
320  $(top_builddir)/src/util/libgnunetutil.la \
321  libgnunettestbed.la
322
323 test_testbed_api_testbed_run_topologysmallworld_SOURCES = \
324  test_testbed_api_testbed_run.c
325 test_testbed_api_testbed_run_topologysmallworld_LDADD = \
326  $(top_builddir)/src/util/libgnunetutil.la \
327  libgnunettestbed.la
328
329 test_testbed_api_testbed_run_topologyfromfile_SOURCES = \
330  test_testbed_api_testbed_run.c
331 test_testbed_api_testbed_run_topologyfromfile_LDADD = \
332  $(top_builddir)/src/util/libgnunetutil.la \
333  libgnunettestbed.la
334
335 test_testbed_api_testbed_run_topologyscalefree_SOURCES = \
336  test_testbed_api_testbed_run.c
337 test_testbed_api_testbed_run_topologyscalefree_LDADD = \
338  $(top_builddir)/src/util/libgnunetutil.la \
339  libgnunettestbed.la
340
341 test_testbed_api_testbed_run_waitforever_SOURCES = \
342  test_testbed_api_testbed_run.c
343 test_testbed_api_testbed_run_waitforever_LDADD = \
344  $(top_builddir)/src/util/libgnunetutil.la \
345  libgnunettestbed.la
346
347 test_testbed_api_statistics_SOURCES = \
348  test_testbed_api_statistics.c
349 test_testbed_api_statistics_LDADD = \
350  $(top_builddir)/src/util/libgnunetutil.la \
351  libgnunettestbed.la
352
353 test_testbed_api_peers_manage_services_SOURCES = \
354  test_testbed_api_peers_manage_services.c
355 test_testbed_api_peers_manage_services_LDADD = \
356  $(top_builddir)/src/util/libgnunetutil.la \
357  libgnunettestbed.la
358
359 test_testbed_api_peer_reconfiguration_SOURCES = \
360  test_testbed_api_peer_reconfiguration.c
361 test_testbed_api_peer_reconfiguration_LDADD = \
362  $(top_builddir)/src/util/libgnunetutil.la \
363  libgnunettestbed.la
364
365 test_testbed_api_barriers_SOURCES = \
366  test_testbed_api_barriers.c \
367  test_testbed_api_barriers.h
368 test_testbed_api_barriers_LDADD = \
369  $(top_builddir)/src/util/libgnunetutil.la \
370  libgnunettestbed.la
371
372 gnunet_service_test_barriers_SOURCES = \
373   gnunet-service-test-barriers.c \
374   test_testbed_api_barriers.h
375 gnunet_service_test_barriers_LDADD = \
376  $(top_builddir)/src/util/libgnunetutil.la \
377  libgnunettestbed.la
378
379 EXTRA_DIST = \
380   test_testbed_api.conf \
381   test_testbed_api_test_timeout.conf \
382   test_testbed_api_testbed_run_topologyring.conf \
383   test_testbed_api_testbed_run_topologyclique.conf \
384   test_testbed_api_testbed_run_topologyline.conf \
385   test_testbed_api_testbed_run_topologyrandom.conf \
386   test_testbed_api_testbed_run_topologysmallworldring.conf \
387   test_testbed_api_testbed_run_topology2dtorus.conf \
388   test_testbed_api_testbed_run_topologysmallworld.conf \
389   test_testbed_api_testbed_run_topologyfromfile.conf \
390   test_testbed_api_testbed_run_topologyscalefree.conf \
391   test_testbed_api_barriers.conf.in \
392   overlay_topology.txt \
393   sample_hosts.txt \
394   sample.job