ProjectExplorer: Fix toolchain bundling for llvm-mingw

Change-Id: I1fd6b59a9192510d9049b7540ae654560a4872fb
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Christian Kandeler
2024-10-21 15:28:11 +02:00
parent fbaff902b8
commit a62d483ede

View File

@@ -1606,6 +1606,12 @@ std::unique_ptr<ToolchainConfigWidget> GccToolchainFactory::createConfigurationW
FilePath GccToolchainFactory::correspondingCompilerCommand( FilePath GccToolchainFactory::correspondingCompilerCommand(
const FilePath &srcPath, Id targetLang) const const FilePath &srcPath, Id targetLang) const
{ {
// llvm-mingw
if (supportedToolchainType() == Constants::MINGW_TOOLCHAIN_TYPEID
&& srcPath.fileName().contains("clang")) {
return GccToolchain::correspondingCompilerCommand(srcPath, targetLang, "clang", "clang++");
}
if (supportedToolchainType() == Constants::GCC_TOOLCHAIN_TYPEID if (supportedToolchainType() == Constants::GCC_TOOLCHAIN_TYPEID
|| supportedToolchainType() == Constants::MINGW_TOOLCHAIN_TYPEID) { || supportedToolchainType() == Constants::MINGW_TOOLCHAIN_TYPEID) {
return GccToolchain::correspondingCompilerCommand(srcPath, targetLang, "gcc", "g++"); return GccToolchain::correspondingCompilerCommand(srcPath, targetLang, "gcc", "g++");