我如何为我的 UWP 项目编译 openssl 1.1.1?

How can i compile openssl 1.1.1 for my UWP project?

我想在 UWP 项目中使用 TLS1.3,但我不知道如何为我的 UWP 项目编译这个 https://www.openssl.org/source/openssl-1.1.1g.tar.gz

would like to use TLS1.3 in a UWP project

恐怕您无法在 UWP 平台中使用 TLS 1.3。源自 official document UWP 平台中支持的 TLS 的最大版本是 1.2。如果您确实想要此功能,请随时 post 您对 windows 反馈中心应用的要求,或关注以下 UWP SDK 更新。

您应该使用“perl configure VC-WIN32-ONECORE no-shared enable-capieng”在“Visual Studio 2019 Tools Command Prompt”中配置 OpenSSL。

然后 运行“nmake”和“nmake 安装”。现在您可以在“Windows 运行时组件(通用 Windows)”项目中使用 OpenSSL。

但是你必须添加“libssl.lib;libcrypto.lib;Kernel32.lib”作为“附加依赖项”。

或使用“perl Configure VC-WIN32-ONECORE --release no-asm no-hw no-dso no-tests no-stdio no-async no-shared”。那么不需要“Kernel32.lib”。