Skip to content

Sharp's node-gyp & node-addon-api dependencies #524

@kadams54

Description

@kadams54
  • node: 24.7.0 (via asdf)
  • npm: 11.5.1 (via asdf)
  • macOS: 26.4.1

When I try to run npm install on a fresh clone/fork of the repo, I get the following error:

❯ npm install
npm warn deprecated node-domexception@1.0.0: Use your platform's native DOMException instead
npm warn deprecated glob@9.3.5: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me
npm warn deprecated glob@10.5.0: Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me
npm error code 1
npm error path /Users/kyleadams/Code/companycam/background-agents/node_modules/sharp
npm error command failed
npm error command sh -c node install/check.js || npm run build
npm error > sharp@0.34.5 build
npm error > node install/build.js
npm error
npm error sharp: Attempting to build from source via node-gyp
npm error sharp: See https://sharp.pixelplumbing.com/install#building-from-source
npm error sharp: Please add node-addon-api to your dependencies
npm error A complete log of this run can be found in: 

2026-04-21T17_14_42_443Z-debug-0.log

I can provide the full log if needed. I added node-gyp and node-addon-apis as dev dependencies and that cleared up my build issues:

npm add -D node-gyp node-addon-api

I'm happy to submit a PR with the correct fix, whether that's explicitly adding those dependencies as above or some other route.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions