aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorTom de Vries <tdevries@suse.de>2023-06-18 11:05:31 +0200
committerTom de Vries <tdevries@suse.de>2023-06-18 11:05:31 +0200
commitb7b77500dc56e5bc21473dd4f3dde2543d894557 (patch)
tree5328c4054859928dcb9d1bbed992e747a063d057 /gdb
parent2156c51d71dddafd43832c65972a38ed96c32fc0 (diff)
downloadfsf-binutils-gdb-b7b77500dc56e5bc21473dd4f3dde2543d894557.zip
fsf-binutils-gdb-b7b77500dc56e5bc21473dd4f3dde2543d894557.tar.gz
fsf-binutils-gdb-b7b77500dc56e5bc21473dd4f3dde2543d894557.tar.bz2
[gdb/testsuite] Clean standard_output_file dir in gdb_init
In commit e2adba909e7 ("[gdb/testsuite] Clean up before compilation in gdb.ada/call-no-debug.exp") I added some code in the test-case to remove some files at the start of the test-case: ... remote_file host delete [standard_output_file prog.o] remote_file host delete [standard_output_file prog.ali] ... Replace this with cleaning up the entire directory instead, for all test-cases. Tested on x86_64-linux. Suggested-By: Tom Tromey <tom@tromey.com> Reviewed-By: Tom Tromey <tom@tromey.com>
Diffstat (limited to 'gdb')
-rw-r--r--gdb/testsuite/gdb.ada/call-no-debug.exp5
-rw-r--r--gdb/testsuite/lib/gdb.exp3
2 files changed, 3 insertions, 5 deletions
diff --git a/gdb/testsuite/gdb.ada/call-no-debug.exp b/gdb/testsuite/gdb.ada/call-no-debug.exp
index df81c87..422b837 100644
--- a/gdb/testsuite/gdb.ada/call-no-debug.exp
+++ b/gdb/testsuite/gdb.ada/call-no-debug.exp
@@ -21,11 +21,6 @@ require allow_ada_tests
standard_ada_testfile prog
-# Since we use no-force to compile prog, make sure we don't pick up files
-# from a previous compilation.
-remote_file host delete [standard_output_file prog.o]
-remote_file host delete [standard_output_file prog.ali]
-
# Compile pck without debuginfo but prog with it.
if {[gdb_compile_ada $srcdir/$subdir/$testdir/pck.adb \
[standard_output_file pck.o] object {}] != ""} {
diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
index f214a6b..741b851 100644
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -6420,6 +6420,9 @@ proc default_gdb_init { test_file_name } {
set gdb_test_file_name [file rootname [file tail $test_file_name]]
+ # Clean directory containing the standard output files.
+ remote_exec build "rm -rf [standard_output_file ""]"
+
# Make sure that the wrapper is rebuilt
# with the appropriate multilib option.
if { $gdb_wrapper_target != [current_target_name] } {