LIBS += -lc
endif
+COPYSCRIPTS = test_thread_exit test_thread_stall test_tp_fail \
+ test_health.sh test_thread_ok
+dist_noinst_SCRIPTS = $(COPYSCRIPTS)
+
if NO_SHARED
# Do not build this test if shared libraries support was
# explicitly disabled.
+
+EXTRA_DIST = health_exit.c health_stall.c health_fail.c \
+ health_check.c $(COPYSCRIPTS)
+
else
# In order to test the health check feature, the libhealth* libs
# must be built as .so to be able to LD_PRELOAD them.
health_check_SOURCES = health_check.c $(UTILS)
health_check_LDADD = $(top_builddir)/src/lib/lttng-ctl/liblttng-ctl.la \
$(top_builddir)/src/common/libcommon.la
-endif
-dist_noinst_SCRIPTS = test_thread_exit test_thread_stall test_tp_fail \
- test_health.sh test_thread_ok
-EXTRA_DIST = test_thread_exit test_thread_stall test_tp_fail \
- test_health.sh test_thread_ok
+EXTRA_DIST = $(COPYSCRIPTS)
+
+endif
all-local:
@if [ x"$(srcdir)" != x"$(builddir)" ]; then \
- for script in $(EXTRA_DIST); do \
+ for script in $(COPYSCRIPTS); do \
cp -f $(srcdir)/$$script $(builddir); \
done; \
fi
clean-local:
@if [ x"$(srcdir)" != x"$(builddir)" ]; then \
- for script in $(EXTRA_DIST); do \
+ for script in $(COPYSCRIPTS); do \
rm -f $(builddir)/$$script; \
done; \
fi
+if NO_SHARED
+# Do not build this test if shared libraries support was
+# explicitly disabled.
+
+CLEANFILES = lttng-ust-clock-override-test.so \
+ lttng-ust-clock-override-test.so.debug
+
+EXTRA_DIST = test_clock_override lttng-ust-clock-override-test.c
+
+else
+
AM_CPPFLAGS = -I$(srcdir)
# The rpath is necessary because libtool won't build a shared library
rm -f $(builddir)/$$script; \
done; \
fi
+
+endif
+if NO_SHARED
+# Do not build this test if shared libraries support was
+# explicitly disabled.
+
+CLEANFILES = lttng-ust-getcpu-override-test.so \
+ lttng-ust-getcpu-override-test.so.debug
+
+EXTRA_DIST = test_getcpu_override run-getcpu-override \
+ lttng-ust-getcpu-override-test.c
+
+else
+
AM_CPPFLAGS = -I$(srcdir)
# The rpath is necessary because libtool won't build a shared library
rm -f $(builddir)/$$script; \
done; \
fi
+
+endif
noinst_PROGRAMS = demo_builtin demo_static
-if !NO_SHARED
+COPYSCRIPTS = test_linking test_linking.py demo_preload
+noinst_SCRIPTS = $(COPYSCRIPTS)
+
+if NO_SHARED
+
+EXTRA_DIST = tp.c ust_tests_demo.h tp2.c ust_tests_demo2.h \
+ tp3.c ust_tests_demo3.h demo.c ust_tests_demo.h \
+ $(COPYSCRIPTS)
+
+else
# Force the shared flag on the noinst libraries since they are
# only built static by default
FORCE_SHARED_LIB_OPTIONS = -module -shared -avoid-version \
demo_LDADD = -lc
endif
-endif
+EXTRA_DIST = $(COPYSCRIPTS)
-noinst_SCRIPTS = test_linking test_linking.py demo_preload
-EXTRA_DIST = test_linking test_linking.py demo_preload
+endif
all-local:
@if [ x"$(srcdir)" != x"$(builddir)" ]; then \
- for script in $(EXTRA_DIST); do \
+ for script in $(COPYSCRIPTS); do \
cp -f $(srcdir)/$$script $(builddir); \
done; \
fi
clean-local:
@if [ x"$(srcdir)" != x"$(builddir)" ]; then \
- for script in $(EXTRA_DIST); do \
+ for script in $(COPYSCRIPTS); do \
rm -f $(builddir)/$$script; \
done; \
fi
-AM_CFLAGS=-I$(srcdir)
if NO_SHARED
# Do not build this test if shared libraries support was
# explicitly disabled.
+
+CLEANFILES = demo
+
+EXTRA_DIST = demo-trace demo.c ust_tests_demo.h \
+ tp3.c ust_tests_demo3.h tp2.c ust_tests_demo2.h \
+ tp.c ust_tests_demo.h
+
else
+
+AM_CFLAGS=-I$(srcdir)
+
# Force the shared flag on the noinst libraries since they are
# only built static by default
FORCE_SHARED_LIB_OPTIONS = -module -shared -avoid-version \
rm -f $(builddir)/$$script; \
done; \
fi
+
endif
+if NO_SHARED
+# Do not build this test if shared libraries support was
+# explicitly disabled.
+
+CLEANFILES = libfoo.so libfoo.so.debug prog
+
+EXTRA_DIST = test_ust-dl test_ust-dl.py libfoo.c libfoo.h \
+ prog.c
+
+else
+
objcopy_verbose = $(objcopy_verbose_@AM_V@)
objcopy_verbose_ = $(objcopy_verbose_@AM_DEFAULT_V@)
objcopy_verbose_0 = @echo OBJCOPY $@;
libfoo_la_LDFLAGS = -module -shared -avoid-version \
-rpath $(abs_builddir)
-noinst_SCRIPTS = test_ust-dl test_ust-dl.py
-EXTRA_DIST = test_ust-dl test_ust-dl.py
+CLEANFILES = libfoo.so libfoo.so.debug
# Extract debug symbols
libfoo.so.debug: libfoo.la
@cp -f .libs/libfoo.so libfoo.so
$(objcopy_verbose)$(OBJCOPY) --strip-debug --add-gnu-debuglink=libfoo.so.debug libfoo.so
+noinst_SCRIPTS = test_ust-dl test_ust-dl.py
+EXTRA_DIST = test_ust-dl test_ust-dl.py
+
all-local: libfoo.so
@if [ x"$(srcdir)" != x"$(builddir)" ]; then \
for script in $(EXTRA_DIST); do \
done; \
fi
-CLEANFILES = libfoo.so libfoo.so.debug
+endif
source $TESTDIR/utils/utils.sh
+if [ ! -x "$CURDIR/.libs/libfoo.so" ]; then
+ BAIL_OUT "No shared object generated"
+fi
+
start_lttng_sessiond_notap
python3 ${CURDIR}/test_ust-dl.py