- notify clients when a tunnel times out
[oweals/gnunet.git] / src / mesh / Makefile.am
1 INCLUDES = -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 pkgcfgdir= $(pkgdatadir)/config.d/
13
14 pkgcfg_DATA = \
15   mesh.conf
16
17 plugindir = $(libdir)/gnunet
18
19 AM_CLFAGS = -g
20
21 bin_PROGRAMS = \
22  gnunet-service-mesh
23
24 lib_LTLIBRARIES = \
25   libgnunetmesh.la \
26   libgnunetmeshblock.la
27
28 plugin_LTLIBRARIES = \
29  libgnunet_plugin_block_mesh.la
30
31 libgnunet_plugin_block_mesh_la_SOURCES = \
32  plugin_block_mesh.c
33 libgnunet_plugin_block_mesh_la_LIBADD = \
34  $(top_builddir)/src/mesh/libgnunetmeshblock.la \
35  $(top_builddir)/src/block/libgnunetblock.la \
36  $(top_builddir)/src/util/libgnunetutil.la
37 libgnunet_plugin_block_mesh_la_LDFLAGS = \
38  $(GN_PLUGIN_LDFLAGS)
39 libgnunet_plugin_block_mesh_la_DEPENDENCIES = \
40  libgnunetmeshblock.la \
41  $(top_builddir)/src/block/libgnunetblock.la \
42  $(top_builddir)/src/util/libgnunetutil.la
43
44 libgnunetmesh_la_SOURCES = \
45   mesh_api.c mesh_common.c
46 libgnunetmesh_la_LIBADD = \
47   $(top_builddir)/src/util/libgnunetutil.la \
48   $(XLIB) \
49   $(LTLIBINTL)
50 libgnunetmesh_la_LDFLAGS = \
51   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
52   -version-info 1:0:0
53
54 libgnunetmeshblock_la_SOURCES = \
55   mesh_block_lib.c
56 libgnunetmeshblock_la_LIBADD = \
57   $(top_builddir)/src/util/libgnunetutil.la \
58   $(XLIB) \
59   $(LTLIBINTL)
60 libgnunetmeshblock_la_LDFLAGS = \
61   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
62   -version-info 1:0:0
63
64 gnunet_service_mesh_SOURCES = \
65  gnunet-service-mesh.c \
66  mesh_tunnel_tree.c \
67  mesh_common.c
68 gnunet_service_mesh_CFLAGS = $(AM_CFLAGS)
69 gnunet_service_mesh_LDADD = \
70   $(top_builddir)/src/util/libgnunetutil.la \
71   $(top_builddir)/src/core/libgnunetcore.la \
72   $(top_builddir)/src/dht/libgnunetdht.la \
73   $(top_builddir)/src/statistics/libgnunetstatistics.la \
74   $(top_builddir)/src/block/libgnunetblock.la \
75   $(top_builddir)/src/mesh/libgnunetmeshblock.la \
76   $(top_builddir)/src/regex/libgnunetregex.la
77 gnunet_service_mesh_DEPENDENCIES = \
78   $(top_builddir)/src/util/libgnunetutil.la \
79   $(top_builddir)/src/core/libgnunetcore.la \
80   $(top_builddir)/src/dht/libgnunetdht.la \
81   $(top_builddir)/src/statistics/libgnunetstatistics.la \
82   $(top_builddir)/src/block/libgnunetblock.la \
83   libgnunetmeshblock.la \
84   $(top_builddir)/src/regex/libgnunetregex.la
85 if LINUX
86 gnunet_service_mesh_LDFLAGS = -lrt
87 endif
88
89 check_PROGRAMS = \
90  test_mesh_api \
91  test_mesh_tree_api \
92  test_mesh_local_1 \
93  test_mesh_local_2 \
94  test_mesh_local_traffic_fwd \
95  test_mesh_local_traffic_bck \
96  test_mesh_local_traffic_both \
97  test_mesh_2dtorus \
98  test_mesh_regex \
99  test_mesh_small_unicast \
100  test_mesh_small_multicast \
101  test_mesh_small_speed \
102  test_mesh_small_speed_nobuf \
103  test_mesh_small_speed_min \
104  test_mesh_small_speed_ack
105
106 test_mesh_api_SOURCES = \
107  test_mesh_api.c
108 test_mesh_api_LDADD = \
109  $(top_builddir)/src/util/libgnunetutil.la \
110  $(top_builddir)/src/testing/libgnunettesting.la \
111  $(top_builddir)/src/mesh/libgnunetmesh.la
112 test_mesh_api_DEPENDENCIES = \
113   libgnunetmesh.la \
114    $(top_builddir)/src/util/libgnunetutil.la
115
116 test_mesh_tree_api_SOURCES = \
117  test_mesh_tree_api.c
118 test_mesh_tree_api_LDADD = \
119  $(top_builddir)/src/util/libgnunetutil.la \
120  $(top_builddir)/src/dht/libgnunetdht.la
121 test_mesh_tree_api_DEPENDENCIES = \
122   libgnunetmesh.la \
123   $(top_builddir)/src/dht/libgnunetdht.la
124
125 test_mesh_local_1_SOURCES = \
126  test_mesh_local_1.c
127 test_mesh_local_1_LDADD = \
128  $(top_builddir)/src/util/libgnunetutil.la \
129  $(top_builddir)/src/testing/libgnunettesting.la \
130  $(top_builddir)/src/mesh/libgnunetmesh.la
131 test_mesh_local_1_DEPENDENCIES = \
132   libgnunetmesh.la
133
134 test_mesh_local_2_SOURCES = \
135  test_mesh_local_2.c
136 test_mesh_local_2_LDADD = \
137  $(top_builddir)/src/util/libgnunetutil.la \
138  $(top_builddir)/src/testing/libgnunettesting.la \
139  $(top_builddir)/src/mesh/libgnunetmesh.la
140 test_mesh_local_2_DEPENDENCIES = \
141   libgnunetmesh.la
142
143 test_mesh_local_traffic_fwd_SOURCES = \
144  test_mesh_local_traffic.c
145 test_mesh_local_traffic_fwd_LDADD = \
146  $(top_builddir)/src/util/libgnunetutil.la \
147  $(top_builddir)/src/testing/libgnunettesting.la \
148  $(top_builddir)/src/mesh/libgnunetmesh.la
149 test_mesh_local_traffic_fwd_DEPENDENCIES = \
150   libgnunetmesh.la
151
152 test_mesh_local_traffic_bck_SOURCES = \
153  test_mesh_local_traffic.c
154 test_mesh_local_traffic_bck_LDADD = \
155  $(top_builddir)/src/util/libgnunetutil.la \
156  $(top_builddir)/src/testing/libgnunettesting.la \
157  $(top_builddir)/src/mesh/libgnunetmesh.la
158 test_mesh_local_traffic_bck_DEPENDENCIES = \
159   libgnunetmesh.la
160
161 test_mesh_local_traffic_both_SOURCES = \
162  test_mesh_local_traffic.c
163 test_mesh_local_traffic_both_LDADD = \
164  $(top_builddir)/src/util/libgnunetutil.la \
165  $(top_builddir)/src/testing/libgnunettesting.la \
166  $(top_builddir)/src/mesh/libgnunetmesh.la
167 test_mesh_local_traffic_both_DEPENDENCIES = \
168   libgnunetmesh.la
169
170
171 test_mesh_2dtorus_SOURCES = \
172  test_mesh_2dtorus.c
173 test_mesh_2dtorus_LDADD = \
174   $(top_builddir)/src/util/libgnunetutil.la \
175   $(top_builddir)/src/testing_old/libgnunettesting_old.la
176
177 test_mesh_regex_SOURCES = \
178  test_mesh_regex.c
179 test_mesh_regex_LDADD = \
180   $(top_builddir)/src/mesh/libgnunetmesh.la \
181   $(top_builddir)/src/util/libgnunetutil.la \
182   $(top_builddir)/src/testing_old/libgnunettesting_old.la
183 test_mesh_regex_DEPENDENCIES = \
184   libgnunetmesh.la
185
186
187 test_mesh_small_unicast_SOURCES = \
188  test_mesh_small.c
189 test_mesh_small_unicast_LDADD = \
190   $(top_builddir)/src/mesh/libgnunetmesh.la \
191   $(top_builddir)/src/util/libgnunetutil.la \
192   $(top_builddir)/src/testing_old/libgnunettesting_old.la
193 test_mesh_small_unicast_DEPENDENCIES = \
194   libgnunetmesh.la
195
196 test_mesh_small_multicast_SOURCES = \
197  test_mesh_small.c
198 test_mesh_small_multicast_LDADD = \
199   $(top_builddir)/src/mesh/libgnunetmesh.la \
200   $(top_builddir)/src/util/libgnunetutil.la \
201   $(top_builddir)/src/testing_old/libgnunettesting_old.la
202 test_mesh_small_multicast_DEPENDENCIES = \
203   libgnunetmesh.la
204
205 test_mesh_small_speed_SOURCES = \
206  test_mesh_small.c
207 test_mesh_small_speed_LDADD = \
208   $(top_builddir)/src/mesh/libgnunetmesh.la \
209   $(top_builddir)/src/util/libgnunetutil.la \
210   $(top_builddir)/src/testing_old/libgnunettesting_old.la
211 test_mesh_small_speed_DEPENDENCIES = \
212   libgnunetmesh.la
213
214 test_mesh_small_speed_min_SOURCES = \
215  test_mesh_small.c
216 test_mesh_small_speed_min_LDADD = \
217   $(top_builddir)/src/mesh/libgnunetmesh.la \
218   $(top_builddir)/src/util/libgnunetutil.la \
219   $(top_builddir)/src/testing_old/libgnunettesting_old.la
220 test_mesh_small_speed_min_DEPENDENCIES = \
221   libgnunetmesh.la
222
223 test_mesh_small_speed_nobuf_SOURCES = \
224  test_mesh_small.c
225 test_mesh_small_speed_nobuf_LDADD = \
226   $(top_builddir)/src/mesh/libgnunetmesh.la \
227   $(top_builddir)/src/util/libgnunetutil.la \
228   $(top_builddir)/src/testing_old/libgnunettesting_old.la
229 test_mesh_small_speed_nobuf_DEPENDENCIES = \
230   libgnunetmesh.la
231
232 test_mesh_small_speed_ack_SOURCES = \
233  test_mesh_small.c
234 test_mesh_small_speed_ack_LDADD = \
235   $(top_builddir)/src/mesh/libgnunetmesh.la \
236   $(top_builddir)/src/util/libgnunetutil.la \
237   $(top_builddir)/src/testing_old/libgnunettesting_old.la
238 test_mesh_small_speed_ack_DEPENDENCIES = \
239   libgnunetmesh.la
240
241 if ENABLE_TEST_RUN
242 TESTS = test_mesh_api \
243  test_mesh_tree_api \
244  test_mesh_local_1 test_mesh_local_2 \
245  test_mesh_local_traffic_fwd \
246  test_mesh_local_traffic_bck \
247  test_mesh_local_traffic_both \
248  test_mesh_2dtorus test_mesh_regex \
249  test_mesh_small_unicast test_mesh_small_multicast \
250  test_mesh_small_speed
251 endif
252
253 EXTRA_DIST = \
254   test_mesh.conf \
255   test_mesh_2dtorus.conf \
256   test_mesh_small.conf \
257   test_mesh_path.conf