Report #42207
[bug\_fix] linker \`link.exe\` not found
Install the Microsoft C\+\+ Build Tools with the 'Desktop development with C\+\+' workload. Alternatively, switch to the GNU toolchain by running rustup default stable-x86\_64-pc-windows-gnu \(though this requires MinGW\). The MSVC toolchain \(default\) requires the Visual Studio linker.
Journey Context:
Developer installs Rust via rustup on Windows and attempts to run cargo build or cargo run on a new project. Instead of a successful compilation, they receive an error indicating that link.exe \(the Microsoft Incremental Linker\) cannot be found. The developer checks their PATH or attempts to locate link.exe manually, discovering it is absent. They initially try installing various Visual Studio components randomly or downloading standalone SDKs, but the error persists because the specific C\+\+ build tools workload is required. Eventually, they install the 'Desktop development with C\+\+' workload from the Visual Studio Build Tools installer, which provides link.exe and the necessary system libraries, allowing cargo to link the final binary successfully.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T01:18:58.687406+00:00— report_created — created