Compiling Qt 5.7 on Windows using MinGW
I am having problems compiling Qt 5.7 inside a Windows 7 virtual machine. Until now I usually installed the binary (MinGW) package, including the compiler that comes with it, and then I compiled the source-code myself (into a completely separate directory) to have a little more control over certain builds.
When I try this with Qt 5.7, which comes with MinGW 5.3.0,
configurethrows an error that the compiler seemingly doesn't support C++11. That of course cannot be true, but I don't know how to tell configure that the compiler is sufficient.
Maybe I have to set some environment variables, maybe I should install a version of MinGW myself... any kind of hint would be very much appreciated.
maybe - when you are not doing this already - it's enough to explicitly specify the mkspecs:
configure -platform win32-g++
Sadly that didn't help. Here are the final lines I see when trying to run
configure.bat(I tried it on a fresh directory, so the previous attempts should not influence the result):
Running configuration tests... QMake failed! ERROR: Qt requires a C++11 compiler and yours does not seem to be that. Please upgrade.
Since the error-statement is definitely wrong, I honestly think that the configure-script is a little buggy. As far as I understand, this is the first iteration of Qt that absolutely requires a C++11-capable compiler.
Also, here is my whole configure-call, maybe it is useful:
configure.bat -release -opensource -confirm-license -nomake tools -nomake examples -nomake tests -no-compile-examples -opengl desktop -no-warnings-are-errors -no-angle -no-sse4.1 -no-sse4.2 -no-avx -no-avx2 -no-avx512 -mp
I experimented with a couple of flags, including setting the C++11-flag for
configuremanually, but I have had no success so far. Any further suggestions maybe?
I will push this once more, if that is ok. The problem still persists and I still have no idea how to solve it.
Might be a silly question but do you have several version of MinGW installed ? Did you install the one coming with the Qt installer ?
I did install the one coming with the Qt package, there is no other version installed.