Closed
Description
Describe the bug
Windows 11
Visual Studio 17.10.1
Conan version 2.3.2
vcvars
is not sourced correctly resulting in some libraries failing to build
How to reproduce it
I have a profile as follows:
[settings]
os=Windows
arch=x86_64
build_type=Debug
compiler=clang
compiler.version=17
compiler.runtime=dynamic
compiler.runtime_type=Debug
compiler.runtime_version=v143
[conf]
tools.cmake.cmaketoolchain:generator=Ninja Multi-Config
all recipes show the following:
conanvcvars.bat: Activating environment Visual Studio 17 - amd64 - winsdk_version=None - vcvars_ver=14.3
[ERROR:vcvars.bat] Toolset directory for version '14.3' was not found.
[ERROR:VsDevCmd.bat] *** VsDevCmd.bat encountered errors. Environment may be incomplete and/or incorrect. ***
[ERROR:VsDevCmd.bat] In an uninitialized command prompt, please 'set VSCMD_DEBUG=[value]' and then re-run
[ERROR:VsDevCmd.bat] vsdevcmd.bat [args] for additional details.
[ERROR:VsDevCmd.bat] Where [value] is:
[ERROR:VsDevCmd.bat] 1 : basic debug logging
[ERROR:VsDevCmd.bat] 2 : detailed debug logging
[ERROR:VsDevCmd.bat] 3 : trace level logging. Redirection of output to a file when using this level is recommended.
[ERROR:VsDevCmd.bat] Example: set VSCMD_DEBUG=3
[ERROR:VsDevCmd.bat] vsdevcmd.bat > vsdevcmd.trace.txt 2>&1
and some decide to die right after (e.g. libjpeg-turbo
)
I can see in the code that v143 is mapped to vcvars_ver=14.3
:
conan/conan/tools/microsoft/visual.py
Lines 133 to 136 in 5abec94
However, when using 17.10, the 14.3
tools are wiped by the VS installer. In light of this bug and work I've been doing lately around VS, I express desire for:
- a way to specify the vcvars_version
- a way to pass a different setup script entirely (ties back into [feature] More customization options for Platform and PlatformToolset in MSBuildToolchain #16276)
Metadata
Metadata
Assignees
Labels
No labels