【发布时间】:2020-11-23 12:00:47
【问题描述】:
我尝试从 Visual Studio 2019 中“构建解决方案”,因为 Python.NET 项目带有 .sln VS 解决方案文件
但是,它跳过了我感兴趣的 Python.Runtime 构建:
1>------ Skipped Build: Project: Python.Runtime ------
此外,其他 4 个构建有错误:
3>C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Microsoft\NuGet\16.0\Microsoft.NuGet.targets(186,5): error : Your project file doesn't list 'win-x64' as a "RuntimeIdentifier". You should add 'win-x64' to the "RuntimeIdentifiers" property in your project file and then re-run NuGet restore.
另外,当按照https://github.com/pythonnet/pythonnet/wiki/Installation#github-installation-from-master-branch 上的说明运行python setup.py 时,我遇到了另一个错误,即无法找到已安装的Windows Kits 根目录。一直在寻找答案并尝试了不同版本的 Python、.NET Core、.NET 等,但均无济于事。我在https://github.com/pythonnet/pythonnet/issues/1272详细说明了它
环境
- Pythonnet 版本:3.0(正在进行中,最新的 master 分支以 c81c3c3 结尾)
- Python 版本:3.7.9
- 操作系统:Windows 10、64 位、WinPE
【问题讨论】:
标签: python.net winreg