libctf: tests: prune warnings from compiler output

We were failing to call prune_warnings appropriately, leading to
false-positive test failures on some platforms (observed on
sparclinux).

libctf/ChangeLog:

	* testsuite/lib/ctf-lib.exp: Prune warnings from compiler and
	linker output.
	* testsuite/libctf-regression/libctf-repeat-cu.exp: Likewise,
	and ar output too.
This commit is contained in:
Nick Alcock
2022-06-11 13:07:18 +01:00
parent 3ec2b3c058
commit 6a8829ebb2
2 changed files with 6 additions and 6 deletions

View File

@@ -181,7 +181,7 @@ proc run_lookup_test { name } {
}
# Compile and link the lookup program.
set comp_output [compile_link_one_host_cc $opts(lookup) "tmpdir/lookup" "libctf.la"]
set comp_output [prune_warnings [compile_link_one_host_cc $opts(lookup) "tmpdir/lookup" "libctf.la"]]
if { $comp_output != ""} {
send_log "compilation of lookup program $opts(lookup) failed with <$comp_output>"
@@ -217,7 +217,7 @@ proc run_lookup_test { name } {
}
}
set comp_output [run_host_cmd "$CC_FOR_TARGET" "$CFLAGS_FOR_TARGET $lookup_flags [concat $src] -o $lookup_output"]
set comp_output [prune_warnings [run_host_cmd "$CC_FOR_TARGET" "$CFLAGS_FOR_TARGET $lookup_flags [concat $src] -o $lookup_output"]]
if { $comp_output != ""} {
send_log "compilation of CTF program [concat $src] failed with <$comp_output>"