Bioinformatics ReviewBioinformatics Review
Notification Show More
Font ResizerAa
  •  Home
  • Docking
  • MD Simulation
  • Tools
  • More Topics
    • Softwares
    • Sequence Analysis
    • Algorithms
    • Bioinformatics Programming
    • Bioinformatics Research Updates
    • Drug Discovery
    • Phylogenetics
    • Structural Bioinformatics
    • Editorials
    • Tips & Tricks
    • Bioinformatics News
    • Featured
    • Genomics
    • Bioinformatics Infographics
  • Community
    • BiR-Research Group
    • Community Q&A
    • Ask a question
    • Join Telegram Channel
    • Join Facebook Group
    • Join Reddit Group
    • Subscription Options
    • Become a Patron
    • Write for us
  • About Us
    • About BiR
    • BiR Scope
    • The Team
    • Guidelines for Research Collaboration
    • Feedback
    • Contact Us
    • Recent @ BiR
  • Subscription
  • Account
    • Visit Dashboard
    • Login
Font ResizerAa
Bioinformatics ReviewBioinformatics Review
Search
Have an existing account? Sign In
Follow US
SoftwareTips & TricksTools

CMake installation and upgrade: What worked & what didn’t?!

Dr. Muniba Faiza
Last updated: March 13, 2025 8:55 pm
Dr. Muniba Faiza
Share
4 Min Read
CMake installation and upgrade: What worked & what didn’t?!
SHARE

CMake is a widely used cross-platform build system that automates the process of compiling and linking software projects. In bioinformatics, CMake can be utilized to manage the build process of software tools and pipelines used for data analysis, algorithm implementation, and other computational tasks. However, managing the versions of CMake or upgrading it on Ubuntu (Linux) can be a trivial task for beginners. In this article, we provide methods for installing and upgrading CMake on Ubuntu.

Contents
What didn’t work!What worked!Preparing systemDownloading CMakeInstalling PrerequisitesInstalling CMake

What didn’t work!

I tried to install and upgrade my CMake from version 3.16 to 3.2x using different methods including: (If you prefer not to read this, you can jump to the next section for the installation instructions.)

  • pip3 (pip3 install cmake)
    It did install the latest CMake (version 3.29) but couldn’t find the location. I got errors while trying to install other software as follows:
    “Command ‘cmake’ not found,”, or
    “Requirement already up-to-date: cmake in /.local/lib/python3.8/site-packages (3.29.2)”
    “bash: /usr/bin/cmake: No such file or directory“
  • hash -r
    In one of my previous posts, I mentioned about this command. However, it works only when you have correctly installed the CMake version and want to upgrade. It can’t find the new path and you get errors like:
    “CMake Error: Could not find CMAKE_ROOT !!! CMake has most likely not been installed correctly. Modules directory not found in /home/user/.local/share/cmake-3.16 cmake version 3.16.3”
  • sudo apt install cmake
    You can install CMake from the repository but you will not be able to find its location.
  • sudo snap install cmake
    It also didn’t work for me. I got an error stating:
    “Error: This revision of snap “cmake” was published using classic confinement
    and thus may perform arbitrary system changes outside of the security
    sandbox that snaps are usually confined to, which may put your system at
    risk.If you understand and want to proceed repeat the command including
    –classic.“

None of the methods mentioned above worked for me. I had to uninstall CMake and reinstall it from scratch, as demonstrated in the following section.

What worked!

Preparing system

Update and upgrade your system first.

$ sudo apt-get update

$ sudo apt-get upgrade

Uninstall the previous version of CMake.

$ pip3 uninstall cmake

Downloading CMake

Clone the GitHub directory of CMake from here or use the following command. You can download it in any directory, I am downloading it in ‘Downloads‘.

$ git clone https://github.com/Kitware/CMake.git

Installing Prerequisites

Install the build dependency package necessary for CMake installation.

$ sudo apt install build-essential libssl-dev

Installing CMake

Let’s change to the CMake directory.

$ cd CMake/

Now run the bootstrap script present in the same directory.

$ ./bootstrap

It will take a few minutes to finish. After it finishes, run the make command:

$ make

After that, install CMake,

$ sudo make install

It will take a while to finish the installation.

After that, check your installation using the following command:

$ cmake --version

It should display the latest version.


 

TAGGED:cmakeCMake installCMake upgradeLinuxubuntu
Share This Article
Facebook Copy Link Print
ByDr. Muniba Faiza
Follow:
Dr. Muniba is a Bioinformatician based in New Delhi, India. She has completed her PhD in Bioinformatics from South China University of Technology, Guangzhou, China. She has cutting edge knowledge of bioinformatics tools, algorithms, and drug designing. When she is not reading she is found enjoying with the family. Know more about Muniba
Leave a Comment

Leave a Reply Cancel reply

You must be logged in to post a comment.

Starting in Bioinformatics? Do This First!
Starting in Bioinformatics? Do This First!
Tips & Tricks
[Editorial] Is it ethical to change the order of authors’ names in a manuscript?
Editorial Opinion
Installing bbtools on Ubuntu
[Tutorial] Installing BBTools on Ubuntu (Linux).
Sequence Analysis Software Tools
wes_data_analysis Whole Exome Sequencing (WES) Data visualization Toolkit
wes_data_analysis: Whole Exome Sequencing (WES) Data visualization Toolkit
Bioinformatics Programming GitHub Python

You Might Also Like

MOCCA- A New Suite to Model cis- regulatory Elements for Motif Occurrence Combinatorics
AlgorithmsSoftwareTools

MOCCA- A New Suite to Model cis- regulatory Elements for Motif Occurrence Combinatorics

May 19, 2021
Sequence AnalysisSoftwareTools

Homology search against a local dataset using NCBI-BLAST+ command-line tool

October 27, 2022
protein structure & folding prediction using remote homologs
SoftwareStructural BioinformaticsStructure PredictionTools

Protein structure & folding information exploited from remote homologs.

March 31, 2023
AlgorithmsTools

WebFEATURE : Tool to identify and visualize Functional Sites in Macromolecules

May 20, 2020
Copyright 2024 IQL Technologies
  • Journal
  • Customer Support
  • Contact Us
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Cookie Policy
  • Sitemap
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?

Not a member? Sign Up