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

Library can't be installed #103

Open
rptoma opened this issue May 19, 2020 · 5 comments
Open

Library can't be installed #103

rptoma opened this issue May 19, 2020 · 5 comments

Comments

@rptoma
Copy link
Contributor

rptoma commented May 19, 2020

The library can not be installed.

Node version 14.2.0
npm version 6.14.5

OS: macOS Catalina 10.15.3

I think it is because of the sharp dependency which needs to be updated.

If you try to install that version of sharp in the project, it would give the same error. The latest sharp version works, though.

It might be that that version of sharp is not supported on macOS Catalina: cncf/landscapeapp#475.

> (node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)

info sharp Using cached /Users/username/.npm/_libvips/libvips-8.7.4-darwin-x64.tar.gz
prebuild-install WARN install No prebuilt binaries found (target=14.2.0 runtime=node arch=x64 libc= platform=darwin)
  TOUCH Release/obj.target/libvips-cpp.stamp
  CXX(target) Release/obj.target/sharp/src/common.o
  CXX(target) Release/obj.target/sharp/src/metadata.o
  CXX(target) Release/obj.target/sharp/src/stats.o
../src/stats.cc:130:19: error: no matching member function for call to 'Set'
        channels->Set(i, channelStat);
        ~~~~~~~~~~^~~
/Users/username/Library/Caches/node-gyp/14.2.0/include/node/v8.h:3639:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context,
                                    ^
/Users/username/Library/Caches/node-gyp/14.2.0/include/node/v8.h:3642:37: note: candidate function not viable: requires 3 arguments, but 2 were provided
  V8_WARN_UNUSED_RESULT Maybe<bool> Set(Local<Context> context, uint32_t index,
                                    ^
1 error generated.
make: *** [Release/obj.target/sharp/src/stats.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:315:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12)
gyp ERR! System Darwin 19.3.0
gyp ERR! command "/usr/local/Cellar/node/14.2.0/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/username/Documents/Disertatie/project-name-backend/node_modules/sharp
gyp ERR! node -v v14.2.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok 
npm WARN [email protected] No description
npm WARN [email protected] No repository field.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `(node install/libvips && node install/dll-copy && prebuild-install) || (node-gyp rebuild && node install/dll-copy)`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/username/.npm/_logs/2020-05-19T11_38_54_024Z-debug.log
username@s-MacBook-Pro- project-name-backend % 
@rptoma
Copy link
Contributor Author

rptoma commented May 19, 2020

I created a PR #104

@rylnd
Copy link
Collaborator

rylnd commented Jun 19, 2020

Hey @rptoma! It looks like you're using a newer version of node than is currently supported. As a temporary workaround, you may be able to use node 10.x as that appears to use a prebuilt version of sharp-libvps.

@antonlukin
Copy link

Hello there.
I think it's a good idea to support the current nodejs version.

@parostatkiem-zz
Copy link

Bump: I came across this library of wonderful avatars and I'd like to use it. Sadly, it doesn't support the LTS Nodejs 😞

itsthatguy added a commit that referenced this issue Aug 2, 2021
rylnd added a commit that referenced this issue Jan 14, 2022
This was similarly fixed on the master branch, but updating to address #103.
@rylnd
Copy link
Collaborator

rylnd commented Jan 14, 2022

I've just released version 0.5.0, which specifies node >= 10.x and includes an updated version of the sharp package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants