linux升级cmake

如果出现如下报错,就应该升级cmake了!

CMake Error at CMakeLists.txt:1 (cmake_minimum_required):

CMake 3.1 or higher is required. You are running version 2.8.12.2

-- Configuring incomplete, errors occurred!

官网

可以下载各个版本的cmake: https://cmake.org/files/

升级

1.下载cmake,这里选择cmake-3.12.4,当然可以选择更新的版本:

进入https://cmake.org/files/v3.12/

选择cmake-3.12.4.tar.gz

2.解压后进入文件夹进行编译编译

bash 复制代码
./bootstrap
make
sudo make install

3.查看版本

bash 复制代码
cmake --version

打印如下,说明安装成功了!

cmake version 3.12.4

安装完后,发现make会出报错如下:

CMake Error: Could not find CMAKE_ROOT !!!

CMake has most likely not been installed correctly.

Modules directory not found in

/usr/local/bin

CMake Error: Error executing cmake::LoadCache(). Aborting.

bash 复制代码
hash -r

问题3

-- Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the system variable OPENSSL_ROOT_DIR (missing: OPENSSL_CRYPTO_LIBRARY OPENSSL_INCLUDE_DIR)

bash 复制代码
sudo yum install openssl-devel
相关推荐
好评12411 小时前
【Linux】网络基础概念
linux·网络
杨云龙UP11 小时前
Toad for Oracle 调整表空间 Datafile 大小:Usage、Used Pct of Max 与 RESIZE 实战
linux·运维·服务器·数据库·oracle·dba·数据库运维
raindayinrain11 小时前
深入理解linux内核--文件页高速缓存,页框回收,性能优化
linux·性能优化·高速缓存·页框
奶茶树11 小时前
【C++】13. C++11新特性【上】
c语言·开发语言·c++·git·github
wabs66612 小时前
关于栈【力扣1047. 删除字符串中的所有相邻重复项的思考】
数据结构·c++·算法·leetcode··代码随想录
badboy12112 小时前
Xilinx Vitis Core Development Kit 2025.2.1_Win+Linux
linux·fpga开发·xilinx
那年窗外下的雪.12 小时前
Linux 学习笔记
linux·笔记·学习
HiDev_12 小时前
【非标自动化】2、认识元器件(高速计数模块)
运维·自动化
橘色的喵13 小时前
PySide6 工业上位机的实时帧链、零拷贝与跨语言架构
c++·架构·图像·pyside
PTCCTP13 小时前
CSP2024-J T3小木棍
c++