summaryrefslogtreecommitdiffstats
path: root/Help
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2021-06-09 12:05:15 (GMT)
committerKitware Robot <kwrobot@kitware.com>2021-06-09 12:05:21 (GMT)
commitfee0619e7c7e01324813ad447872b2da90f2f9e6 (patch)
treed9b1fddef099b42a268a6e6cede4b48c9d97e129 /Help
parent5c18c8a178c2504975760d6c52d71a2a32774159 (diff)
parentb00512e6929c046ff472563cf1d0407149c51bb7 (diff)
downloadCMake-fee0619e7c7e01324813ad447872b2da90f2f9e6.zip
CMake-fee0619e7c7e01324813ad447872b2da90f2f9e6.tar.gz
CMake-fee0619e7c7e01324813ad447872b2da90f2f9e6.tar.bz2
Merge topic 'help-presets'
b00512e692 Help: presets: add note for ExternalProject users with env vars Acked-by: Kitware Robot <kwrobot@kitware.com> Acked-by: Kyle Edwards <kyle.edwards@kitware.com> Merge-request: !6201
Diffstat (limited to 'Help')
-rw-r--r--Help/manual/cmake-presets.7.rst13
1 files changed, 13 insertions, 0 deletions
diff --git a/Help/manual/cmake-presets.7.rst b/Help/manual/cmake-presets.7.rst
index 0bcd691..db26b5a 100644
--- a/Help/manual/cmake-presets.7.rst
+++ b/Help/manual/cmake-presets.7.rst
@@ -401,6 +401,19 @@ that may contain the following fields:
are applied. Setting a variable to ``null`` causes it to not be set,
even if a value was inherited from another preset.
+ .. note::
+
+ For a CMake project using ExternalProject with a configuration preset
+ having environment variables needed in the ExternalProject, use a build
+ preset that inherits that configuration preset or the ExternalProject
+ will not have the environment variables set in the configuration preset.
+ Example: suppose the host defaults to one compiler (say Clang)
+ and the user wishes to use another compiler (say GCC). Set configuration
+ preset environment variables ``CC`` and ``CXX`` and use a build preset
+ that inherits that configuration preset. Otherwise the ExternalProject
+ may use a different (system default) compiler than the top-level CMake
+ project.
+
``configurePreset``
An optional string specifying the name of a configure preset to