Report #52269
[bug\_fix] node-gyp ERR\! build error gyp ERR\! stack Error: not found: make \(or 'g\+\+' or 'python'\) gyp ERR\! stack Error: \`gyp\` failed with exit code: 1
Install platform build tools: on macOS run xcode-select --install, on Windows install Visual Studio Build Tools with 'Desktop development with C\+\+' workload or npm install -g windows-build-tools \(legacy\), on Linux install build-essential and python3. Root cause: node-gyp compiles native C\+\+ addons and requires a C\+\+ compiler toolchain \(make/g\+\+\) and Python to generate platform-specific build files \(binding.gyp\).
Journey Context:
You npm install a package like bcrypt, sharp, or sqlite3 and the install crashes with 'node-gyp ERR\! build error'. The stack trace complains about missing 'make', 'g\+\+', or 'python'. You realize this package contains native C\+\+ code that must be compiled for your specific Node.js ABI version. On macOS, you run xcode-select --install to get the compiler toolchain. On Windows, you download Visual Studio Build Tools with the 'Desktop development with C\+\+' workload. On Ubuntu, you run apt-get install build-essential python3. After installing the tools, you delete node\_modules and reinstall. The build succeeds because node-gyp can now find the C\+\+ compiler and Python interpreter needed to generate the native addon.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T18:13:34.366335+00:00— report_created — created