VS_SETTINGS.rst 636 B

12345678910111213141516171819202122232425
  1. VS_SETTINGS
  2. -----------
  3. .. versionadded:: 3.18
  4. Set any item metadata on a file.
  5. .. versionadded:: 3.22
  6. This property is honored for all source file types.
  7. Previously it worked only for non-built files.
  8. Takes a list of ``Key=Value`` pairs. Tells the Visual Studio generator to set
  9. ``Key`` to ``Value`` as item metadata on the file.
  10. For example:
  11. .. code-block:: cmake
  12. set_property(SOURCE file.hlsl PROPERTY VS_SETTINGS "Key=Value" "Key2=Value2")
  13. will set ``Key`` to ``Value`` and ``Key2`` to ``Value2`` on the
  14. ``file.hlsl`` item as metadata.
  15. :manual:`Generator expressions <cmake-generator-expressions(7)>` are supported.