Skip to content

Latest commit

 

History

History
84 lines (55 loc) · 1.48 KB

CMakePresets.md

File metadata and controls

84 lines (55 loc) · 1.48 KB

CMake Presets

The template uses Cmake Presets, enabling a convenient way of running CMake, CTest, and CPack.

You can find out more about presets in the official CMake documentation about Presets. I also wrote an article as a TL;DR on CMake presets, giving an overview of how to define and work with them.

Configure

To list all available configure presets, some dependent on the current system:

cmake --list-presets

Run configure presets by name:

cmake --preset debug

Build

To list all available build presets, some dependent on the current system:

cmake --build --list-presets

Run build presets by name:

cmake --build --preset debug

Test

To list all available test presets:

ctest --list-presets

Run test presets by name, executing CTest:

ctest --preset all

Packaging

To list all available packaging presets, some dependent on the current system:

cpack --list-presets

Run packaging presets by name, executing CPack:

cpack --preset release

Workflows

To list all available workflows, some dependent on the current system:

cmake --workflow --list-presets

Run a workflow by name:

cmake --workflow --preset dist

Next up: Platform dependent code