Closed wjandrea closed 3 years ago
It looks like we're still having trouble with one of our native dependencies.
Here's a workaround to install Hydrogen in Ubuntu:
$ sudo apt-get install libzmq3-dev
$ npm_config_zmq_external=true apm install hydrogen # and restart atom if it was already open
I can reproduce the issue:
::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo
::Callback = void (*)(const v8::WeakCallbackInfo ::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo ::Callback = void (*)(const v8::WeakCallbackInfo ::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo ::Callback = void (*)(const v8::WeakCallbackInfo ::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo ::Callback = void (*)(const v8::WeakCallbackInfo
Can you run node-gyp-build
inside node_modules/@aminya/zeromq
and give me the result? I don't understand why it even builds as prebuilds are already included in the package!
@aminya
Here's what I get:
$ npm --versions
{
npm: '6.14.12',
ares: '1.16.1',
brotli: '1.0.9',
cldr: '37.0',
icu: '67.1',
llhttp: '2.1.3',
modules: '83',
napi: '7',
nghttp2: '1.41.0',
node: '14.16.1',
openssl: '1.1.1k',
tz: '2020a',
unicode: '13.0',
uv: '1.40.0',
v8: '8.4.371.19-node.18',
zlib: '1.2.11'
}
$ npm_config_zmq_external=true apm install hydrogen
Installing hydrogen to /home/nriesco/.atom/packages ✓
$ npm i -g node-gyp-build
/home/nriesco/bin/node-gyp-build -> /home/nriesco/lib/node_modules/node-gyp-build/bin.js
/home/nriesco/bin/node-gyp-build-optional -> /home/nriesco/lib/node_modules/node-gyp-build/optional.js
/home/nriesco/bin/node-gyp-build-test -> /home/nriesco/lib/node_modules/node-gyp-build/build-test.js
+ node-gyp-build@4.2.3
updated 1 package in 0.253s
$ npm i -g node-gyp
/home/nriesco/bin/node-gyp -> /home/nriesco/lib/node_modules/node-gyp/bin/node-gyp.js
+ node-gyp@8.0.0
updated 1 package in 2.377s
$ cd .atom/packages/Hydrogen/node_modules/\@aminya/zeromq/
$ node-gyp-build
gyp info it worked if it ends with ok
gyp info using node-gyp@8.0.0
gyp info using node@14.16.1 | linux | x64
gyp info find Python using Python version 3.7.3 found at "/usr/bin/python3"
gyp info spawn /usr/bin/python3
gyp info spawn args [
gyp info spawn args '/home/nriesco/lib/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args 'binding.gyp',
gyp info spawn args '-f',
gyp info spawn args 'make',
gyp info spawn args '-I',
gyp info spawn args '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build/config.gypi',
gyp info spawn args '-I',
gyp info spawn args '/home/nriesco/lib/node_modules/node-gyp/addon.gypi',
gyp info spawn args '-I',
gyp info spawn args '/home/nriesco/.cache/node-gyp/14.16.1/include/node/common.gypi',
gyp info spawn args '-Dlibrary=shared_library',
gyp info spawn args '-Dvisibility=default',
gyp info spawn args '-Dnode_root_dir=/home/nriesco/.cache/node-gyp/14.16.1',
gyp info spawn args '-Dnode_gyp_dir=/home/nriesco/lib/node_modules/node-gyp',
gyp info spawn args '-Dnode_lib_file=/home/nriesco/.cache/node-gyp/14.16.1/<(target_arch)/node.lib',
gyp info spawn args '-Dmodule_root_dir=/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq',
gyp info spawn args '-Dnode_engine=v8',
gyp info spawn args '--depth=.',
gyp info spawn args '--no-parallel',
gyp info spawn args '--generator-output',
gyp info spawn args 'build',
gyp info spawn args '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
make: Entering directory '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build'
ACTION binding_gyp_libzmq_target_prepare_build zmq/BUILD_SUCCESS
Building libzmq for linux
child process exited with code null
TOUCH Release/obj.target/libzmq.stamp
CXX(target) Release/obj.target/zmq/binding.o
../binding.cc: In member function ‘void zmq::Socket::NotifyReadReady()’:
../binding.cc:399:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 0, NULL);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:399:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 0, NULL);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In member function ‘void zmq::Socket::NotifySendReady()’:
../binding.cc:407:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 0, NULL);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:407:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 0, NULL);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In member function ‘void zmq::Socket::MonitorEvent(uint16_t, int32_t, char*)’:
../binding.cc:458:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 4, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:458:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 4, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In member function ‘void zmq::Socket::MonitorError(const char*)’:
../binding.cc:473:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:473:73: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(this->handle(), callback_v.As<Function>(), 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In static member function ‘static void zmq::Socket::UV_MonitorCallback(uv_timer_t*, int)’:
../binding.cc:545:98: warning: cast between incompatible function types from ‘void (*)(uv_timer_t*, int)’ {aka ‘void (*)(uv_timer_s*, int)’} to ‘uv_timer_cb’ {aka ‘void (*)(uv_timer_s*)’} [-Wcast-function-type]
uv_timer_start(s->monitor_handle_, reinterpret_cast<uv_timer_cb>(Socket::UV_MonitorCallback), s->timer_interval_, 0);
^
../binding.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE zmq::Socket::Bind(Nan::NAN_METHOD_ARGS_TYPE)’:
../binding.cc:779:37: warning: cast between incompatible function types from ‘void (*)(uv_work_t*)’ {aka ‘void (*)(uv_work_s*)’} to ‘uv_after_work_cb’ {aka ‘void (*)(uv_work_s*, int)’} [-Wcast-function-type]
(uv_after_work_cb)UV_BindAsyncAfter);
^~~~~~~~~~~~~~~~~
../binding.cc: In static member function ‘static void zmq::Socket::UV_BindAsyncAfter(uv_work_t*)’:
../binding.cc:814:70: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(Nan::GetCurrentContext()->Global(), cb, 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:814:70: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(Nan::GetCurrentContext()->Global(), cb, 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE zmq::Socket::Unbind(Nan::NAN_METHOD_ARGS_TYPE)’:
../binding.cc:860:37: warning: cast between incompatible function types from ‘void (*)(uv_work_t*)’ {aka ‘void (*)(uv_work_s*)’} to ‘uv_after_work_cb’ {aka ‘void (*)(uv_work_s*, int)’} [-Wcast-function-type]
(uv_after_work_cb)UV_UnbindAsyncAfter);
^~~~~~~~~~~~~~~~~~~
../binding.cc: In static member function ‘static void zmq::Socket::UV_UnbindAsyncAfter(uv_work_t*)’:
../binding.cc:893:70: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(Nan::GetCurrentContext()->Global(), cb, 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc:893:70: warning: ‘v8::Local<v8::Value> Nan::MakeCallback(v8::Local<v8::Object>, v8::Local<v8::Function>, int, v8::Local<v8::Value>*)’ is deprecated [-Wdeprecated-declarations]
Nan::MakeCallback(Nan::GetCurrentContext()->Global(), cb, 1, argv);
^
In file included from ../binding.cc:40:
../../../nan/nan.h:1026:46: note: declared here
NAN_DEPRECATED inline v8::Local<v8::Value> MakeCallback(
^~~~~~~~~~~~
../binding.cc: In static member function ‘static Nan::NAN_METHOD_RETURN_TYPE zmq::Socket::Monitor(Nan::NAN_METHOD_ARGS_TYPE)’:
../binding.cc:1122:103: warning: cast between incompatible function types from ‘void (*)(uv_timer_t*, int)’ {aka ‘void (*)(uv_timer_s*, int)’} to ‘uv_timer_cb’ {aka ‘void (*)(uv_timer_s*)’} [-Wcast-function-type]
uv_timer_start(socket->monitor_handle_, reinterpret_cast<uv_timer_cb>(Socket::UV_MonitorCallback), timer_interval, 0);
^
In file included from ../binding.cc:25:
../binding.cc: At global scope:
/home/nriesco/.cache/node-gyp/14.16.1/include/node/node.h:758:43: warning: cast between incompatible function types from ‘void (*)(Nan::ADDON_REGISTER_FUNCTION_ARGS_TYPE)’ {aka ‘void (*)(v8::Local<v8::Object>)’} to ‘node::addon_register_func’ {aka ‘void (*)(v8::Local<v8::Object>, v8::Local<v8::Value>, void*)’} [-Wcast-function-type]
(node::addon_register_func) (regfunc), \
^
/home/nriesco/.cache/node-gyp/14.16.1/include/node/node.h:792:3: note: in expansion of macro ‘NODE_MODULE_X’
NODE_MODULE_X(modname, regfunc, NULL, 0) // NOLINT (readability/null_usage)
^~~~~~~~~~~~~
../binding.cc:1558:1: note: in expansion of macro ‘NODE_MODULE’
NODE_MODULE(zmq, init)
^~~~~~~~~~~
In file included from ../binding.cc:24:
/home/nriesco/.cache/node-gyp/14.16.1/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/nriesco/.cache/node-gyp/14.16.1/include/node/node_object_wrap.h:85:78: required from here
/home/nriesco/.cache/node-gyp/14.16.1/include/node/v8.h:10874: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]
reinterpret_cast<Callback>(callback), type);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/nriesco/.cache/node-gyp/14.16.1/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/nriesco/.cache/node-gyp/14.16.1/include/node/v8.h:10874: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]
SOLINK_MODULE(target) Release/obj.target/zmq.node
g++: error: ./Release/../../zmq/lib/libzmq.a: No such file or directory
make: *** [zmq.target.mk:143: Release/obj.target/zmq.node] Error 1
make: Leaving directory '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build'
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/home/nriesco/lib/node_modules/node-gyp/lib/build.js:194:23)
gyp ERR! stack at ChildProcess.emit (events.js:315:20)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
gyp ERR! System Linux 5.4.0-72-generic
gyp ERR! command "/home/nriesco/.local/lib/node-v14.16.1-linux-x64/bin/node" "/home/nriesco/lib/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
gyp ERR! node -v v14.16.1
gyp ERR! node-gyp -v v8.0.0
gyp ERR! not ok
$
Oh, forgot that running node-gyp-build
directly doesn't work as you are using your system's npm rather than what apm
uses. So, it will not find prebuilds.
@aminya Please, see https://github.com/zeromq/zeromq.js/pull/458 . It fixes the issue with building from source.
Is there anything I can do to debug why node-gyp-build
doesn't use the prebuilts?
I see these prebuilts in the package installed by Hydrogen:
$ find . -name *.node
./build/Release/obj.target/zmq.node
./build/Release/zmq.node
./prebuilds/linux-x64/node.abi72.node
./prebuilds/linux-x64/electron.abi80.node
./prebuilds/linux-x64/electron.abi73.node
./prebuilds/linux-x64/electron.abi70.node
./prebuilds/win32-x64/node.abi72.node
./prebuilds/win32-x64/electron.abi80.node
./prebuilds/win32-x64/electron.abi73.node
./prebuilds/win32-x64/electron.abi70.node
./prebuilds/darwin-x64/node.abi72.node
./prebuilds/darwin-x64/electron.abi80.node
./prebuilds/darwin-x64/electron.abi73.node
./prebuilds/darwin-x64/electron.abi70.node
./prebuilds/win32-ia32/node.abi72.node
./prebuilds/win32-ia32/electron.abi80.node
./prebuilds/win32-ia32/electron.abi73.node
./prebuilds/win32-ia32/electron.abi70.node
Try apm install --verbose
and see what happens inside node-gyp-build before it starts to build from the source. There should be a message like: No prebuilds were found for this architecture.
No message, it goes directly to build from source:
$ pwd
/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
$ apm install --verbose
Installing modules npm WARN deprecated mkdirp@0.5.1: Legacy versions of mkdirp are no longer supported. Please update to mkdirp 1.x. (Note that the API surface has changed to use Promises in 1.x.)
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
> @aminya/zeromq@5.2.15 install /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
> node-gyp-build || npm run build:libzmq
make: Entering directory '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build'
ACTION binding_gyp_libzmq_target_prepare_build zmq/BUILD_SUCCESS
Building libzmq for linux
[...]
@aminya
I've edited package.json
so that install
invokes node-gyp-build-test
. This shows that we need the prebuilt for ABI 72 (Atom v1.56.0 comes with node v12.14.1, i.e. ABI 72).
$ apm install --verbose
Installing modules
> @aminya/zeromq@5.2.15 install /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
> node-gyp-build-test || npm run build:libzmq
internal/modules/cjs/loader.js:815
return process.dlopen(module, path.toNamespacedPath(filename));
^
Error: The module '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build/Release/zmq.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 80. This version of Node.js requires
NODE_MODULE_VERSION 72. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
at Object.Module._extensions..node (internal/modules/cjs/loader.js:815:18)
at Module.load (internal/modules/cjs/loader.js:641:32)
at Function.Module._load (internal/modules/cjs/loader.js:556:12)
at Module.require (internal/modules/cjs/loader.js:681:19)
at require (internal/modules/cjs/helpers.js:16:16)
at load (/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/node_modules/node-gyp-build/index.js:21:10)
at Object.<anonymous> (/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/node_modules/node-gyp-build/build-test.js:19:19)
at Module._compile (internal/modules/cjs/loader.js:774:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:785:10)
at Module.load (internal/modules/cjs/loader.js:641:32)
The error from Node-js is a little fuzzy. Electron's ABI versions are usually 1 number more than Node's ABI version. So, when it says 72, it probably means 73, which as you see it is included:
OK, this is what I get after I delete the zmq.node
I had previously built. Now, the error is similar to what one of our users reported:
$ rm -rf build/Release/
$ apm install --verbose
Installing modules
> @aminya/zeromq@5.2.15 install /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
> node-gyp-build-test || npm run build:libzmq
internal/modules/cjs/loader.js:815
return process.dlopen(module, path.toNamespacedPath(filename));
^
Error: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.26' not found (required by /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/prebuilds/linux-x64/node.abi72.node)
at Object.Module._extensions..node (internal/modules/cjs/loader.js:815:18)
at Module.load (internal/modules/cjs/loader.js:641:32)
at Function.Module._load (internal/modules/cjs/loader.js:556:12)
at Module.require (internal/modules/cjs/loader.js:681:19)
at require (internal/modules/cjs/helpers.js:16:16)
at load (/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/node_modules/node-gyp-build/index.js:21:10)
at Object.<anonymous> (/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/node_modules/node-gyp-build/build-test.js:19:19)
at Module._compile (internal/modules/cjs/loader.js:774:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:785:10)
at Module.load (internal/modules/cjs/loader.js:641:32)
> @aminya/zeromq@5.2.15 build:libzmq /home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq
> node-gyp rebuild
make: Entering directory '/home/nriesco/.atom/packages/Hydrogen/node_modules/@aminya/zeromq/build'
[...]
I haven't found a general solution for the version 'GLIBCXX_3.4.22' not found
error other than installing libstdc++.
It's installed in my machine. I guess the problem is the version.
I am asking the question again to see if we can do anything about it https://github.com/nodejs/node-gyp/issues/2297#issuecomment-821981723
Do you know what triggered this issue? What has changed between zeromq@5.2.0
and zeromq@5.2.7
? Is it because the new prebuilts come from GH actions?
If I'm getting this right. The issue is that GH action is building the linux prebuilts in ubuntu-20.04
, which uses gcc v9
;
whereas Debian 10
uses gcc v8
.
This isn't really a bug. For gcc v8
zeromq fallback to build from source, as it should,
@n-riesco Could you remove hydrogen, and then clone the master branch, and try to run the tests?
git clone https://github.com/nteract/hydrogen.git
cd hydrogen
apm install --verbose
npm run build
npm run test
I think this time the source build passes, but still, it doesn't find the correct prebuilds?
@aminya It works until npm
commands (but I'd expect so)
::Callback, v8::WeakCallbackType) [with P = node::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo
::Callback = void (*)(const v8::WeakCallbackInfo ::Callback, v8::WeakCallbackType) [with P = Nan::ObjectWrap; T = v8::Object; typename v8::WeakCallbackInfo ::Callback = void (*)(const v8::WeakCallbackInfo
I've run the specs from Atom, and they all pass:
So, I think the only remaining issue is that the user should install libstdc++6
manually if they get the error related to the version. I am going to see if it is possible to build zeromq.node statically with no need for any external dependencies.
Hydrogen is now up-to-date for me. Thanks!
This looks like it has been resolved, but I get a similar error related to zeromq when trying to install Hydrogen on Manjaro (Linux 5.13.19-2-MANJARO and x86-64 architecture).
After re-installing zeromq with sudo pacman -S zeromq
I ran
$ npm_config_zmq_external=true apm install hydrogen
which gave
Installing hydrogen to /home/julsy/.atom/packages [31m✗
[39m[31m
> @aminya/zeromq@5.2.16 install /tmp/apm-install-dir-20211115-89062-1taj1mg.0feo/node_modules/Hydrogen/node_modules/@aminya/zeromq
> node-gyp-build || npm run build:libzmq
> @aminya/zeromq@5.2.16 build:libzmq
> node-gyp rebuild
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated json-parser@1.1.5: `json-parser` is deprecated. Please use `comment-json` instead
npm WARN deprecated popper.js@1.16.1: You can find the new Popper v2 at @popperjs/core, this package is dedicated to the legacy v1
(node:89106) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only.
(Use `node --trace-deprecation ...` to show where the warning was created)
gyp: name 'openssl_fips' is not defined while evaluating condition 'openssl_fips != ""' in binding.gyp while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/lib/node_modules/atom-package-manager/node_modules/npm/node_modules/node-gyp/lib/configure.js:351:16)
gyp ERR! stack at ChildProcess.emit (node:events:390:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Linux 5.13.19-2-MANJARO
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/atom-package-manager/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/apm-install-dir-20211115-89062-1taj1mg.0feo/node_modules/Hydrogen/node_modules/@aminya/zeromq
gyp ERR! node -v v17.1.0
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
gyp: name 'openssl_fips' is not defined while evaluating condition 'openssl_fips != ""' in binding.gyp while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit (/usr/lib/node_modules/node-gyp/lib/configure.js:353:16)
gyp ERR! stack at ChildProcess.emit (node:events:390:28)
gyp ERR! stack at Process.ChildProcess._handle.onexit (node:internal/child_process:290:12)
gyp ERR! System Linux 5.13.19-2-MANJARO
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /tmp/apm-install-dir-20211115-89062-1taj1mg.0feo/node_modules/Hydrogen/node_modules/@aminya/zeromq
gyp ERR! node -v v17.1.0
gyp ERR! node-gyp -v v8.2.0
gyp ERR! not ok
npm WARN enoent ENOENT: no such file or directory, open '/tmp/apm-install-dir-20211115-89062-1taj1mg.0feo/package.json'
npm WARN mobx-react@6.3.1 requires a peer of react@^16.8.0 || 16.9.0-alpha.0 but none is installed. You must install peer dependencies yourself.
npm WARN @nteract/markdown@4.6.2 requires a peer of react@^16.11.0 but none is installed. You must install peer dependencies yourself.
npm WARN @nteract/markdown@4.6.2 requires a peer of react-dom@^16.3.2 but none is installed. You must install peer dependencies yourself.
npm WARN @nteract/transform-vega@7.0.10 requires a peer of react@^16.3.2 but none is installed. You must install peer dependencies yourself.
npm WARN @nteract/outputs@3.0.11 requires a peer of react@^16.3.2 but none is installed. You must install peer dependencies yourself.
npm WARN react-table@6.11.5 requires a peer of react@^16.x.x but none is installed. You must install peer dependencies yourself.
npm WARN react-table@6.11.5 requires a peer of react-dom@^16.x.x but none is installed. You must install peer dependencies yourself.
npm WARN react-markdown@4.3.1 requires a peer of react@^15.0.0 || ^16.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @nteract/presentational-components@3.4.12 requires a peer of react@^16.3.2 but none is installed. You must install peer dependencies yourself.
npm WARN react-json-tree@0.12.1 requires a peer of react@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN react-json-tree@0.12.1 requires a peer of react-dom@^16.3.0 but none is installed. You must install peer dependencies yourself.
npm WARN mobx-react-lite@2.2.2 requires a peer of react@^16.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN apm-install-dir-20211115-89062-1taj1mg.0feo No description
npm WARN apm-install-dir-20211115-89062-1taj1mg.0feo No repository field.
npm WARN apm-install-dir-20211115-89062-1taj1mg.0feo No README data
npm WARN apm-install-dir-20211115-89062-1taj1mg.0feo No license field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @aminya/zeromq@5.2.16 install: `node-gyp-build || npm run build:libzmq`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @aminya/zeromq@5.2.16 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/julsy/.atom/.apm/_logs/2021-12-15T08_32_41_497Z-debug.log
[39m
The complete log is here: hydrogen-error.log
atom --version
returns
Atom : 1.58.0
Electron: 9.4.4
Chrome : 83.0.4103.122
Node : 12.14.1
and apm --version
apm 2.6.4
npm 6.14.9
node 17.1.0 x64
atom 1.58.0
python 3.9.7
git 2.34.1
I'm not really a JS aficionado. Any idea on how I can fix this?
Prerequisites
Enable Debug Messages
isn't useful in this case, is it?2090 is very similar, but IDK if it's the same thing due to different distro and different Atom version. By all means, close this as a duplicate if needed.
Description
Can't update to Hydrogen 2.15.3 on Linux
Steps to Reproduce
Versions
OS version: Ubuntu 18.04.5 Kernel: Linux 4.15.0-142-generic Architecture: x86-64
Hydrogen version:
Atom says 2.14.7, but
apm show hydrogen
says 2.15.3.Plugins
Have you installed and activated any of the Hydrogen plugins below ?
Logs
Expected behavior
Update Hydrogen
Screenshots
Additional context
(none)