Implement the relayd live features
[lttng-tools.git] / tests / unit / Makefile.am
1 AM_CFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/src -I$(top_srcdir)/tests/utils/ -I$(srcdir)
2 AM_LDFLAGS =
3
4 if LTTNG_TOOLS_BUILD_WITH_LIBDL
5 AM_LDFLAGS += -ldl
6 endif
7 if LTTNG_TOOLS_BUILD_WITH_LIBC_DL
8 AM_LDFLAGS += -lc
9 endif
10
11 LIBTAP=$(top_builddir)/tests/utils/tap/libtap.la
12
13 LIBCOMMON=$(top_builddir)/src/common/libcommon.la
14 LIBSESSIOND_COMM=$(top_builddir)/src/common/sessiond-comm/libsessiond-comm.la
15 LIBHASHTABLE=$(top_builddir)/src/common/hashtable/libhashtable.la
16 LIBRELAYD=$(top_builddir)/src/common/relayd/librelayd.la
17
18 # Define test programs
19 noinst_PROGRAMS = test_uri test_session test_kernel_data test_utils_parse_size_suffix
20
21 if HAVE_LIBLTTNG_UST_CTL
22 noinst_PROGRAMS += test_ust_data
23 endif
24
25 # URI unit tests
26 test_uri_SOURCES = test_uri.c
27 test_uri_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBHASHTABLE)
28
29 # Session unit test
30 SESSIONS=$(top_builddir)/src/bin/lttng-sessiond/session.o \
31 $(top_builddir)/src/bin/lttng-sessiond/consumer.o \
32 $(top_builddir)/src/bin/lttng-sessiond/utils.o \
33 $(top_builddir)/src/bin/lttng-sessiond/health.o \
34 $(top_builddir)/src/bin/lttng-sessiond/snapshot.o \
35 $(top_builddir)/src/common/.libs/uri.o \
36 $(top_builddir)/src/common/.libs/utils.o \
37 $(top_builddir)/src/common/.libs/error.o
38
39 test_session_SOURCES = test_session.c
40 test_session_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBRELAYD) $(LIBSESSIOND_COMM) \
41 $(LIBHASHTABLE) -lrt
42 test_session_LDADD += $(SESSIONS)
43
44 # UST data structures unit test
45 if HAVE_LIBLTTNG_UST_CTL
46 UST_DATA_TRACE=$(top_builddir)/src/bin/lttng-sessiond/trace-ust.o \
47 $(top_builddir)/src/bin/lttng-sessiond/consumer.o \
48 $(top_builddir)/src/bin/lttng-sessiond/utils.o \
49 $(top_builddir)/src/bin/lttng-sessiond/buffer-registry.o \
50 $(top_builddir)/src/bin/lttng-sessiond/ust-registry.o \
51 $(top_builddir)/src/bin/lttng-sessiond/ust-metadata.o \
52 $(top_builddir)/src/bin/lttng-sessiond/ust-app.o \
53 $(top_builddir)/src/bin/lttng-sessiond/ust-consumer.o \
54 $(top_builddir)/src/bin/lttng-sessiond/fd-limit.o \
55 $(top_builddir)/src/bin/lttng-sessiond/health.o \
56 $(top_builddir)/src/bin/lttng-sessiond/session.o \
57 $(top_builddir)/src/bin/lttng-sessiond/snapshot.o \
58 $(top_builddir)/src/common/.libs/uri.o \
59 $(top_builddir)/src/common/.libs/utils.o
60
61 test_ust_data_SOURCES = test_ust_data.c
62 test_ust_data_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBRELAYD) $(LIBSESSIOND_COMM)\
63 $(LIBHASHTABLE) -lrt -llttng-ust-ctl
64 test_ust_data_LDADD += $(UST_DATA_TRACE)
65 endif
66
67 # Kernel data structures unit test
68 KERN_DATA_TRACE=$(top_builddir)/src/bin/lttng-sessiond/trace-kernel.o \
69 $(top_builddir)/src/bin/lttng-sessiond/consumer.o \
70 $(top_builddir)/src/bin/lttng-sessiond/health.o \
71 $(top_builddir)/src/bin/lttng-sessiond/utils.o \
72 $(top_builddir)/src/common/.libs/uri.o \
73 $(top_builddir)/src/common/.libs/utils.o
74
75 test_kernel_data_SOURCES = test_kernel_data.c
76 test_kernel_data_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBRELAYD) $(LIBSESSIOND_COMM) \
77 $(LIBHASHTABLE) -lrt
78 test_kernel_data_LDADD += $(KERN_DATA_TRACE)
79
80 # parse_size_suffix unit test
81 UTILS_PARSE_SIZE_SUFFIX=$(top_builddir)/src/common/.libs/utils.o \
82 $(top_builddir)/src/common/.libs/runas.o
83
84 test_utils_parse_size_suffix_SOURCES = test_utils_parse_size_suffix.c
85 test_utils_parse_size_suffix_LDADD = $(LIBTAP) $(LIBHASHTABLE) $(LIBCOMMON)
86 test_utils_parse_size_suffix_LDADD += $(UTILS_PARSE_SIZE_SUFFIX)
This page took 0.046016 seconds and 5 git commands to generate.