From e497069013ce9d032c86c23a5a818e941c9d2d65 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Mon, 12 Jan 2009 13:57:59 +0000 Subject: [PATCH] * ld-elf/elf.exp: Save and restore LDFLAGS. * ld-scripts/default-script.exp: Likewise. * ld-scripts/empty-orphan.exp: Likewise, and add to LDFLAGS rather than replacing. * ld-scripts/include.exp: Set --local-store for SPU. --- ld/testsuite/ChangeLog | 8 ++++++++ ld/testsuite/ld-elf/elf.exp | 3 +++ ld/testsuite/ld-scripts/default-script.exp | 2 ++ ld/testsuite/ld-scripts/empty-orphan.exp | 5 ++++- ld/testsuite/ld-scripts/include.exp | 3 ++- 5 files changed, 19 insertions(+), 2 deletions(-) diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog index 1ba7fcd727b..2fb90dfc9d2 100644 --- a/ld/testsuite/ChangeLog +++ b/ld/testsuite/ChangeLog @@ -1,3 +1,11 @@ +2009-01-13 Alan Modra + + * ld-elf/elf.exp: Save and restore LDFLAGS. + * ld-scripts/default-script.exp: Likewise. + * ld-scripts/empty-orphan.exp: Likewise, and add to LDFLAGS rather + than replacing. + * ld-scripts/include.exp: Set --local-store for SPU. + 2009-01-12 Alan Modra * ld-spu/ovl.d: Allow for absolute branches in stubs. diff --git a/ld/testsuite/ld-elf/elf.exp b/ld/testsuite/ld-elf/elf.exp index 080d9857112..b2c196a1ef1 100644 --- a/ld/testsuite/ld-elf/elf.exp +++ b/ld/testsuite/ld-elf/elf.exp @@ -25,6 +25,7 @@ if ![is_elf_format] { return } +set old_ldflags $LDFLAGS if { [istarget spu*-*-*] } { set LDFLAGS "$LDFLAGS --local-store 0:0" } @@ -60,6 +61,8 @@ if { [check_gc_sections_available] } { } } +set LDFLAGS $old_ldflags + # The following tests require running the executable generated by ld. if ![isnative] { return diff --git a/ld/testsuite/ld-scripts/default-script.exp b/ld/testsuite/ld-scripts/default-script.exp index 202f5324dec..b7d10ed1afd 100644 --- a/ld/testsuite/ld-scripts/default-script.exp +++ b/ld/testsuite/ld-scripts/default-script.exp @@ -19,6 +19,7 @@ # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, # MA 02110-1301, USA. +set old_ldflags $LDFLAGS if { [istarget spu*-*-*] } { set LDFLAGS "$LDFLAGS --local-store 0:0" } @@ -30,3 +31,4 @@ foreach t $test_list { run_dump_test [file rootname $t] } +set LDFLAGS $old_ldflags diff --git a/ld/testsuite/ld-scripts/empty-orphan.exp b/ld/testsuite/ld-scripts/empty-orphan.exp index 59a51a80ca7..cc0374fab8a 100644 --- a/ld/testsuite/ld-scripts/empty-orphan.exp +++ b/ld/testsuite/ld-scripts/empty-orphan.exp @@ -25,10 +25,13 @@ if ![is_elf_format] { return } +set old_ldflags $LDFLAGS if { [istarget spu*-*-*] } { - set LDFLAGS "--local-store 0:0" + set LDFLAGS "$LDFLAGS --local-store 0:0" } set testname "empty-orphan" run_dump_test empty-orphan + +set LDFLAGS $old_ldflags diff --git a/ld/testsuite/ld-scripts/include.exp b/ld/testsuite/ld-scripts/include.exp index 98fd55d22a0..eec5fd80fab 100644 --- a/ld/testsuite/ld-scripts/include.exp +++ b/ld/testsuite/ld-scripts/include.exp @@ -26,7 +26,7 @@ if [is_aout_format] { set old_ldflags $LDFLAGS if { [istarget spu*-*-*] } { - set LDFLAGS "$LDFLAGS --no-overlays" + set LDFLAGS "$LDFLAGS --local-store 0:0 --no-overlays" } set test_list [lsort [glob -nocomplain $srcdir/$subdir/include*.d]] @@ -36,4 +36,5 @@ foreach test_file $test_list { verbose $test_name run_dump_test $test_name } + set LDFLAGS $old_ldflags -- 2.30.2