Multi-configuration generatorΒΆ

Generator that allows to use several build types on build step while doing only one configure step. List of available build types can be specified by CMAKE_CONFIGURATION_TYPES. Default value for CMAKE_CONFIGURATION_TYPES is a list of:

  • Debug

  • Release

  • MinSizeRel

  • RelWithDebInfo

Example of configuring Debug + Release project and building Debug variant:

> cmake -H. -B_builds -DCMAKE_CONFIGURATION_TYPES=Release;Debug -GXcode
> cmake --build _builds --config Debug

It is legal to use same _builds directory to build Release variant without rerunning configure again:

> cmake --build _builds --config Release

Multi-configuration generators: