Skip to content

compilation Error nodejs v12 #20

@fezzz

Description

@fezzz

Hi,

compiling for nodejs v12 is not possible, could you please update in order to be v8 compliant?

Thanks,
Felix

pi@xxx:/usr/local/lib $ sudo npm install -g --unsafe-perm socketwatcher -g

socketwatcher@0.3.0 install /usr/local/lib/node_modules/socketwatcher
node-gyp rebuild

make: Verzeichnis „/usr/local/lib/node_modules/socketwatcher/build“ wird betreten
CXX(target) Release/obj.target/socketwatcher/socket_watcher.o
../socket_watcher.cpp: In static member function ‘static void SocketWatcher::Initialize(v8::Localv8::Object)’:
../socket_watcher.cpp:29:36: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’
constructor.Reset(t->GetFunction());
^
In file included from /root/.cache/node-gyp/12.8.1/include/node/node.h:63:0,
from ../node_modules/nan/nan.h:54,
from ../socket_watcher.hpp:8,
from ../socket_watcher.cpp:5:
/root/.cache/node-gyp/12.8.1/include/node/v8.h:5955:46: note: candidate: v8::MaybeLocalv8::Function v8::FunctionTemplate::GetFunction(v8::Localv8::Context)
V8_WARN_UNUSED_RESULT MaybeLocal GetFunction(
^~~~~~~~~~~
/root/.cache/node-gyp/12.8.1/include/node/v8.h:5955:46: note: candidate expects 1 argument, 0 provided
../socket_watcher.cpp:30:75: error: no matching function for call to ‘v8::FunctionTemplate::GetFunction()’
exports->Set(Nan::New("SocketWatcher").ToLocalChecked(), t->GetFunction());
^
In file included from /root/.cache/node-gyp/12.8.1/include/node/node.h:63:0,
from ../node_modules/nan/nan.h:54,
from ../socket_watcher.hpp:8,
from ../socket_watcher.cpp:5:
/root/.cache/node-gyp/12.8.1/include/node/v8.h:5955:46: note: candidate: v8::MaybeLocalv8::Function v8::FunctionTemplate::GetFunction(v8::Localv8::Context)
V8_WARN_UNUSED_RESULT MaybeLocal GetFunction(
^~~~~~~~~~~
/root/.cache/node-gyp/12.8.1/include/node/v8.h:5955:46: note: candidate expects 1 argument, 0 provided
../socket_watcher.cpp: In static member function ‘static void SocketWatcher::Callback(uv_poll_t*, int, int)’:
../socket_watcher.cpp:77:60: warning: ‘v8::Localv8::Value Nan::MakeCallback(v8::Localv8::Object, v8::Localv8::Function, int, v8::Localv8::Value)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(watcher->handle(), callback, argc, argv);
^
In file included from ../socket_watcher.hpp:8:0,
from ../socket_watcher.cpp:5:
../node_modules/nan/nan.h:1024:46: note: declared here
NAN_DEPRECATED inline v8::Localv8::Value MakeCallback(
^~~~~~~~~~~~
../socket_watcher.cpp: In static member function ‘static void SocketWatcher::New(const Nan::FunctionCallbackInfov8::Value&)’:
../socket_watcher.cpp:104:49: error: no matching function for call to ‘v8::Function::NewInstance()’
info.GetReturnValue().Set(cons->NewInstance());
^
In file included from /root/.cache/node-gyp/12.8.1/include/node/node.h:63:0,
from ../node_modules/nan/nan.h:54,
from ../socket_watcher.hpp:8,
from ../socket_watcher.cpp:5:
/root/.cache/node-gyp/12.8.1/include/node/v8.h:4138:44: note: candidate: v8::MaybeLocalv8::Object v8::Function::NewInstance(v8::Localv8::Context, int, v8::Localv8::Value
) const
V8_WARN_UNUSED_RESULT MaybeLocal NewInstance(
^~~~~~~~~~~
/root/.cache/node-gyp/12.8.1/include/node/v8.h:4138:44: note: candidate expects 3 arguments, 0 provided
/root/.cache/node-gyp/12.8.1/include/node/v8.h:4141:44: note: candidate: v8::MaybeLocalv8::Object v8::Function::NewInstance(v8::Localv8::Context) const
V8_WARN_UNUSED_RESULT MaybeLocal NewInstance(
^~~~~~~~~~~
/root/.cache/node-gyp/12.8.1/include/node/v8.h:4141:44: note: candidate expects 1 argument, 0 provided
../socket_watcher.cpp: In static member function ‘static void SocketWatcher::Set(const Nan::FunctionCallbackInfov8::Value&)’:
../socket_watcher.cpp:116:32: error: no matching function for call to ‘v8::Value::Int32Value()’
int fd = info[0]->Int32Value();
^
In file included from /root/.cache/node-gyp/12.8.1/include/node/node.h:63:0,
from ../node_modules/nan/nan.h:54,
from ../socket_watcher.hpp:8,
from ../socket_watcher.cpp:5:
/root/.cache/node-gyp/12.8.1/include/node/v8.h:2576:40: note: candidate: v8::Maybe v8::Value::Int32Value(v8::Localv8::Context) const
V8_WARN_UNUSED_RESULT Maybe<int32_t> Int32Value(Local context) const;
^~~~~~~~~~
/root/.cache/node-gyp/12.8.1/include/node/v8.h:2576:40: note: candidate expects 1 argument, 0 provided
socketwatcher.target.mk:107: die Regel für Ziel „Release/obj.target/socketwatcher/socket_watcher.o“ scheiterte
make: *** [Release/obj.target/socketwatcher/socket_watcher.o] Fehler 1
make: Verzeichnis „/usr/local/lib/node_modules/socketwatcher/build“ wird verlassen
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:196:23)
gyp ERR! stack at ChildProcess.emit (events.js:203:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.19.66-v7+
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 /usr/local/lib/node_modules/socketwatcher
gyp ERR! node -v v12.8.1
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! socketwatcher@0.3.0 install: node-gyp rebuild
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the socketwatcher@0.3.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/2019-08-20T15_43_29_027Z-debug.log

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions