-
-
Notifications
You must be signed in to change notification settings - Fork 34.4k
Description
Situation
Starting with Node.js 24, ClangCL is required to compile on Windows. (see BUILDING.md).
When executing .\vcbuild on Windows in v24.x and higher branches, if Visual Studio is installed without ClangCL, then the logs can be misinterpreted:
Using ClangCL because the Node.js version being compiled is >= 24.
Looking for Visual Studio 2026
Looking for Visual Studio 2022
Failed to find a suitable Visual Studio installation or Clang compiler/LLVM toolset.
"Using ClangCL" sounds as though ClangGL has been found and then combined with the other lines it sounds like Visual Studio wasn't found. In fact Visual Studio was found and it is just ClangCL that is missing.
Steps to reproduce
-
Remove any existing Visual Studio installations. Install Visual Studio Build Tools 2026 (v18)
https://aka.ms/vs/stable/vs_buildtools.exe with workload "Desktop development with C++" -
Install other prerequisites for Windows as described in BUILDING.md
In PowerShell on Windows 11 25H2:
git clone https://github.com/nodejs/node.git
cd node
git checkout main # if already cloned
.\vcbuildLogs
.\vcbuild
Looking for Python
Python found in C:\Users\mikem\AppData\Local\Microsoft\WindowsApps\\python.exe
Python 3.14.2
Looking for NASM
Using ClangCL because the Node.js version being compiled is >= 24.
Looking for Visual Studio 2026
Looking for Visual Studio 2022
Failed to find a suitable Visual Studio installation or Clang compiler/LLVM toolset.
Try to run in a "Developer Command Prompt" or consult
https://github.com/nodejs/node/blob/HEAD/BUILDING.md#windows
Suggestion
In vcbuild.bat:
- Change the text from "Using ClangCL ..." to "ClangCL is required because the Node.js version being compiled is >= 24." or similar.
Line 249 in 57a71cd
| echo Using ClangCL because the Node.js version being compiled is ^>= 24. |
- Change "Failed to find a suitable Visual Studio installation or Clang compiler/LLVM toolset." to
"Failed to find a suitable Visual Studio installation with Clang compiler/LLVM toolset.". In other words, change "or" to "with".
Line 327 in 57a71cd
| if defined clang_cl set "clang_echo= or Clang compiler/LLVM toolset" |