Help: CMAKE_POSITION_INDEPENDENT_CODE is ignored for some targets

SHARED and MODULE library targets have
POSITION_INDEPENDENT_CODE default to TRUE regardless of
CMAKE_POSITION_INDEPENDENT_CODE.
This commit is contained in:
Andreas Hartmetz
2024-09-09 16:28:29 +02:00
parent 7e1a0739db
commit a6315790a1
2 changed files with 6 additions and 6 deletions
@@ -4,6 +4,6 @@ CMAKE_POSITION_INDEPENDENT_CODE
Default value for :prop_tgt:`POSITION_INDEPENDENT_CODE` of targets.
This variable is used to initialize the
:prop_tgt:`POSITION_INDEPENDENT_CODE` property on all the targets.
See that target property for additional information. If set, its
value is also used by the :command:`try_compile` command.
:prop_tgt:`POSITION_INDEPENDENT_CODE` property on targets that
are not ``SHARED`` or ``MODULE`` library targets.
If set, its value is also used by the :command:`try_compile` command.