1 AM_CFLAGS = -I$(top_srcdir)/include -I$(top_srcdir)/src -I$(top_srcdir)/tests/utils/ -I$(srcdir)
4 if LTTNG_TOOLS_BUILD_WITH_LIBDL
7 if LTTNG_TOOLS_BUILD_WITH_LIBC_DL
11 LIBTAP=$(top_builddir)/tests/utils/tap/libtap.la
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
17 # Define test programs
18 noinst_PROGRAMS = test_uri test_session test_kernel_data test_utils_parse_size_suffix
20 if HAVE_LIBLTTNG_UST_CTL
21 noinst_PROGRAMS += test_ust_data
25 test_uri_SOURCES = test_uri.c
26 test_uri_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBHASHTABLE)
29 SESSIONS=$(top_srcdir)/src/bin/lttng-sessiond/session.o \
30 $(top_srcdir)/src/bin/lttng-sessiond/consumer.o \
31 $(top_srcdir)/src/bin/lttng-sessiond/utils.o \
32 $(top_srcdir)/src/bin/lttng-sessiond/health.o \
33 $(top_srcdir)/src/common/.libs/uri.o \
34 $(top_srcdir)/src/common/.libs/utils.o \
35 $(top_srcdir)/src/common/.libs/error.o
37 test_session_SOURCES = test_session.c
38 test_session_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBSESSIOND_COMM) $(LIBHASHTABLE) \
40 test_session_LDADD += $(SESSIONS)
42 # UST data structures unit test
43 if HAVE_LIBLTTNG_UST_CTL
44 UST_DATA_TRACE=$(top_srcdir)/src/bin/lttng-sessiond/trace-ust.o \
45 $(top_srcdir)/src/bin/lttng-sessiond/consumer.o \
46 $(top_srcdir)/src/bin/lttng-sessiond/utils.o \
47 $(top_srcdir)/src/bin/lttng-sessiond/buffer-registry.o \
48 $(top_srcdir)/src/bin/lttng-sessiond/ust-registry.o \
49 $(top_srcdir)/src/bin/lttng-sessiond/ust-metadata.o \
50 $(top_srcdir)/src/bin/lttng-sessiond/ust-app.o \
51 $(top_srcdir)/src/bin/lttng-sessiond/ust-consumer.o \
52 $(top_srcdir)/src/bin/lttng-sessiond/fd-limit.o \
53 $(top_srcdir)/src/bin/lttng-sessiond/health.o \
54 $(top_srcdir)/src/bin/lttng-sessiond/session.o \
55 $(top_srcdir)/src/common/.libs/uri.o \
56 $(top_srcdir)/src/common/.libs/utils.o
58 test_ust_data_SOURCES = test_ust_data.c
59 test_ust_data_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBSESSIOND_COMM) $(LIBHASHTABLE) \
61 test_ust_data_LDADD += $(UST_DATA_TRACE)
64 # Kernel data structures unit test
65 KERN_DATA_TRACE=$(top_srcdir)/src/bin/lttng-sessiond/trace-kernel.o \
66 $(top_srcdir)/src/bin/lttng-sessiond/consumer.o \
67 $(top_srcdir)/src/bin/lttng-sessiond/health.o \
68 $(top_srcdir)/src/bin/lttng-sessiond/utils.o \
69 $(top_srcdir)/src/common/.libs/uri.o \
70 $(top_srcdir)/src/common/.libs/utils.o
72 test_kernel_data_SOURCES = test_kernel_data.c
73 test_kernel_data_LDADD = $(LIBTAP) $(LIBCOMMON) $(LIBSESSIOND_COMM) $(LIBHASHTABLE) \
75 test_kernel_data_LDADD += $(KERN_DATA_TRACE)
77 # parse_size_suffix unit test
78 UTILS_PARSE_SIZE_SUFFIX=$(top_srcdir)/src/common/.libs/utils.o \
79 $(top_srcdir)/src/common/.libs/runas.o
81 test_utils_parse_size_suffix_SOURCES = test_utils_parse_size_suffix.c
82 test_utils_parse_size_suffix_LDADD = $(LIBTAP) $(LIBHASHTABLE) $(LIBCOMMON)
83 test_utils_parse_size_suffix_LDADD += $(UTILS_PARSE_SIZE_SUFFIX)