Report #104583
[bug\_fix] node-gyp: gyp ERR\! stack Error: not found: make
Install build tools: on macOS, \`xcode-select --install\`; on Ubuntu/Debian, \`sudo apt-get install build-essential\`; on Fedora, \`sudo dnf groupinstall 'Development Tools'\`. Root cause: node-gyp requires \`make\` and a C\+\+ compiler \(like gcc or clang\) which are not pre-installed on minimal Linux or fresh macOS systems.
Journey Context:
A developer set up a new Ubuntu 22.04 VM to run a Node.js app that uses \`sharp\` \(an image processing library\). Running \`npm install\` failed with \`gyp ERR\! stack Error: not found: make\`. The developer assumed it was a Node.js version issue, so they tried Node 14, 16, and 18 via nvm — same error. They then checked if \`make\` was installed with \`which make\` — empty output. They ran \`sudo apt-get install build-essential\`, which installed \`make\`, \`gcc\`, \`g\+\+\`, and other tools. After that, \`npm install\` succeeded. The real root cause: \`sharp\` uses node-gyp to compile native C\+\+ code \(libvips\), and Ubuntu's minimal install does not include the \`build-essential\` metapackage. The fix worked because it provided the \`make\` command and C\+\+ compiler that node-gyp needs to run the build scripts.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-09-06T20:08:25.605026+00:00— report_created — created