diff options
author | Joachim Wuttke (h) <j.wuttke@fz-juelich.de> | 2018-11-04 14:48:02 (GMT) |
---|---|---|
committer | Joachim Wuttke (o) <j.wuttke@fz-juelich.de> | 2018-11-06 11:55:23 (GMT) |
commit | fe8acf7c0540ca39300bab5b014e428e84077c7a (patch) | |
tree | d9c174bae2c2fcc86030c95933c582e350ab621a /Help | |
parent | 9891adf74becfa95463f6928fda9f8ac17c934bd (diff) | |
download | CMake-fe8acf7c0540ca39300bab5b014e428e84077c7a.zip CMake-fe8acf7c0540ca39300bab5b014e428e84077c7a.tar.gz CMake-fe8acf7c0540ca39300bab5b014e428e84077c7a.tar.bz2 |
Help: 3 subtypes of boolean generator expressions.
Main classification by return type,
subclassification by dependences
Diffstat (limited to 'Help')
-rw-r--r-- | Help/manual/cmake-generator-expressions.7.rst | 30 |
1 files changed, 20 insertions, 10 deletions
diff --git a/Help/manual/cmake-generator-expressions.7.rst b/Help/manual/cmake-generator-expressions.7.rst index 1c3d3fc..099d398 100644 --- a/Help/manual/cmake-generator-expressions.7.rst +++ b/Help/manual/cmake-generator-expressions.7.rst @@ -63,6 +63,9 @@ They are typically used to construct the condition in a Available boolean expressions are: +Logical Operators +----------------- + ``$<BOOL:condition>`` ``1`` if the ``condition`` is true, else ``0`` @@ -79,12 +82,29 @@ Available boolean expressions are: ``$<NOT:condition>`` ``0`` if ``condition`` is ``1``, else ``1`` +String Comparisons +------------------ + ``$<STREQUAL:a,b>`` ``1`` if ``a`` is STREQUAL ``b``, else ``0`` ``$<EQUAL:a,b>`` ``1`` if ``a`` is EQUAL ``b`` in a numeric comparison, else ``0`` ``$<IN_LIST:a,b>`` ``1`` if ``a`` is IN_LIST ``b``, else ``0`` +``$<VERSION_LESS:v1,v2>`` + ``1`` if ``v1`` is a version less than ``v2``, else ``0``. +``$<VERSION_GREATER:v1,v2>`` + ``1`` if ``v1`` is a version greater than ``v2``, else ``0``. +``$<VERSION_EQUAL:v1,v2>`` + ``1`` if ``v1`` is the same version as ``v2``, else ``0``. +``$<VERSION_LESS_EQUAL:v1,v2>`` + ``1`` if ``v1`` is a version less than or equal to ``v2``, else ``0``. +``$<VERSION_GREATER_EQUAL:v1,v2>`` + ``1`` if ``v1`` is a version greater than or equal to ``v2``, else ``0``. + +Variable Queries +---------------- + ``$<TARGET_EXISTS:target>`` ``1`` if ``target`` exists, else ``0``. ``$<CONFIG:cfg>`` @@ -104,16 +124,6 @@ Available boolean expressions are: ``1`` if the CMake-id of the CXX compiler matches ``compiler_id``, otherwise ``0``. See also the :variable:`CMAKE_<LANG>_COMPILER_ID` variable. -``$<VERSION_LESS:v1,v2>`` - ``1`` if ``v1`` is a version less than ``v2``, else ``0``. -``$<VERSION_GREATER:v1,v2>`` - ``1`` if ``v1`` is a version greater than ``v2``, else ``0``. -``$<VERSION_EQUAL:v1,v2>`` - ``1`` if ``v1`` is the same version as ``v2``, else ``0``. -``$<VERSION_LESS_EQUAL:v1,v2>`` - ``1`` if ``v1`` is a version less than or equal to ``v2``, else ``0``. -``$<VERSION_GREATER_EQUAL:v1,v2>`` - ``1`` if ``v1`` is a version greater than or equal to ``v2``, else ``0``. ``$<C_COMPILER_VERSION:version>`` ``1`` if the version of the C compiler matches ``version``, otherwise ``0``. See also the :variable:`CMAKE_<LANG>_COMPILER_VERSION` variable. |