From 59b2ec52534f90cf22a741cfb482b36f9dcb6a78 Mon Sep 17 00:00:00 2001 From: Stan Cox Date: Wed, 18 Feb 2009 18:00:42 -0500 Subject: Always emit .probes section; use .label method as a backup strategy --- testsuite/systemtap.base/static_uprobes.exp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'testsuite/systemtap.base') diff --git a/testsuite/systemtap.base/static_uprobes.exp b/testsuite/systemtap.base/static_uprobes.exp index 64cb6434..d80bd0c4 100644 --- a/testsuite/systemtap.base/static_uprobes.exp +++ b/testsuite/systemtap.base/static_uprobes.exp @@ -4,6 +4,7 @@ set test "sduprobes" # Compile a C program to use as the user-space probing target set sup_srcpath "[pwd]/static_uprobes.c" set sup_exepath "[pwd]/static_uprobes.x" +set supcplus_exepath "[pwd]/static_uprobes_cplus.x" set fp [open $sup_srcpath "w"] puts $fp " #include @@ -117,7 +118,7 @@ if { $res != "" } { spawn mv $sup_srcpath "[pwd]/static_uprobes.cc" set sup_srcpath "[pwd]/static_uprobes.cc" set sup_flags "$sup_flags c++" -set res [target_compile $sup_srcpath $sup_exepath executable $sup_flags] +set res [target_compile $sup_srcpath $supcplus_exepath executable $sup_flags] if { $res != "" } { verbose "target_compile failed: $res" 2 fail "compiling $sup_srcpath -g" @@ -162,6 +163,7 @@ if {$ok == 4} { pass "$test" } { fail "$test ($ok)" } set ok 0 +spawn objcopy -R .probes $supcplus_exepath $sup_exepath verbose -log "spawn stap -c $sup_exepath $sup_stppath" spawn stap -c $sup_exepath $sup_stppath expect { @@ -178,4 +180,4 @@ expect { wait if {$ok == 4} { pass "$test" } { fail "$test ($ok)" } -catch {exec rm -f $sup_srcpath $sup_exepath $sup_hpath $sup_stppath} +catch {exec rm -f $sup_srcpath $sup_exepath $supcplus_exepath $sup_hpath $sup_stppath} -- cgit