From: Alan Modra Date: Tue, 17 Mar 2009 05:33:00 +0000 (+0000) Subject: ld/ X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=bba21f1561dba85f85c50bc995443fd51c80609d;p=binutils-gdb.git ld/ * configure.host (HOSTING_LIBS): Two dollars on shell variable expansion to suit make. ld/testsuite * config/default.exp (get_link_files): Replace double dollars with single dollars. --- diff --git a/ld/ChangeLog b/ld/ChangeLog index b721b25162a..7937748dc08 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,8 @@ +2009-03-17 Alan Modra + + * configure.host (HOSTING_LIBS): Two dollars on shell variable + expansion to suit make. + 2009-03-17 Alan Modra * configure.in: Invoke ACX_PROG_CMP_IGNORE_INITIAL. diff --git a/ld/configure.host b/ld/configure.host index 9174971cb42..a6b1da33206 100644 --- a/ld/configure.host +++ b/ld/configure.host @@ -10,7 +10,7 @@ HDEFINES= HOSTING_CRT0=/lib/crt0.o -HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ]; then libgcc=../gcc/libgcc.a; else libgcc=\`${CC} -print-libgcc-file-name\`; fi; if [ -f ../gcc/libgcc_eh.a ]; then libgcc="$libgcc ../gcc/libgcc_eh.a"; else libgcc_eh=\`${CC} -print-file-name=libgcc_eh.a\`; if [ x"$libgcc_eh" != xlibgcc_eh.a ]; then libgcc="$libgcc $libgcc_eh"; fi; fi; if [ -f ../gcc/libunwind.a ]; then libgcc="$libgcc ../gcc/libunwind.a"; else libunwind=\`${CC} -print-file-name=libunwind.a\`; if [ x"$libunwind" != xlibunwind.a ]; then libgcc="$libgcc $libunwind"; fi; fi; echo --start-group $libgcc -lc --end-group`' +HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ]; then libgcc=../gcc/libgcc.a; else libgcc=\`${CC} -print-libgcc-file-name\`; fi; if [ -f ../gcc/libgcc_eh.a ]; then libgcc="$$libgcc ../gcc/libgcc_eh.a"; else libgcc_eh=\`${CC} -print-file-name=libgcc_eh.a\`; if [ x"$$libgcc_eh" != xlibgcc_eh.a ]; then libgcc="$$libgcc $$libgcc_eh"; fi; fi; if [ -f ../gcc/libunwind.a ]; then libgcc="$$libgcc ../gcc/libunwind.a"; else libunwind=\`${CC} -print-file-name=libunwind.a\`; if [ x"$$libunwind" != xlibunwind.a ]; then libgcc="$$libgcc $$libunwind"; fi; fi; echo --start-group $$libgcc -lc --end-group`' # # Generic configurations: diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog index 78c941b9ffd..b13f7a066cb 100644 --- a/ld/testsuite/ChangeLog +++ b/ld/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2009-03-17 Alan Modra + + * config/default.exp (get_link_files): Replace double dollars with + single dollars. + 2009-03-17 Alan Modra * ld-bootstrap/bootstrap.exp: Use DO_COMPARE. Remove unnecessary diff --git a/ld/testsuite/config/default.exp b/ld/testsuite/config/default.exp index ab35ecfa53f..952be42a331 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' <