INTERFACE_LINK_LIBRARIES.rst 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. INTERFACE_LINK_LIBRARIES
  2. ------------------------
  3. List public interface libraries for a library.
  4. This property contains the list of transitive link dependencies. When
  5. the target is linked into another target using the
  6. :command:`target_link_libraries` command, the libraries listed (and
  7. recursively their link interface libraries) will be provided to the
  8. other target also. This property is overridden by the
  9. :prop_tgt:`LINK_INTERFACE_LIBRARIES` or
  10. :prop_tgt:`LINK_INTERFACE_LIBRARIES_<CONFIG>` property if policy
  11. :policy:`CMP0022` is ``OLD`` or unset.
  12. The value of this property is used by the generators when constructing
  13. the link rule for a dependent target. A dependent target's direct
  14. link dependencies, specified by its :prop_tgt:`LINK_LIBRARIES` target
  15. property, are linked first, followed by indirect dependencies from the
  16. transitive closure of the direct dependencies'
  17. ``INTERFACE_LINK_LIBRARIES`` properties. See policy :policy:`CMP0022`.
  18. Contents of ``INTERFACE_LINK_LIBRARIES`` may use "generator expressions"
  19. with the syntax ``$<...>``. See the :manual:`cmake-generator-expressions(7)`
  20. manual for available expressions. See the :manual:`cmake-buildsystem(7)`
  21. manual for more on defining buildsystem properties.
  22. .. include:: LINK_LIBRARIES_INDIRECTION.txt
  23. ``INTERFACE_LINK_LIBRARIES`` adds transitive link dependencies for a
  24. target's dependents. In advanced use cases, one may update the
  25. direct link dependencies of a target's dependents by using the
  26. :prop_tgt:`INTERFACE_LINK_LIBRARIES_DIRECT` and
  27. :prop_tgt:`INTERFACE_LINK_LIBRARIES_DIRECT_EXCLUDE` target properties.
  28. Creating Relocatable Packages
  29. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  30. .. |INTERFACE_PROPERTY_LINK| replace:: ``INTERFACE_LINK_LIBRARIES``
  31. .. include:: /include/INTERFACE_LINK_LIBRARIES_WARNING.txt