Ask Your Question
0

Installing ROS2-Dashing from source fails (Ubuntu 19.10 eoan)

asked 2020-03-04 04:47:06 -0600

cxrandolph gravatar image

I'm interested in working with rclcpp, so I've decided to install ROS2 (Dashing) by building it from source, on a system with a fresh upgrade to Ubuntu 19.10 eoan. I am using this guide from ros.org to do so. However, I simply cannot manage to successfully build ROS2. The following problems I have encountered are:

  1. Install development tools and ROS tools: I was unable to succesfully run sudo apt install python3-colcon-common-extensions. It returned with E: Unable to locate package python3-colcon-common-extensions.

    Workaround: I obtained colcon using pip3 install -U colcon-common-extensions. I then added it to my PATH environment variable

  2. Install dependencies using rosdep: Running rosdep install --from-paths src --ignore-src --rosdistro dashing -y --skip-keys "console_bridge fastcdr fastrtps libopensplice67 libopensplice69 rti-connext-dds-5.3.1 urdfdom_headers" yielded the following output: ERROR: the following packages/stacks could not have their rosdep keys resolved to system dependencies: rosidl_parser: No definition of [python3-lark-parser] for OS version [eoan]

    I was able to install python3-lark-parser through pip3 however, and hoped that sorted out the problem.

  3. Building: Running colcon build --symlink-install yields:

    • Summary: 169 packages finished [13min 11s]
    • 1 package failed: rviz_rendering
    • 5 packages aborted: diagnostic_msgs rclcpp sensor_msgs shape_msgs visualization_msgs
    • 23 packages had stderr output: actionlib_msgs composition_interfaces diagnostic_msgs fastrtps geometry_msgs lifecycle_msgs nav_msgs qt_gui_cpp rcl_interfaces rmw_connext_cpp rmw_connext_shared_cpp rmw_fastrtps_shared_cpp rmw_opensplice_cpp rosidl_generator_py rosidl_typesupport_connext_c rosidl_typesupport_connext_cpp rviz_rendering sensor_msgs std_msgs std_srvs test_msgs tf2_msgs visualization_msgs
    • 96 packages not processed

After this I was unable to do anything to try and repair my installation. I unfortunately feel a bit overwhelmed by the amount of dependencies and what I perceive to be the complexity of the ROS2 build process.

Are there any measures I can take to repair my installation and get ROS2 working?

edit retag flag offensive close merge delete

Comments

so I've decided to install ROS2 (Dashing)

can you clarify why you're using an older version, instead of Eloquent?

Additionally: 19.04 is not an officially supported version of Ubuntu at this time for ROS 2, so running into some dependency issues seems like it would be expected.

gvdhoorn gravatar image gvdhoorn  ( 2020-03-04 06:03:33 -0600 )edit

I simply defaulted to Dashing as it was the distribution I've used in the past, but only via a docker image. I realize it is now illogical of me to have paired an older version of ROS with a newer unsupported version of Ubuntu. I can attempt to reinstall an older version of Ubuntu and repeat the procedure with a new version of ROS, but I'd rather avoid that if possible.

I was hopeful there might be some errors here other users recognize and have solutions for :s

cxrandolph gravatar image cxrandolph  ( 2020-03-04 06:15:33 -0600 )edit

I would still recommend trying Eloquent, as I expect this to be the first thing you'll get as a question from the maintainers.

I was hopeful there might be some errors here other users recognize

You show two things:

  1. some dependency resolution problems, both of which are perhaps to be expected due to using an unsupported OS (but with pip work-around)
  2. a build output summary from Colcon. This doesn't tell us much, other than that rviz_rendering could not be build successfully. Without seeing the actual error(s), there isn't much to say about that, except that I can again see how that could fail, as rviz uses Ogre, which has a tendency to break things between Ubuntu releases

The RViz build failure then basically stops the entire build.

The other "23 packages with stderr output" should also get some attention, but focusing on one package first would ...(more)

gvdhoorn gravatar image gvdhoorn  ( 2020-03-04 06:52:10 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
2

answered 2020-03-04 06:59:21 -0600

marguedas gravatar image

1) and 2): this is the right workaround as these packages are released as debs only on the targeted Ubuntu versions (and eoan is not a targeted version).

3) This comes from https://github.com/ros2/rviz/issues/402, as you are using a more recent version of GCC than the one on bionic, new warnings show up and cause the build to fail as RViz was using the -Werror flag.

a) Dashing: If you want to build dashing anyway.you can work around by either disabling the warning as listed in the issue description. Or remove the -Werror flag as in https://github.com/ros2/rviz/pull/420

b) Eloquent: If you build Eloquent, https://github.com/ros2/rviz/pull/420 is already part of eloquent so it will build without error.

Note that for Eloquent you will also have to install python packages by hand as they are not available from debs:

pip3 install rosdistro ifcfg 
rosdep install --from-paths src --ignore-src --rosdistro eloquent -y --skip-keys "console_bridge fastcdr fastrtps libopensplice67 libopensplice69 rti-connext-dds-5.3.1 urdfdom_headers python3-lark-parser python3-catkin-pkg-modules python3-ifcfg python3-rosdistro-modules"
edit flag offensive delete link more

Comments

Okay. Following advice from marguedas for the rosdep workaround, combined with the flag --os=ubuntu:bionic to get around problems where it didn't recognize eoan, I was able to successfully complete the build. I also had to substitute:

wget https://raw.githubusercontent.com/ros2/ros2/dashing/ros2.repos

with

wget https://raw.githubusercontent.com/ros2/ros2/eloquent/ros2.repos

Finally, I had to run export ROS_DISTRO=eloquent to avoid some path related warnings from my previous attempt at installing dashing. For now things seem okay. I will update this if I find there are problems with the build after.

Thank you all so far for your assistance in getting this installed correctly. I really appreciate it!

I just hope the process for recompiling isn't 30m each time I edit a file :P

cxrandolph gravatar image cxrandolph  ( 2020-03-04 14:07:24 -0600 )edit

Finally, I had to run export ROS_DISTRO=eloquent to avoid some path related warnings from my previous attempt at installing dashing. For now things seem okay. I will update this if I find there are problems with the build after.

This sounds like you are treating the symptom not the problem. You probably have something automatically sourcing the dashing setup, such as in your ~/.bashrc that you should clean up instead of just overriding the variable that we're checking. There's other things in the environment that might cause you issues if you don't clean it up.

tfoote gravatar image tfoote  ( 2020-03-04 15:25:28 -0600 )edit

@tfoote Good call with .bashrc. I've cleared it out, and removed some stuff in /opt/ that was also related to dashing.

cxrandolph gravatar image cxrandolph  ( 2020-03-04 16:14:07 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2020-03-04 04:47:06 -0600

Seen: 1,339 times

Last updated: Mar 04 '20