}
- perror "could not assemble locview-1 test file"
- unresolved "readelf - failed to assemble"
- fail "readelf --debug-dump=loc"
+# locview - Check dumping of location lists with location views.
+if {![binutils_assemble $srcdir/$subdir/locview-1.s tmpdir/locview-1.o]} then {
- perror "could not assemble locview-2 test file"
- unresolved "readelf - failed to assemble"
- fail "readelf --debug-dump=loc"
++ unresolved "readelf --debug-dump=loc locview-1 (failed to assemble)"
+} else {
+
+ if ![is_remote host] {
+ set tempfile tmpdir/locview-1.o
+ } else {
+ set tempfile [remote_download host tmpdir/locview-1.o]
+ }
+
+ readelf_test --debug-dump=loc $tempfile readelf.locview-1 {}
+}
+if {![binutils_assemble $srcdir/$subdir/locview-2.s tmpdir/locview-2.o]} then {
++ unresolved "readelf --debug-dump=loc locview-2 (failed to assemble)"
+} else {
+
+ if ![is_remote host] {
+ set tempfile tmpdir/locview-2.o
+ } else {
+ set tempfile [remote_download host tmpdir/locview-2.o]
+ }
+
+ readelf_test --debug-dump=loc $tempfile readelf.locview-2 {}
+}
+
+
# Check that decompressed dumps work.
if {![binutils_assemble $srcdir/$subdir/z.s tmpdir/z.o]} then {
- perror "could not assemble decompress dump test file"
- unresolved "readelf - failed to assemble"
- fail "readelf -z"
+ unresolved "readelf --decompress --hex-dump .debug_loc z (failed to assemble)"
} else {
if ![is_remote host] {
}
# Assemble the DWARF-5 test file.
if {![binutils_assemble_flags $srcdir/$subdir/dw5.S tmpdir/dw5.o $hpux]} then {
- perror "could not assemble dw5 test file"
- unresolved "readelf - failed to assemble dw5"
- return
- }
-
- # Download it.
- if ![is_remote host] {
- set tempfile tmpdir/dw5.o
+ unresolved "readelf -wiaoRlL dw5 (failed to assemble)"
} else {
- set tempfile [remote_download host tmpdir/dw5.o]
- }
- # First, determine the size, so specific output matchers can be used.
- readelf_find_size $tempfile
+ # Download it.
+ if ![is_remote host] {
+ set tempfile tmpdir/dw5.o
+ } else {
+ set tempfile [remote_download host tmpdir/dw5.o]
+ }
+
+ # First, determine the size, so specific output matchers can be used.
+ readelf_find_size $tempfile
- # Make sure that readelf can decode the contents.
- readelf_test -wiaoRlL $tempfile dw5.W { nds32*-elf }
+ # Make sure that readelf can decode the contents.
- readelf_test -wiaoRlL $tempfile dw5.W {}
++ readelf_test -wiaoRlL $tempfile dw5.W { nds32*-elf }
+ }
}