Porting tests
This commit is contained in:
parent
4a097b63ca
commit
1b8490d8fa
51 changed files with 968 additions and 0 deletions
Binary file not shown.
Binary file not shown.
|
|
@ -0,0 +1,20 @@
|
|||
summary: Test for BZ#1785294 (binutils support secondary relocation sections)
|
||||
description: |
|
||||
Bug summary: binutils: support secondary relocation sections [rhel 7.9]
|
||||
Bugzilla link: https://bugzilla.redhat.com/show_bug.cgi?id=1785294
|
||||
contact:
|
||||
- Milos Prchlik <mprchlik@redhat.com>
|
||||
- Edjunior Machado <emachado@redhat.com>
|
||||
duration: 10m
|
||||
|
||||
# Configurable fields
|
||||
require+:
|
||||
- grep
|
||||
- gawk
|
||||
|
||||
link+:
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1785294
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1804151
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1804149
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1804148
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1801879
|
||||
85
tests/bugs/binutils-support-secondary-relocation-sections/test.sh
Executable file
85
tests/bugs/binutils-support-secondary-relocation-sections/test.sh
Executable file
|
|
@ -0,0 +1,85 @@
|
|||
#!/bin/bash
|
||||
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /tools/binutils/Regression/bz1785294-binutils-support-secondary-relocation-sections
|
||||
# Description: Test for BZ#1785294 (binutils support secondary relocation sections)
|
||||
# Author: Edjunior Machado <emachado@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2020 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation, either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
# Include Beaker environment
|
||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||
|
||||
. "$TMT_TREE/tests/lib.sh" || exit 1
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
buTestHeader
|
||||
|
||||
rlRun "SOURCE_DIR=$(pwd)"
|
||||
|
||||
buEnterTmpDir
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStart FAIL "Check support"
|
||||
rlRun "ARCH=$(arch)"
|
||||
case "$ARCH" in
|
||||
x86_64 | ppc64le)
|
||||
KO_FILE="${SOURCE_DIR}/kpatch-3_10_0-1062-1-15.${ARCH}.ko"
|
||||
rlLogInfo "KO_FILE=$KO_FILE"
|
||||
HAS_SUPPORT=1
|
||||
;;
|
||||
*)
|
||||
rlLogWarning "Feature not supported on $ARCH"
|
||||
HAS_SUPPORT=0
|
||||
;;
|
||||
esac
|
||||
rlPhaseEnd
|
||||
|
||||
if [ $HAS_SUPPORT = 1 ]; then
|
||||
rlPhaseStartTest
|
||||
rlAssertExists $KO_FILE
|
||||
rlRun "set -o pipefail" 0 "Conserve the non-zero return value through the pipe"
|
||||
|
||||
# As suggested by nickc@redhat.com:
|
||||
rlRun "objcopy $KO_FILE copy.ko"
|
||||
rlRun "readelf --wide --section-headers copy.ko |& tee readelf_headers.out"
|
||||
rlRun -l "grep \".klp.rela.vmlinux.*\ RELA\ \" readelf_headers.out"
|
||||
|
||||
# And as suggested by joe.lawrence@redhat.com:
|
||||
rlRun "readelf --wide --relocs $KO_FILE |& tee readelf_relocs.out"
|
||||
rlRun -l "awk \"/^Relocation section '.klp/\" RS='\n\n' ORS='\n\n' readelf_relocs.out"
|
||||
rlRun -l "grep \"^Relocation section '.klp\" readelf_relocs.out"
|
||||
|
||||
rlRun "readelf --wide --symbols $KO_FILE |& tee readelf_symbols.out"
|
||||
# Section index for these symbols must be SHN_LIVEPATCH (0xff20)
|
||||
rlRun -l "grep '\[0xff20\]\ \.klp\.sym' readelf_symbols.out"
|
||||
|
||||
rlRun "tar czvf readelf_outputs.tar.gz readelf_headers.out readelf_relocs.out readelf_symbols.out"
|
||||
rlFileSubmit readelf_outputs.tar.gz "${PACKAGES}-readelf_outputs.tar.gz"
|
||||
rlPhaseEnd
|
||||
fi
|
||||
|
||||
rlPhaseStartCleanup
|
||||
buExitTmpDir
|
||||
rlPhaseEnd
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
summary: Tests -pie + -fpie with __thread
|
||||
contact:
|
||||
- Milos Prchlik <mprchlik@redhat.com>
|
||||
- Michal Nowak <mnowak@redhat.com>
|
||||
duration: 5m
|
||||
|
||||
# Configurable fields
|
||||
link+:
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=755872
|
||||
53
tests/bugs/fpie-pie-does-not-appear-to-work-with-__thread-variables/test.sh
Executable file
53
tests/bugs/fpie-pie-does-not-appear-to-work-with-__thread-variables/test.sh
Executable file
|
|
@ -0,0 +1,53 @@
|
|||
#!/bin/bash
|
||||
# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /tools/binutils/Regression/bz755872-fpie-pie-does-not-appear-to-work-with-__thread-variables
|
||||
# Description: Tests -pie + -fpie with __thread
|
||||
# Author: Michal Nowak <mnowak@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2011 Red Hat, Inc. All rights reserved.
|
||||
#
|
||||
# This copyrighted material is made available to anyone wishing
|
||||
# to use, modify, copy, or redistribute it subject to the terms
|
||||
# and conditions of the GNU General Public License version 2.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public
|
||||
# License along with this program; if not, write to the Free
|
||||
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||
# Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
# Include Beaker environment
|
||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||
|
||||
. "$TMT_TREE/tests/lib.sh" || exit 1
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
buTestHeader
|
||||
|
||||
testdir="$(pwd)"
|
||||
buEnterTmpDir
|
||||
|
||||
rlRun "cp -v $testdir/w.c $TmpDir"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
rlRun "gcc -o w -g -O2 -pie -fpie w.c" 0 "Compile __thread with -fpie -pie"
|
||||
rlAssertExists "w"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
buExitTmpDir
|
||||
rlPhaseEnd
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
__thread int a;
|
||||
|
||||
int
|
||||
main(void)
|
||||
{
|
||||
return a;
|
||||
}
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
int __attribute__ ((noinline)) foo(int x, int y)
|
||||
{
|
||||
return x & y;
|
||||
}
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
#include <stdio.h>
|
||||
extern int foo(int, int);
|
||||
|
||||
int main()
|
||||
{
|
||||
printf("%d\n", foo(1, 3));
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
summary: RHEL8 gold does not resolve the address of main()
|
||||
description: |
|
||||
rhel8 gold does not resolve the address of main() when it is in a shared library in aarch64
|
||||
contact:
|
||||
- Milos Prchlik <mprchlik@redhat.com>
|
||||
- Edjunior Machado <emachado@redhat.com>
|
||||
duration: 5m
|
||||
|
||||
# Configurable fields
|
||||
link+:
|
||||
- verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1693661
|
||||
63
tests/bugs/rhel8-gold-does-not-resolve-the-address-of-main/test.sh
Executable file
63
tests/bugs/rhel8-gold-does-not-resolve-the-address-of-main/test.sh
Executable file
|
|
@ -0,0 +1,63 @@
|
|||
#!/bin/bash
|
||||
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /tools/binutils/Regression/bz1693661-rhel8-gold-does-not-resolve-the-address-of-main
|
||||
# Description: Test for BZ#1693661 (rhel8 gold does not resolve the address of main())
|
||||
# Author: Edjunior Machado <emachado@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2019 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public License as
|
||||
# published by the Free Software Foundation, either version 2 of
|
||||
# the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
# Include Beaker environment
|
||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||
|
||||
. "$TMT_TREE/tests/lib.sh" || exit 1
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
buTestHeader
|
||||
|
||||
testdir="$(pwd)"
|
||||
buEnterTmpDir
|
||||
|
||||
rlRun "cp -v $testdir/main.c $testdir/foo.c $TmpDir"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
rlRun "gcc -o main.o -fPIC -c main.c"
|
||||
rlRun "gcc -shared -o libmain.so main.o"
|
||||
rlRun "gcc -o foo.o -c foo.c"
|
||||
|
||||
rlLogInfo "Linking with gold..."
|
||||
rlRun "gcc -fuse-ld=gold -o gold.out -lmain -L$PWD -Wl,-v,-rpath=$PWD foo.o"
|
||||
rlAssertExists "gold.out"
|
||||
rlRun "./gold.out" # On bz#1693661, it segfaults
|
||||
|
||||
rlLogInfo "Linking with bfd..."
|
||||
rlRun "gcc -fuse-ld=bfd -o bfd.out -lmain -L$PWD -Wl,-v,-rpath=$PWD foo.o"
|
||||
rlAssertExists "bfd.out"
|
||||
rlRun "./bfd.out"
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
buExitTmpDir
|
||||
rlPhaseEnd
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
7
tests/supported-targets/6_i686_arch
Normal file
7
tests/supported-targets/6_i686_arch
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
i386
|
||||
i386:x86-64
|
||||
i8086
|
||||
i386:intel
|
||||
i386:x86-64:intel
|
||||
l1om
|
||||
l1om:intel
|
||||
16
tests/supported-targets/6_i686_tgt
Normal file
16
tests/supported-targets/6_i686_tgt
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
elf32-i386
|
||||
a.out-i386-linux
|
||||
pei-i386
|
||||
elf64-x86-64
|
||||
elf64-l1om
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
trad-core
|
||||
22
tests/supported-targets/6_ppc64_arch
Normal file
22
tests/supported-targets/6_ppc64_arch
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
spu:256K
|
||||
17
tests/supported-targets/6_ppc64_tgt
Normal file
17
tests/supported-targets/6_ppc64_tgt
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
elf64-powerpc
|
||||
elf64-powerpcle
|
||||
elf32-powerpc
|
||||
elf32-powerpcle
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
elf32-spu
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
2
tests/supported-targets/6_s390x_arch
Normal file
2
tests/supported-targets/6_s390x_arch
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
s390:31-bit
|
||||
s390:64-bit
|
||||
13
tests/supported-targets/6_s390x_tgt
Normal file
13
tests/supported-targets/6_s390x_tgt
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
elf64-s390
|
||||
elf32-s390
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
trad-core
|
||||
6
tests/supported-targets/6_x86_64_arch
Normal file
6
tests/supported-targets/6_x86_64_arch
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
i386:x86-64
|
||||
i8086
|
||||
i386:intel
|
||||
i386:x86-64:intel
|
||||
l1om
|
||||
l1om:intel
|
||||
16
tests/supported-targets/6_x86_64_tgt
Normal file
16
tests/supported-targets/6_x86_64_tgt
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
elf64-x86-64
|
||||
elf32-i386
|
||||
a.out-i386-linux
|
||||
pei-i386
|
||||
pei-x86-64
|
||||
elf64-l1om
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
16
tests/supported-targets/7_aarch64_arch
Normal file
16
tests/supported-targets/7_aarch64_arch
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
aarch64
|
||||
arm
|
||||
armv2
|
||||
armv2a
|
||||
armv3
|
||||
armv3m
|
||||
armv4
|
||||
armv4t
|
||||
armv5
|
||||
armv5t
|
||||
armv5te
|
||||
xscale
|
||||
ep9312
|
||||
iwmmxt
|
||||
iwmmxt2
|
||||
plugin
|
||||
15
tests/supported-targets/7_aarch64_tgt
Normal file
15
tests/supported-targets/7_aarch64_tgt
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
elf64-littleaarch64
|
||||
elf64-bigaarch64
|
||||
elf32-littlearm
|
||||
elf32-bigarm
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/7_ppc64_arch
Normal file
27
tests/supported-targets/7_ppc64_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
18
tests/supported-targets/7_ppc64_tgt
Normal file
18
tests/supported-targets/7_ppc64_tgt
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
elf64-powerpc
|
||||
elf64-powerpcle
|
||||
elf32-powerpc
|
||||
elf32-powerpcle
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/7_ppc64le_arch
Normal file
27
tests/supported-targets/7_ppc64le_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
19
tests/supported-targets/7_ppc64le_tgt
Normal file
19
tests/supported-targets/7_ppc64le_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-powerpcle
|
||||
elf64-powerpc
|
||||
elf32-powerpcle
|
||||
elf32-powerpc
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
ppcboot
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
3
tests/supported-targets/7_s390x_arch
Normal file
3
tests/supported-targets/7_s390x_arch
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
s390:31-bit
|
||||
s390:64-bit
|
||||
plugin
|
||||
14
tests/supported-targets/7_s390x_tgt
Normal file
14
tests/supported-targets/7_s390x_tgt
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
elf64-s390
|
||||
elf32-s390
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
trad-core
|
||||
12
tests/supported-targets/7_x86_64_arch
Normal file
12
tests/supported-targets/7_x86_64_arch
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
i386
|
||||
i386:x86-64
|
||||
i386:x64-32
|
||||
i8086
|
||||
i386:intel
|
||||
i386:x86-64:intel
|
||||
i386:x64-32:intel
|
||||
l1om
|
||||
l1om:intel
|
||||
k1om
|
||||
k1om:intel
|
||||
plugin
|
||||
19
tests/supported-targets/7_x86_64_tgt
Normal file
19
tests/supported-targets/7_x86_64_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-x86-64
|
||||
elf32-i386
|
||||
elf32-x86-64
|
||||
a.out-i386-linux
|
||||
pei-i386
|
||||
pei-x86-64
|
||||
elf64-l1om
|
||||
elf64-k1om
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
16
tests/supported-targets/8_aarch64_arch
Normal file
16
tests/supported-targets/8_aarch64_arch
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
aarch64
|
||||
arm
|
||||
armv2
|
||||
armv2a
|
||||
armv3
|
||||
armv3m
|
||||
armv4
|
||||
armv4t
|
||||
armv5
|
||||
armv5t
|
||||
armv5te
|
||||
xscale
|
||||
ep9312
|
||||
iwmmxt
|
||||
iwmmxt2
|
||||
plugin
|
||||
15
tests/supported-targets/8_aarch64_tgt
Normal file
15
tests/supported-targets/8_aarch64_tgt
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
elf64-littleaarch64
|
||||
elf64-bigaarch64
|
||||
elf32-littlearm
|
||||
elf32-bigarm
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/8_ppc64_arch
Normal file
27
tests/supported-targets/8_ppc64_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
18
tests/supported-targets/8_ppc64_tgt
Normal file
18
tests/supported-targets/8_ppc64_tgt
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
elf64-powerpc
|
||||
elf64-powerpcle
|
||||
elf32-powerpc
|
||||
elf32-powerpcle
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/8_ppc64le_arch
Normal file
27
tests/supported-targets/8_ppc64le_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
19
tests/supported-targets/8_ppc64le_tgt
Normal file
19
tests/supported-targets/8_ppc64le_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-powerpcle
|
||||
elf64-powerpc
|
||||
elf32-powerpcle
|
||||
elf32-powerpc
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
ppcboot
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
3
tests/supported-targets/8_s390x_arch
Normal file
3
tests/supported-targets/8_s390x_arch
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
s390:31-bit
|
||||
s390:64-bit
|
||||
plugin
|
||||
14
tests/supported-targets/8_s390x_tgt
Normal file
14
tests/supported-targets/8_s390x_tgt
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
elf64-s390
|
||||
elf32-s390
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
trad-core
|
||||
12
tests/supported-targets/8_x86_64_arch
Normal file
12
tests/supported-targets/8_x86_64_arch
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
i386
|
||||
i386:x86-64
|
||||
i386:x64-32
|
||||
i8086
|
||||
i386:intel
|
||||
i386:x86-64:intel
|
||||
i386:x64-32:intel
|
||||
l1om
|
||||
l1om:intel
|
||||
k1om
|
||||
k1om:intel
|
||||
plugin
|
||||
19
tests/supported-targets/8_x86_64_tgt
Normal file
19
tests/supported-targets/8_x86_64_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-x86-64
|
||||
elf32-i386
|
||||
elf32-x86-64
|
||||
a.out-i386-linux
|
||||
pei-i386
|
||||
pei-x86-64
|
||||
elf64-l1om
|
||||
elf64-k1om
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
16
tests/supported-targets/9_aarch64_arch
Normal file
16
tests/supported-targets/9_aarch64_arch
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
aarch64
|
||||
arm
|
||||
armv2
|
||||
armv2a
|
||||
armv3
|
||||
armv3m
|
||||
armv4
|
||||
armv4t
|
||||
armv5
|
||||
armv5t
|
||||
armv5te
|
||||
xscale
|
||||
ep9312
|
||||
iwmmxt
|
||||
iwmmxt2
|
||||
plugin
|
||||
15
tests/supported-targets/9_aarch64_tgt
Normal file
15
tests/supported-targets/9_aarch64_tgt
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
elf64-littleaarch64
|
||||
elf64-bigaarch64
|
||||
elf32-littlearm
|
||||
elf32-bigarm
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/9_ppc64_arch
Normal file
27
tests/supported-targets/9_ppc64_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
18
tests/supported-targets/9_ppc64_tgt
Normal file
18
tests/supported-targets/9_ppc64_tgt
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
elf64-powerpc
|
||||
elf64-powerpcle
|
||||
elf32-powerpc
|
||||
elf32-powerpcle
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
27
tests/supported-targets/9_ppc64le_arch
Normal file
27
tests/supported-targets/9_ppc64le_arch
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
rs6000:6000
|
||||
rs6000:rs1
|
||||
rs6000:rsc
|
||||
rs6000:rs2
|
||||
powerpc:common64
|
||||
powerpc:common
|
||||
powerpc:603
|
||||
powerpc:EC603e
|
||||
powerpc:604
|
||||
powerpc:403
|
||||
powerpc:601
|
||||
powerpc:620
|
||||
powerpc:630
|
||||
powerpc:a35
|
||||
powerpc:rs64ii
|
||||
powerpc:rs64iii
|
||||
powerpc:7400
|
||||
powerpc:e500
|
||||
powerpc:e500mc
|
||||
powerpc:e500mc64
|
||||
powerpc:MPC8XX
|
||||
powerpc:750
|
||||
powerpc:titan
|
||||
powerpc:vle
|
||||
powerpc:e5500
|
||||
powerpc:e6500
|
||||
plugin
|
||||
19
tests/supported-targets/9_ppc64le_tgt
Normal file
19
tests/supported-targets/9_ppc64le_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-powerpcle
|
||||
elf64-powerpc
|
||||
elf32-powerpcle
|
||||
elf32-powerpc
|
||||
aixcoff-rs6000
|
||||
aixcoff64-rs6000
|
||||
aix5coff64-rs6000
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
ppcboot
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
3
tests/supported-targets/9_s390x_arch
Normal file
3
tests/supported-targets/9_s390x_arch
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
s390:31-bit
|
||||
s390:64-bit
|
||||
plugin
|
||||
14
tests/supported-targets/9_s390x_tgt
Normal file
14
tests/supported-targets/9_s390x_tgt
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
elf64-s390
|
||||
elf32-s390
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
trad-core
|
||||
12
tests/supported-targets/9_x86_64_arch
Normal file
12
tests/supported-targets/9_x86_64_arch
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
i386
|
||||
i386:x86-64
|
||||
i386:x64-32
|
||||
i8086
|
||||
i386:intel
|
||||
i386:x86-64:intel
|
||||
i386:x64-32:intel
|
||||
l1om
|
||||
l1om:intel
|
||||
k1om
|
||||
k1om:intel
|
||||
plugin
|
||||
19
tests/supported-targets/9_x86_64_tgt
Normal file
19
tests/supported-targets/9_x86_64_tgt
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
elf64-x86-64
|
||||
elf32-i386
|
||||
elf32-x86-64
|
||||
a.out-i386-linux
|
||||
pei-i386
|
||||
pei-x86-64
|
||||
elf64-l1om
|
||||
elf64-k1om
|
||||
elf64-little
|
||||
elf64-big
|
||||
elf32-little
|
||||
elf32-big
|
||||
plugin
|
||||
srec
|
||||
symbolsrec
|
||||
verilog
|
||||
tekhex
|
||||
binary
|
||||
ihex
|
||||
6
tests/supported-targets/main.fmf
Normal file
6
tests/supported-targets/main.fmf
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
summary: Tests that binutils target support matrix does not regress.
|
||||
|
||||
contact:
|
||||
- Milos Prchlik <mprchlik@redhat.com>
|
||||
- Arjun Shankar <ashankar@redhat.com>
|
||||
duration: 10m
|
||||
93
tests/supported-targets/test.sh
Executable file
93
tests/supported-targets/test.sh
Executable file
|
|
@ -0,0 +1,93 @@
|
|||
#!/bin/bash
|
||||
# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# runtest.sh of /tools/binutils/Regression/supported-targets
|
||||
# Description: Tests that binutils target support matrix does not regress.
|
||||
# Author: Arjun Shankar <ashankar@redhat.com>
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
#
|
||||
# Copyright (c) 2015 Red Hat, Inc.
|
||||
#
|
||||
# This copyrighted material is made available to anyone wishing
|
||||
# to use, modify, copy, or redistribute it subject to the terms
|
||||
# and conditions of the GNU General Public License version 2.
|
||||
#
|
||||
# This program is distributed in the hope that it will be
|
||||
# useful, but WITHOUT ANY WARRANTY; without even the implied
|
||||
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
# PURPOSE. See the GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public
|
||||
# License along with this program; if not, write to the Free
|
||||
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
|
||||
# Boston, MA 02110-1301, USA.
|
||||
#
|
||||
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
# Include Beaker environment
|
||||
. /usr/bin/rhts-environment.sh || exit 1
|
||||
. /usr/share/beakerlib/beakerlib.sh || exit 1
|
||||
|
||||
. "$TMT_TREE/tests/lib.sh" || exit 1
|
||||
|
||||
rlJournalStart
|
||||
rlPhaseStartSetup
|
||||
buTestHeader
|
||||
|
||||
if rlIsRHEL "=6"; then
|
||||
release=6
|
||||
elif rlIsRHEL "=7"; then
|
||||
release=7
|
||||
elif rlIsRHEL "=8"; then
|
||||
release=8
|
||||
elif rlIsRHEL "=9"; then
|
||||
release=9
|
||||
else
|
||||
rlLog "$(cat /etc/redhat-release)"
|
||||
rlFail "No Baseline available for this major release; using RHEL-7 as baseline"
|
||||
release=7
|
||||
fi
|
||||
|
||||
rlLogInfo "Selected release: ${release}"
|
||||
|
||||
arch=$(uname -m)
|
||||
|
||||
expected_tgt_file="$(pwd)/${release}_${arch}_tgt"
|
||||
expected_arch_file="$(pwd)/${release}_${arch}_arch"
|
||||
|
||||
baseline_tgt=($(cat "${release}_${arch}_tgt"))
|
||||
baseline_arch=($(cat "${release}_${arch}_arch"))
|
||||
|
||||
buEnterTmpDir
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
rlRun "objdump --help | grep 'supported targets' | sed 's/objdump: supported targets: //' | tr ' ' '\n' > actual_tgt"
|
||||
rlRun "objdump --help | grep 'supported architectures' | sed 's/objdump: supported architectures: //' | tr ' ' '\n' > actual_arch"
|
||||
|
||||
rlLog "expected targets:"
|
||||
rlLog "$(cat $expected_tgt_file)"
|
||||
rlLog "expected architectures:"
|
||||
rlLog "$(cat $expected_arch_file)"
|
||||
rlLog "actual targets:"
|
||||
rlLog "$(cat actual_tgt)"
|
||||
rlLog "actual architectures:"
|
||||
rlLog "$(cat actual_arch)"
|
||||
|
||||
for bt in ${baseline_tgt[@]}; do
|
||||
rlAssertGrep "^$bt$" actual_tgt
|
||||
done
|
||||
|
||||
for ba in ${baseline_arch[@]}; do
|
||||
rlAssertGrep "^$ba$" actual_arch
|
||||
done
|
||||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartCleanup
|
||||
buExitTmpDir
|
||||
rlPhaseEnd
|
||||
|
||||
rlJournalPrintText
|
||||
rlJournalEnd
|
||||
Loading…
Add table
Add a link
Reference in a new issue