public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] testsuite: Treat empty string in needs_status_wrapper as a false value
@ 2013-10-17 12:59 Anton Kolesov
  2013-10-17 15:07 ` Anton Kolesov
  0 siblings, 1 reply; 7+ messages in thread
From: Anton Kolesov @ 2013-10-17 12:59 UTC (permalink / raw)
  To: gdb-patches; +Cc: Anton Kolesov, Jeremy.bennett

GCC testsuite treats empty string in [target_info needs_status_wrapper] the
same way as "0" - as a false value. GDB testsuite on the other hand recognizes
only zero as false. This patch changes this to improve compatibilty of board files.

gdb/testsuite/ChangeLog:

2013-10-17  Anton Kolesov <Anton.Kolesov@synopsys.com>

    * lib/gdb.exp (gdb_compile, gdb_wrapper_init): Treat empty string in
    target_info needs_status_wrapper the same way as zero - as a false value.
---
 gdb/testsuite/lib/gdb.exp | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
index 3efd539..f5f1555 100644
--- a/gdb/testsuite/lib/gdb.exp
+++ b/gdb/testsuite/lib/gdb.exp
@@ -2511,6 +2511,7 @@ proc gdb_wrapper_init { args } {
     if { $gdb_wrapper_initialized == 1 } { return; }
 
     if {[target_info exists needs_status_wrapper] && \
+	    [target_info needs_status_wrapper] != "" && \
 	    [target_info needs_status_wrapper] != "0"} {
 	set result [build_wrapper "testglue.o"]
 	if { $result != "" } {
@@ -2610,6 +2611,7 @@ proc gdb_compile {source dest type options} {
     if { $gdb_wrapper_initialized == 0 } { gdb_wrapper_init }
 
     if {[target_info exists needs_status_wrapper] && \
+	    [target_info needs_status_wrapper] != "" && \
 	    [target_info needs_status_wrapper] != "0" && \
 	    [info exists gdb_wrapper_file]} {
 	lappend options "libs=${gdb_wrapper_file}"
-- 
1.8.4.1

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2013-10-25  9:25 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-17 12:59 [PATCH] testsuite: Treat empty string in needs_status_wrapper as a false value Anton Kolesov
2013-10-17 15:07 ` Anton Kolesov
2013-10-21 11:17   ` [PATCH v2] testsuite: Treat an empty string in needs_status_wrapper as false Anton Kolesov
2013-10-21 11:23     ` Pedro Alves
2013-10-22 10:51       ` [PATCH v3] " Anton Kolesov
2013-10-24 22:07         ` Pedro Alves
2013-10-25  9:25           ` Anton Kolesov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).