This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] fix status_wrapper for multi-libs


Andrew, 

This is the patch that should correct the problem with
using status_wrapper with multi-libs.

Michael

2002-05-15  Nick Clifton  <nickc@cambridge.redhat.com>

	* lib/gdb.exp (gdb_wrapper_init): Just because
	gdb_wrapper_file exists, this does not mean that the file
	should not be rebuilt.  That is what gdb_wrapper_initialized
	is for.
	(default_gdb_init): Reset gdb_wrapper_initialized.

Index: gdb.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/lib/gdb.exp,v
retrieving revision 1.18
diff -p -r1.18 gdb.exp
*** gdb.exp	10 May 2002 18:38:09 -0000	1.18
--- gdb.exp	23 May 2002 21:24:58 -0000
*************** proc gdb_wrapper_init { args } {
*** 1119,1126 ****
      if { $gdb_wrapper_initialized == 1 } { return; }
  
      if {[target_info exists needs_status_wrapper] && \
! 	    [target_info needs_status_wrapper] != "0" && \
! 	    ![info exists gdb_wrapper_file]} {
  	set result [build_wrapper "testglue.o"];
  	if { $result != "" } {
  	    set gdb_wrapper_file [lindex $result 0];
--- 1119,1125 ----
      if { $gdb_wrapper_initialized == 1 } { return; }
  
      if {[target_info exists needs_status_wrapper] && \
! 	    [target_info needs_status_wrapper] != "0"} {
  	set result [build_wrapper "testglue.o"];
  	if { $result != "" } {
  	    set gdb_wrapper_file [lindex $result 0];
*************** proc gdb_continue { function } {
*** 1390,1397 ****
--- 1389,1402 ----
  }
  
  proc default_gdb_init { args } {
+     global gdb_wrapper_initialized
+     
      gdb_clear_suppressed;
  
+     # Make sure that the wrapper is rebuilt
+     # with the appropriate multilib option.
+     set gdb_wrapper_initialized 0
+     
      # Uh, this is lame. Really, really, really lame. But there's this *one*
      # testcase that will fail in random places if we don't increase this.
      match_max -d 20000


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]