【注】安装完后,执行cmake --version会报如下错误
CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/Applications/CMake 2.8-11.app/Contents/bin
CMake Error: Error executing cmake::LoadCache(). Aborting.
【解决方法】
先执行:
hash -r
然后再执行:cmake --version
完美解决
本文详细介绍了在安装CMake后遇到“Could not find CMAKE_ROOT”错误的解决方案。通过执行命令'hash -r'和重新运行'cmake --version',可以成功解决此问题。
1759





