diff options
author | Jan Holthuis <jan.holthuis@ruhr-uni-bochum.de> | 2021-03-18 21:29:00 +0100 |
---|---|---|
committer | Jan Holthuis <jan.holthuis@ruhr-uni-bochum.de> | 2021-03-18 21:31:22 +0100 |
commit | 6c4fa4055d1acea5f28c9e1c3ace810b7ac8266e (patch) | |
tree | 24ef1caf051c1d88b160658e4aeda39409e82ce5 /cmake | |
parent | bd9e196c9bd032a7633d8f20326097acf210b645 (diff) |
CMake: Explain difference between default_option and cmake_dependent_option
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/modules/DefaultOption.cmake | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cmake/modules/DefaultOption.cmake b/cmake/modules/DefaultOption.cmake index b8cc640d05..c9c0b6d134 100644 --- a/cmake/modules/DefaultOption.cmake +++ b/cmake/modules/DefaultOption.cmake @@ -24,6 +24,10 @@ Example invocation: If ``USE_BAR`` is true and ``USE_ZOT`` is false, the option called ``USE_FOO`` will default to ``ON``, otherwise it will default to ``OFF``. + +In contrast to ``cmake_dependent_option`` which disables the option completely +if the ``<depends>`` condition evaluates to false, ``default_option`` will only +set a default and the value may be overridden by the user. #]=======================================================================] macro(DEFAULT_OPTION option doc depends) |