Describe the bug
The Windows build scripts hardcode Visual Studio 2022 Build Tools and a specific MSVC toolset version, so a machine with only Visual Studio 2026 (v18 / MSVC 14.51) installed cannot build OVMS.
Specifically:
windows_install_build_dependencies.bat, windows_build.bat, windows_setupvars.bat, and windows_test.bat hardcode C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools, the CMake generator string "Visual Studio 17 2022", and a pinned MSVC toolset version (14.44.35207).
- MSVC 14.51 (VS 2026) raises C5285 ("specializing
std::is_signed is forbidden") on TensorFlow/XLA's quantized-type specializations (xla/tsl/framework/type_traits.h). XLA builds with /WX, so it escalates to a fatal C2220 and the build aborts.
- The OpenCV dependency build hardcodes
-T v142 (VS 2019 toolset, absent on a VS 2026 box), and newer CMake (4.x) errors out in OpenCV's python auto-detection (find_package called with invalid argument "OFF").
- The
openvino dependency link uses mklink /d (symbolic link), which requires SeCreateSymbolicLinkPrivilege (admin / Developer Mode).
Expected behavior
The Windows build should auto-detect the installed Visual Studio edition and MSVC toolset (via vswhere) and build successfully on supported newer toolchains (VS 2022 through VS 2026), without requiring an elevated shell.
Environment
- OS: Windows 11
- Toolchain: Visual Studio 2026 (18.7), MSVC 14.51
- OVMS: 2026.3.0 (built from source)
Fix
Resolved by PR #4328 (vswhere auto-detection of VS edition/generator/toolset, /wd5285 for XLA, OpenCV toolset/python fixes, and mklink /j junction for non-elevated installs).
Describe the bug
The Windows build scripts hardcode Visual Studio 2022 Build Tools and a specific MSVC toolset version, so a machine with only Visual Studio 2026 (v18 / MSVC 14.51) installed cannot build OVMS.
Specifically:
windows_install_build_dependencies.bat,windows_build.bat,windows_setupvars.bat, andwindows_test.bathardcodeC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools, the CMake generator string"Visual Studio 17 2022", and a pinned MSVC toolset version (14.44.35207).std::is_signedis forbidden") on TensorFlow/XLA's quantized-type specializations (xla/tsl/framework/type_traits.h). XLA builds with/WX, so it escalates to a fatalC2220and the build aborts.-T v142(VS 2019 toolset, absent on a VS 2026 box), and newer CMake (4.x) errors out in OpenCV's python auto-detection (find_package called with invalid argument "OFF").openvinodependency link usesmklink /d(symbolic link), which requiresSeCreateSymbolicLinkPrivilege(admin / Developer Mode).Expected behavior
The Windows build should auto-detect the installed Visual Studio edition and MSVC toolset (via
vswhere) and build successfully on supported newer toolchains (VS 2022 through VS 2026), without requiring an elevated shell.Environment
Fix
Resolved by PR #4328 (vswhere auto-detection of VS edition/generator/toolset,
/wd5285for XLA, OpenCV toolset/python fixes, andmklink /jjunction for non-elevated installs).