-fix use of possibly wrong or uninitialized session
[oweals/gnunet.git] / src / peerstore / Makefile.am
1 AM_CPPFLAGS = -I$(top_srcdir)/src/include
2
3 plugindir = $(libdir)/gnunet
4
5 pkgcfgdir= $(pkgdatadir)/config.d/
6
7 libexecdir= $(pkglibdir)/libexec/
8
9 dist_pkgcfg_DATA = \
10   peerstore.conf
11
12 if MINGW
13  WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols 
14 endif
15
16 if USE_COVERAGE
17   AM_CFLAGS = -fprofile-arcs -ftest-coverage
18 endif
19
20 bin_PROGRAMS = \
21  gnunet-peerstore 
22
23 libexec_PROGRAMS = \
24  gnunet-service-peerstore
25
26 lib_LTLIBRARIES = \
27  libgnunetpeerstore.la
28
29 gnunet_peerstore_SOURCES = \
30  gnunet-peerstore.c
31 gnunet_peerstore_LDADD = \
32   $(top_builddir)/src/util/libgnunetutil.la \
33   libgnunetpeerstore.la \
34   $(GN_LIBINTL)
35
36 gnunet_service_peerstore_SOURCES = \
37  gnunet-service-peerstore.c \
38  peerstore_common.c
39 gnunet_service_peerstore_CFLAGS = $(AM_CFLAGS)
40 gnunet_service_peerstore_LDADD = \
41   $(top_builddir)/src/util/libgnunetutil.la \
42   $(GN_LIBINTL)
43
44 libgnunetpeerstore_la_SOURCES = \
45   peerstore_api.c \
46   peerstore_common.c
47 libgnunetpeerstore_la_LIBADD = \
48   $(top_builddir)/src/util/libgnunetutil.la
49 libgnunetpeerstore_la_LDFLAGS = \
50   $(GN_LIB_LDFLAGS)
51
52 plugin_LTLIBRARIES = \
53   libgnunet_plugin_peerstore_sqlite.la
54
55 libgnunet_plugin_peerstore_sqlite_la_SOURCES = \
56   plugin_peerstore_sqlite.c
57 libgnunet_plugin_peerstore_sqlite_la_LIBADD = \
58   libgnunetpeerstore.la  \
59   $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \
60   $(LTLIBINTL)
61 libgnunet_plugin_peerstore_sqlite_la_LDFLAGS = \
62  $(GN_PLUGIN_LDFLAGS)
63
64 check_PROGRAMS = \
65  test_peerstore_api_store \
66  test_peerstore_api_iterate \
67  test_peerstore_api_watch \
68  test_peerstore_api_sync \
69  perf_peerstore_store
70
71 if ENABLE_TEST_RUN
72 AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;
73 TESTS = $(check_PROGRAMS)
74 endif
75
76 test_peerstore_api_store_SOURCES = \
77  test_peerstore_api_store.c
78 test_peerstore_api_store_LDADD = \
79   libgnunetpeerstore.la  \
80   $(top_builddir)/src/testing/libgnunettesting.la \
81   $(top_builddir)/src/util/libgnunetutil.la
82
83 test_peerstore_api_iterate_SOURCES = \
84  test_peerstore_api_iterate.c
85 test_peerstore_api_iterate_LDADD = \
86   libgnunetpeerstore.la  \
87   $(top_builddir)/src/testing/libgnunettesting.la \
88   $(top_builddir)/src/util/libgnunetutil.la
89
90 test_peerstore_api_watch_SOURCES = \
91  test_peerstore_api_watch.c
92 test_peerstore_api_watch_LDADD = \
93   libgnunetpeerstore.la  \
94   $(top_builddir)/src/testing/libgnunettesting.la \
95   $(top_builddir)/src/util/libgnunetutil.la
96
97 test_peerstore_api_sync_SOURCES = \
98  test_peerstore_api_sync.c
99 test_peerstore_api_sync_LDADD = \
100   libgnunetpeerstore.la  \
101   $(top_builddir)/src/testing/libgnunettesting.la \
102   $(top_builddir)/src/util/libgnunetutil.la
103
104 perf_peerstore_store_SOURCES = \
105  perf_peerstore_store.c
106 perf_peerstore_store_LDADD = \
107   libgnunetpeerstore.la  \
108   $(top_builddir)/src/testing/libgnunettesting.la \
109   $(top_builddir)/src/util/libgnunetutil.la