Ubuntu下安装cmake

今天因为项目的原因需要将cmake升级一下,原来我是按照链接没有卸载旧版本,直接升级。但是出现一些问题,然后我全部卸载后,重新安装。以下就是我的安装步骤。

第一步
从http://distfiles.macports.org/cmake/中下载最新的版本到本地。
Ubuntu下安装cmake
为了方便,我将下载好的版本复制到了指定的文件夹。
Ubuntu下安装cmake
第二步
安装

  1. 打开ubuntu,进入下载的文件目录。
    Ubuntu下安装cmake
  2. 解压文件
 tar -zxvf cmake-3.12.4.tar.gz

Ubuntu下安装cmake
3. 执行如下命令,对cmake进行安装

$ cd cmake-3.12.4
$ ./configure
$ make
$ sudo make install

安装完成后查看

[email protected]:/bin$ cmake --version
cmake version 3.12.4

CMake suite maintained and supported by Kitware (kitware.com/cmake).

参考:
https://blog.csdn.net/learning_tortosie/article/details/80593956

相关文章:

  • 2021-06-18
  • 2021-05-25
  • 2021-12-29
  • 2022-01-02
  • 2022-03-03
  • 2022-01-05
  • 2021-05-08
猜你喜欢
  • 2021-04-20
  • 2021-11-06
  • 2022-02-07
  • 2021-05-22
  • 2022-12-23
  • 2021-07-08
  • 2021-09-30
相关资源
相似解决方案