microsoft / microsoft/BitNet

Building on Windows11 Failed with missing ClangCL

Open
#199 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
40.3k
Forks
3.7k
PR merge metrics
No merged PRs in 30d

Description

When I build by executing python setup_env.py -md models/BitNet-b1.58-2B-4T -q i2_s:

Project "E:\Bitnet\BitNet\build\CMakeFiles\4.0.0-rc2\VCTargetsPath.vcxproj" on node 1 (default targets).
C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\MSBuild\Microsoft\VC\v170\Microsoft.CppBuild.targets(456,5): error MSB8020: The build tools for ClangCL (Platform Toolset = 'ClangCL') cannot be found. To build using the ClangCL build tools, please install ClangCL build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution". [E:\Bitnet\BitNet\build\CMakeFiles\4.0.0-rc2\VCTargetsPath.vcxproj]
Done Building Project "E:\Bitnet\BitNet\build\CMakeFiles\4.0.0-rc2\VCTargetsPath.vcxproj" (default targets) -- FAILED.

I have installed Clang from official repository. And Clang-cl is in system PATH:

PS E:\Bitnet\BitNet> clang-cl.exe --version
clang version 20.1.3
Target: x86_64-pc-windows-msvc
Thread model: posix
InstalledDir: C:\Program Files\LLVM\bin

What should I do to continue the building process?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with setup_env.py and the CMake-generated VCTargetsPath.vcxproj referenced in the MSBuild error. Reproduce the command on Windows 11, inspect how the ClangCL toolset is selected, and verify the configured toolchain against clang-cl.exe --version. Done means the command completes without the missing ClangCL build-tools error.

Written by the indexing model from the issue text.

Assessment

Tech stack
cmake, cpp, python
Domain
build-system, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.