Commit | Line | Data |
---|---|---|
26b53d3b | 1 | AM_CFLAGS=-I$(srcdir) |
ccf7af6c CB |
2 | if NO_SHARED |
3 | # Do not build this test if shared libraries support was | |
4 | # explicitly disabled. | |
5 | else | |
6 | # Force the shared flag on the noinst libraries since they are | |
7 | # only built static by default | |
26b53d3b DG |
8 | FORCE_SHARED_LIB_OPTIONS = -module -shared -avoid-version \ |
9 | -rpath $(abs_builddir) | |
10 | ||
11 | #contains ust_tests_demo.h and ust_tests_demo2.h provider probes | |
12 | liblttng_ust_provider_ust_tests_demo_la_SOURCES = \ | |
13 | tp.c ust_tests_demo.h \ | |
14 | tp2.c ust_tests_demo2.h | |
15 | liblttng_ust_provider_ust_tests_demo_la_LIBADD = -llttng-ust | |
16 | liblttng_ust_provider_ust_tests_demo_la_LDFLAGS = $(FORCE_SHARED_LIB_OPTIONS) | |
17 | ||
18 | #contains ust_tests_demo3.h provider probes | |
19 | liblttng_ust_provider_ust_tests_demo3_la_SOURCES = tp3.c ust_tests_demo3.h | |
20 | liblttng_ust_provider_ust_tests_demo3_la_LIBADD = -llttng-ust | |
21 | liblttng_ust_provider_ust_tests_demo3_la_LDFLAGS = $(FORCE_SHARED_LIB_OPTIONS) | |
22 | ||
23 | noinst_LTLIBRARIES = liblttng-ust-provider-ust-tests-demo.la \ | |
24 | liblttng-ust-provider-ust-tests-demo3.la | |
25 | ||
26 | noinst_PROGRAMS = demo | |
27 | demo_SOURCES = demo.c ust_tests_demo.h | |
28 | # The demo program only depends on libdl/libc for dlopen(). | |
29 | if LTTNG_TOOLS_BUILD_WITH_LIBDL | |
30 | demo_LDADD = -ldl | |
31 | endif | |
32 | if LTTNG_TOOLS_BUILD_WITH_LIBC_DL | |
33 | demo_LDADD = -lc | |
34 | endif | |
0a340972 DG |
35 | |
36 | noinst_SCRIPTS = demo-trace | |
37 | EXTRA_DIST = demo-trace | |
c83e7ca0 DG |
38 | |
39 | all-local: | |
40 | @if [ x"$(srcdir)" != x"$(builddir)" ]; then \ | |
41 | for script in $(EXTRA_DIST); do \ | |
42 | cp -f $(srcdir)/$$script $(builddir); \ | |
43 | done; \ | |
44 | fi | |
45 | ||
46 | clean-local: | |
47 | @if [ x"$(srcdir)" != x"$(builddir)" ]; then \ | |
48 | for script in $(EXTRA_DIST); do \ | |
49 | rm -f $(builddir)/$$script; \ | |
50 | done; \ | |
51 | fi | |
ccf7af6c | 52 | endif |