earendil-works/pi · error
Microsoft C++ Build Tools not found. Install the Visual Stud
Error message
Microsoft C++ Build Tools not found. Install the Visual Studio C++ workload or set PI_TUI_WIN32_TOOLCHAIN=mingw.
What it means
Error "Microsoft C++ Build Tools not found. Install the Visual Studio C++ workload or set PI_TUI_WIN32_TOOLCHAIN=mingw." thrown in earendil-works/pi.
Source
Thrown at packages/tui/native/win32/build.mjs:224
PI_TUI_WIN32_TOOLCHAIN=msvc|mingw
CC_X64=/path/to/x86_64-w64-mingw32-gcc
CC_ARM64=/path/to/aarch64-w64-mingw32-gcc
CC=/path/to/clang`);
process.exit(0);
}
const requestedToolchain = process.env.PI_TUI_WIN32_TOOLCHAIN;
if (requestedToolchain && requestedToolchain !== "msvc" && requestedToolchain !== "mingw") {
throw new Error("PI_TUI_WIN32_TOOLCHAIN must be either 'msvc' or 'mingw'");
}
const vsDevCmd = findVisualStudioDevCmd();
const hasMsvc = vsDevCmd ? canUseMsvc(vsDevCmd) : false;
const toolchain = requestedToolchain ?? (process.platform === "win32" && vsDevCmd ? "msvc" : "mingw");
if (toolchain === "msvc") {
if (!vsDevCmd || !hasMsvc) {
throw new Error("Microsoft C++ Build Tools not found. Install the Visual Studio C++ workload or set PI_TUI_WIN32_TOOLCHAIN=mingw.");
}
for (const target of targets) buildWithMsvc(target, vsDevCmd);
} else {
for (const target of targets) buildWithMingw(target);
}
View on GitHub (pinned to 4af9d21d3b)
Solutions
- Install the Visual Studio C++ workload, or set PI_TUI_WIN32_TOOLCHAIN=mingw.
When it happens
Trigger: Thrown at packages/tui/native/win32/build.mjs:224 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of earendil-works/pi@4af9d21d3b (2026-08-24).
Data as JSON: /api/errors/dce964e03c72d57a.
Report an issue: GitHub.