diff --git a/cmake/QtProcessConfigureArgs.cmake b/cmake/QtProcessConfigureArgs.cmake index 505673ca2c7..ba056290cc8 100644 --- a/cmake/QtProcessConfigureArgs.cmake +++ b/cmake/QtProcessConfigureArgs.cmake @@ -733,6 +733,9 @@ function(guess_compiler_from_mkspec) elseif(mkspec MATCHES "-icc(-|$)") set(c_compiler "icc") set(cxx_compiler "icpc") + elseif(mkspec MATCHES "-msvc(-|$)") + set(c_compiler "cl") + set(cxx_compiler "cl") endif() if(guess_c_compiler AND NOT c_compiler STREQUAL "") push("-DCMAKE_C_COMPILER=${c_compiler}")