Failed at the [email protected] install script 'node-gyp rebuild'
Ubuntu 16.04 Ive tried this on 14.04 as well with no luck.
None of the NodeJS versions will build Cryptonote-Util. It was suggested that i use NodeJS 0.8, however I cannot find any builds of node that are compatible.
Readout from Node 0.12:
> [email protected] install /home/ponyexpress/pool/node_modules/cryptonote-util
> node-gyp rebuild
make: Entering directory '/home/ponyexpress/pool/node_modules/cryptonote-util/build'
CXX(target) Release/obj.target/cryptonote/src/main.o
../src/main.cc: In function ‘v8::Handle<v8::Value> except(const char*)’:
../src/main.cc:19:44: error: ‘New’ is not a member of ‘v8::String’
return ThrowException(Exception::Error(String::New(msg)));
^
../src/main.cc:19:61: error: ‘ThrowException’ was not declared in this scope
return ThrowException(Exception::Error(String::New(msg)));
^
../src/main.cc: At global scope:
../src/main.cc:35:34: error: ‘Arguments’ does not name a type
Handle<Value> convert_blob(const Arguments& args) {
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> convert_blob(const int&)’:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:36:17: error: within this context
HandleScope scope;
^
../src/main.cc:38:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:41:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:56:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:56:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:56:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:57:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: At global scope:
../src/main.cc:60:37: error: ‘Arguments’ does not name a type
Handle<Value> convert_blob_bb(const Arguments& args) {
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> convert_blob_bb(const int&)’:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:61:17: error: within this context
HandleScope scope;
^
../src/main.cc:63:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:66:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:81:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:81:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:81:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:82:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: At global scope:
../src/main.cc:85:36: error: ‘Arguments’ does not name a type
Handle<Value> address_decode(const Arguments& args) {
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> address_decode(const int&)’:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:86:17: error: within this context
HandleScope scope;
^
../src/main.cc:88:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:91:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:106:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:106:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:106:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:107:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: In function ‘void init(v8::Handle<v8::Object>)’:
../src/main.cc:111:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("convert_blob"), FunctionTemplate::New(conve
^
../src/main.cc:111:87: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
tring::NewSymbol("convert_blob"), FunctionTemplate::New(convert_blob)->GetFunct
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
../src/main.cc:112:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("convert_blob_bb"), FunctionTemplate::New(co
^
../src/main.cc:112:93: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
:NewSymbol("convert_blob_bb"), FunctionTemplate::New(convert_blob_bb)->GetFunct
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
../src/main.cc:113:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("address_decode"), FunctionTemplate::New(add
^
../src/main.cc:113:91: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
g::NewSymbol("address_decode"), FunctionTemplate::New(address_decode)->GetFunct
^
In file included from /home/ponyexpress/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/ponyexpress/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
cryptonote.target.mk:103: recipe for target 'Release/obj.target/cryptonote/src/main.o' failed
make: *** [Release/obj.target/cryptonote/src/main.o] Error 1
make: Leaving directory '/home/ponyexpress/pool/node_modules/cryptonote-util/build'
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:276:23)
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.4.0-38-generic
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/ponyexpress/pool/node_modules/cryptonote-util
gyp ERR! node -v v6.6.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
[email protected] /home/ponyexpress/pool
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected]
├── [email protected] (git://github.com/zone117x/node-multi-hashing.git#73996fe77104108f2d66ef750b3e1bce42e4d8f0)
└── [email protected]
npm ERR! Linux 4.4.0-38-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "update"
npm ERR! node v6.6.0
npm ERR! npm v3.10.7
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the cryptonote-util package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs cryptonote-util
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls cryptonote-util
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/ponyexpress/pool/npm-debug.log
Readout from NodeJS 0.10:
> [email protected] install /home/bigboyfluffypants/pool/node_modules/cryptonote-util
> node-gyp rebuild
make: Entering directory '/home/bigboyfluffypants/pool/node_modules/cryptonote-util/build'
CXX(target) Release/obj.target/cryptonote/src/main.o
../src/main.cc: In function ‘v8::Handle<v8::Value> except(const char*)’:
../src/main.cc:19:44: error: ‘New’ is not a member of ‘v8::String’
return ThrowException(Exception::Error(String::New(msg)));
^
../src/main.cc:19:61: error: ‘ThrowException’ was not declared in this scope
return ThrowException(Exception::Error(String::New(msg)));
^
../src/main.cc: At global scope:
../src/main.cc:35:34: error: ‘Arguments’ does not name a type
Handle<Value> convert_blob(const Arguments& args) {
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> convert_blob(const int&)’:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:36:17: error: within this context
HandleScope scope;
^
../src/main.cc:38:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:41:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:56:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:56:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:56:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:57:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: At global scope:
../src/main.cc:60:37: error: ‘Arguments’ does not name a type
Handle<Value> convert_blob_bb(const Arguments& args) {
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> convert_blob_bb(const int&)’:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:61:17: error: within this context
HandleScope scope;
^
../src/main.cc:63:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:66:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:81:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:81:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:81:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:82:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: At global scope:
../src/main.cc:85:36: error: ‘Arguments’ does not name a type
Handle<Value> address_decode(const Arguments& args) {
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h: In function ‘v8::Handle<v8::Value> address_decode(const int&)’:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:915:13: error: ‘v8::HandleScope::HandleScope()’ is protected
V8_INLINE HandleScope() {}
^
../src/main.cc:86:17: error: within this context
HandleScope scope;
^
../src/main.cc:88:14: error: request for member ‘Length’ in ‘args’, which is of non-class type ‘const int’
if (args.Length() < 1)
^
../src/main.cc:91:34: error: invalid types ‘const int[int]’ for array subscript
Local<Object> target = args[0]->ToObject();
^
../src/main.cc:106:11: error: expected primary-expression before ‘*’ token
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:106:13: error: ‘buff’ was not declared in this scope
Buffer* buff = Buffer::New(output.data(), output.size());
^
../src/main.cc:106:60: error: no matching function for call to ‘New(const char*, std::__cxx11::basic_string<char>::size_type)’
Buffer* buff = Buffer::New(output.data(), output.size());
^
In file included from ../src/main.cc:2:0:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate, size_t length)
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:31:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, v8::Local<v8::String>, node::encoding)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:34:40: note: no known conversion for argument 1 from ‘const char*’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t, node::Buffer::FreeCallback, void*)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:39:40: note: candidate expects 5 arguments, 2 provided
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate: v8::MaybeLocal<v8::Object> node::Buffer::New(v8::Isolate*, char*, size_t)
NODE_EXTERN v8::MaybeLocal<v8::Object> New(v8::Isolate* isolate,
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node_buffer.h:46:40: note: candidate expects 3 arguments, 2 provided
../src/main.cc:107:18: error: ‘class v8::HandleScope’ has no member named ‘Close’
return scope.Close(buff->handle_);
^
../src/main.cc: In function ‘void init(v8::Handle<v8::Object>)’:
../src/main.cc:111:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("convert_blob"), FunctionTemplate::New(conve
^
../src/main.cc:111:87: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
tring::NewSymbol("convert_blob"), FunctionTemplate::New(convert_blob)->GetFunct
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
../src/main.cc:112:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("convert_blob_bb"), FunctionTemplate::New(co
^
../src/main.cc:112:93: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
:NewSymbol("convert_blob_bb"), FunctionTemplate::New(convert_blob_bb)->GetFunct
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
../src/main.cc:113:18: error: ‘NewSymbol’ is not a member of ‘v8::String’
exports->Set(String::NewSymbol("address_decode"), FunctionTemplate::New(add
^
../src/main.cc:113:91: error: no matching function for call to ‘v8::FunctionTemplate::New(v8::Handle<v8::Value> (&)(const int&))’
g::NewSymbol("address_decode"), FunctionTemplate::New(address_decode)->GetFunct
^
In file included from /home/bigboyfluffypants/.node-gyp/6.6.0/include/node/node.h:42:0,
from ../src/main.cc:1:
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4483:34: note: no known conversion for argument 1 from ‘v8::Handle<v8::Value>(const int&) {aka v8::Local<v8::Value>(const int&)}’ to ‘v8::Isolate*’
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate: static v8::Local<v8::FunctionTemplate> v8::FunctionTemplate::New(v8::Isolate*, v8::FunctionCallback, v8::Local<v8::Value>, v8::Local<v8::Signature>, int, v8::ConstructorBehavior)
static Local<FunctionTemplate> New(
^
/home/bigboyfluffypants/.node-gyp/6.6.0/include/node/v8.h:4487:34: note: candidate expects 6 arguments, 1 provided
cryptonote.target.mk:103: recipe for target 'Release/obj.target/cryptonote/src/main.o' failed
make: *** [Release/obj.target/cryptonote/src/main.o] Error 1
make: Leaving directory '/home/bigboyfluffypants/pool/node_modules/cryptonote-util/build'
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:276:23)
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.4.0-38-generic
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/bigboyfluffypants/pool/node_modules/cryptonote-util
gyp ERR! node -v v6.6.0
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
[email protected] /home/bigboyfluffypants/pool
└── [email protected] (git://github.com/zone117x/node-multi-hashing.git#73996fe77104108f2d66ef750b3e1bce42e4d8f0)
npm ERR! Linux 4.4.0-38-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "update"
npm ERR! node v6.6.0
npm ERR! npm v3.10.7
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the cryptonote-util package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs cryptonote-util
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls cryptonote-util
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/bigboyfluffypants/pool/npm-debug.log
Try a different version of v8
I've got the exact same issue using ubuntu 16.04, please help. Node v.6.7.0 NPM v.3.10.3
Install instructions for NodeJS and NPM on Ubuntu 14.04 and 16.04:
First remove NodeJS:
sudo ap-get remove npm nodejs -y
Then download and unzip NodeJS v0.10.25
wget https://nodejs.org/dist/v0.10.25/node-v0.10.25.tar.gz && tar xvzf node-v0.10.25.tar.gz
Compile and Install NodeJS and NPM from the source:
cd node-v0.10.25
make
sudo make install
Make sure to remove node_modules directory before you run npm update
I use node version 0.10.48 with much success. I believe any 0.10.X version should work. I also use the Node Version Manager to install / select / test various node versions.
https://www.digitalocean.com/community/tutorials/how-to-install-node-js-with-nvm-node-version-manager-on-a-vps
And as recommended above. Building from source would work just as well.
@devinjdawson you're using node version 6 in both of your examples. Even though the second one is listed at 0.10. Check your logs.
you could also use: curl -sL https://deb.nodesource.com/setup_0.10 | sudo -E bash - sudo apt-get install -y nodejs
Hi,
I have a similar issue, and even following devinjdawson's instructions it fails:
[email protected] install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is most likely a problem with the cryptonote-util package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get their info via:
npm ERR! npm owner ls cryptonote-util
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.13.0-110-generic
npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "update"
npm ERR! cwd /home/monero/pool
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.24
npm ERR! code ELIFECYCLE
[email protected] node_modules/multi-hashing
└── [email protected]
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/monero/pool/npm-debug.log
npm ERR! not ok code 0
Linux version: Linux vm4 3.13.0-110-generic #157-Ubuntu SMP Mon Feb 20 11:54:05 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux Ubuntu 14.04.5 LTS
Thanks
@devinjdawson I had the same issue, you have to make sure to use node 0.6.48
EDIT: FIXED SEE MY RESPONSE BELOW
@denniselmenace can you clarify which node version to use? I am having this same issue but cannot find "node 0.6.48"
Having this issue as well. I've tried 1000 different ways and i can't get npm build to work. On a new Digital Ocean droplet with Ubuntu 14.04 I'm running only the following commands but it fails every time, no matter what version of node I try:
Commands run on new droplet:
apt-get update -y apt-get upgrade -y apt-get install -y git redis-server libboost1.55-all-dev cmake libssl-dev gcc build-essential libssl-dev git clone https://github.com/zone117x/node-cryptonote-pool.git pool wget https://nodejs.org/dist/v0.10.48/node-v0.10.48.tar.gz && tar xvzf node-v0.10.48.tar.gz cd node-v0.10.48 make make install cd ~/pool npm update
Output Errors:
[email protected] node_modules/bignum
├── [email protected]
└── [email protected] ([email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected])
make: Entering directory '/root/pool/node_modules/cryptonote-util/build'
CXX(target) Release/obj.target/cryptonote/src/main.o
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-5/README.Bugs> for instructions.
cryptonote.target.mk:104: recipe for target 'Release/obj.target/cryptonote/src/main.o' failed
make: *** [Release/obj.target/cryptonote/src/main.o] Error 4
make: Leaving directory '/root/pool/node_modules/cryptonote-util/build'
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:276:23)
gyp ERR! stack at ChildProcess.emit (events.js:98:17)
gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:820:12)
gyp ERR! System Linux 4.4.0-78-generic
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /root/pool/node_modules/cryptonote-util
gyp ERR! node -v v0.10.48
gyp ERR! node-gyp -v v3.3.1
gyp ERR! not ok
make: Leaving directory '/root/pool/node_modules/multi-hashing/build'
[email protected] node_modules/multi-hashing
└── [email protected]
npm ERR! Linux 4.4.0-78-generic
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "update"
npm ERR! node v0.10.48
npm ERR! npm v2.15.1
npm ERR! code ELIFECYCLE
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script 'node-gyp rebuild'.
npm ERR! This is most likely a problem with the cryptonote-util package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs cryptonote-util
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!
npm ERR! npm owner ls cryptonote-util
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /root/pool/npm-debug.log
@bgroins I've figured it out! At least for my system. Before compiling and any time you need to recompile delete the folder .node-gyp (mine was in my root so I do "rm -rf ~/.node-gyp"). After this reboot! If you don't reboot you will get same error. Now go into your project folder and "npm update", it should work now!
Using node v 0.10.48
After replace/downgrade nodejs version it works for me. Spacial Thanks @nibbons , @devinjdawson , @edilio
when the owner of cryptonote-util will fix finally his module
curl -o /tmp/use_nodejs_version_9.sh -sL https://deb.nodesource.com/setup_9.x sh /tmp/use_nodejs_version_9.sh sudo apt-get install nodejs -qy