summaryrefslogtreecommitdiffstats
path: root/Help
diff options
context:
space:
mode:
authorMarc Chevrier <marc.chevrier@gmail.com>2020-04-05 15:21:57 (GMT)
committerMarc Chevrier <marc.chevrier@gmail.com>2020-04-19 13:04:54 (GMT)
commit3fdae5acaaa7ef29e8776e4dccde6102016624f6 (patch)
treef47d16339bdf750c80eae9200d2ddf1a7ab84153 /Help
parent38332fc4facce48d6eaefdf55886a3e1eb85e659 (diff)
downloadCMake-3fdae5acaaa7ef29e8776e4dccde6102016624f6.zip
CMake-3fdae5acaaa7ef29e8776e4dccde6102016624f6.tar.gz
CMake-3fdae5acaaa7ef29e8776e4dccde6102016624f6.tar.bz2
Genex: Add generator expressions $<DEVICE_LINK> and $<HOST_LINK>
These generator expressions can only be used in link options properties. These expressions return the arguments respectively for device and host link step, otherwise return an empty string.
Diffstat (limited to 'Help')
-rw-r--r--Help/manual/cmake-generator-expressions.7.rst12
-rw-r--r--Help/release/dev/genex-DEVICE_LINK-HOST_LINK.rst6
2 files changed, 18 insertions, 0 deletions
diff --git a/Help/manual/cmake-generator-expressions.7.rst b/Help/manual/cmake-generator-expressions.7.rst
index 72de4ac..9e411a4 100644
--- a/Help/manual/cmake-generator-expressions.7.rst
+++ b/Help/manual/cmake-generator-expressions.7.rst
@@ -362,6 +362,18 @@ Variable Queries
evaluation will give ``C`` as link language, so the second pass will
correctly add target ``libother`` as link dependency.
+``$<DEVICE_LINK:list>``
+ Returns the list if it is the device link step, an empty list otherwise.
+ The device link step is controlled by :prop_tgt:`CUDA_SEPARABLE_COMPILATION`
+ and :prop_tgt:`CUDA_RESOLVE_DEVICE_SYMBOLS` properties. This expression can
+ only be used to specify link options.
+
+``$<HOST_LINK:list>``
+ Returns the list if it is the normal link step, an empty list otherwise.
+ This expression is mainly useful when a device link step is also involved
+ (see ``$<DEVICE_LINK:list>`` generator expression). This expression can only
+ be used to specify link options.
+
String-Valued Generator Expressions
===================================
diff --git a/Help/release/dev/genex-DEVICE_LINK-HOST_LINK.rst b/Help/release/dev/genex-DEVICE_LINK-HOST_LINK.rst
new file mode 100644
index 0000000..ef275e7
--- /dev/null
+++ b/Help/release/dev/genex-DEVICE_LINK-HOST_LINK.rst
@@ -0,0 +1,6 @@
+genex-DEVICE_LINK-HOST_LINK
+---------------------------
+
+* To manage device and host link steps, the ``$<DEVICE_LINK:...>`` and
+ ``$<HOST_LINK:...>``
+ :manual:`generator expressions <cmake-generator-expressions(7)>` were added.