Why we use CMake and why you should too:

Why Cmake? What it is and why we recommend it.

Published: Last updated:

Category: Blog, Software

2 Min. Read time

When developing a new product, it is easy to get carried away. The enthusiasm for the task, the creativity of the developers involved, the various development kits from the chip and module manufacturers. Sometimes hearing about an idea is enough to make you want to jump straight into developing features and software in general.

While this passion is commendable and can sometimes even offer a faster route to market, it is not necessarily the most efficient approach, especially when it comes to large-scale implementation. For software projects, it is therefore best to use what is called a “build system”.

A build system is a set of tools and processes that automate the compilation and assembly of source code into executable programs, libraries or other deployable artefacts. Generally, it consists of a compiler (translates written source code into machine code) and build tools & configuration (an automated process that compiles source files and produces a library).

Here at ithinx we currently prefer CMake (Cross-Platform Make) as our build tool of choice.

What is CMake exactly? 

CMake is an open source build system and configuration tool used to manage the build process of software projects. It allows developers to define the build process in a platform-independent and efficient way by creating a set of configuration files (CMakeLists.txt) that describe how the project should be built.

cmake
cmake
cmake
cmake

Why are we so keen on it?

Platform independence: CMake allows developers to define build configurations that work seamlessly across different operating systems and build environments.

Generator-based build system: CMake generates platform-specific build files (e.g. Makefiles, Visual Studio project files) based on the project configuration and is thus adaptable to different build tools.

Modularity and dependency management: CMake supports modular project structures and helps manage dependencies between different components or libraries.

Customisable configuration: Developers can customise build settings, compile options and other parameters via CMake, tailoring the build process to specific requirements.

Out-of-source builds: CMake encourages the practice of building the project outside the source code directory to enable clean and organised builds without cluttering the source tree.

Integration with testing frameworks: CMake facilitates integration with testing frameworks and enables automated testing as part of the build process. As you will read elsewhere on our website, we place great emphasis on testing and automating tests.

Overall, CMake simplifies and standardises the process of building software projects and makes it easier for developers to manage and maintain complex build configurations on different platforms.

Cmake ithinx
Cmake ithinx

ithinx Cmake Template

At ithinx we go one step further and use our own ithinx CMake template. Our template simplifies and standardises the integration of CMake into projects, simplifies testing and creates a seamless integration with our continuous integration system (mostly Jenkins), generates code metrics (a methodology to measure the quality of code), documentation and creates generic deployment packages.

At ithinx, this all supports the V-model we use for development and allows new people (either in the project or in the organisation) to get started easily. Most importantly, it reduces the set-up effort, i.e. less time for us and therefore less cost for our clients.

ithinx Logo
ithinx Logo
  • Smart grid
    Smart grid

    Fit4eChange – truly flexible smart grids

  • Embedded World 2024 ENG ithinx
    Embedded World 2024 ENG ithinx

    Visit us at Embedded World 2024!

We look forward to hearing from you!

Please enable JavaScript in your browser to complete this form.
This site is registered on wpml.org as a development site.