mirror of
https://github.com/reactos/CMake.git
synced 2025-02-12 14:58:45 +00:00
Help: Document target_precompile_headers genex with angle brackets
When passing a `<header>` inside a generator expression, the closing `>` needs to be encoded as `$<ANGLE-R>`. Add an example to the docs. Fixes: #19940
This commit is contained in:
parent
c1d5d5eb11
commit
f35df783b5
@ -79,6 +79,17 @@ must be available for the compiler to find them. Other header file names
|
||||
source directory (e.g. :variable:`CMAKE_CURRENT_SOURCE_DIR`) and will be
|
||||
included by absolute path.
|
||||
|
||||
When specifying angle brackets inside a :manual:`generator expression
|
||||
<cmake-generator-expressions(7)>`, be sure to encode the closing ``>``
|
||||
as ``$<ANGLE-R>``. For example:
|
||||
|
||||
.. code-block:: cmake
|
||||
|
||||
target_precompile_headers(mylib PRIVATE
|
||||
"$<$<COMPILE_LANGUAGE:C>:<stddef.h$<ANGLE-R>>"
|
||||
"$<$<COMPILE_LANGUAGE:CXX>:<cstddef$<ANGLE-R>>"
|
||||
)
|
||||
|
||||
See Also
|
||||
^^^^^^^^
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user