You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Windows10下CMake编译VTK 9.2.2失败:无法写入文件/创建目录求助

VTK 9.2.2 CMake构建失败问题

错误信息

CMake Error: Cannot open file for write: C:/Program Files/vtk/bin/CMakeCache.txt.tmpc3fcf
CMake Error: Unable to (re)create the private pkgRedirects directory:
C:/Program Files/vtk/bin/CMakeFiles/pkgRedirects
CMake Error: : System Error: No such file or directory
CMake Error: Unable to open cache file for save. C:/Program Files/vtk/bin/CMakeCache.txt
CMake Error: : System Error: No such file or directory

环境信息

  • Windows 10 系统
  • VTK 9.2.2
  • CMake 3.25.1
  • 尝试过多个Visual Studio版本,问题一致

执行步骤

  1. 从官网下载VTK
  2. 将下载文件放入Program Files目录
  3. 在下载包外创建/vtk文件夹,并在其中新建/src和/bin子文件夹
  4. 将下载文件复制到/src文件夹
  5. 打开CMake GUI,选择/src为源目录,/bin为构建目录
  6. 点击Generate后出现上述错误

已尝试动作

  • 按照视频教程操作,问题未解决
  • 搜索相关解决方案,未找到完全匹配的错误案例

内容的提问来源于stack exchange,提问作者Compiler v2

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.08 15:20:32