diff options
author | Brad King <brad.king@kitware.com> | 2022-11-15 15:53:49 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2022-11-17 12:57:21 (GMT) |
commit | 8437141b53919619f6d21f5f446d26df42373c68 (patch) | |
tree | 025fe7b9aea2bbdd4504304463ea7299bd4b4d9f /Help/manual | |
parent | d22a225251ebc10323e934a8790984dcbbb9b18a (diff) | |
download | CMake-8437141b53919619f6d21f5f446d26df42373c68.zip CMake-8437141b53919619f6d21f5f446d26df42373c68.tar.gz CMake-8437141b53919619f6d21f5f446d26df42373c68.tar.bz2 |
Genex: Fix TARGET_PROPERTY lookup scope in transitive usage requirements
When `$<TARGET_PROPERTY:tgt,prop>` is used in an `INTERFACE_*` target
property for usage requirements, it may be evaluated in the context of a
dependent target in another directory. Look up the `tgt` name in the
directory of the target whose property holds the expression so that
imported targets isolated to that directory are visible.
Fixes: #24163
Diffstat (limited to 'Help/manual')
-rw-r--r-- | Help/manual/cmake-generator-expressions.7.rst | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Help/manual/cmake-generator-expressions.7.rst b/Help/manual/cmake-generator-expressions.7.rst index faa793f..eb57b1e 100644 --- a/Help/manual/cmake-generator-expressions.7.rst +++ b/Help/manual/cmake-generator-expressions.7.rst @@ -1401,6 +1401,13 @@ In the following, the phrase "the ``tgt`` filename" means the name of the Note that ``tgt`` is not added as a dependency of the target this expression is evaluated on. + .. versionchanged:: 3.26 + When encountered during evaluation of :ref:`Target Usage Requirements`, + typically in an ``INTERFACE_*`` target property, lookup of the ``tgt`` + name occurs in the directory of the target specifying the requirement, + rather than the directory of the consuming target for which the + expression is being evaluated. + .. genex:: $<TARGET_PROPERTY:prop> Value of the property ``prop`` on the target for which the expression |