Fatal error encountered while installing rclnodejs on macOS Catalina & Node.JS v12
See original GitHub issue rongshen@rs ~/tmp/ros2/pub npm i rclnodejs -S 10099 11:44:07
> int64-napi@1.0.1 install /Users/rongshen/tmp/ros2/pub/node_modules/int64-napi
> node-gyp rebuild
CC(target) Release/obj.target/int64/src/int64.o
../src/int64.c:55:54: warning: incompatible pointer types passing 'uint64_t *' (aka 'unsigned long long *') to parameter of type 'size_t *'
(aka 'unsigned long *') [-Wincompatible-pointer-types]
napi_get_buffer_info(env, _raw, (void**)raw, &rawLength);
^~~~~~~~~~
/Users/rongshen/Library/Caches/node-gyp/12.13.1/include/node/node_api.h:142:54: note: passing argument to parameter 'length' here
size_t* length);
^
1 warning generated.
SOLINK_MODULE(target) Release/int64.node
> ref-napi@2.0.2 install /Users/rongshen/tmp/ros2/pub/node_modules/ref-napi
> node-gyp-build
> rclnodejs@0.14.0 install /Users/rongshen/tmp/ros2/pub/node_modules/rclnodejs
> node-gyp rebuild
CXX(target) Release/obj.target/rclnodejs/src/addon.o
CXX(target) Release/obj.target/rclnodejs/src/executor.o
CXX(target) Release/obj.target/rclnodejs/src/handle_manager.o
CXX(target) Release/obj.target/rclnodejs/src/rcl_action_bindings.o
../src/rcl_action_bindings.cpp:631:5: warning: ignoring return value of function declared with 'warn_unused_result' attribute [-Wunused-result]
rcl_action_cancel_response_fini(cancel_response_ptr);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~
1 warning generated.
CXX(target) Release/obj.target/rclnodejs/src/rcl_bindings.o
../src/rcl_bindings.cpp:32:10: fatal error: 'rosidl_generator_c/string_functions.h' file not found
#include <rosidl_generator_c/string_functions.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [Release/obj.target/rclnodejs/src/rcl_bindings.o] Error 1
gyp ERR! build error
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack at ChildProcess.onExit (/Users/rongshen/.nvm/versions/node/v12.13.1/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 Darwin 19.5.0
gyp ERR! command "/Users/rongshen/.nvm/versions/node/v12.13.1/bin/node" "/Users/rongshen/.nvm/versions/node/v12.13.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/rongshen/tmp/ros2/pub/node_modules/rclnodejs
gyp ERR! node -v v12.13.1
gyp ERR! node-gyp -v v5.1.0
gyp ERR! not ok
npm WARN pub@1.0.0 No description
npm WARN pub@1.0.0 No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! rclnodejs@0.14.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the rclnodejs@0.14.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! /Users/rongshen/.npm/_logs/2020-06-07T03_44_41_932Z-debug.log
SIP has already disabled.
Issue Analytics
- State:
- Created 3 years ago
- Comments:12 (7 by maintainers)
Top Results From Across the Web
"node" Error message after installing Cat… - Apple Discussions
After installing macOS Catalina, an error message keeps popping up that says: "node" cannot be opened because the developer cannot be ...
Read more >Nodejs with macOS: # Fatal error in , line 0 - gatsby develop
It seems a Node-related issue. According to this GitHub thread, try: arch -x86_64 zsh nvm install 14 nvm alias default 14 exit.
Read more >Catalina Yarn/NPM issues - JavaScript - ShakaCode Forum
If you can't get the npm package node-pre-gyp to install… Solution Head to the instructions on how to fix this: Errors I got...
Read more >Installation of NodeJS & NPM in MacOS Catalina - YouTube
Install NodeJS & NPM in MacOS Catalina 10.5.7NodeJS Sitehttps:// nodejs.org/https://www.patreon.com/javimata.
Read more >gyp: No Xcode or CLT version detected - ERR! configure error ...
Is node-gyp (Node.js native addon build tool) failing during yarn install or npm install? If your macOS got upgraded to Catalina (10.15) ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
edit: ops just saw @minggangw suggestion…
@zentala Sorry you are hitting this issue. Try installing as follows:
The most recent rclnodejs version is 0.14.1 which is only compatible with the latest ros2 foxy release. The rclnodejs v0.14.0 is the most recent version compatible with ros2 eloquent.
Action item will be to revisit the docs to see if we can make the version compatibility info more prominent on npmjs.
@zentala If you are running Eloquent, and you have to install rclnodejs 0.14.0