How do I use 'underlays' to build ROS from source ?

asked 2020-10-29 08:30:38 -0500

elpidiovaldez gravatar image

It looks like I need to build ROS Melodic from source (again), this time on the Jetson Nano. I have built ROS from source before, but the result has never been very satisfactory, so I'd appreciate some advice on how best to go about it.

  • The official guide uses catkin_make_isolated. I had always used catkin_make for my own projects, so my workspace ended up with directories for build and build_isolated etc. Some packages got into both. I have no idea how the system decides which to use, or how to sort this mess out.
  • When I tried to use catkin_make_isolated for my own packages, the system seemed to revisit the entire ROS system for every build and took a very long time.

I believe I could avoid this by use of an 'underlay'. I think I should set up a workspace for building the ROS system, and build it with catkin_make_isolated. Then I should set up a separate workspace for my own packages that 'inherits' from the underlay. I could safely use catkin_make within the second workspace, and not cause the underlay to be rebuilt, or mix build_ and build_isolated.

I am not certain how to set up the underlay and overlay workspaces. Also I wonder if I build and install ROS if I can safely delete the devel and build directories.

edit retag flag offensive close merge delete