Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fatal error: 'vips/vips8' file not found #2854

Closed
hooraygith opened this issue Aug 21, 2021 · 3 comments
Closed

fatal error: 'vips/vips8' file not found #2854

hooraygith opened this issue Aug 21, 2021 · 3 comments

Comments

@hooraygith
Copy link

Did you see the documentation relating to installation?

Yes

Have you ensured the architecture and platform of Node.js used for npm install is the same as the architecture and platform of Node.js used at runtime?

Yes

Are you using the latest version? Is the version currently in use as reported by npm ls sharp the same as the latest version as reported by npm view sharp dist-tags.latest?

Yes

If you are using npm v6 or earlier and installing as a root or sudo user, have you tried with the npm install --unsafe-perm flag?

No

If you are using npm v7, does the user running npm install own the directory it is run in?

Yes

If you are using the ignore-scripts feature of npm, have you tried with the npm install --ignore-scripts=false flag?

I didn't use ignore-scripts

What is the complete output of running npm install --verbose sharp? Have you checked this output for useful error messages?

npm verb cli [
npm verb cli   '/usr/local/Cellar/node/16.2.0/bin/node',
npm verb cli   '/usr/local/bin/npm',
npm verb cli   'install',
npm verb cli   '--verbose',
npm verb cli   'sharp'
npm verb cli ]
npm info using npm@7.13.0
npm info using node@v16.2.0
npm timing npm:load:whichnode Completed in 1ms
npm timing config:load:defaults Completed in 1ms
npm timing config:load:file:/usr/local/lib/node_modules/npm/npmrc Completed in 2ms
npm timing config:load:builtin Completed in 2ms
npm timing config:load:cli Completed in 2ms
npm timing config:load:env Completed in 1ms
npm timing config:load:file:/Users/rouwan/github/test/.npmrc Completed in 1ms
npm timing config:load:project Completed in 1ms
npm timing config:load:file:/Users/rouwan/.npmrc Completed in 1ms
npm timing config:load:user Completed in 1ms
npm timing config:load:file:/usr/local/etc/npmrc Completed in 0ms
npm timing config:load:global Completed in 0ms
npm timing config:load:validate Completed in 2ms
npm timing config:load:credentials Completed in 1ms
npm timing config:load:setEnvs Completed in 1ms
npm timing config:load Completed in 12ms
npm timing npm:load:configload Completed in 12ms
npm timing npm:load:setTitle Completed in 2ms
npm timing npm:load:setupLog Completed in 1ms
npm timing npm:load:cleanupLog Completed in 2ms
npm timing npm:load:configScope Completed in 0ms
npm timing npm:load:projectScope Completed in 1ms
npm timing npm:load Completed in 23ms
npm timing config:load:flatten Completed in 3ms
npm timing arborist:ctor Completed in 1ms
npm timing arborist:ctor Completed in 0ms
npm timing idealTree:init Completed in 28ms
npm timing idealTree:userRequests Completed in 2ms
npm http fetch GET 200 https://registry.npm.taobao.org/sharp 197ms
npm http fetch GET 304 https://registry.npm.taobao.org/semver 52ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/tunnel-agent 71ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/color 100ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/node-addon-api 172ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/tar-fs 168ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/detect-libc 180ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/prebuild-install 194ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/simple-get 200ms (from cache)
npm timing idealTree:#root Completed in 419ms
npm http fetch GET 304 https://registry.npm.taobao.org/minimist 214ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/color-convert 226ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/rc 215ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/color-string 230ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/tar-stream 203ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/expand-template 236ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/safe-buffer 200ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/node-abi 234ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/napi-build-utils 236ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/chownr 213ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/github-from-package 243ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/npmlog 245ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/decompress-response 234ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/lru-cache 246ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/once 233ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/pump 257ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/mkdirp-classic 269ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/simple-concat 252ms (from cache)
npm timing idealTree:node_modules/sharp Completed in 310ms
npm http fetch GET 304 https://registry.npm.taobao.org/simple-swizzle 26ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/color-name 33ms (from cache)
npm timing idealTree:node_modules/color Completed in 38ms
npm timing idealTree:node_modules/color-convert Completed in 1ms
npm timing idealTree:node_modules/color-name Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/is-arrayish 46ms (from cache)
npm timing idealTree:node_modules/color-string Completed in 48ms
npm timing idealTree:node_modules/detect-libc Completed in 0ms
npm timing idealTree:node_modules/node-addon-api Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/strip-json-comments 77ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/end-of-stream 83ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/deep-extend 83ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/gauge 86ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/are-we-there-yet 93ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/set-blocking 130ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/ini 131ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/console-control-strings 172ms (from cache)
npm timing idealTree:node_modules/prebuild-install Completed in 188ms
npm timing idealTree:node_modules/expand-template Completed in 0ms
npm timing idealTree:node_modules/github-from-package Completed in 0ms
npm timing idealTree:node_modules/minimist Completed in 0ms
npm timing idealTree:node_modules/mkdirp-classic Completed in 0ms
npm timing idealTree:node_modules/napi-build-utils Completed in 0ms
npm timing idealTree:node_modules/node-abi Completed in 2ms
npm http fetch GET 304 https://registry.npm.taobao.org/aproba 105ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/has-unicode 107ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/object-assign 109ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/delegates 114ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/string-width 112ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/readable-stream 118ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/wide-align 120ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/signal-exit 130ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/strip-ansi 126ms (from cache)
npm timing idealTree:node_modules/npmlog Completed in 146ms
npm http fetch GET 304 https://registry.npm.taobao.org/inherits 66ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/core-util-is 69ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/process-nextick-args 69ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/isarray 71ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/util-deprecate 71ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/string_decoder 74ms (from cache)
npm timing idealTree:node_modules/are-we-there-yet Completed in 80ms
npm timing idealTree:node_modules/console-control-strings Completed in 0ms
npm timing idealTree:node_modules/delegates Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/is-fullwidth-code-point 41ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/code-point-at 44ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/ansi-regex 44ms (from cache)
npm timing idealTree:node_modules/gauge Completed in 53ms
npm timing idealTree:node_modules/aproba Completed in 0ms
npm timing idealTree:node_modules/has-unicode Completed in 0ms
npm timing idealTree:node_modules/object-assign Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/wrappy 28ms (from cache)
npm timing idealTree:node_modules/pump Completed in 33ms
npm timing idealTree:node_modules/end-of-stream Completed in 0ms
npm timing idealTree:node_modules/once Completed in 1ms
npm timing idealTree:node_modules/rc Completed in 2ms
npm timing idealTree:node_modules/deep-extend Completed in 0ms
npm timing idealTree:node_modules/ini Completed in 0ms
npm timing idealTree:node_modules/readable-stream Completed in 10ms
npm timing idealTree:node_modules/core-util-is Completed in 0ms
npm timing idealTree:node_modules/inherits Completed in 0ms
npm timing idealTree:node_modules/isarray Completed in 0ms
npm timing idealTree:node_modules/process-nextick-args Completed in 0ms
npm timing idealTree:node_modules/safe-buffer Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/yallist 40ms (from cache)
npm timing idealTree:node_modules/semver Completed in 49ms
npm timing idealTree:node_modules/lru-cache Completed in 1ms
npm timing idealTree:node_modules/set-blocking Completed in 0ms
npm timing idealTree:node_modules/signal-exit Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/mimic-response 27ms (from cache)
npm timing idealTree:node_modules/simple-get Completed in 32ms
npm timing idealTree:node_modules/decompress-response Completed in 2ms
npm timing idealTree:node_modules/mimic-response Completed in 0ms
npm timing idealTree:node_modules/simple-concat Completed in 0ms
npm timing idealTree:node_modules/simple-swizzle Completed in 3ms
npm timing idealTree:node_modules/is-arrayish Completed in 0ms
npm timing idealTree:node_modules/string_decoder Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/number-is-nan 23ms (from cache)
npm timing idealTree:node_modules/string-width Completed in 28ms
npm timing idealTree:node_modules/code-point-at Completed in 0ms
npm timing idealTree:node_modules/is-fullwidth-code-point Completed in 1ms
npm timing idealTree:node_modules/number-is-nan Completed in 0ms
npm timing idealTree:node_modules/strip-ansi Completed in 2ms
npm timing idealTree:node_modules/ansi-regex Completed in 0ms
npm timing idealTree:node_modules/strip-json-comments Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/bl 33ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/fs-constants 38ms (from cache)
npm timing idealTree:node_modules/tar-fs Completed in 46ms
npm timing idealTree:node_modules/chownr Completed in 0ms
npm http fetch GET 304 https://registry.npm.taobao.org/buffer 30ms (from cache)
npm timing idealTree:node_modules/tar-stream Completed in 36ms
npm http fetch GET 304 https://registry.npm.taobao.org/base64-js 43ms (from cache)
npm http fetch GET 304 https://registry.npm.taobao.org/ieee754 44ms (from cache)
npm timing idealTree:node_modules/bl Completed in 49ms
npm timing idealTree:node_modules/buffer Completed in 1ms
npm timing idealTree:node_modules/base64-js Completed in 0ms
npm timing idealTree:node_modules/fs-constants Completed in 0ms
npm timing idealTree:node_modules/ieee754 Completed in 0ms
npm timing idealTree:node_modules/tunnel-agent Completed in 0ms
npm timing idealTree:node_modules/util-deprecate Completed in 0ms
npm timing idealTree:node_modules/wide-align Completed in 0ms
npm timing idealTree:node_modules/wrappy Completed in 0ms
npm timing idealTree:node_modules/yallist Completed in 0ms
npm timing idealTree:node_modules/bl/node_modules/readable-stream Completed in 0ms
npm timing idealTree:node_modules/node-abi/node_modules/semver Completed in 0ms
npm timing idealTree:node_modules/tar-stream/node_modules/readable-stream Completed in 0ms
npm timing idealTree:buildDeps Completed in 1606ms
npm timing idealTree:fixDepFlags Completed in 1ms
npm timing idealTree Completed in 1639ms
npm timing reify:loadTrees Completed in 1641ms
npm timing reify:diffTrees Completed in 2ms
npm timing reify:retireShallow Completed in 1ms
npm timing reify:createSparse Completed in 14ms
npm timing reify:loadBundles Completed in 0ms
npm http fetch POST 404 https://registry.npm.taobao.org/-/npm/v1/security/advisories/bulk 284ms
npm timing reifyNode:node_modules/chownr Completed in 383ms
npm timing reifyNode:node_modules/number-is-nan Completed in 383ms
npm timing reifyNode:node_modules/is-fullwidth-code-point Completed in 383ms
npm timing reifyNode:node_modules/ansi-regex Completed in 384ms
npm timing reifyNode:node_modules/code-point-at Completed in 385ms
npm timing reifyNode:node_modules/process-nextick-args Completed in 386ms
npm timing reifyNode:node_modules/strip-json-comments Completed in 388ms
npm timing reifyNode:node_modules/ini Completed in 389ms
npm timing reifyNode:node_modules/wrappy Completed in 389ms
npm timing reifyNode:node_modules/once Completed in 388ms
npm timing reifyNode:node_modules/end-of-stream Completed in 388ms
npm timing reifyNode:node_modules/strip-ansi Completed in 389ms
npm timing reifyNode:node_modules/aproba Completed in 390ms
npm timing reifyNode:node_modules/object-assign Completed in 391ms
npm timing reifyNode:node_modules/has-unicode Completed in 392ms
npm timing reifyNode:node_modules/wide-align Completed in 392ms
npm timing reifyNode:node_modules/string-width Completed in 392ms
npm timing reifyNode:node_modules/mkdirp-classic Completed in 394ms
npm timing reifyNode:node_modules/simple-swizzle Completed in 394ms
npm timing reifyNode:node_modules/color-name Completed in 396ms
npm timing reifyNode:node_modules/simple-get Completed in 397ms
npm timing reifyNode:node_modules/ieee754 Completed in 407ms
npm timing reifyNode:node_modules/fs-constants Completed in 408ms
npm timing reifyNode:node_modules/mimic-response Completed in 409ms
npm timing reifyNode:node_modules/decompress-response Completed in 410ms
npm timing reifyNode:node_modules/lru-cache Completed in 411ms
npm timing reifyNode:node_modules/inherits Completed in 410ms
npm timing reifyNode:node_modules/set-blocking Completed in 410ms
npm timing reifyNode:node_modules/console-control-strings Completed in 411ms
npm timing reifyNode:node_modules/color-string Completed in 411ms
npm timing reifyNode:node_modules/tunnel-agent Completed in 412ms
npm timing reifyNode:node_modules/base64-js Completed in 417ms
npm timing reifyNode:node_modules/yallist Completed in 418ms
npm timing reifyNode:node_modules/color Completed in 417ms
npm timing reifyNode:node_modules/util-deprecate Completed in 421ms
npm timing reifyNode:node_modules/signal-exit Completed in 420ms
npm timing reifyNode:node_modules/expand-template Completed in 423ms
npm timing reifyNode:node_modules/simple-concat Completed in 428ms
npm timing reifyNode:node_modules/safe-buffer Completed in 429ms
npm timing reifyNode:node_modules/string_decoder Completed in 430ms
npm timing reifyNode:node_modules/deep-extend Completed in 429ms
npm timing reifyNode:node_modules/pump Completed in 429ms
npm timing reifyNode:node_modules/npmlog Completed in 429ms
npm timing reifyNode:node_modules/napi-build-utils Completed in 429ms
npm timing reifyNode:node_modules/is-arrayish Completed in 442ms
npm timing reifyNode:node_modules/isarray Completed in 441ms
npm timing reifyNode:node_modules/core-util-is Completed in 445ms
npm timing reifyNode:node_modules/delegates Completed in 445ms
npm timing reifyNode:node_modules/color-convert Completed in 455ms
npm http fetch POST 404 https://registry.npm.taobao.org/-/npm/v1/security/audits/quick 156ms
npm verb audit error HttpErrorGeneral: 404 Not Found - POST https://registry.npm.taobao.org/-/npm/v1/security/audits/quick - [not_found] document not found
npm verb audit error     at /usr/local/lib/node_modules/npm/node_modules/npm-registry-fetch/check-response.js:134:15
npm verb audit error     at async Map.[getReport] (/usr/local/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:316:21)
npm verb audit error     at async Map.run (/usr/local/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:103:19)
npm verb audit error  HttpErrorGeneral: 404 Not Found - POST https://registry.npm.taobao.org/-/npm/v1/security/audits/quick - [not_found] document not found
npm verb audit error     at /usr/local/lib/node_modules/npm/node_modules/npm-registry-fetch/check-response.js:134:15
npm verb audit error     at async Map.[getReport] (/usr/local/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:316:21)
npm verb audit error     at async Map.run (/usr/local/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:103:19) {
npm verb audit error   headers: [Object: null prototype] {
npm verb audit error     server: [ 'Tengine' ],
npm verb audit error     'content-type': [ 'application/json; charset=utf-8' ],
npm verb audit error     'transfer-encoding': [ 'chunked' ],
npm verb audit error     connection: [ 'keep-alive' ],
npm verb audit error     date: [ 'Sat, 21 Aug 2021 09:54:07 GMT' ],
npm verb audit error     'x-current-requests': [ '1' ],
npm verb audit error     vary: [ 'Origin' ],
npm verb audit error     'x-readtime': [ '1' ],
npm verb audit error     'content-encoding': [ 'gzip' ],
npm verb audit error     'x-alicdn-da-ups-status': [ 'endOs,0,404' ],
npm verb audit error     via: [ 'cache7.l2cm10-9[15,0], kunlun1.cn462[46,0]' ],
npm verb audit error     'timing-allow-origin': [ '*' ],
npm verb audit error     eagleid: [ 'b739529516295396474378278e' ],
npm verb audit error     'x-fetch-attempts': [ '1' ]
npm verb audit error   },
npm verb audit error   statusCode: 404,
npm verb audit error   code: 'E404',
npm verb audit error   method: 'POST',
npm verb audit error   uri: 'https://registry.npm.taobao.org/-/npm/v1/security/audits/quick',
npm verb audit error   body: {
npm verb audit error     error: '[not_found] document not found',
npm verb audit error     reason: '[not_found] document not found'
npm verb audit error   },
npm verb audit error   pkgid: undefined
npm verb audit error }
npm timing auditReport:getReport Completed in 471ms
npm timing reify:audit Completed in 474ms
npm timing reifyNode:node_modules/detect-libc Completed in 473ms
npm timing reifyNode:node_modules/tar-stream Completed in 478ms
npm timing reifyNode:node_modules/are-we-there-yet Completed in 477ms
npm timing reifyNode:node_modules/node-abi/node_modules/semver Completed in 478ms
npm timing reifyNode:node_modules/buffer Completed in 496ms
npm timing reifyNode:node_modules/github-from-package Completed in 503ms
npm timing reifyNode:node_modules/rc Completed in 508ms
npm timing reifyNode:node_modules/bl Completed in 512ms
npm timing reifyNode:node_modules/prebuild-install Completed in 511ms
npm timing reifyNode:node_modules/node-abi Completed in 514ms
npm timing reifyNode:node_modules/gauge Completed in 529ms
npm timing reifyNode:node_modules/minimist Completed in 529ms
npm timing reifyNode:node_modules/readable-stream Completed in 558ms
npm timing reifyNode:node_modules/tar-stream/node_modules/readable-stream Completed in 561ms
npm timing reifyNode:node_modules/bl/node_modules/readable-stream Completed in 562ms
npm timing reifyNode:node_modules/node-addon-api Completed in 563ms
npm timing reifyNode:node_modules/tar-fs Completed in 567ms
npm timing reifyNode:node_modules/semver Completed in 576ms
npm timing reifyNode:node_modules/sharp Completed in 582ms
npm timing reify:unpack Completed in 590ms
npm timing reify:unretire Completed in 1ms
npm timing build:queue Completed in 3ms
npm timing build:link:node_modules/prebuild-install Completed in 10ms
npm timing build:link:node_modules/semver Completed in 10ms
npm timing build:link:node_modules/rc Completed in 11ms
npm timing build:link:node_modules/node-abi/node_modules/semver Completed in 9ms
npm timing build:link:node_modules/detect-libc Completed in 13ms
npm timing build:link Completed in 14ms
npm info run sharp@0.29.0 install node_modules/sharp node-gyp rebuild
npm info run sharp@0.29.0 install { code: 1, signal: null }
npm timing reify:rollback:createSparse Completed in 116ms
npm timing reify:rollback:retireShallow Completed in 0ms
npm timing command:install Completed in 8384ms
npm verb stack Error: command failed
npm verb stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/@npmcli/promise-spawn/index.js:64:27)
npm verb stack     at ChildProcess.emit (node:events:365:28)
npm verb stack     at maybeClose (node:internal/child_process:1067:16)
npm verb stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
npm verb pkgid sharp@0.29.0
npm verb cwd /Users/rouwan/github/test
npm verb Darwin 18.7.0
npm verb argv "/usr/local/Cellar/node/16.2.0/bin/node" "/usr/local/bin/npm" "install" "--verbose" "sharp"
npm verb node v16.2.0
npm verb npm  v7.13.0
npm ERR! code 1
npm ERR! path /Users/rouwan/github/test/node_modules/sharp
npm ERR! command failed
npm ERR! command sh -c node-gyp rebuild
npm ERR! cc -o Release/obj.target/nothing/../node-addon-api/nothing.o ../../node-addon-api/nothing.c '-DNODE_GYP_MODULE_NAME=nothing' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/include/node -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/src -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/openssl/config -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/openssl/openssl/include -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/uv/include -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/zlib -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/v8/include  -O3 -gdwarf-2 -mmacosx-version-min=10.13 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -fno-strict-aliasing -MMD -MF ./Release/.deps/Release/obj.target/nothing/../node-addon-api/nothing.o.d.raw   -c
npm ERR!   rm -f Release/nothing.a && ./gyp-mac-tool filter-libtool libtool  -static -o Release/nothing.a Release/obj.target/nothing/../node-addon-api/nothing.o
npm ERR!   touch Release/obj.target/libvips-cpp.stamp
npm ERR!   c++ -o Release/obj.target/sharp-darwin-x64/src/common.o ../src/common.cc '-DNODE_GYP_MODULE_NAME=sharp-darwin-x64' '-DUSING_UV_SHARED=1' '-DUSING_V8_SHARED=1' '-DV8_DEPRECATION_WARNINGS=1' '-DV8_DEPRECATION_WARNINGS' '-DV8_IMMINENT_DEPRECATION_WARNINGS' '-D_GLIBCXX_USE_CXX11_ABI=1' '-D_DARWIN_USE_64_BIT_INODE=1' '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DNAPI_VERSION=5' '-DBUILDING_NODE_EXTENSION' -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/include/node -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/src -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/openssl/config -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/openssl/openssl/include -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/uv/include -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/zlib -I/Users/rouwan/Library/Caches/node-gyp/16.2.0/deps/v8/include -I../../node-addon-api -I../vendor/8.11.3/darwin-x64/include -I../vendor/8.11.3/darwin-x64/include/glib-2.0 -I../vendor/8.11.3/darwin-x64/lib/glib-2.0/include  -O3 -gdwarf-2 -mmacosx-version-min=10.9 -arch x86_64 -Wall -Wendif-labels -W -Wno-unused-parameter -std=c++11 -stdlib=libc++ -fexceptions -Wall -Oz -MMD -MF ./Release/.deps/Release/obj.target/sharp-darwin-x64/src/common.o.d.raw   -c
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp verb cli [
npm ERR! gyp verb cli   '/usr/local/Cellar/node/16.2.0/bin/node',
npm ERR! gyp verb cli   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js',
npm ERR! gyp verb cli   'rebuild'
npm ERR! gyp verb cli ]
npm ERR! gyp info using node-gyp@7.1.2
npm ERR! gyp info using node@16.2.0 | darwin | x64
npm ERR! gyp verb command rebuild []
npm ERR! gyp verb command clean []
npm ERR! gyp verb clean removing "build" directory
npm ERR! gyp verb command configure []
npm ERR! gyp verb find Python Python is not set from command line or npm configuration
npm ERR! gyp verb find Python Python is not set from environment variable PYTHON
npm ERR! gyp verb find Python checking if "python3" can be used
npm ERR! gyp verb find Python - executing "python3" to get executable path
npm ERR! gyp verb find Python - executable path is "/usr/local/opt/python@3.9/bin/python3.9"
npm ERR! gyp verb find Python - executing "/usr/local/opt/python@3.9/bin/python3.9" to get version
npm ERR! gyp verb find Python - version is "3.9.5"
npm ERR! gyp info find Python using Python version 3.9.5 found at "/usr/local/opt/python@3.9/bin/python3.9"
npm ERR! gyp verb get node dir no --target version specified, falling back to host node version: 16.2.0
npm ERR! gyp verb command install [ '16.2.0' ]
npm ERR! gyp verb install input version string "16.2.0"
npm ERR! gyp verb install installing version: 16.2.0
npm ERR! gyp verb install --ensure was passed, so won't reinstall if already installed
npm ERR! gyp verb install version is already installed, need to check "installVersion"
npm ERR! gyp verb got "installVersion" 9
npm ERR! gyp verb needs "installVersion" 9
npm ERR! gyp verb install version is good
npm ERR! gyp verb get node dir target node version installed: 16.2.0
npm ERR! gyp verb build dir attempting to create "build" dir: /Users/rouwan/github/test/node_modules/sharp/build
npm ERR! gyp verb build dir "build" dir needed to be created? /Users/rouwan/github/test/node_modules/sharp/build
npm ERR! gyp verb build/config.gypi creating config file
npm ERR! gyp verb build/config.gypi writing out config file: /Users/rouwan/github/test/node_modules/sharp/build/config.gypi
npm ERR! (node:41239) [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 verb config.gypi checking for gypi file: /Users/rouwan/github/test/node_modules/sharp/config.gypi
npm ERR! gyp verb common.gypi checking for gypi file: /Users/rouwan/github/test/node_modules/sharp/common.gypi
npm ERR! gyp verb gyp gyp format was not specified; forcing "make"
npm ERR! gyp info spawn /usr/local/opt/python@3.9/bin/python3.9
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args   '/usr/local/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/rouwan/github/test/node_modules/sharp/build/config.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/usr/local/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args   '-I',
npm ERR! gyp info spawn args   '/Users/rouwan/Library/Caches/node-gyp/16.2.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/rouwan/Library/Caches/node-gyp/16.2.0',
npm ERR! gyp info spawn args   '-Dnode_gyp_dir=/usr/local/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args   '-Dnode_lib_file=/Users/rouwan/Library/Caches/node-gyp/16.2.0/<(target_arch)/node.lib',
npm ERR! gyp info spawn args   '-Dmodule_root_dir=/Users/rouwan/github/test/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 verb command build []
npm ERR! gyp verb build type Release
npm ERR! gyp verb architecture x64
npm ERR! gyp verb node dev dir /Users/rouwan/Library/Caches/node-gyp/16.2.0
npm ERR! gyp verb `which` succeeded for `make` /usr/bin/make
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'V=1', 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! ../src/common.cc:24: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-darwin-x64/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 (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
npm ERR! gyp ERR! stack     at ChildProcess.emit (node:events:365:28)
npm ERR! gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
npm ERR! gyp ERR! System Darwin 18.7.0
npm ERR! gyp ERR! command "/usr/local/Cellar/node/16.2.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /Users/rouwan/github/test/node_modules/sharp
npm ERR! gyp ERR! node -v v16.2.0
npm ERR! gyp ERR! node-gyp -v v7.1.2
npm ERR! gyp ERR! not ok
npm verb exit 1
npm timing npm Completed in 8755ms
npm verb code 1

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/rouwan/.npm/_logs/2021-08-21T09_54_13_821Z-debug.log

What is the output of running npx envinfo --binaries --system?

 System:
    OS: macOS Mojave 10.14.6
    CPU: (4) x64 Intel(R) Core(TM) i5-7360U CPU @ 2.30GHz
    Memory: 19.73 MB / 16.00 GB
    Shell: 5.3 - /bin/zsh
  Binaries:
    Node: 16.2.0 - /usr/local/bin/node
    npm: 7.13.0 - /usr/local/bin/npm

And this is my .npmrc

registry=https://registry.npm.taobao.org
sharp_binary_host=https://npm.taobao.org/mirrors/sharp
sharp_libvips_binary_host=https://npm.taobao.org/mirrors/sharp-libvips

package-lock=false
@lovell
Copy link
Owner

lovell commented Aug 21, 2021

It looks like there might be missing entries from this install log - sharp should be logging why it chooses to compile from source. My best guess would be that this machine has previously had a global vips package installed via Homebrew, but that it has been partially removed. If so, run brew uninstall vips to remove it completely.

@lovell
Copy link
Owner

lovell commented Sep 23, 2021

This looks like (yet another) example of the lockfile bug in npm v7 - please see npm/cli#2606

@lovell
Copy link
Owner

lovell commented Oct 3, 2021

This is a bug in npm v7 - please subscribe to npm/cli#2606 for updates.

@lovell lovell closed this as completed Oct 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants