The most common situation is when you want to install the latest version of cmake, but your Operating System's repositories are not updated. For example, in my case I have a laptop running Ubuntu 16.04, and when I executed the command sudo apt install cmake
the installed version was 3.5.1; instead of, 3.12.3 which is the current version at cmake.org.
How can I get the latest version?
Well, we can install it by following one of this methods:
A. Building and Installing (recommended)
A-1.