Static build rclnodejs.node problem
See original GitHub issueHas any one tried static build rclnodejs.node with ROS2 foxy ?
I’m trying to use rclnodejs with electron, but rclnodejs.node relies on librcl.so, librmw.so, and some ros2 core shared libraries. One approach is source /opt/ros/foxy/setup.bash
every time when electron start, but personally I don’t prefer this approach, because most electron application is a deliverable software, it supposed to double clicked to launch this app.
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
codeLive: Creating LWR Static Sites on Node.js - YouTube
Learn how to create a static site with LWR (Lightning Web Runtime)Connect with Salesforce Developers:Website: ...
Read more >rclnodejs - npm
rclnodejs is a Node.js client for the Robot Operating System (ROS 2). It provides a simple and easy JavaScript API for ROS 2...
Read more >About ROS 2 client libraries - ROS Documentation
Node.js rclnodejs is a Node.js client for the Robot Operating System (ROS 2). It provides a simple and easy JavaScript API for ROS...
Read more >Deploy an Express server that uses express.static to serve a ...
I had similar issue: serve some static content and use /api routes. ... Build separately serverless and static content.
Read more >initial (6a97978c) · Commits · Oleg Dzhimiev / rclnodejs-testing
app.use('/node_modules',express.static(path.join(__dirname, ... #!/usr/bin/env node ... Event listener for HTTP server "error" event.
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
As distributing
rclnodejs
in a bundle was a hard requirement for my use case, I spent the time to develop a workaround and have compiled it in this example repository for posterity.After evaluating the alternatives discussed here (including building
rclnodejs
statically or using a launch file), I wrote a launch file (similar to sourcing from~/.bashsrc
as suggested by @minggangw).This is not an ideal solution in production, since it requires the distribution of 2 files (the Electron executable, and the
launch
executable). This introduces challenges in automatically updating the entire distributed code (i.e., the Electron app is auto-updatable but thelaunch
file is not).Nonetheless, a well-designed distribution strategy (e.g., through a tar and some good instructions on how to launch to the end-user) should generally be sufficient.
@cwyark I have a similar requirement to you where I would like to maintain the production release capability enabled by Electron’s
autoUpdater
, if possible without the additional liability/complexity of an external script that the end-user may need to update as well.While ideally static ROS2 could be bundled in this Electron application I understand that to be inaccessible.
So, assuming the end-user’s environment has ROS2 installed, I was curious if you went down the path of using
source /opt/ros/foxy/setup.bash
or instead had made headway with a static version ofrclnodejs
.Also, in either scenario did you get
rclnodejs
working beyond an Electron development server and into a bundled distributable executable?Thanks in advance.