简体   繁体   English

在VS2015中无法以ARM模式构建C ++静态库(Windows Phone 8.1)

[英]Cannot build C++ Static Library (Windows Phone 8.1) in ARM mode in VS2015

I am using Visual Studio 2015 Pro RTM after an upgrade from 2015 RC. 从2015 RC升级后,我正在使用Visual Studio 2015 Pro RTM。

When I create a new C++ Static Library (Windows Phone 8.1) (File | New Project | Visual C++ | Windows | Windows 8 | Windows Phone | Static Library (Windows Phone 8.1), it builds fine in X86. When I try to build it in ARM, I get 当我创建一个新的C ++静态库(Windows Phone 8.1)(文件|新建项目| Visual C ++ | Windows | Windows 8 | Windows Phone |静态库(Windows Phone 8.1)时,它在X86中可以正常运行。在ARM中,我得到了

Error   D8027   cannot execute 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_arm\c2.dll'  

Which is strange because it references 12.0 (VS2013) and VS2015 is 14.0. 这很奇怪,因为它引用了12.0(VS2013),而VS2015是14.0。 Any ideas how to solve it? 有什么想法如何解决吗? I installed VS2015 with C++ support. 我安装了具有C ++支持的VS2015。

I had the same problem. 我有同样的问题。 What worked for me was to run the 'Repair' option in the VS installer from the control panel 'Programs and Features'. 对我有用的是从控制面板“程序和功能”中运行VS安装程序中的“修复”选项。 It took a while, but after the reboot I was able to rebuild without any problems. 花费了一段时间,但是重新启动后,我得以重建而没有任何问题。

It sounds like you have some stale components in your installation (left over from RC). 听起来您的安装中有一些陈旧的组件(RC遗留下来的)。 In VS 2015 RC, there was a bug where project templates were installed even if the required tools were not. 在VS 2015 RC中,存在一个错误,即即使未安装必需的工具也安装了项目模板。 This was fixed in the RTM release. 这已在RTM版本中修复。

For Windows 8.1 and Windows Phone 8.0/8.1 support, you need to select the "Windows 8.1 and Windows Phone 8.0/8.1 Tools" optional feature in VS setup. 对于Windows 8.1和Windows Phone 8.0 / 8.1支持,您需要在VS安装程序中选择“ Windows 8.1和Windows Phone 8.0 / 8.1工具”可选功能。 That will include the compiler, libs, and SDKs needed to work with components for those app platforms. 这将包括与那些应用程序平台的组件一起使用所需的编译器,库和SDK。

Context: For Store & Phone apps (8/8.1), the VC++ compiler toolset and app platform are directly linked. 上下文:对于商店和电话应用程序(8 / 8.1),VC ++编译器工具集和应用程序平台是直接链接的。 So, the fact that Windows Phone 8.1 projects are attempting to make use of the VS 2013 compiler is expected. 因此,可以预期Windows Phone 8.1项目正在尝试使用VS 2013编译器的事实。

Windows Phone 8.0 => v110 VC++ compiler toolset; Windows Phone 8.0 => v110 VC ++编译器工具集; Windows Phone 8.1 & Windows 8.1 (store) => v120 VC++ compiler toolset Windows Phone 8.1和Windows 8.1(存储)=> v120 VC ++编译器工具集

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

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