dsprenkels / dsprenkels/sss-node

Support for node 16 and 18

Open
#14 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
37
Forks
8
PR merge metrics
No merged PRs in 30d

Description

I'm trying to get this package running with node version 16.18.0 and I'm getting a lot of errors. Is this package not compatible w/ node 16.18.0? My plan is to later upgrade to LTS version 18.

```
Installing JavaScript dependencies
npm ERR! code 1
npm ERR! path /Users/username/Desktop/nodejs_app/node_modules/shamirsecretsharing
npm ERR! command failed
npm ERR! command sh -c -- node-gyp rebuild
npm ERR! CXX(target) Release/obj.target/shamirsecretsharing/shamirsecretsharing.o
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.1.0
npm ERR! gyp info using node@16.18.0 | darwin | arm64
npm ERR! gyp info find Python using Python version 3.9.13 found at "/Library/Frameworks/Python.framework/Versions/3.9/bin/python3"
npm ERR! gyp info spawn /Library/Frameworks/Python.framework/Versions/3.9/bin/python3
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args '/Users/username/.asdf/installs/nodejs/16.18.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/username/Desktop/nodejs_app/node_modules/shamirsecretsharing/build/config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/username/.asdf/installs/nodejs/16.18.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/username/Library/Caches/node-gyp/16.18.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/username/Library/Caches/node-gyp/16.18.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=/Users/username/.asdf/installs/nodejs/16.18.0/lib/node_modules/npm/node_modules/node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/username/Library/Caches/node-gyp/16.18.0/<(target_arch)/node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/username/Desktop/nodejs_app/node_modules/shamirsecretsharing',
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! ../shamirsecretsharing.cc:5:12: fatal error: 'sss/sss.h' file not found
npm ERR! #include "sss/sss.h"
npm ERR! ^~~~~~~~~~~
npm ERR! 1 error generated.
npm ERR! make: *** [Release/obj.target/shamirsecretsharing/shamirsecretsharing.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/username/.asdf/installs/nodejs/16.18.0/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:201:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28)
npm ERR! gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:293:12)
npm ERR! gyp ERR! System Darwin 21.6.0
npm ERR! gyp ERR! command "/Users/username/.asdf/installs/nodejs/16.18.0/bin/node" "/Users/username/.asdf/installs/nodejs/16.18.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /Users/username/Desktop/nodejs_app/node_modules/shamirsecretsharing
npm ERR! gyp ERR! node -v v16.18.0
npm ERR! gyp ERR! node-gyp -v v9.1.0
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:
npm ERR! /Users/username/.npm/_logs/2022-11-03T10_53_37_700Z-debug-0.log
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the npm install failure on Node 16 or 18 and read binding.gyp alongside shamirsecretsharing.cc. Investigate why the native build cannot find sss/sss.h; done means the package installs successfully on the requested Node versions and its existing checks still pass.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, node.js
Domain
api, cryptography
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.