Closed will-holley closed 3 months ago
Running npm install, I get
npm install
▶ npm install npm ERR! code 1 npm ERR! path /Users/will/Code/rxc/rxc-www/node_modules/sharp npm ERR! command failed npm ERR! command sh -c node-gyp rebuild npm ERR! CC(target) Release/obj.target/nothing/../node-addon-api/nothing.o npm ERR! LIBTOOL-STATIC Release/nothing.a npm ERR! TOUCH Release/obj.target/libvips-cpp.stamp npm ERR! CXX(target) Release/obj.target/sharp/src/common.o npm ERR! gyp info it worked if it ends with ok npm ERR! gyp info using node-gyp@7.1.2 npm ERR! gyp info using node@16.6.0 | darwin | x64 npm ERR! gyp info find Python using Python version 3.9.5 found at "/Users/will/.pyenv/versions/3.9.5/bin/python3" npm ERR! (node:12450) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only. npm ERR! (Use `node --trace-deprecation ...` to show where the warning was created) npm ERR! gyp info spawn /Users/will/.pyenv/versions/3.9.5/bin/python3 npm ERR! gyp info spawn args [ npm ERR! gyp info spawn args '/Users/will/.nvm/versions/node/v16.6.0/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py', npm ERR! gyp info spawn args 'binding.gyp', npm ERR! gyp info spawn args '-f', npm ERR! gyp info spawn args 'make', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/Users/will/Code/rxc/rxc-www/node_modules/sharp/build/config.gypi', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/Users/will/.nvm/versions/node/v16.6.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi', npm ERR! gyp info spawn args '-I', npm ERR! gyp info spawn args '/Users/will/Library/Caches/node-gyp/16.6.0/include/node/common.gypi', npm ERR! gyp info spawn args '-Dlibrary=shared_library', npm ERR! gyp info spawn args '-Dvisibility=default', npm ERR! gyp info spawn args '-Dnode_root_dir=/Users/will/Library/Caches/node-gyp/16.6.0', npm ERR! gyp info spawn args '-Dnode_gyp_dir=/Users/will/.nvm/versions/node/v16.6.0/lib/node_modules/npm/node_modules/node-gyp', npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/will/Library/Caches/node-gyp/16.6.0/<(target_arch)/node.lib', npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/will/Code/rxc/rxc-www/node_modules/sharp', npm ERR! gyp info spawn args '-Dnode_engine=v8', npm ERR! gyp info spawn args '--depth=.', npm ERR! gyp info spawn args '--no-parallel', npm ERR! gyp info spawn args '--generator-output', npm ERR! gyp info spawn args 'build', npm ERR! gyp info spawn args '-Goutput_dir=.' npm ERR! gyp info spawn args ] npm ERR! gyp info spawn make npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ] npm ERR! warning: /Library/Developer/CommandLineTools/usr/bin/libtool: archive library: Release/nothing.a the table of contents is empty (no object file members in the library define global symbols) npm ERR! ../src/common.cc:23:10: fatal error: 'vips/vips8' file not found npm ERR! #include <vips/vips8> npm ERR! ^~~~~~~~~~~~ npm ERR! 1 error generated. npm ERR! make: *** [Release/obj.target/sharp/src/common.o] Error 1 npm ERR! gyp ERR! build error npm ERR! gyp ERR! stack Error: `make` failed with exit code: 2 npm ERR! gyp ERR! stack at ChildProcess.onExit (/Users/will/.nvm/versions/node/v16.6.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23) npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:394:28) npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12) npm ERR! gyp ERR! System Darwin 20.6.0 npm ERR! gyp ERR! command "/Users/will/.nvm/versions/node/v16.6.0/bin/node" "/Users/will/.nvm/versions/node/v16.6.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" npm ERR! gyp ERR! cwd /Users/will/Code/rxc/rxc-www/node_modules/sharp npm ERR! gyp ERR! node -v v16.6.0 npm ERR! gyp ERR! node-gyp -v v7.1.2 npm ERR! gyp ERR! not ok
I didn't spend any time debugging further. Ideally the repo "just installs" via a shell script that makes Sharp.
to solve this problem, install vips.
with Homebrew: brew install vips
brew install vips
Running
npm install
, I getI didn't spend any time debugging further. Ideally the repo "just installs" via a shell script that makes Sharp.