CMP0038.rst 690 B

123456789101112131415161718
  1. CMP0038
  2. -------
  3. Targets may not link directly to themselves.
  4. CMake 2.8.12 and lower allowed a build target to link to itself directly with
  5. a :command:`target_link_libraries` call. This is an indicator of a bug in
  6. user code.
  7. The ``OLD`` behavior for this policy is to ignore targets which list themselves
  8. in their own link implementation. The ``NEW`` behavior for this policy is to
  9. report an error if a target attempts to link to itself.
  10. This policy was introduced in CMake version 3.0. CMake version
  11. |release| warns when the policy is not set and uses ``OLD`` behavior. Use
  12. the :command:`cmake_policy` command to set it to ``OLD`` or ``NEW`` explicitly.
  13. .. include:: DEPRECATED.txt