talira

A powerful software build system

open sourceBSD-3-Clauseself-hostablefree

CMake is an open source, cross-platform family of tools designed to build, test and package software. You describe the build once in simple configuration files and CMake generates a native build for Visual Studio, Xcode, Ninja, Make or VS Code, with CTest for running tests and CPack for making installers. Kitware calls it the de-facto standard for building C++ code. Bill Hoffman, co-founder and CTO of Kitware, created it for the ITK and VTK toolkits; Kitware also sells training and support.

Ways to install

Problems it solves

  • build my C++ project on Windows, macOS and Linux from one set of build files
  • generate Visual Studio and Xcode projects for my C++ code instead of maintaining each by hand
  • my hand-written Makefiles rebuild everything when I change one file
  • keep build output out of my source tree and have several build configurations side by side
  • detect installed libraries and compiler features on each machine before compiling C or C++
  • make installers for Windows, macOS and Linux from my C++ project's build
  • run my C++ project's tests after every build and send the results to a dashboard
  • link a C++ library's dependencies transitively without listing every flag by hand
  • move a large C++ codebase off bjam or autotools to a cross-platform build system
  • use Ninja for faster C++ builds without writing Ninja files myself

Features

  • single source builds on multiple platforms, from Android and iOS to HPC systems
  • generates builds for Visual Studio, Xcode, Ninja, Make and VS Code
  • accurate dependencies and minimal rebuilds, including Fortran and C++ modules
  • out-of-source builds with multiple build trees per source tree
  • target-centric builds with transitive link dependencies
  • system introspection cache, editable in CMake's GUIs
  • CTest cross-platform testing, with results sent to CDash and run in parallel
  • CPack cross-platform installers for Linux, Windows and Mac
  • cross-platform install system
  • custom commands at build time for code generators

Capabilities

Has a command line toolplan not known

Alternatives

The same job

These do what CMake does.

  1. Bazel a fast, scalable, multi-language and extensible build system

Compare CMake with the top 3