From 814bc89d4635f101b2c0077598f31aad95ed15b7 Mon Sep 17 00:00:00 2001 From: fche Date: Sat, 12 Aug 2006 05:13:09 +0000 Subject: 2006-08-12 Frank Ch. Eigler * configure.ac, Makefile.am: Descend into testsuite/ directory. Remove local test logic. * configure, Makefile.in: Regenerated. * runtest.sh: Not yet removed. * HACKING: Update for new testsuite layout. 2006-08-12 Frank Ch. Eigler * all: Reorganized old pass-1..4 tests one dejagnu bucket. Moved over old pass-5 tests, except for disabled syscalls tests. * Makefile (installcheck): New target for running pass-1..5 tests against installed systemtap. --- testsuite/lib/systemtap.exp | 61 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) create mode 100644 testsuite/lib/systemtap.exp (limited to 'testsuite/lib/systemtap.exp') diff --git a/testsuite/lib/systemtap.exp b/testsuite/lib/systemtap.exp new file mode 100644 index 00000000..6bb578b4 --- /dev/null +++ b/testsuite/lib/systemtap.exp @@ -0,0 +1,61 @@ +load_lib site.exp + +proc installtest_p {} { + global TOOL_OPTIONS + if {[info exists TOOL_OPTIONS] && ($TOOL_OPTIONS == "install")} { + return 1 + } else { return 0 } +} + +proc print_systemtap_version {} { + set version [exec /bin/uname -r] + set location "/boot/vmlinux-$version" + if {! [file exists $location]} { + # try the debuginfo location + set location "/usr/lib/debug/lib/modules/$version/vmlinux" + if {! [file exists $location]} { set location "" } + } + + print "kernel location: $location" + print "kernel version: $version" + + set location [exec /usr/bin/which stap] + regexp {version [^)]*} [exec stap -V 2>@ stdout] version + + print "systemtap location: $location" + print "systemtap version: $version" +} + + +proc setup_systemtap_environment {} { + global srcdir prefix env + + # need an absolute SRCDIR for the top-level src/ tree + if {[string index $srcdir 0] != "/"} then { + set env(SRCDIR) [exec pwd]/$srcdir/.. + } else { + set env(SRCDIR) $srcdir/.. + } + + if [installtest_p] { + set env(LD_LIBRARY_PATH) $prefix/lib/systemtap + set env(SYSTEMTAP_TAPSET) $prefix/share/systemtap/tapset + set env(SYSTEMTAP_RUNTIME) $prefix/share/systemtap/runtime + set env(PATH) $prefix/bin:$env(PATH) + } else { + set env(LD_LIBRARY_PATH) ../lib-elfutils:../lib-elfutils/systemtap + set env(SYSTEMTAP_TAPSET) $env(SRCDIR)/tapset + set env(SYSTEMTAP_RUNTIME) $env(SRCDIR)/runtime + set env(PATH) ..:$env(PATH) + } +} + + +setup_systemtap_environment +print_systemtap_version + + +proc systemtap_init {args} {} +proc systemtap_version {} {} +proc systemtap_exit {} {} + -- cgit