Skip to content
Commit 6ee3b244 authored by YunQiang Su's avatar YunQiang Su Committed by Brad Smith
Browse files

Clang/Gnu: Scan GCC with triple without vendor if vendor is unknown

If ScanLibDirForGCCTriple with target triple fails, let's try the triple with
vendor stripped if vendor is unknown.

Debian always uses triples without a vendor section. In general, triples without
a vendor section is the most similar aliases than any other aliases.

To archive this, we add a private member TripleNoVendor to
GCCInstallationDetector.

This modification makes testcases riscv32-toolchain.c and riscv64-toolchain.c
fail. The reason is that they are wrong: --triple riscv64-unknown-elf tries
to use riscv64-unknown-linux-gnu first.

This patch accidentally fixes this problem.

We also drop the path delimiter pattern {{/|\\\\}}, as these 2 tests are
disabled on Windows, and in fact the positions of this pattern are not
correct.

Reviewed by: MaskRay

Differential Revision: https://reviews.llvm.org/D158183
parent c4672454
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment