mold/0003-Skip-tests-that-fail-o...

130 lines
4.3 KiB
Diff

From 7cfbb9c4895e51ab8673b6a3f14c82be49b023c8 Mon Sep 17 00:00:00 2001
Message-Id: <7cfbb9c4895e51ab8673b6a3f14c82be49b023c8.1651339128.git.github@sicherha.de>
From: Christoph Erhardt <github@sicherha.de>
Date: Fri, 29 Apr 2022 21:44:33 +0200
Subject: [PATCH] Skip tests that fail on i686 and armv7l
---
test/elf/exception.sh | 2 ++
test/elf/gdb-index-compress-output.sh | 3 +++
test/elf/gdb-index-dwarf2.sh | 3 +++
test/elf/gdb-index-dwarf3.sh | 3 +++
test/elf/gdb-index-dwarf4.sh | 3 +++
test/elf/gdb-index-dwarf5.sh | 3 +++
test/elf/hello-static.sh | 2 ++
test/elf/ifunc-static.sh | 2 ++
8 files changed, 21 insertions(+)
diff --git a/test/elf/exception.sh b/test/elf/exception.sh
index 5df54b14..a4138103 100755
--- a/test/elf/exception.sh
+++ b/test/elf/exception.sh
@@ -14,6 +14,8 @@ mold="$(pwd)/mold"
t=out/test/elf/$testname
mkdir -p $t
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+
cat <<EOF | $CXX -c -o $t/a.o -xc++ -fPIC -
int main() {
try {
diff --git a/test/elf/gdb-index-compress-output.sh b/test/elf/gdb-index-compress-output.sh
index 05bfabd2..c22792ae 100755
--- a/test/elf/gdb-index-compress-output.sh
+++ b/test/elf/gdb-index-compress-output.sh
@@ -16,6 +16,9 @@ mkdir -p $t
[ $MACHINE = $(uname -m) ] || { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+[ $MACHINE = i686 ] && { echo skipped; exit; }
+
which gdb >& /dev/null || { echo skipped; exit; }
cat <<EOF | $CC -c -o $t/a.o -fPIC -g -ggnu-pubnames -gdwarf-4 -xc - -ffunction-sections
diff --git a/test/elf/gdb-index-dwarf2.sh b/test/elf/gdb-index-dwarf2.sh
index 8e15c8e8..b6e6297e 100755
--- a/test/elf/gdb-index-dwarf2.sh
+++ b/test/elf/gdb-index-dwarf2.sh
@@ -16,6 +16,9 @@ mkdir -p $t
[ $MACHINE = $(uname -m) ] || { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+[ $MACHINE = i686 ] && { echo skipped; exit; }
+
which gdb >& /dev/null || { echo skipped; exit; }
echo 'int main() {}' | $CC -o /dev/null -xc -gdwarf-2 -g - >& /dev/null ||
diff --git a/test/elf/gdb-index-dwarf3.sh b/test/elf/gdb-index-dwarf3.sh
index 727dfcbe..466f9597 100755
--- a/test/elf/gdb-index-dwarf3.sh
+++ b/test/elf/gdb-index-dwarf3.sh
@@ -16,6 +16,9 @@ mkdir -p $t
[ $MACHINE = $(uname -m) ] || { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+[ $MACHINE = i686 ] && { echo skipped; exit; }
+
which gdb >& /dev/null || { echo skipped; exit; }
echo 'int main() {}' | $CC -o /dev/null -xc -gdwarf-3 -g - >& /dev/null ||
diff --git a/test/elf/gdb-index-dwarf4.sh b/test/elf/gdb-index-dwarf4.sh
index 79ae5d1a..5512cd27 100755
--- a/test/elf/gdb-index-dwarf4.sh
+++ b/test/elf/gdb-index-dwarf4.sh
@@ -16,6 +16,9 @@ mkdir -p $t
[ $MACHINE = $(uname -m) ] || { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+[ $MACHINE = i686 ] && { echo skipped; exit; }
+
which gdb >& /dev/null || { echo skipped; exit; }
echo 'int main() {}' | $CC -o /dev/null -xc -gdwarf-4 -g - >& /dev/null ||
diff --git a/test/elf/gdb-index-dwarf5.sh b/test/elf/gdb-index-dwarf5.sh
index 02c0249d..09d20907 100755
--- a/test/elf/gdb-index-dwarf5.sh
+++ b/test/elf/gdb-index-dwarf5.sh
@@ -16,6 +16,9 @@ mkdir -p $t
[ $MACHINE = $(uname -m) ] || { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+[ $MACHINE = i686 ] && { echo skipped; exit; }
+
which gdb >& /dev/null || { echo skipped; exit; }
echo 'int main() {}' | $CC -o /dev/null -xc -gdwarf-5 -g - >& /dev/null ||
diff --git a/test/elf/hello-static.sh b/test/elf/hello-static.sh
index 5780b88b..05c60f91 100755
--- a/test/elf/hello-static.sh
+++ b/test/elf/hello-static.sh
@@ -14,6 +14,8 @@ mold="$(pwd)/mold"
t=out/test/elf/$testname
mkdir -p $t
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+
cat <<EOF | $CC -o $t/a.o -c -xc -
#include <stdio.h>
diff --git a/test/elf/ifunc-static.sh b/test/elf/ifunc-static.sh
index e7b0b8c8..150dc921 100755
--- a/test/elf/ifunc-static.sh
+++ b/test/elf/ifunc-static.sh
@@ -17,6 +17,8 @@ mkdir -p $t
# IFUNC is not supported on RISC-V yet
[ $MACHINE = riscv64 ] && { echo skipped; exit; }
+[ $MACHINE = armv7l ] && { echo skipped; exit; }
+
# Skip if libc is musl because musl does not support GNU FUNC
echo 'int main() {}' | $CC -o $t/exe -xc -
readelf --dynamic $t/exe | grep -q ld-musl && { echo OK; exit; }
--
2.35.1