Commit dcdeade5 authored by Brad King's avatar Brad King Committed by Kitware Robot

Merge topic 'msvc-runtime-library-doc'

282d9f31 MSVC: Document behavior when MSVC_RUNTIME_LIBRARY is not set
Acked-by: Kitware Robot's avatarKitware Robot <kwrobot@kitware.com>
Merge-request: !3573
parents 6618cbf3 282d9f31
......@@ -20,7 +20,9 @@ CMake 3.15 and above prefer to leave the MSVC runtime library selection flags
out of the default :variable:`CMAKE_<LANG>_FLAGS_<CONFIG>` values and instead
offer a first-class abstraction. The :variable:`CMAKE_MSVC_RUNTIME_LIBRARY`
variable and :prop_tgt:`MSVC_RUNTIME_LIBRARY` target property may be set to
select the MSVC runtime library.
select the MSVC runtime library. If they are not set then CMake uses the
default value ``MultiThreaded$<$<CONFIG:Debug>:Debug>DLL`` which is
equivalent to the original flags.
This policy provides compatibility with projects that have not been updated
to be aware of the abstraction. The policy setting takes effect as of the
......
......@@ -19,6 +19,9 @@ support per-configuration specification. For example, the code:
selects for the target ``foo`` a multi-threaded statically-linked runtime
library with or without debug information depending on the configuration.
If this property is not set then CMake uses the default value
``MultiThreaded$<$<CONFIG:Debug>:Debug>DLL`` to select a MSVC runtime library.
.. note::
This property has effect only when policy :policy:`CMP0091` is set to ``NEW``
......
......@@ -20,6 +20,11 @@ support per-configuration specification. For example, the code:
selects for all following targets a multi-threaded statically-linked runtime
library with or without debug information depending on the configuration.
If this variable is not set then the :prop_tgt:`MSVC_RUNTIME_LIBRARY` target
property will not be set automatically. If that property is not set then
CMake uses the default value ``MultiThreaded$<$<CONFIG:Debug>:Debug>DLL``
to select a MSVC runtime library.
.. note::
This variable has effect only when policy :policy:`CMP0091` is set to ``NEW``
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment