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

Unable to install on Solus #856

Closed
ekremkaraca opened this issue Jun 24, 2017 · 3 comments
Closed

Unable to install on Solus #856

ekremkaraca opened this issue Jun 24, 2017 · 3 comments
Milestone

Comments

@ekremkaraca
Copy link
Contributor

Hi guys,

I'm using Solus operating system with Node 6.11 & npm 5.0.3. During installation of sharp, I had an error like below:

2017-06-24T10:35:56+0300 <error> new.js:12 () Error: warning fsevents@1.1.2: The platform "linux" is incompatible with this module.
error /tmp/beta-test-gatsby-site/node_modules/sharp: Command failed.
Exit code: 1
Command: sh
Arguments: -c node-gyp rebuild
Directory: /tmp/beta-test-gatsby-site/node_modules/sharp
Output:
gyp info it worked if it ends with ok
gyp info using node-gyp@3.6.2
gyp info using node@6.11.0 | linux | x64
gyp http GET https://nodejs.org/download/release/v6.11.0/node-v6.11.0-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v6.11.0/node-v6.11.0-headers.tar.gz
gyp http GET https://nodejs.org/download/release/v6.11.0/SHASUMS256.txt
gyp http 200 https://nodejs.org/download/release/v6.11.0/SHASUMS256.txt
gyp info spawn /usr/bin/python2
gyp info spawn args [ '/home/ekrem/.nvm/versions/node/v6.11.0/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/tmp/beta-test-gatsby-site/node_modules/sharp/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/home/ekrem/.nvm/versions/node/v6.11.0/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/home/ekrem/.node-gyp/6.11.0/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/home/ekrem/.node-gyp/6.11.0',
gyp info spawn args   '-Dnode_gyp_dir=/home/ekrem/.nvm/versions/node/v6.11.0/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/home/ekrem/.node-gyp/6.11.0/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/tmp/beta-test-gatsby-site/node_modules/sharp',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.' ]
ERROR: ldd (Solus) 2.25 requires manual installation - please see http://sharp.dimens.io/en/stable/install/
gyp: Call to 'LDD_VERSION="ldd (Solus) 2.25
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Written by Roland McGrath and Ulrich Drepper." node -e "require('./binding').download_vips()"' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error 
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/home/ekrem/.nvm/versions/node/v6.11.0/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:336:16)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Linux 4.9.32-31.lts
gyp ERR! command "/home/ekrem/.nvm/versions/node/v6.11.0/bin/node" "/home/ekrem/.nvm/versions/node/v6.11.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/beta-test-gatsby-site/node_modules/sharp
gyp ERR! node -v v6.11.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok

    at /tmp/node_modules/gatsby/dist/utils/init-starter.js:56:16
    at ChildProcess.exithandler (child_process.js:211:5)
    at emitTwo (events.js:106:13)
    at ChildProcess.emit (events.js:191:7)
    at maybeClose (internal/child_process.js:891:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)

I've checked out installation page but there was no information available for my os.

@lovell
Copy link
Owner

lovell commented Jun 24, 2017

Hello, I don't have any experience of Solus, but it looks like it uses glibc 2.25.

Are you able to try the following change to your local binding.js file to see if it works?

- if (/(glibc|gnu libc|gentoo)/i.test(lddVersion)) {
+ if (/(glibc|gnu libc|gentoo|solus)/i.test(lddVersion)) {

@lovell lovell added the triage label Jun 24, 2017
@ekremkaraca
Copy link
Contributor Author

Hi again!

Seems it's worked after I cloned the repo, changed the line and installed local file:

> fsevents@1.1.2 install /tmp/sharp/node_modules/fsevents
> node install


> sharp@0.18.2-alpha install /tmp/sharp
> node-gyp rebuild

make: Entering directory '/tmp/sharp/build'
  TOUCH Release/obj.target/libvips-cpp.stamp
  CXX(target) Release/obj.target/sharp/src/common.o
../src/common.cc: In function ‘std::tuple<int, int> sharp::CalculateCrop(int, int, int, int, int)’:
../src/common.cc:440:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
         top = inHeight - outHeight;
         ~~~~^~~~~~~~~~~~~~~~~~~~~~
../src/common.cc:441:7: note: here
       case 7:
       ^~~~
  CXX(target) Release/obj.target/sharp/src/metadata.o
  CXX(target) Release/obj.target/sharp/src/operations.o
  CXX(target) Release/obj.target/sharp/src/pipeline.o
  CXX(target) Release/obj.target/sharp/src/sharp.o
  CXX(target) Release/obj.target/sharp/src/utilities.o
  SOLINK_MODULE(target) Release/obj.target/sharp.node
  COPY Release/sharp.node
  TOUCH Release/obj.target/win_copy_dlls.stamp
make: Leaving directory '/tmp/sharp/build'
npm notice created a lockfile as package-lock.json. You should commit this file.
added 962 packages in 73.795s

@lovell
Copy link
Owner

lovell commented Jun 24, 2017

Great, thanks for confirming. Are you able to submit a PR with this change?

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

No branches or pull requests

2 participants