ssbc / scuttle-shell

A system tray app for running Secure Scuttlebutt and providing sbot features to your local system
54 stars 10 forks source link

Installation fails at leveldown #38

Open physkets opened 4 years ago

physkets commented 4 years ago

I cloned the repository and attempted an install via npm install, but the installation fails:

gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/usr/lib/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:314:20)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:276:12)
gyp ERR! System Linux 5.8.3-zen1-1-zen
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/user/Applications/scuttle-shell/node_modules/ssb-server/node_modules/leveldown
gyp ERR! node -v v14.8.0
gyp ERR! node-gyp -v v7.0.0
gyp ERR! not ok 
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: sodium-native@2.3.0 (node_modules/ssb-server/node_modules/sodium-native):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: sodium-native@2.3.0 install: `node-gyp-build "node preinstall.js" "node postinstall.js"`
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! leveldown@4.0.2 install: `prebuild-install || node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the leveldown@4.0.2 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

I am attaching the full log: 2020-08-23T17_22_54_081Z-debug.log

rhz commented 4 years ago

I'm having the same problem. When I run npm search leveldown I see that the latest version is 5.6.0. scuttle-shell is using version 4.0.2, which is maybe too old to be compiled by nodejs version 14.9.0. That leveldown version is required by sodium-native version 2.3.0, which itself is required directly by scuttle-shell and indirectly through ssb-server. So changing the version of sodium-native in package.json isn't enough to fix the issue. In https://github.com/ssbc/ssb-server/ it suggests to use nvm install 10 and nvm alias default 10 so that npm install uses nodejs version 10 by default. I'm left wondering what's blocking the update of ssb-server to make it compile on nodejs versions after 10.

physkets commented 4 years ago

I'm able to use ssb-server with the latest NodeJS: v14.9.0, so I don't think that is an issue.

rhz commented 4 years ago

Right. The last version of ssb-server available on npm is 16.0.1 and it compiles well on nodejs v14.9.0. However, scuttle-shell requires ssb-server version 14.1.12 in its package.json file and that version doesn't compile on nodejs v14.9.0.

stale[bot] commented 3 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

retog commented 3 years ago

After updating the dependencies npm install succeeded.

Unfortunatly npm run start fails with:

libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast
systrayhelper 0.0.5 (d5794e2a72a9cb160d78b6fd9ee640ad1df02af7 built 2018-12-05T09:24:55Z)
got action: {update-item {ssb version: 19.2.0  false false false} {   []} 1}
/home/reto/Documents/3rdparties/scuttle-shell/node_modules/ssb-peer-invites/node_modules/ssb-keys/util.js:42
  var i = buf.indexOf('.')
              ^

TypeError: buf.indexOf is not a function
    at Object.exports.toBuffer (/home/reto/Documents/3rdparties/scuttle-shell/node_modules/ssb-peer-invites/node_modules/ssb-keys/util.js:42:15)