Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.5k views
in Technique[技术] by (71.8m points)

cmake 3.12 version installation on RHEL 7

I had cmake 3.9 version on my RHEL 7.6 system. But for some development work, i need 3.12 version. I downloaded the https://cmake.org/files/v3.12/cmake-3.12.2.tar.gz. Untarred the tar file and Executed the commands trying to install it. But I am getting errors in each of the below case. Can anyone please let me know if you have any idea to fix it and get the latest version?

1st trial

./bootstrap --prefix=$HOME
make;make install
CMake Error at cmake_install.cmake:82 (file):
  file failed to open for writing (Permission denied):
/workspace/poomanju/_cmake_build/cmake-3.12.2/install_manifest.txt

2nd trial

./bootstrap
make;make install.

3rd trial

./configure
make;make install

I tried the command being root. It seems the installation completes successfully. But when I come out of root privilege and view the version as regular user, I see the version is still 3.9.

bash-4.2$ /usr/local/bin/cmake --version
cmake version 3.12.2
CMake suite maintained and supported by Kitware (kitware.com/cmake).

bash-4.2$ which cmake
/usr/local/bin/cmake

bash-4.2$ cmake --version
CMake Error: Could not find CMAKE_ROOT !!!
CMake has most likely not been installed correctly.
Modules directory not found in
/usr/local/share/cmake-3.9
cmake version 3.9.6
CMake suite maintained and supported by Kitware (kitware.com/cmake).
question from:https://stackoverflow.com/questions/65895922/cmake-3-12-version-installation-on-rhel-7

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...