Mac下安装cmake

2020-09-28 20:53

从 https://cmake.org/download/ 下载cmake,选择dmg安装文件

安装完成后,打开cmake图形界面,在menu菜单栏选择 Tools → How to install For Command Line Use,然后复制命令行语句

sudo "/Applications/CMake.app/Contents/bin/cmake-gui" --install

执行完成,cmake命令就可以用了

aaaaa$ cmake

Usage


 

  cmake [options] <path-to-source>

  cmake [options] <path-to-existing-build>

  cmake [options] -S <path-to-source> -B <path-to-build>


 

Specify a source directory to (re-)generate a build system for it in the

current working directory.  Specify an existing build directory to

re-generate its build system.


 

Run 'cmake --help' for more information.