For Ubuntu Focal Fossa (20.04) sudo apt-add-repository 'deb focal main'ī.
![download cmake linux download cmake linux](https://linux-cdn.softpedia.com/screenshots/CMake_1.png)
Obtain a copy of the signing key wget -O - 2>/dev/null | gpg -dearmor - | sudo tee /etc/apt//kitware.gpg >/dev/nullĪ. Remove old version of cmake sudo apt purge -auto-remove cmake Kitware now has an APT repository that currently supports Ubuntu 16.04, 18.04 and 20.04 If you want the Previous Release 3.18.5 just replace the version and build parameters like this: version=3.18 According to the official web page the Latest Release is 3.19.1. The build may change if cmake is updated. In 3.19.X the X represents the last part of the version that we defined as build. Add the installed binary link to /usr/local/bin/cmake by running this: sudo ln -s /opt/cmake/bin/cmake /usr/local/bin/cmakeī-4. Sudo sh cmake-$version.$build-Linux-x86_64.sh -prefix=/opt/cmakeī-3. Wget $version/cmake-$version.$build-Linux-x86_64.sh Update the version and build variables in the following command to get the desired version: version=3.19
#DOWNLOAD CMAKE LINUX INSTALL#
Go to the official CMake webpage, then download and install the latest. Uninstall the default version provided by Ubuntu's package manager as in A-1.ī-2. Using binary files ( cmake-gui wont work well)ī-1. Results of cmake -version: cmake version 3.19.XĬMake suite maintained and supported by Kitware (/cmake).ī.
![download cmake linux download cmake linux](http://codelite.org/images/wiki/DebugCodeLite/debug-codelite-linux-2.png)
Go to the official CMake webpage, then download and extract the latest version. Uninstall the default version provided by Ubuntu's package manager and configuration by using: sudo apt remove -purge -auto-remove cmakeĪ-2. Building and Installing (recommended)Ī-1. Well, we can install it by following one of these methods: Building and Installing or Using binary files. 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.19.1 which is the current version at. The most common situation is when you want to install the latest version of cmake, but your Operating System's repositories are not updated.