CMake is a cross-platform, open-source build system. CMake is a family of tools designed to build, test and package software.
Here are the simple steps to download, configure, compile, and install CMake on a Linux machine. I have tested these instructions on Debian/Ubuntu Linux distributions but they should work on all Linux machines where compilers and make utilities are installed. Please take a look atconfiguring Ubuntu Linux after installationto configure your Debian/Ubuntu Linux box for the required tools.
Please make sure you check the downloaded file’s integrity before unzipping it. ’#’ (w/o quotes) in front of commands below means you have to run the command as root user (or use sudoinstead if your system supports that).
Download:$ wget http://www.cmake.org/files/v2.8/cmake-2.8.3.tar.gzExtration of cmake source code from downloaded file:
$ tar xzf cmake-2.8.3.tar.gz$ cd cmake-2.8.3Configuration:
If you want to see the available conifuration options, run command below.
$ ./configure --help
In order to configure cmake before installation, run command below.
$ ./configure --prefix=/opt/cmake
We basically instructed the install script to install CMake in /opt/cmake.
Compilation:$ makeInstallation:
# make installVerification:
After installation without any errors you can verify the installation by running the command below:
$ /opt/cmake/bin/cmake -version
The output should look something like below (depending upon cmake version you are installing).
cmake version 2.8.3
Please feel free to use the comments form below if you have any questions or need more explanation on anything. Use the icons below to share this tutorial with your friends.
相关文章:
1. Win11右键没有压缩选项怎么办?Win11右键没有压缩选项的解决方法2. Win11 文件资源管理器将有重大更新,新设计泄露3. Win11发布预览版Build 22000.1639更新补丁KB5022905推送(附更新修复内容汇总)4. KB5022845导致Win1122H2更新驱动失败 Surface出现0x80070103错误5. Win11回退按钮没反应怎么办?Win11回退按钮没反应的解决方法6. Win11开机后出现explorer.exe应用程序错误怎么解决? exe应用程序错误解决办法7. Win11 预览版25300怎么开启文件资源管理器图库隐藏功能?8. 为Win12让路:Win11 2023终极正式版来了9. Win11控制面板一直闪烁怎么回事?Win11控制面板打不开一直闪解决方法10. Win11 release preview通道是什么?release preview频道更新Win11好吗?