
When --gcc-triple is used, the driver will search for the 'best' gcc installation that has the given triple. This is useful for distributions that want clang to use a specific gcc triple, but do not want to pin to a specific version as would be required by using --gcc-install-dir. Having clang linked to a specific gcc version can cause clang to stop working when the version of gcc installed on the system gets updated.
15 lines
596 B
C++
15 lines
596 B
C++
// UNSUPPORTED: system-windows
|
|
|
|
// RUN: %clang --target=x86_64-redhat-linux-gnu \
|
|
// RUN: --sysroot=%S/Inputs/fedora_39_tree --gcc-triple=x86_64-redhat-linux -v 2>&1 | \
|
|
// RUN: FileCheck %s --check-prefix=TRIPLE_EXISTS
|
|
|
|
// TRIPLE_EXISTS: {{^}}Selected GCC installation:
|
|
// TRIPLE_EXISTS: fedora_39_tree/usr/lib/gcc/x86_64-redhat-linux/13{{$}}
|
|
|
|
// RUN: %clang --target=x86_64-redhat-linux-gnu \
|
|
// RUN: --sysroot=%S/Inputs/fedora_39_tree --gcc-triple=x86_64-gentoo-linux -v 2>&1 | \
|
|
// RUN: FileCheck %s --check-prefix=TRIPLE_DOESNT_EXIST
|
|
|
|
// TRIPLE_DOESNT_EXIST-NOT: x86_64-gentoo-linux
|