aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite
diff options
context:
space:
mode:
Diffstat (limited to 'ld/testsuite')
-rw-r--r--ld/testsuite/ChangeLog5
-rw-r--r--ld/testsuite/config/default.exp10
2 files changed, 14 insertions, 1 deletions
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index 78c941b..b13f7a0 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2009-03-17 Alan Modra <amodra@bigpond.net.au>
+ * config/default.exp (get_link_files): Replace double dollars with
+ single dollars.
+
+2009-03-17 Alan Modra <amodra@bigpond.net.au>
+
* ld-bootstrap/bootstrap.exp: Use DO_COMPARE. Remove unnecessary
cleanup and log output.
diff --git a/ld/testsuite/config/default.exp b/ld/testsuite/config/default.exp
index ab35ecf..952be42 100644
--- a/ld/testsuite/config/default.exp
+++ b/ld/testsuite/config/default.exp
@@ -115,9 +115,17 @@ proc get_link_files {varname} {
global srcdir
global CC
if ![info exists $varname] {
- set status [catch "exec sh -c \"host='$target_triplet' && CC='$CC' && . $srcdir/../configure.host && eval echo \\$$varname\"" result]
+ #configure.host returns variables that can be substituted into
+ #makefile rules, with embedded shell variable expansions.
+ #make wants $$shell_var, we want $shell_var ...
+ set cmd "host='$target_triplet' && . $srcdir/../configure.host && sed -e 's,\\\$\\\$,\$,g' <<EOF\n\$$varname\nEOF"
+ set status [catch "exec sh -c [list $cmd]" result]
+ if $status { error "Error getting native link files: $result" }
+ set cmd "CC='$CC' && eval echo \"$result\""
+ set status [catch "exec sh -c [list $cmd]" result]
if $status { error "Error getting native link files: $result" }
set $varname $result
+ send_log "$varname = $result\n"
}
}