summaryrefslogtreecommitdiff
path: root/Help/generator
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2020-01-17 16:00:28 -0500
committerKyle Edwards <kyle.edwards@kitware.com>2020-01-22 10:26:21 -0500
commit8337ed0d731f869823efcacf2460a4efbf74a991 (patch)
treecaf2baf60879268e6725235e43c28ea35aeaf0e9 /Help/generator
parent110037369d9be6c346f3de5074bb2e4d47c7e36c (diff)
downloadcmake-8337ed0d731f869823efcacf2460a4efbf74a991.tar.gz
Ninja Multi-Config: Add variable to control aliases in build.ninja
Diffstat (limited to 'Help/generator')
-rw-r--r--Help/generator/Ninja Multi-Config.rst11
1 files changed, 10 insertions, 1 deletions
diff --git a/Help/generator/Ninja Multi-Config.rst b/Help/generator/Ninja Multi-Config.rst
index 248eb0534d..41cd5c26c4 100644
--- a/Help/generator/Ninja Multi-Config.rst
+++ b/Help/generator/Ninja Multi-Config.rst
@@ -78,4 +78,13 @@ targets built with the generated code.
As a convenience, ``Ninja Multi-Config`` offers a
:variable:`CMAKE_NINJA_MULTI_DEFAULT_BUILD_TYPE` setting. If this variable is
specified, a ``build.ninja`` file will be generated which points to the
-specified ``build-<Config>.ninja`` file.
+specified ``build-<Config>.ninja`` file. In addition, if
+:variable:`CMAKE_NINJA_MULTI_DEFAULT_BUILD_TYPE` is used in conjunction with
+:variable:`CMAKE_NINJA_MULTI_CROSS_CONFIG_ENABLE`, you can also specify
+:variable:`CMAKE_NINJA_MULTI_DEFAULT_BUILD_ALIAS`, which changes the config
+of the ``<target>`` targets in ``build.ninja``. For example, if you set
+:variable:`CMAKE_NINJA_MULTI_DEFAULT_BUILD_TYPE` to ``Release``, but set
+:variable:`CMAKE_NINJA_MULTI_DEFAULT_BUILD_ALIAS` to ``Debug`` or ``all``,
+all ``<target>`` aliases in ``build.ninja`` will resolve to ``<target>:Debug``
+or ``<target>:all``, but custom commands will still use the ``Release``
+configuration.