Skip to content

Commit 0353f6a

Browse files
committed
[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.
1 parent f5bab96 commit 0353f6a

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

bolt/test/AArch64/lit.local.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
if "AArch64" not in config.root.targets:
22
config.unsupported = True
33

4-
flags = "--target=aarch64-pc-linux -nostartfiles -nostdlib -ffreestanding"
4+
flags = "--target=aarch64-unknown-linux-gnu -nostartfiles -nostdlib -ffreestanding"
55

66
config.substitutions.insert(0, ("%cflags", f"%cflags {flags}"))
77
config.substitutions.insert(0, ("%cxxflags", f"%cxxflags {flags}"))

bolt/test/X86/lit.local.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
if not "X86" in config.root.targets:
22
config.unsupported = True
33

4-
flags = "--target=x86_64-pc-linux -nostdlib"
4+
flags = "--target=x86_64-unknown-linux-gnu -nostdlib"
55

66
config.substitutions.insert(0, ("%cflags", f"%cflags {flags}"))
77
config.substitutions.insert(0, ("%cxxflags", f"%cxxflags {flags}"))

bolt/test/lit.local.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
host_linux_triple = config.target_triple.split("-")[0] + "-linux"
1+
host_linux_triple = config.target_triple.split("-")[0] + "-unknown-linux-gnu"
22
common_linker_flags = "-fuse-ld=lld -Wl,--unresolved-symbols=ignore-all"
33
flags = f"--target={host_linux_triple} {common_linker_flags}"
44

0 commit comments

Comments
 (0)