安裝cmake之前,記得更新gcc,請參考 centos7 更新GCC版本到7.3.0
#shell 太簡單,懶得解釋
wget https://cmake.org/files/v3.11/cmake-3.11.4.tar.gz
tar xzvf cmake-3.11.4.tar.gz
cd cmake-3.11.4
./bootstrap
gmake
gmake install
參考資料:
https://cmake.org/download/