Software developer stories
en de

Install cmake 3.11.1 on Ubuntu

Sometimes you just want a newer version than ubuntu ships. This code will update cmake to version 3.11.1 or any other version you want.

# Removing the old cmake
sudo apt purge cmake
sudo apt autoremove

# Downloading the new
sudo mkdir /opt/cmake
sudo sh --prefix=/opt/cmake --skip-license
# Make it available
sudo update-alternatives --install /usr/bin/cmake cmake /opt/cmake/bin/cmake 1 --force