adding a GNUNET_memcmp_priv for constant-time comparing of data; fixes #6152 (modulo...
[oweals/gnunet.git] / src / nse / Makefile.am
1 # This Makefile.am is in the public domain
2 AM_CPPFLAGS = -I$(top_srcdir)/src/include
3
4 if USE_COVERAGE
5   AM_CFLAGS = --coverage -O0
6   XLIB = -lgcov
7 endif
8
9 pkgcfgdir= $(pkgdatadir)/config.d/
10
11 libexecdir= $(pkglibdir)/libexec/
12
13 pkgcfg_DATA = \
14   nse.conf
15
16 bin_PROGRAMS = gnunet-nse
17
18 gnunet_nse_SOURCES = gnunet-nse.c
19 gnunet_nse_LDADD = \
20   libgnunetnse.la \
21   $(top_builddir)/src/util/libgnunetutil.la \
22   $(XLIB) $(GN_LIBINTL)
23
24 lib_LTLIBRARIES = libgnunetnse.la
25
26 libgnunetnse_la_SOURCES = \
27   nse_api.c nse.h
28 libgnunetnse_la_LIBADD = \
29   $(top_builddir)/src/util/libgnunetutil.la \
30   $(GN_LIBINTL) $(XLIB)
31 libgnunetnse_la_LDFLAGS = \
32   $(GN_LIB_LDFLAGS)   \
33   -version-info 0:0:0
34
35
36 libexec_PROGRAMS = \
37  gnunet-service-nse
38
39 if HAVE_TESTING
40 noinst_PROGRAMS = \
41  gnunet-nse-profiler
42 endif
43
44 gnunet_nse_profiler_SOURCES = \
45  gnunet-nse-profiler.c
46 gnunet_nse_profiler_LDADD = -lm \
47   libgnunetnse.la \
48   $(top_builddir)/src/util/libgnunetutil.la \
49   $(top_builddir)/src/statistics/libgnunetstatistics.la \
50   $(top_builddir)/src/testbed/libgnunettestbed.la \
51   $(GN_LIBINTL)
52
53 gnunet_service_nse_SOURCES = \
54  gnunet-service-nse.c
55 gnunet_service_nse_LDADD = \
56   libgnunetnse.la \
57   $(top_builddir)/src/util/libgnunetutil.la \
58   $(top_builddir)/src/core/libgnunetcore.la \
59   $(top_builddir)/src/statistics/libgnunetstatistics.la \
60   $(LIBGCRYPT_LIBS) \
61   -lm -lgcrypt \
62   $(GN_LIBINTL)
63 if ENABLE_NSE_HISTOGRAM
64   gnunet_service_nse_LDADD += \
65     $(top_builddir)/src/testbed-logger/libgnunettestbedlogger.la
66 endif
67
68
69 if HAVE_BENCHMARKS
70   MULTIPEER_TEST = test_nse_multipeer
71 endif
72
73 if HAVE_TESTING
74 check_PROGRAMS = \
75  test_nse_api \
76  perf_kdf \
77  $(MULTIPEER_TEST)
78 endif
79
80 if ENABLE_TEST_RUN
81 AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME;
82 TESTS = $(check_PROGRAMS)
83 endif
84
85 test_nse_api_SOURCES = \
86  test_nse_api.c
87 test_nse_api_LDADD = \
88   libgnunetnse.la \
89   $(top_builddir)/src/testing/libgnunettesting.la \
90   $(top_builddir)/src/util/libgnunetutil.la
91
92 test_nse_multipeer_SOURCES = \
93  test_nse_multipeer.c
94 test_nse_multipeer_LDADD = \
95   libgnunetnse.la \
96   $(top_builddir)/src/util/libgnunetutil.la \
97   $(top_builddir)/src/testbed/libgnunettestbed.la \
98   -lm
99
100 perf_kdf_SOURCES = \
101  perf_kdf.c
102 perf_kdf_LDADD = \
103   $(top_builddir)/src/util/libgnunetutil.la \
104   $(LIBGCRYPT_LIBS) \
105   -lgcrypt
106
107 EXTRA_DIST = \
108   test_nse.conf \
109   nse_profiler_test.conf