Changed testcases structure
[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 AM_CLFAGS = -g
13
14 bin_PROGRAMS = \
15  gnunet-service-mesh
16
17 lib_LTLIBRARIES = \
18   libgnunetmesh.la \
19   libgnunetmeshnew.la
20
21 libgnunetmesh_la_SOURCES = \
22   mesh_api.c mesh_protocol.h
23 libgnunetmesh_la_LIBADD = \
24   $(top_builddir)/src/util/libgnunetutil.la \
25   $(top_builddir)/src/transport/libgnunettransport.la \
26   $(top_builddir)/src/core/libgnunetcore.la \
27   $(GN_LIBINTL) $(XLIB)
28 libgnunetmesh_la_LDFLAGS = \
29   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
30   -version-info 0:0:0
31
32 gnunet_service_mesh_SOURCES = \
33  gnunet-service-mesh.c mesh_tunnel_tree.c
34 gnunet_service_mesh_LDADD = \
35   $(top_builddir)/src/core/libgnunetcore.la\
36   $(top_builddir)/src/dht/libgnunetdht.la \
37   $(top_builddir)/src/util/libgnunetutil.la
38  gnunet_service_mesh_DEPENDENCIES = \
39   $(top_builddir)/src/core/libgnunetcore.la\
40   $(top_builddir)/src/dht/libgnunetdht.la \
41   $(top_builddir)/src/util/libgnunetutil.la
42
43 libgnunetmeshnew_la_SOURCES = \
44   mesh_api_new.c mesh.h
45 libgnunetmeshnew_la_LIBADD = \
46   $(top_builddir)/src/util/libgnunetutil.la \
47   $(XLIB)
48 libgnunetmeshnew_la_LDFLAGS = \
49   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
50   -version-info 0:0:0
51
52 check_PROGRAMS = \
53  test_mesh_api \
54  test_mesh_path_api \
55  test_mesh_local_1 \
56  test_mesh_local_2 \
57  test_mesh_small_unicast \
58  test_mesh_small_unicast_far \
59  test_mesh_small_multicast
60
61 test_mesh_api_SOURCES = \
62  test_mesh_api.c
63 test_mesh_api_LDADD = \
64  $(top_builddir)/src/util/libgnunetutil.la \
65  $(top_builddir)/src/mesh/libgnunetmeshnew.la
66 test_mesh_api_DEPENDENCIES = \
67   libgnunetmeshnew.la \
68    $(top_builddir)/src/util/libgnunetutil.la
69
70 test_mesh_path_api_SOURCES = \
71  test_mesh_path_api.c mesh_tunnel_tree.c
72 test_mesh_path_api_LDADD = \
73  $(top_builddir)/src/util/libgnunetutil.la \
74   $(top_builddir)/src/dht/libgnunetdht.la
75 test_mesh_path_api_DEPENDENCIES = \
76   libgnunetmeshnew.la \
77   $(top_builddir)/src/dht/libgnunetdht.la
78
79 test_mesh_local_1_SOURCES = \
80  test_mesh_local_1.c
81 test_mesh_local_1_LDADD = \
82  $(top_builddir)/src/util/libgnunetutil.la \
83  $(top_builddir)/src/mesh/libgnunetmeshnew.la
84 test_mesh_local_1_DEPENDENCIES = \
85   libgnunetmeshnew.la
86
87 test_mesh_local_2_SOURCES = \
88  test_mesh_local_2.c
89 test_mesh_local_2_LDADD = \
90  $(top_builddir)/src/util/libgnunetutil.la \
91  $(top_builddir)/src/mesh/libgnunetmeshnew.la
92 test_mesh_local_2_DEPENDENCIES = \
93   libgnunetmeshnew.la
94
95 test_mesh_small_unicast_SOURCES = \
96  test_mesh_small.c
97 test_mesh_small_unicast_LDADD = \
98   $(top_builddir)/src/mesh/libgnunetmeshnew.la \
99   $(top_builddir)/src/util/libgnunetutil.la \
100   $(top_builddir)/src/testing/libgnunettesting.la
101 test_mesh_small_unicast_DEPENDENCIES = \
102   libgnunetmeshnew.la
103
104 test_mesh_small_unicast_far_SOURCES = \
105  test_mesh_small.c
106 test_mesh_small_unicast_far_LDADD = \
107   $(top_builddir)/src/mesh/libgnunetmeshnew.la \
108   $(top_builddir)/src/util/libgnunetutil.la \
109   $(top_builddir)/src/testing/libgnunettesting.la
110 test_mesh_small_unicast_far_DEPENDENCIES = \
111   libgnunetmeshnew.la
112
113 test_mesh_small_multicast_SOURCES = \
114  test_mesh_small.c
115 test_mesh_small_multicast_LDADD = \
116   $(top_builddir)/src/mesh/libgnunetmeshnew.la \
117   $(top_builddir)/src/util/libgnunetutil.la \
118   $(top_builddir)/src/testing/libgnunettesting.la
119 test_mesh_small_multicast_DEPENDENCIES = \
120   libgnunetmeshnew.la
121
122
123 if ENABLE_TEST_RUN
124 TESTS = test_mesh_api test_mesh_path_api test_mesh_local_1 test_mesh_local_2 test_mesh_small_unicast test_mesh_small_multicast
125 endif
126
127 EXTRA_DIST = \
128   test_mesh.conf \
129   test_mesh_path.conf \
130   test_mesh_small.conf