mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-26 13:56:22 +08:00
Use is_xcoff_format in binutils testsuite
and restrict some other tests using is_*_format. * testsuite/binutils-all/ar.exp: Use is_xcoff_format. * testsuite/binutils-all/nm.exp: Likewise. * testsuite/binutils-all/copy-2.d: Run only for elf and pe targets. * testsuite/binutils-all/copy-3.d: Run only for elf targets. * testsuite/binutils-all/set-section-alignment.d: Likewise. * testsuite/binutils-all/copy-4.d: Don't run for xcoff.
This commit is contained in:
@ -1,3 +1,12 @@
|
|||||||
|
2020-07-07 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
|
* testsuite/binutils-all/ar.exp: Use is_xcoff_format.
|
||||||
|
* testsuite/binutils-all/nm.exp: Likewise.
|
||||||
|
* testsuite/binutils-all/copy-2.d: Run only for elf and pe targets.
|
||||||
|
* testsuite/binutils-all/copy-3.d: Run only for elf targets.
|
||||||
|
* testsuite/binutils-all/set-section-alignment.d: Likewise.
|
||||||
|
* testsuite/binutils-all/copy-4.d: Don't run for xcoff.
|
||||||
|
|
||||||
2020-07-07 Alan Modra <amodra@gmail.com>
|
2020-07-07 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
* testsuite/lib/binutils-common.exp (is_xcoff_format): New.
|
* testsuite/lib/binutils-common.exp (is_xcoff_format): New.
|
||||||
|
@ -727,7 +727,7 @@ if { [file exists $base_dir/bfdtest1] && [file exists $base_dir/bfdtest2] } {
|
|||||||
|
|
||||||
long_filenames $bfdtests
|
long_filenames $bfdtests
|
||||||
|
|
||||||
# xcoff, ecoff, and vms archive support doesn't handle thin archives
|
# xcoff, ecoff, and vms archive support doesn't handle thin archives
|
||||||
if { ![is_xcoff_format]
|
if { ![is_xcoff_format]
|
||||||
&& ![istarget "*-*-*ecoff"]
|
&& ![istarget "*-*-*ecoff"]
|
||||||
&& ![istarget "*-*-vms"] } {
|
&& ![istarget "*-*-vms"] } {
|
||||||
|
@ -3,10 +3,9 @@
|
|||||||
#objcopy: --set-section-flags foo=contents,alloc,load,code
|
#objcopy: --set-section-flags foo=contents,alloc,load,code
|
||||||
#name: copy with setting section flags 2
|
#name: copy with setting section flags 2
|
||||||
#source: copytest.s
|
#source: copytest.s
|
||||||
#notarget: *-*-*aout *-*-aix* h8300-*-* hppa*-*-hpux* mips-*-ultrix* mips-*-osf* mips-*-ecoff* mips-*-irix mips-*-irix[2-4] mips-*-riscos* ns32k-*-*
|
# Many formats do not allow arbitrary section flags, just run for ELF and PE.
|
||||||
# Note - we use copytest.s and a section named "foo" rather
|
#target: [is_elf_format] [is_pecoff_format]
|
||||||
# than .text because for some file formats (eg PE) the .text
|
#xfail: h8300-*-*
|
||||||
# section has a fixed set of flags and these cannot be changed.
|
|
||||||
|
|
||||||
.*: +file format .*
|
.*: +file format .*
|
||||||
|
|
||||||
|
@ -3,9 +3,10 @@
|
|||||||
#objcopy: --set-section-flags .text=alloc,data
|
#objcopy: --set-section-flags .text=alloc,data
|
||||||
#name: copy with setting section flags 3
|
#name: copy with setting section flags 3
|
||||||
#source: bintest.s
|
#source: bintest.s
|
||||||
#notarget: *-*-*aout *-*-*coff *-*-cygwin* *-*-darwin *-*-mingw* *-*-go32 *-*-*pe hppa*-*-hpux* ns32k-*-* powerpc-*-aix* rs6000-*-* rx-*-*
|
# The .text section in most formats has a fixed set of flags which
|
||||||
# The .text # section in PE/COFF has a fixed set of flags and these
|
# cannot be changed, just run for ELF.
|
||||||
# cannot be changed. We skip it for them.
|
#target: [is_elf_format]
|
||||||
|
#xfail: rx-*-*
|
||||||
|
|
||||||
.*: +file format .*
|
.*: +file format .*
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
#source: bintest.s
|
#source: bintest.s
|
||||||
#strip: --strip-unneeded
|
#strip: --strip-unneeded
|
||||||
#nm: -n
|
#nm: -n
|
||||||
#notarget: *-*-aix* *-*-linuxecoff
|
#notarget: [is_xcoff_format] *-*-linuxecoff
|
||||||
#name: strip --strip-unneeded on common symbol
|
#name: strip --strip-unneeded on common symbol
|
||||||
|
|
||||||
#...
|
#...
|
||||||
|
@ -50,7 +50,9 @@ if {![binutils_assemble $srcdir/$subdir/bintest.s tmpdir/bintest.o]} then {
|
|||||||
|
|
||||||
# This test does not work correctly on XCOFF targets, because XCOFF
|
# This test does not work correctly on XCOFF targets, because XCOFF
|
||||||
# does not enter static symbols in the symbol table.
|
# does not enter static symbols in the symbol table.
|
||||||
setup_xfail "*-*-aix*"
|
if [is_xcoff_format] {
|
||||||
|
setup_xfail *-*-*
|
||||||
|
}
|
||||||
|
|
||||||
set got [binutils_run $NM "$NMFLAGS $tempfile"]
|
set got [binutils_run $NM "$NMFLAGS $tempfile"]
|
||||||
|
|
||||||
@ -108,7 +110,9 @@ if {![binutils_assemble $srcdir/$subdir/bintest.s tmpdir/bintest.o]} then {
|
|||||||
|
|
||||||
# This test does not work correctly on XCOFF targets, because XCOFF
|
# This test does not work correctly on XCOFF targets, because XCOFF
|
||||||
# does not enter static symbols in the symbol table.
|
# does not enter static symbols in the symbol table.
|
||||||
setup_xfail "*-*-aix*"
|
if [is_xcoff_format] {
|
||||||
|
setup_xfail *-*-*
|
||||||
|
}
|
||||||
|
|
||||||
set got [binutils_run $NM "$NMFLAGS -P $tempfile"]
|
set got [binutils_run $NM "$NMFLAGS -P $tempfile"]
|
||||||
|
|
||||||
|
@ -2,7 +2,8 @@
|
|||||||
#PROG: objcopy
|
#PROG: objcopy
|
||||||
#objcopy: --set-section-alignment .text=16
|
#objcopy: --set-section-alignment .text=16
|
||||||
#objdump: --section-headers
|
#objdump: --section-headers
|
||||||
#notarget: *-*-*aout *-*-*coff *-*-cygwin* *-*-darwin *-*-mingw* *-*-go32 *-*-*pe hppa*-*-hpux* ns32k-*-* powerpc-*-aix* rs6000-*-* rx-*-* *-*-vms
|
#target: [is_elf_format]
|
||||||
|
#xfail: rx-*-*
|
||||||
|
|
||||||
#...
|
#...
|
||||||
.*\.text.*2\*\*4
|
.*\.text.*2\*\*4
|
||||||
|
Reference in New Issue
Block a user