aboutsummaryrefslogtreecommitdiff
path: root/ld/testsuite
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@novell.com>2005-11-15 08:32:02 +0000
committerJan Beulich <jbeulich@novell.com>2005-11-15 08:32:02 +0000
commit9ab8018267fa3d466d8302aea29281dc121c5a52 (patch)
tree744e6eb67e9d780f3fecd64d1056e6e9f8493a0d /ld/testsuite
parent331e31641e5c53b8963537de87068a56f7a75dce (diff)
downloadfsf-binutils-gdb-9ab8018267fa3d466d8302aea29281dc121c5a52.zip
fsf-binutils-gdb-9ab8018267fa3d466d8302aea29281dc121c5a52.tar.gz
fsf-binutils-gdb-9ab8018267fa3d466d8302aea29281dc121c5a52.tar.bz2
binutils/testsuite/
2005-11-15 Jan Beulich <jbeulich@novell.com> * config/default.exp (link_or_copy): New. Use it for setting up assembler and linker for the compiler to use. ld/testsuite/ 2005-11-15 Jan Beulich <jbeulich@novell.com> * ld-bootstrap/bootstrap.exp: Delete ld-partial.o and ld[123]* after test. * ld-elf/elf.exp: Delete preinit, init, and fini after test. * ld-elf/sec64k.exp: Use macro and repeat in generated source files. Delete object files after test.
Diffstat (limited to 'ld/testsuite')
-rw-r--r--ld/testsuite/ChangeLog8
-rw-r--r--ld/testsuite/ld-bootstrap/bootstrap.exp3
-rw-r--r--ld/testsuite/ld-elf/elf.exp2
-rw-r--r--ld/testsuite/ld-elf/sec64k.exp30
4 files changed, 32 insertions, 11 deletions
diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog
index 0a132c2..fe5329f 100644
--- a/ld/testsuite/ChangeLog
+++ b/ld/testsuite/ChangeLog
@@ -1,3 +1,11 @@
+2005-11-15 Jan Beulich <jbeulich@novell.com>
+
+ * ld-bootstrap/bootstrap.exp: Delete ld-partial.o and ld[123]*
+ after test.
+ * ld-elf/elf.exp: Delete preinit, init, and fini after test.
+ * ld-elf/sec64k.exp: Use macro and repeat in generated source
+ files. Delete object files after test.
+
2005-11-11 Hans-Peter Nilsson <hp@axis.com>
* ld-cris/noov.d: Restrict to cris-*-*elf*.
diff --git a/ld/testsuite/ld-bootstrap/bootstrap.exp b/ld/testsuite/ld-bootstrap/bootstrap.exp
index 6faa6d6..58cb969 100644
--- a/ld/testsuite/ld-bootstrap/bootstrap.exp
+++ b/ld/testsuite/ld-bootstrap/bootstrap.exp
@@ -169,3 +169,6 @@ foreach flags {"" "strip" "--static" "--traditional-format"
fail $testname
}
}
+
+catch "exec rm -f tmpdir/ld-partial.o tmpdir/ld1 tmpdir/ld2 tmpdir/ld3" status
+catch "exec rm -f tmpdir/ld1tail tmpdir/ld2tail tmpdir/ld3tail" status
diff --git a/ld/testsuite/ld-elf/elf.exp b/ld/testsuite/ld-elf/elf.exp
index 5cba743..43c4282 100644
--- a/ld/testsuite/ld-elf/elf.exp
+++ b/ld/testsuite/ld-elf/elf.exp
@@ -45,3 +45,5 @@ set array_tests {
# NetBSD ELF systems do not currently support the .*_array sections.
run_ld_link_exec_tests [list "*-*-netbsdelf*"] $array_tests
+
+catch "exec rm -f tmpdir/preinit tmpdir/init tmpdir/fini" status
diff --git a/ld/testsuite/ld-elf/sec64k.exp b/ld/testsuite/ld-elf/sec64k.exp
index cc15afb..b4a88a0 100644
--- a/ld/testsuite/ld-elf/sec64k.exp
+++ b/ld/testsuite/ld-elf/sec64k.exp
@@ -39,7 +39,6 @@ if { ![runtest_file_p $runtests $test1] \
set sfiles {}
set max_sec 66000
set secs_per_file 1000
-set secn 0
for { set i 0 } { $i < $max_sec / $secs_per_file } { incr i } {
set sfile "$objdir/tmpdir/sec64-$i.s"
lappend sfiles $sfile
@@ -50,7 +49,7 @@ for { set i 0 } { $i < $max_sec / $secs_per_file } { incr i } {
return
}
- if { $secn == 0 } {
+ if { $i == 0 } {
puts $ofd " .global _start"
puts $ofd "_start:"
puts $ofd " .global foo_0"
@@ -59,15 +58,20 @@ for { set i 0 } { $i < $max_sec / $secs_per_file } { incr i } {
# Make sure the used section is not covered by common linker scripts.
# They should get separate section entries even without -r.
- for { set j 0 } { $j < $secs_per_file } { incr j } {
- incr secn
- puts $ofd " .section .foo.$secn,\"ax\""
- puts $ofd " .global foo_$secn"
- puts $ofd "foo_$secn:"
- puts $ofd " .long foo_[expr $secn - 1]"
- puts $ofd "bar_$secn:"
- puts $ofd " .long bar_$secn"
- }
+ puts $ofd " .altmacro"
+ puts $ofd " .macro sec secn, secp"
+ puts $ofd " .section .foo.\\secn,\"ax\""
+ puts $ofd " .global foo_\\secn"
+ puts $ofd "foo_\\secn:"
+ puts $ofd " .long foo_\\secp"
+ puts $ofd "bar_\\secn:"
+ puts $ofd " .long bar_\\secn"
+ puts $ofd " .endm"
+ puts $ofd " secn = [expr $i * $secs_per_file]"
+ puts $ofd " .rept $secs_per_file"
+ puts $ofd " secn = secn + 1"
+ puts $ofd " sec %(secn), %(secn-1)"
+ puts $ofd " .endr"
close $ofd
}
@@ -141,3 +145,7 @@ puts $ofd ".* (\[0-9\] foo_1|66... foo_66000)"
puts $ofd "#pass"
close $ofd
run_dump_test "tmpdir/$test2"
+
+for { set i 1 } { $i < $max_sec / $secs_per_file } { incr i } {
+ catch "exec rm -f tmpdir/dump$i.o" status
+}