* lib/gdb.exp (current_target_name): New procedure.
(gdb_wrapper_target): New variable. (gdb_wrapper_init): Set gdb_wrapper_target. (default_gdb_init): Check gdb_wrapper_target before rebuilding the wrapper.
This commit is contained in:
parent
21327321a0
commit
f6838f8147
@ -1,3 +1,11 @@
|
||||
2009-11-13 Daniel Jacobowitz <dan@codesourcery.com>
|
||||
|
||||
* lib/gdb.exp (current_target_name): New procedure.
|
||||
(gdb_wrapper_target): New variable.
|
||||
(gdb_wrapper_init): Set gdb_wrapper_target.
|
||||
(default_gdb_init): Check gdb_wrapper_target before rebuilding the
|
||||
wrapper.
|
||||
|
||||
2009-11-13 Daniel Jacobowitz <dan@codesourcery.com>
|
||||
|
||||
* gdb.base/remote.exp: Delete the slowest load test.
|
||||
|
@ -1699,12 +1699,24 @@ proc test_compiler_info { {compiler ""} } {
|
||||
return [string match $compiler $compiler_info]
|
||||
}
|
||||
|
||||
proc current_target_name { } {
|
||||
global target_info
|
||||
if [info exists target_info(target,name)] {
|
||||
set answer $target_info(target,name)
|
||||
} else {
|
||||
set answer ""
|
||||
}
|
||||
return $answer
|
||||
}
|
||||
|
||||
set gdb_wrapper_initialized 0
|
||||
set gdb_wrapper_target ""
|
||||
|
||||
proc gdb_wrapper_init { args } {
|
||||
global gdb_wrapper_initialized;
|
||||
global gdb_wrapper_file;
|
||||
global gdb_wrapper_flags;
|
||||
global gdb_wrapper_target
|
||||
|
||||
if { $gdb_wrapper_initialized == 1 } { return; }
|
||||
|
||||
@ -1719,6 +1731,7 @@ proc gdb_wrapper_init { args } {
|
||||
}
|
||||
}
|
||||
set gdb_wrapper_initialized 1
|
||||
set gdb_wrapper_target [current_target_name]
|
||||
}
|
||||
|
||||
# Some targets need to always link a special object in. Save its path here.
|
||||
@ -2361,6 +2374,7 @@ proc gdb_continue { function } {
|
||||
|
||||
proc default_gdb_init { args } {
|
||||
global gdb_wrapper_initialized
|
||||
global gdb_wrapper_target
|
||||
global cleanfiles
|
||||
|
||||
set cleanfiles {}
|
||||
@ -2369,7 +2383,9 @@ proc default_gdb_init { args } {
|
||||
|
||||
# Make sure that the wrapper is rebuilt
|
||||
# with the appropriate multilib option.
|
||||
set gdb_wrapper_initialized 0
|
||||
if { $gdb_wrapper_target != [current_target_name] } {
|
||||
set gdb_wrapper_initialized 0
|
||||
}
|
||||
|
||||
# Unlike most tests, we have a small number of tests that generate
|
||||
# a very large amount of output. We therefore increase the expect
|
||||
|
Loading…
x
Reference in New Issue
Block a user