This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb] Avoid testsuite errors about missing compilers.
- From: Nick Clifton <nickc at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 11 Aug 2016 09:23:16 -0000
- Subject: [binutils-gdb] Avoid testsuite errors about missing compilers.
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=7f6bf02d58c837d0a5f1e266058cc0e6bd6fc318
commit 7f6bf02d58c837d0a5f1e266058cc0e6bd6fc318
Author: Nick Clifton <nickc@redhat.com>
Date: Thu Aug 11 10:22:41 2016 +0100
Avoid testsuite errors about missing compilers.
PR ld/20436
* testsuite/lib/ld-lib.exp (check_gcc_plugin_enabled): When not
testing remotely, check to see if target compiler is installed
before trying to run it.
Diff:
---
ld/ChangeLog | 7 +++++++
ld/testsuite/lib/ld-lib.exp | 5 ++++-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/ld/ChangeLog b/ld/ChangeLog
index f6b994e..6e9565c 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,10 @@
+2016-08-11 Nick Clifton <nickc@redhat.com>
+
+ PR ld/20436
+ * testsuite/lib/ld-lib.exp (check_gcc_plugin_enabled): When not
+ testing remotely, check to see if target compiler is installed
+ before trying to run it.
+
2016-08-10 Maciej W. Rozycki <macro@imgtec.com>
PR ld/15428
diff --git a/ld/testsuite/lib/ld-lib.exp b/ld/testsuite/lib/ld-lib.exp
index b3cdb70..23055be 100644
--- a/ld/testsuite/lib/ld-lib.exp
+++ b/ld/testsuite/lib/ld-lib.exp
@@ -1815,7 +1815,10 @@ proc check_gcc_plugin_enabled { } {
if {![info exists CC]} {
set CC [find_gcc]
}
- if { $CC == "" } {
+ if { $CC == ""} {
+ return 0
+ }
+ if { ![is_remote host] && [which $CC] == 0 } then {
return 0
}
set state [remote_exec host $CC -v]