简体   繁体   English

是否可以在Windows套件中控制Windows SDK版本?

[英]Is it possible to control the Windows SDK version in Windows Kits?

Currently when building my Visual C++ application I link out to the Windows SDK in order to use winusb.h . 目前,在构建我的Visual C ++应用程序时,我链接到Windows SDK以使用winusb.h This results in an Additional Include Directories with an include for both a um and shared directory,as shown here: 这会导致其他包含目录包含um和共享目录,如下所示:

在此输入图像描述

Unfortunately, different developers on the project all have different Windows SDK versions installed on their machines, I assume this is to do with either Windows Updates or different Visual Studio installation dates. 不幸的是,项目上的不同开发人员都在他们的计算机上安装了不同的Windows SDK版本,我认为这与Windows更新或不同的Visual Studio安装日期有关。 This means we currently have a whole host of SDK version numbers included in this list. 这意味着我们目前在此列表中包含了大量SDK版本号。

My question is: Is there a way to either control the SDK version installed, or to include a more generic directory pathname? 我的问题是: 有没有办法控制安装的SDK版本,或包含更通用的目录路径名?

As pointed out by @Richard Critten in the comments of the question, the Windows 10 SDK options are configurable, and installable through the Visual Studio Installer. 正如@Richard Critten在该问题的评论中所指出的,Windows 10 SDK选项是可配置的,并且可以通过Visual Studio Installer进行安装。

As shown below, there are many different options for SDK installation 如下所示,SDK安装有许多不同的选项 VS安装选项

It would be sensible to pick one that works for your development environment & team, and ensure every developer has that option installed for their own Visual Studio environment. 选择适合您的开发环境和团队的一个是明智的,并确保每个开发人员都为他们自己的Visual Studio环境安装了该选项。

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

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