简体   繁体   English

将VC2010编译器添加到VS2012

[英]Adding VC2010 compiler to VS2012

I have installed VS2012 express.It uses VC11 compiler.I need to add also VC10 compiler to be able working with some older libs.I have installed Windows 7.1 SDK which comes with VC10 compiler.Now I can select VC10 from PlatformToolset.But when compiling I am getting this error: 我已经安装了VS2012 express.It使用VC11编译器。我还需要添加VC10编译器才能使用一些较旧的libs。我已经安装了VC7编译器附带的Windows 7.1 SDK。现在我可以从PlatformToolset.But中选择VC10进行编译我收到此错误:

Warning 1 warning MSB8003: Could not find WindowsSDKDir variable from the registry. 警告1警告MSB8003:无法从注册表中找到WindowsSDKDir变量。 TargetFrameworkVersion or PlatformToolset may be set to an invalid version number. TargetFrameworkVersion或PlatformToolset可能设置为无效的版本号。 C:\\Program Files (x86)\\MSBuild\\Microsoft.Cpp\\v4.0\\Microsoft.CppBuild.targets 297 5 (Visual Studio 2010) C:\\ Program Files(x86)\\ MSBuild \\ Microsoft.Cpp \\ v4.0 \\ Microsoft.CppBuild.targets 297 5(Visual Studio 2010)

Now , I am sure the problem is that I installed the VS not on C but on E.Though Windows SDK I have installed on E too.Somehow I see the config is looking for the "WindowsSDKDir " on C.Where can I change it ? 现在,我确定问题是我安装的VS不在C上但在E.Though Windows SDK上我已经安装在E上。我看到配置正在寻找C上的“WindowsSDKDir”。我可以在哪里更改它?

好吧,最后我通过删除Windows SDK并安装Visual Studio Express 2010来修复它。现在VS2012编译好VC10。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM