Compilation error under MSVC2015 32-bit
-
I have a source code which is built in Qt and I need to modify it (Moreover that I am new in Qt). Environment details specified as: Windows: Desktop Qt 5.9.2 with MSVC2015 32bit.
My system is working under Windows 10. I installed Qt 5.9.2. In Manage kits->Build & Run, I selected “Desktop Qt 5.9.2 MSVC 2015 32-bit”.
When I rebuild, it displays the following in issues :
“C1189: #error : Qt requires a C++11 compiler and yours does not seem to be that.”
After analyzing, I found an error message in Manage kits -> Build & Run :
The message is ::::: The Compiler "Microsoft Visual C++ Compiler 11.0 (x86)" (x86-windows-msvc2012-pe-32bit) cannot produce code for the Qt version "Qt 5.9.2 MSVC2015 32bit" (x86-windows-msvc2015-pe-32bit).
Can somebody help me to resolve it? -
I have a source code which is built in Qt and I need to modify it (Moreover that I am new in Qt). Environment details specified as: Windows: Desktop Qt 5.9.2 with MSVC2015 32bit.
My system is working under Windows 10. I installed Qt 5.9.2. In Manage kits->Build & Run, I selected “Desktop Qt 5.9.2 MSVC 2015 32-bit”.
When I rebuild, it displays the following in issues :
“C1189: #error : Qt requires a C++11 compiler and yours does not seem to be that.”
After analyzing, I found an error message in Manage kits -> Build & Run :
The message is ::::: The Compiler "Microsoft Visual C++ Compiler 11.0 (x86)" (x86-windows-msvc2012-pe-32bit) cannot produce code for the Qt version "Qt 5.9.2 MSVC2015 32bit" (x86-windows-msvc2015-pe-32bit).
Can somebody help me to resolve it?Hi and welcome to devnet forum
Most MS VisualStudio compilers are not compatible between their versions. And that is what the message says. You need to install the MSVC version 2015 32 bit for compatibility with the pre-build Qt libs in this case.
-
Thanks koahnig .
I have already installed MSVC version 2015 32 bit, that is coming with Qt 5.9.2.
Do I have to install it again? Can we install this independently? If it is possible to install independently can you give me a link for the same. -
Hi,
It looks like you don't have Visual Studio 2015 installed but an older version. You can't mix and match compilers like that. The only exception is VS2017 which is compatible with VS2015.
Therefore, install the matching version of Visual Studio.
-
Thanks koahnig .
I have already installed MSVC version 2015 32 bit, that is coming with Qt 5.9.2.
Do I have to install it again? Can we install this independently? If it is possible to install independently can you give me a link for the same.@JosephAlex said in Compilation error under MSVC2015 32-bit:
Thanks koahnig .
I have already installed MSVC version 2015 32 bit, that is coming with Qt 5.9.2.
Do I have to install it again? Can we install this independently? If it is possible to install independently can you give me a link for the same.Nope, you have installed pre-build Qt libraries which are compiled with MSVC 2015 32 bit. The MS compilers you have to install separately. Because of license issues they cannot be installed by Qt's online installer.
As @SGaist explains you may decide to install either MSVC 2015 or MSVC 2017, because those 2 compiler versions are the only exception of general incompatibility issue between ms compilers.
-
Thanks SGaist and koahnig.