From: Pierre-Marc Fournier Date: Tue, 8 Sep 2009 17:56:39 +0000 (-0400) Subject: add basic_long test program X-Git-Tag: v1.9.1~932 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=5f04cdcbbea9d600b3f325dd739b217ab2a8f78a;p=lttng-ust.git add basic_long test program --- diff --git a/configure.ac b/configure.ac index a8accce4..500765b7 100644 --- a/configure.ac +++ b/configure.ac @@ -81,6 +81,8 @@ AC_CONFIG_FILES([ tests/Makefile tests/hello/Makefile tests/hello2/Makefile + tests/basic/Makefile + tests/basic_long/Makefile libmallocwrap/Makefile libinterfork/Makefile ustd/Makefile diff --git a/tests/Makefile.am b/tests/Makefile.am index 0308483d..644b80f1 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -1 +1 @@ -SUBDIRS = hello hello2 +SUBDIRS = hello hello2 basic basic_long diff --git a/tests/basic_long/Makefile.am b/tests/basic_long/Makefile.am new file mode 100644 index 00000000..219be7a7 --- /dev/null +++ b/tests/basic_long/Makefile.am @@ -0,0 +1,9 @@ +INCLUDES = -I$(top_builddir)/share -I$(top_builddir)/libust \ + $(KCOMPAT_CFLAGS) $(URCU_CFLAGS) + +noinst_PROGRAMS = basic_long +basic_long_SOURCES = basic_long.c +basic_long_LDADD = $(top_builddir)/libust/libust.la $(URCU_LIBS) + +noinst_SCRIPTS = run +EXTRA_DIST = run diff --git a/tests/basic_long/basic_long.c b/tests/basic_long/basic_long.c new file mode 100644 index 00000000..29f26ef9 --- /dev/null +++ b/tests/basic_long/basic_long.c @@ -0,0 +1,20 @@ +#include +#include + +#include "marker.h" + + +int main() +{ + printf("Basic test program\n"); + + for(;;) { + trace_mark(ust, bar, "str %s", "FOOBAZ"); + trace_mark(ust, bar2, "number1 %d number2 %d", 53, 9800); + usleep(1000000); + } + + return 0; +} + +MARKER_LIB; diff --git a/tests/basic_long/run b/tests/basic_long/run new file mode 100755 index 00000000..a137ed2f --- /dev/null +++ b/tests/basic_long/run @@ -0,0 +1,8 @@ +#!/bin/sh + +# Run with nothing + + +#LD_LIBRARY_PATH=../../libust/.libs:../../../liburcu $1 .libs/basic +#UST_AUTOPROBE="/foo" LD_LIBRARY_PATH=../../libust/.libs:../../../liburcu $1 .libs/basic +UST_AUTOPROBE=1 UST_TRACE=1 LD_LIBRARY_PATH=../../libust/.libs:../../../liburcu $1 .libs/basic_long