Hexagon / node-telldus

Node bindings for telldus-core
Other
34 stars 10 forks source link

node install fails on node 12 #78

Closed solidfox closed 4 years ago

solidfox commented 4 years ago

The last lines in the error message:

/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8config.h:311:3: note: in definition of macro 'V8_DEPRECATED'
   declarator __attribute__((deprecated(message)))
   ^~~~~~~~~~
../telldus.cc:920:34: error: no matching function for call to 'v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)'
     String::Utf8Value str(args[3]);
                                  ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:3039:5: note: candidate: 'v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::Value>)'
     Utf8Value(Isolate* isolate, Local<v8::Value> obj);
     ^~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:3039:5: note:   candidate expects 2 arguments, 1 provided
../telldus.cc:923:35: error: no matching function for call to 'v8::String::Utf8Value::Utf8Value(v8::Local<v8::Value>)'
     String::Utf8Value str2(args[4]);
                                   ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:3039:5: note: candidate: 'v8::String::Utf8Value::Utf8Value(v8::Isolate*, v8::Local<v8::Value>)'
     Utf8Value(Isolate* isolate, Local<v8::Value> obj);
     ^~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:3039:5: note:   candidate expects 2 arguments, 1 provided
../telldus.cc:927:36: error: no matching function for call to 'v8::Value::NumberValue()'
     work->f = args[0]->NumberValue(); // Worktype
                                    ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note: candidate: 'v8::Maybe<double> v8::Value::NumberValue(v8::Local<v8::Context>) const'
   V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
                                       ^~~~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note:   candidate expects 1 argument, 0 provided
../telldus.cc:928:40: error: no matching function for call to 'v8::Value::NumberValue()'
     work->devID = args[1]->NumberValue(); // Device ID
                                        ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note: candidate: 'v8::Maybe<double> v8::Value::NumberValue(v8::Local<v8::Context>) const'
   V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
                                       ^~~~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note:   candidate expects 1 argument, 0 provided
../telldus.cc:929:36: error: no matching function for call to 'v8::Value::NumberValue()'
     work->v = args[2]->NumberValue(); // Arbitrary number value
                                    ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note: candidate: 'v8::Maybe<double> v8::Value::NumberValue(v8::Local<v8::Context>) const'
   V8_WARN_UNUSED_RESULT Maybe<double> NumberValue(Local<Context> context) const;
                                       ^~~~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2608:39: note:   candidate expects 1 argument, 0 provided
../telldus.cc:1050:5: error: 'Handle' was not declared in this scope
     Handle<Value> argv;
     ^~~~~~
../telldus.cc:1050:5: note: suggested alternative: 'rand_r'
     Handle<Value> argv;
     ^~~~~~
     rand_r
../telldus.cc:1050:17: error: expected primary-expression before '>' token
     Handle<Value> argv;
                 ^
../telldus.cc:1050:19: error: 'argv' was not declared in this scope
     Handle<Value> argv;
                   ^~~~
../telldus.cc:1050:19: note: suggested alternative: 'args'
     Handle<Value> argv;
                   ^~~~
                   args
../telldus.cc:1090:53: warning: 'static v8::Local<v8::String> v8::String::NewFromUtf8(v8::Isolate*, const char*, v8::String::NewStringType, int)' is deprecated: Use maybe version [-Wdeprecated-declarations]
         argv = String::NewFromUtf8(isolate, work->rs); // Return string value
                                                     ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/v8-internal.h:14,
                 from /home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:25,
                 from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2936:21: note: declared here
       Local<String> NewFromUtf8(Isolate* isolate, const char* data,
                     ^~~~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8config.h:311:3: note: in definition of macro 'V8_DEPRECATED'
   declarator __attribute__((deprecated(message)))
   ^~~~~~~~~~
../telldus.cc:1090:53: warning: 'static v8::Local<v8::String> v8::String::NewFromUtf8(v8::Isolate*, const char*, v8::String::NewStringType, int)' is deprecated: Use maybe version [-Wdeprecated-declarations]
         argv = String::NewFromUtf8(isolate, work->rs); // Return string value
                                                     ^
In file included from /home/hoobs/.cache/node-gyp/12.13.1/include/node/v8-internal.h:14,
                 from /home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:25,
                 from /home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:63,
                 from ../telldus.cc:9:
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8.h:2936:21: note: declared here
       Local<String> NewFromUtf8(Isolate* isolate, const char* data,
                     ^~~~~~~~~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/v8config.h:311:3: note: in definition of macro 'V8_DEPRECATED'
   declarator __attribute__((deprecated(message)))
   ^~~~~~~~~~
../telldus.cc: At global scope:
../telldus.cc:1122:11: error: variable or field 'init' declared void
 void init(Handle<Object> exports) {
           ^~~~~~
../telldus.cc:1122:11: error: 'Handle' was not declared in this scope
../telldus.cc:1122:11: note: suggested alternative: 'rand_r'
 void init(Handle<Object> exports) {
           ^~~~~~
           rand_r
../telldus.cc:1122:24: error: expected primary-expression before '>' token
 void init(Handle<Object> exports) {
                        ^
../telldus.cc:1122:26: error: 'exports' was not declared in this scope
 void init(Handle<Object> exports) {
                          ^~~~~~~
In file included from ../telldus.cc:9:
../telldus.cc:1139:22: error: 'init' was not declared in this scope
 NODE_MODULE(telldus, init);
                      ^~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:566:36: note: in definition of macro 'NODE_MODULE_X'
       (node::addon_register_func) (regfunc),                          \
                                    ^~~~~~~
../telldus.cc:1139:1: note: in expansion of macro 'NODE_MODULE'
 NODE_MODULE(telldus, init);
 ^~~~~~~~~~~
../telldus.cc:1139:22: note: suggested alternative: 'int'
 NODE_MODULE(telldus, init);
                      ^~~~
/home/hoobs/.cache/node-gyp/12.13.1/include/node/node.h:566:36: note: in definition of macro 'NODE_MODULE_X'
       (node::addon_register_func) (regfunc),                          \
                                    ^~~~~~~
../telldus.cc:1139:1: note: in expansion of macro 'NODE_MODULE'
 NODE_MODULE(telldus, init);
 ^~~~~~~~~~~
../telldus.cc: In function 'void telldus_v8::SyncCaller(const v8::FunctionCallbackInfo<v8::Value>&)':
../telldus.cc:1044:35: warning: this statement may fall through [-Wimplicit-fallthrough=]
           work->l = getDevicesRaw();
                                   ^
../telldus.cc:1045:9: note: here
         case 27: // getSensors
         ^~~~
make: *** [telldus.target.mk:105: Release/obj.target/telldus/telldus.o] Error 1
make: Leaving directory '/home/hoobs/.hoobs/node_modules/telldus/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:194:23)
gyp ERR! stack     at ChildProcess.emit (events.js:210:5)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.19.75-v7+
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "build"
gyp ERR! cwd /home/hoobs/.hoobs/node_modules/telldus
gyp ERR! node -v v12.13.1
gyp ERR! node-gyp -v v5.0.5
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! telldus@1.1.2 install: `node-gyp configure build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the telldus@1.1.2 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!     /home/hoobs/.npm/_logs/2019-12-17T14_36_17_974Z-debug.log