Yes you can set PlatformToolset without change the vcxproj file.
If you open a vcxproj file, you'll see that there is a PlatformToolset
property.
For visual studio 2012, it is v110; For VS2010, it is v100; For VS2008, it is v90.
You could overwrite this property with /p:PlatformToolset=v110/v100/v90
to change the toolchain.
Note: Sometimes, msbuild failed with error Unsupported platformtoolset value
, it is mostly because you have not specify the VisualStudioVersion
.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…