You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During npm install, there is an error building sha3. How can we fix this?
Running node v10.4,0, npm v6.1.0, Ubuntu 18.04
npm WARN deprecated fs-promise@2.0.3: Use mz or fs-extra^3.0 with Promise Support
npm WARN deprecated tar.gz@1.0.7: ⚠️ WARNING ⚠️ tar.gz module has been deprecated and your application is vulnerable. Please use tar module instead: https://npmjs.com/tar
> sha3@1.2.0 install /root/tokenpool/node_modules/sha3
> node-gyp rebuild
make: Entering directory '/root/tokenpool/node_modules/sha3/build'
CXX(target) Release/obj.target/sha3/src/addon.o
In file included from ../src/addon.cpp:4:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:840:60: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, func, argc, argv);
^
In file included from ../src/addon.cpp:1:0:
/root/.node-gyp/10.4.0/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/addon.cpp:4:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:855:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::String>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, symbol, argc, argv);
^
In file included from ../src/addon.cpp:1:0:
/root/.node-gyp/10.4.0/include/node/node.h:165:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/addon.cpp:4:0:
../../nan/nan.h: In function ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’:
../../nan/nan.h:870:62: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, const char*, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
v8::Isolate::GetCurrent(), target, method, argc, argv);
^
In file included from ../src/addon.cpp:1:0:
/root/.node-gyp/10.4.0/include/node/node.h:158:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
In file included from ../src/addon.cpp:4:0:
../../nan/nan.h: In member function ‘v8::Local<v8::Value> Nan::Callback::Call_(v8::Isolate*, v8::Local<v8::Object>, int, v8::Local<v8::Value>*) const’:
../../nan/nan.h:1484:5: warning: ‘v8::Local<v8::Value> node::MakeCallback(v8::Isolate*, v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations]
));
^
In file included from ../src/addon.cpp:1:0:
/root/.node-gyp/10.4.0/include/node/node.h:172:50: note: declared here
NODE_EXTERN v8::Local<v8::Value> MakeCallback(
^
/root/.node-gyp/10.4.0/include/node/node.h:88:42: note: in definition of macro ‘NODE_DEPRECATED’
__attribute__((deprecated(message))) declarator
^~~~~~~~~~
../src/addon.cpp: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE SHA3Hash::New(Nan::NAN_METHOD_ARGS_TYPE)’:
../src/addon.cpp:49:23: warning: ‘new’ of type ‘SHA3Hash’ with extended alignment 32 [-Waligned-new=]
obj = new SHA3Hash();
^
../src/addon.cpp:49:23: note: uses ‘void* operator new(std::size_t)’, which does not have an alignment parameter
../src/addon.cpp:49:23: note: use ‘-faligned-new’ to enable C++17 over-aligned new support
../src/addon.cpp:59:58: error: no matching function for call to ‘v8::Function::NewInstance(const int&, v8::Local<v8::Value> [1])’
info.GetReturnValue().Set(cons->NewInstance(argc, argv));
^
In file included from /root/.node-gyp/10.4.0/include/node/node.h:63:0,
from ../src/addon.cpp:1:
/root/.node-gyp/10.4.0/include/node/v8.h:3905:44: note: candidate: v8::MaybeLocal<v8::Object> v8::Function::NewInstance(v8::Local<v8::Context>, int, v8::Local<v8::Value>*) const
V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance(
^~~~~~~~~~~
/root/.node-gyp/10.4.0/include/node/v8.h:3905:44: note: candidate expects 3 arguments, 2 provided
/root/.node-gyp/10.4.0/include/node/v8.h:3908:44: note: candidate: v8::MaybeLocal<v8::Object> v8::Function::NewInstance(v8::Local<v8::Context>) const
V8_WARN_UNUSED_RESULT MaybeLocal<Object> NewInstance(
^~~~~~~~~~~
/root/.node-gyp/10.4.0/include/node/v8.h:3908:44: note: candidate expects 1 argument, 2 provided
sha3.target.mk:99: recipe for target 'Release/obj.target/sha3/src/addon.o' failed
make: *** [Release/obj.target/sha3/src/addon.o] Error 1
make: Leaving directory '/root/tokenpool/node_modules/sha3/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:182:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:237:12)
gyp ERR! System Linux 4.15.0-22-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /root/tokenpool/node_modules/sha3
gyp ERR! node -v v10.4.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN ajv-keywords@3.1.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN webpack-cli@2.0.10 requires a peer of webpack@^4.0.0-beta.1 but none is installed. You must install peer dependencies yourself.
npm WARN TokenPool@1.4.0 No repository field.
npm WARN TokenPool@1.4.0 scripts['server'] should probably be scripts['start'].
npm WARN The package mocha is included as both a dev and production dependency.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sha3@1.2.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sha3@1.2.0 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! /root/.npm/_logs/2018-06-06T16_37_55_183Z-debug.log
Your version of GCC is incorrect i believe, or node-gyp is not the correct version. Something related to that. Basically its erroring when compiling the C code. What version of GCC are you running ? What version of node-gyp ?
Followed the instructions and ran
During
npm install
, there is an error building sha3. How can we fix this?Running node v10.4,0, npm v6.1.0, Ubuntu 18.04
Here is debug.log:
The text was updated successfully, but these errors were encountered: