aboutsummaryrefslogtreecommitdiff
path: root/bolt/test
diff options
context:
space:
mode:
authorFangrui Song <i@maskray.me>2024-05-31 17:50:58 -0700
committerFangrui Song <i@maskray.me>2024-05-31 17:50:58 -0700
commit0353f6abdd30c778778604c75e33cbe841a61199 (patch)
tree7c0f87f516718f941bb71b8b90b2babfaddfec4f /bolt/test
parentf5bab9678e8c6b2a58abc7867a4a64408247cf13 (diff)
downloadllvm-0353f6abdd30c778778604c75e33cbe841a61199.zip
llvm-0353f6abdd30c778778604c75e33cbe841a61199.tar.gz
llvm-0353f6abdd30c778778604c75e33cbe841a61199.tar.bz2
[BOLT][test] Use correct normalized triple
bolt/test/lit.local.cfg wants to use the system GCC installation but it specifies a wrong triple ("linux" instead of "linux-gnu") and relies on clangDriver's loose GCC installation detection to pick up "*-linux-gnu". This loose behavior may not work. Use "linux-gnu" instead. Note: neither "linux" nor "linux-gnu" detects "linux-musl" triples, so these tests currently fail on musl based systems. Other files changes are cosmetic.
Diffstat (limited to 'bolt/test')
-rw-r--r--bolt/test/AArch64/lit.local.cfg2
-rw-r--r--bolt/test/X86/lit.local.cfg2
-rw-r--r--bolt/test/lit.local.cfg2
3 files changed, 3 insertions, 3 deletions
diff --git a/bolt/test/AArch64/lit.local.cfg b/bolt/test/AArch64/lit.local.cfg
index 59fa15a..9432240 100644
--- a/bolt/test/AArch64/lit.local.cfg
+++ b/bolt/test/AArch64/lit.local.cfg
@@ -1,7 +1,7 @@
if "AArch64" not in config.root.targets:
config.unsupported = True
-flags = "--target=aarch64-pc-linux -nostartfiles -nostdlib -ffreestanding"
+flags = "--target=aarch64-unknown-linux-gnu -nostartfiles -nostdlib -ffreestanding"
config.substitutions.insert(0, ("%cflags", f"%cflags {flags}"))
config.substitutions.insert(0, ("%cxxflags", f"%cxxflags {flags}"))
diff --git a/bolt/test/X86/lit.local.cfg b/bolt/test/X86/lit.local.cfg
index 947d25c..ea9928d 100644
--- a/bolt/test/X86/lit.local.cfg
+++ b/bolt/test/X86/lit.local.cfg
@@ -1,7 +1,7 @@
if not "X86" in config.root.targets:
config.unsupported = True
-flags = "--target=x86_64-pc-linux -nostdlib"
+flags = "--target=x86_64-unknown-linux-gnu -nostdlib"
config.substitutions.insert(0, ("%cflags", f"%cflags {flags}"))
config.substitutions.insert(0, ("%cxxflags", f"%cxxflags {flags}"))
diff --git a/bolt/test/lit.local.cfg b/bolt/test/lit.local.cfg
index 4f4d84e..8aa5f15 100644
--- a/bolt/test/lit.local.cfg
+++ b/bolt/test/lit.local.cfg
@@ -1,4 +1,4 @@
-host_linux_triple = config.target_triple.split("-")[0] + "-linux"
+host_linux_triple = config.target_triple.split("-")[0] + "-unknown-linux-gnu"
common_linker_flags = "-fuse-ld=lld -Wl,--unresolved-symbols=ignore-all"
flags = f"--target={host_linux_triple} {common_linker_flags}"