TRIGGERcmd-Agent
TRIGGERcmd-Agent copied to clipboard
The built binary from source is broken
Hi, I have found many error when I tried build from source:
make: Entering directory 'TRIGGERcmd-Agent/node_modules/fs-xattr/build'
CXX(target) Release/obj.target/xattr/src/async.o
../src/async.cc: In member function ‘virtual void XattrWorker::HandleErrorCallback()’:
../src/async.cc:35:27: warning: ‘v8::Local<v8::Value> Nan::Callback::Call(int, v8::Local<v8::Value>*) const’ is deprecated [-Wdeprecated-declarations]
35 | callback->Call(1, argv);
| ^
In file included from ../src/async.cc:2:
../../nan/nan.h:1742:3: note: declared here
1742 | Call(int argc, v8::Local<v8::Value> argv[]) const {
| ^~~~
../src/async.cc: In constructor ‘SetWorker::SetWorker(v8::Local<v8::Value>, v8::Local<v8::Value>, v8::Local<v8::Value>, Nan::Callback*)’:
../src/async.cc:52:55: error: no matching function for call to ‘v8::Value::ToObject()’
52 | v8::Local<v8::Object> bufferObj = value->ToObject();
| ^
In file included from /home/build/.cache/node-gyp/12.9.0/include/node/node.h:63,
from ../src/async.cc:1:
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:2545:44: note: candidate: ‘v8::MaybeLocal<v8::Object> v8::Value::ToObject(v8::Local<v8::Context>) const’
2545 | V8_WARN_UNUSED_RESULT MaybeLocal<Object> ToObject(
| ^~~~~~~~
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:2545:44: note: candidate expects 1 argument, 0 provided
In file included from /home/build/.cache/node-gyp/12.9.0/include/node/v8-internal.h:14,
from /home/build/.cache/node-gyp/12.9.0/include/node/v8.h:25,
from /home/build/.cache/node-gyp/12.9.0/include/node/node.h:63,
from ../src/async.cc:1:
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:2559:31: note: candidate: ‘v8::Local<v8::Object> v8::Value::ToObject(v8::Isolate*) const’
2559 | Local<Object> ToObject(Isolate* isolate) const);
| ^~~~~~~~
/home/build/.cache/node-gyp/12.9.0/include/node/v8config.h:311:3: note: in definition of macro ‘V8_DEPRECATED’
311 | declarator __attribute__((deprecated(message)))
| ^~~~~~~~~~
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:2559:31: note: candidate expects 1 argument, 0 provided
2559 | Local<Object> ToObject(Isolate* isolate) const);
| ^~~~~~~~
/home/build/.cache/node-gyp/12.9.0/include/node/v8config.h:311:3: note: in definition of macro ‘V8_DEPRECATED’
311 | declarator __attribute__((deprecated(message)))
| ^~~~~~~~~~
../src/async.cc: In member function ‘virtual void GetWorker::HandleOKCallback()’:
../src/async.cc:129:27: warning: ‘v8::Local<v8::Value> Nan::Callback::Call(int, v8::Local<v8::Value>*) const’ is deprecated [-Wdeprecated-declarations]
129 | callback->Call(2, argv);
| ^
In file included from ../src/async.cc:2:
../../nan/nan.h:1742:3: note: declared here
1742 | Call(int argc, v8::Local<v8::Value> argv[]) const {
| ^~~~
../src/async.cc: In member function ‘virtual void ListWorker::HandleOKCallback()’:
../src/async.cc:186:27: warning: ‘v8::Local<v8::Value> Nan::Callback::Call(int, v8::Local<v8::Value>*) const’ is deprecated [-Wdeprecated-declarations]
186 | callback->Call(2, argv);
| ^
In file included from ../src/async.cc:2:
../../nan/nan.h:1742:3: note: declared here
1742 | Call(int argc, v8::Local<v8::Value> argv[]) const {
| ^~~~
In file included from /home/build/.cache/node-gyp/12.9.0/include/node/node.h:63,
from ../src/async.cc:1:
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h: In instantiation of ‘void v8::PersistentBase<T>::SetWeak(P*, typename v8::WeakCallbackInfo<P>::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo<P>::Callback = void (*)(const v8::WeakCallbackInfo<node::ObjectWrap>&)]’:
/home/build/.cache/node-gyp/12.9.0/include/node/node_object_wrap.h:84:78: required from here
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:9893:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo<node::ObjectWrap>::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<node::ObjectWrap>&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<void>&)’} [-Wcast-function-type]
9893 | reinterpret_cast<Callback>(callback), type);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h: In instantiation of ‘void v8::PersistentBase<T>::SetWeak(P*, typename v8::WeakCallbackInfo<P>::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo<P>::Callback = void (*)(const v8::WeakCallbackInfo<Nan::ObjectWrap>&)]’:
../../nan/nan_object_wrap.h:65:61: required from here
/home/build/.cache/node-gyp/12.9.0/include/node/v8.h:9893:16: warning: cast between incompatible function types from ‘v8::WeakCallbackInfo<Nan::ObjectWrap>::Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<Nan::ObjectWrap>&)’} to ‘Callback’ {aka ‘void (*)(const v8::WeakCallbackInfo<void>&)’} [-Wcast-function-type]
make: *** [xattr.target.mk:111: Release/obj.target/xattr/src/async.o] Error 1
make: Leaving directory '/home/build/rpmbuild/SOURCES/Alexy/TRIGGERcmd-Agent/node_modules/fs-xattr/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:196:23)
gyp ERR! stack at ChildProcess.emit (events.js:209:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 5.10.1-desktop-1bP
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/build/rpmbuild/SOURCES/Alexy/TRIGGERcmd-Agent/node_modules/fs-xattr
gyp ERR! node -v v12.9.0
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok
The binary is created, but I does not displayed on tray, and I get this error as well:
/usr/bin/triggercmdagent
A JavaScript error occurred in the main process
Uncaught Exception:
TypeError: app.requestSingleInstanceLock is not a function
at Object.<anonymous> (/usr/share/triggercmdagent/resources/app/src/main.js:110:24)
at Object.<anonymous> (/usr/share/triggercmdagent/resources/app/src/main.js:836:3)
at Module._compile (module.js:642:30)
at Object.require.extensions.(anonymous function) [as .js] (/usr/share/triggercmdagent/resources/app/node_modules/electron-compile/lib/require-hook.js:77:14)
at Module.load (module.js:561:32)
at tryModuleLoad (module.js:504:12)
at Function.Module._load (module.js:496:3)
at Module.require (module.js:586:17)
at Object.init (/usr/share/triggercmdagent/resources/app/node_modules/electron-compile/lib/config-parser.js:294:16)
at Object.<anonymous> (/usr/share/triggercmdagent/resources/app/es6-shim.js:8:17)