cmake - MSBuild.exe 的 cmake 问题
问题描述
我在 Windows 10 上遇到了 cmake 的问题。我将事情修剪到会产生相同错误的最小示例。我从 Windows 命令提示符运行 cmake(Visual Studio 命令提示符的 git bash 命令行解释器也会出现同样的问题)。我的 CMakeLists.txt 包含三行:
cmake_minimum_required(VERSION 3.1)
project(DEBUG bogus)
我以这种方式运行 cmake:
cmake -G "Visual Studio 15 2017 Win64" .
一个 MSBuild.exe 窗口会短暂弹出一条错误消息,但我无法阅读它。它走得太快了。
命令行窗口显示此错误消息:
CMake Error at CMakeLists.txt:3 (project):
Failed to run MSBuild command:
C:/Program Files (x86)/Microsoft Visual Studio/2017/Professional/MSBuild/15.0/Bin/MSBuild.exe
to get the value of VCTargetsPath:
-- Configuring incomplete, errors occurred!
See also "C:/Users/tmpuser/Desktop/SDK/dependencies/DEBUG/CMakeFiles/CMakeOutput.log".
MSBuild.exe 的可执行文件确实存在。CmakeOutput.log 文件包含:
The system is: Windows - 10.0.17763 - AMD64
有谁知道出了什么问题?
解决方案
推荐阅读
- javascript - Maximo JS 自动化脚本:未定义“importPackage”
- javascript - 如何批量执行 Promise(先解析 10,然后再解析 10,依此类推)
- python - 调用 clear_widgets 时,它不会删除 ScreenManager 中的屏幕
- loops - Vue:避免重复计算
- firebase - 无法确定任务“:app:preDebugBuild”的依赖关系
- ios - 在 UI 测试中找到 UIRefreshControl
- angular - 错误:多个自定义值访问器与未指定名称属性的表单控件匹配
- javascript - 使用 Javascript 使用类名填充元素
- hadoop-yarn - yarn logs 抛出“not valid bcfile”错误
- ios - ARKIT 如何获得世界原点变换