Adapting verify successor code to use trail id
[oweals/gnunet.git] / src / nse / 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 pkgcfgdir= $(pkgdatadir)/config.d/
13
14 libexecdir= $(pkglibdir)/libexec/
15
16 pkgcfg_DATA = \
17   nse.conf
18
19 bin_PROGRAMS = gnunet-nse
20
21 gnunet_nse_SOURCES = gnunet-nse.c
22 gnunet_nse_LDFLAGS = \
23   libgnunetnse.la \
24   $(top_builddir)/src/util/libgnunetutil.la \
25   $(XLIB) $(GN_LIBINTL)
26 gnunet_nse_DEPENDENCIES = \
27   libgnunetnse.la \
28   $(top_builddir)/src/util/libgnunetutil.la
29
30 lib_LTLIBRARIES = libgnunetnse.la
31
32 libgnunetnse_la_SOURCES = \
33   nse_api.c nse.h
34 libgnunetnse_la_LIBADD = \
35   $(top_builddir)/src/util/libgnunetutil.la \
36   $(GN_LIBINTL) $(XLIB)
37 libgnunetnse_la_LDFLAGS = \
38   $(GN_LIB_LDFLAGS)  $(WINFLAGS) \
39   -version-info 0:0:0
40
41
42 libexec_PROGRAMS = \
43  gnunet-service-nse
44
45 if HAVE_TESTING
46 noinst_PROGRAMS = \
47  gnunet-nse-profiler
48 endif
49
50 gnunet_nse_profiler_SOURCES = \
51  gnunet-nse-profiler.c
52 gnunet_nse_profiler_LDADD = -lm \
53   $(top_builddir)/src/nse/libgnunetnse.la \
54   $(top_builddir)/src/util/libgnunetutil.la \
55   $(top_builddir)/src/statistics/libgnunetstatistics.la \
56   $(top_builddir)/src/testbed/libgnunettestbed.la \
57   $(GN_LIBINTL)
58 gnunet_nse_profiler_DEPENDENCIES = \
59   libgnunetnse.la
60
61 gnunet_service_nse_SOURCES = \
62  gnunet-service-nse.c
63 gnunet_service_nse_LDADD = \
64   $(top_builddir)/src/nse/libgnunetnse.la \
65   $(top_builddir)/src/util/libgnunetutil.la \
66   $(top_builddir)/src/core/libgnunetcore.la \
67   $(top_builddir)/src/statistics/libgnunetstatistics.la \
68   $(LIBGCRYPT_LIBS) \
69   -lm -lgcrypt \
70   $(GN_LIBINTL)
71 gnunet_service_nse_DEPENDENCIES = \
72   libgnunetnse.la
73 if ENABLE_NSE_HISTOGRAM
74   gnunet_service_nse_LDADD += \
75     $(top_builddir)/src/testbed/libgnunettestbedlogger.la
76   gnunet_service_nse_DEPENDENCIES += \
77     $(top_builddir)/src/testbed/libgnunettestbedlogger.la
78 endif
79
80
81 if HAVE_BENCHMARKS
82   MULTIPEER_TEST = test_nse_multipeer
83 endif
84
85 if HAVE_TESTING
86 check_PROGRAMS = \
87  test_nse_api \
88  perf_kdf \
89  $(MULTIPEER_TEST)
90 endif
91
92 if ENABLE_TEST_RUN
93 AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;
94 TESTS = $(check_PROGRAMS)
95 endif
96
97 test_nse_api_SOURCES = \
98  test_nse_api.c
99 test_nse_api_LDADD = \
100   $(top_builddir)/src/nse/libgnunetnse.la \
101   $(top_builddir)/src/testing/libgnunettesting.la \
102   $(top_builddir)/src/util/libgnunetutil.la
103
104 test_nse_multipeer_SOURCES = \
105  test_nse_multipeer.c
106 test_nse_multipeer_LDADD = \
107   $(top_builddir)/src/nse/libgnunetnse.la \
108   $(top_builddir)/src/util/libgnunetutil.la \
109   $(top_builddir)/src/testbed/libgnunettestbed.la \
110   -lm
111
112 perf_kdf_SOURCES = \
113  perf_kdf.c
114 perf_kdf_LDADD = \
115   $(top_builddir)/src/util/libgnunetutil.la \
116   $(LIBGCRYPT_LIBS) \
117   -lgcrypt
118
119 EXTRA_DIST = \
120   test_nse.conf \
121   nse_profiler_test.conf
122
123