Skip to content

Commit bda5355

Browse files
memshardedAbrilRBS
andauthored
improve msvc versions description (#4150)
* improve msvc versions description * Update reference/config_files/settings.rst --------- Co-authored-by: Abril Rincón Blanco <[email protected]>
1 parent 57b0a8a commit bda5355

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

reference/config_files/settings.rst

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -209,19 +209,22 @@ Some notes about different compilers:
209209
msvc
210210
++++
211211

212-
- It uses the compiler version, that is 190 (19.0), 191 (19.1), etc, instead of the Visual Studio IDE (15, 16, etc).
213-
- It is only used by the new build integrations in :ref:`conan_tools_cmake` and :ref:`conan_tools_microsoft`,
214-
but not the previous ones.
212+
The ``msvc`` compiler setting uses the actual ``cl.exe`` compiler version, that is 190 (19.0), 191 (19.1), etc, instead of the Visual Studio IDE version(15, 16, etc).
215213

216214
When using the ``msvc`` compiler, the Visual Studio toolset version (the actual ``vcvars`` activation
217215
and ``MSBuild`` location) will be defined by the default provided by that compiler version:
218216

219-
- ``msvc`` compiler version '190': Visual Studio 14 2015
220-
- ``msvc`` compiler version '191': Visual Studio 15 2017
221-
- ``msvc`` compiler version '192': Visual Studio 16 2019
222-
- ``msvc`` compiler version '193': Visual Studio 17 2022
217+
- ``msvc`` compiler version '190': Visual Studio 14 2015 (toolset v140)
218+
- ``msvc`` compiler version '191': Visual Studio 15 2017 (toolset v141)
219+
- ``msvc`` compiler version '192': Visual Studio 16 2019 (toolset v142)
220+
- ``msvc`` compiler version '193': Visual Studio 17 2022 (toolset v143, compiler versions up to 19.39, toolset version 14.3X)
221+
- ``msvc`` compiler version '194': Visual Studio 17 2022 (toolset v143, compiler versions from 19.40, toolset version 14.4X, Visual Studio update 17.10)
223222

224-
This can be configured in your profiles with the ``tools.microsoft.msbuild:vs_version`` configuration:
223+
Note that both ``compiler.version=193`` and ``compiler.version=194`` map to the ``v143`` toolset, but to different toolset versions ``14.3X``
224+
and ``14.4X``, due to the versioning scheme change done from Visual Studio update 17.10 that introduced compiler version 19.40 and toolset version 14.40
225+
while keeping the toolset ``v143`` nomenclature.
226+
227+
If you want to explicitly force a specific Visual Studio IDE version, you can do it with the ``tools.microsoft.msbuild:vs_version`` configuration:
225228

226229
.. code-block:: text
227230
@@ -247,7 +250,6 @@ control is desired, you can just add the ``update`` part to your profiles:
247250
compiler.version=191
248251
compiler.update=3
249252
250-
251253
This will be equivalent to the full version ``1913 (19.13)``. If even further details are desired, you could even add your own digits
252254
to the ``update`` subsetting in ``settings.yml``.
253255

0 commit comments

Comments
 (0)