Reputation: 691
I updated my Windows version to 10.0.15063.0 and every lib is missing, so I had to change the platform version to 10.0.14393.0 on Visual Studio, is there any equivalent for QT? The reason I ask is because QT seems to be using the 10.0.15063.0 version and so I get errors like kernel.lib / shell32.lib are missing, etc.
Upvotes: 1
Views: 901
Reputation: 8311
You need to install the Windows 10 SDK for 10.0.15063.0
If you have Visual Studio 2017 installed this can be done by using the "Visual Studio Installer". In "Individual components", check "Windows 10 SDK (10.0.15063.0) for Desktop C++ x86 and x64" and apply the changes.
If you build your project from the command line you can specify which Windows kit you want to use when calling vcvarsall.bat
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x64 10.0.14393.0
If you use Qt Creator, the call to vcvarsall.bat
is made automatically. You can see the call in Qt Creator settings in "Build & Run" > "Compilers".
However the GUI does not provide a mean to add extra arguments to the command line.
You might be able to force the arguments by editing C:\Users\<username>\AppData\Roaming\QtProject\qtcreator\toolchains.xml
. This file should contains something like:
<value type="QString" key="ProjectExplorer.MsvcToolChain.VarsBat">C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/vcvarsall.bat</value>
<value type="QString" key="ProjectExplorer.MsvcToolChain.VarsBatArg">x86</value>
You could change it to:
<value type="QString" key="ProjectExplorer.MsvcToolChain.VarsBat">C:/Program Files (x86)/Microsoft Visual Studio 14.0/VC/vcvarsall.bat</value>
<value type="QString" key="ProjectExplorer.MsvcToolChain.VarsBatArg">x86 10.0.14393.0</value>
But keep in mind that you are not supposed to edit this file by hand and it may or may not work.
Upvotes: 1