Commit | Line | Data |
---|---|---|
a4cc1b1f MD |
1 | # SPDX-License-Identifier: GPL-2.0-only |
2 | ||
3 | AM_CPPFLAGS += -I$(top_srcdir)/tests/utils -I$(srcdir) \ | |
4 | -I$(top_srcdir)/tests/utils/testapp | |
5 | ||
6 | if HAVE_LIBLTTNG_UST_CTL | |
7 | # Disable some warnings flags to accomodate the tracepoint headers | |
8 | WARN_FLAGS = \ | |
9 | -Wno-redundant-decls \ | |
10 | -Wno-missing-field-initializers | |
11 | ||
12 | AM_CFLAGS += $(WARN_FLAGS) | |
13 | AM_CXXFLAGS += $(WARN_FLAGS) | |
14 | ||
15 | if NO_SHARED | |
16 | # Build the shared library as a static archive if shared libraries | |
17 | # are disabled. | |
18 | FORCE_SHARED_LIB_OPTIONS = | |
19 | else | |
20 | # Force the shared flag on the noinst libraries since they are | |
21 | # only built static by default | |
22 | FORCE_SHARED_LIB_OPTIONS = -module -shared -avoid-version \ | |
23 | -rpath $(abs_builddir) | |
24 | endif | |
25 | ||
26 | noinst_LTLIBRARIES = libtp-so-provider.la libtp-so-define.la \ | |
ab4919b5 KS |
27 | libtp-a-provider.la libtp-a-define.la \ |
28 | libtp-a_c-provider.la libtp-a_c-define.la | |
a4cc1b1f MD |
29 | |
30 | # dynamic libraries | |
31 | libtp_so_provider_la_SOURCES = \ | |
32 | tp-so-provider.cpp \ | |
33 | tp-so.h | |
34 | libtp_so_provider_la_LDFLAGS = \ | |
35 | $(FORCE_SHARED_LIB_OPTIONS) | |
36 | ||
37 | libtp_so_define_la_SOURCES = \ | |
38 | tp-so-define.cpp \ | |
39 | tp-so.h | |
40 | libtp_so_define_la_LDFLAGS = \ | |
41 | $(FORCE_SHARED_LIB_OPTIONS) | |
42 | ||
43 | # static archives | |
44 | libtp_a_provider_la_SOURCES = \ | |
45 | tp-a-provider.cpp \ | |
46 | tp-a.h | |
47 | ||
48 | libtp_a_define_la_SOURCES = \ | |
49 | tp-a-define.cpp \ | |
50 | tp-a.h | |
51 | ||
ab4919b5 KS |
52 | libtp_a_c_provider_la_SOURCES = \ |
53 | tp-a_c-provider.c \ | |
54 | tp-a_c.h | |
55 | ||
56 | libtp_a_c_define_la_SOURCES = \ | |
57 | tp-a_c-define.c \ | |
58 | tp-a_c.h | |
59 | ||
60 | ||
b8e79f3f KS |
61 | noinst_PROGRAMS = gen-ust-events-constructor \ |
62 | uses_heap | |
63 | gen_ust_events_constructor_SOURCES = main.cpp \ | |
a4cc1b1f MD |
64 | 01-tp-before-define.cpp \ |
65 | 02-define-tp.cpp \ | |
66 | 03-tp-after-define.cpp \ | |
67 | 04-tp-provider.cpp \ | |
68 | 05-tp-after-provider.cpp \ | |
69 | obj.cpp \ | |
70 | obj.h \ | |
71 | tp.h | |
72 | gen_ust_events_constructor_LDADD = $(UST_LIBS) \ | |
73 | $(builddir)/libtp-so-define.la \ | |
74 | $(builddir)/libtp-so-provider.la \ | |
75 | $(builddir)/libtp-a-define.la \ | |
76 | $(builddir)/libtp-a-provider.la \ | |
ab4919b5 KS |
77 | $(builddir)/libtp-a_c-define.la \ |
78 | $(builddir)/libtp-a_c-provider.la \ | |
a4cc1b1f MD |
79 | $(top_builddir)/tests/utils/libtestutils.la \ |
80 | $(DL_LIBS) | |
b8e79f3f KS |
81 | |
82 | uses_heap_SOURCES = uses_heap.cpp | |
a4cc1b1f | 83 | endif |