This is an archive of the discontinued LLVM Phabricator instance.

[clang] Enable GNU Toolchain to find musl GCC installations
Needs ReviewPublic

Authored by staticfloat on Sep 12 2019, 1:24 PM.

Details

Summary

The GNU Toolchain GCCDetector misses GCC installations with the triplet x86_64-linux-musl, looking only instead for x86_64-unknown-linux-musl because it does not have the built-in shortcut that it does for glibc-based systems. This patch, taken from the void-linux patch set at https://github.com/void-linux/void-packages/blob/ced162673bf1e824529eb04d8c33a4e30dcfb68e/srcpkgs/llvm8/files/patches/cfe/cfe-004-add-musl-triples.patch improves clang's ability to find these shorter triplets on musl. This is necessary also for environments such as the Julia project's BinaryBuilder, which comprises a large collection of cross-compilers, each installed within a specific multiarch triplet.

Diff Detail

Repository
rC Clang

Event Timeline

staticfloat created this revision.Sep 12 2019, 1:24 PM
mcf added a subscriber: mcf.Jan 12 2020, 3:08 PM