ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Problem building galactic from source

asked 2022-03-31 10:05:34 -0500

mechaniputer gravatar image

Hi folks,

I am attempting to install ROS 2 Galactic from source on Ubuntu 20.04 x86_64 according to the instructions here: https://docs.ros.org/en/galactic/Inst...

My Ubuntu installation is fresh and updated, with the one oddity being that I have replaced the stock kernel with a somewhat modified 5.4 kernel. I do not believe this to be a factor in my current problems.

I'm on this step:

rosdep install --from-paths src --ignore-src -y --skip-keys "fastcdr rti-connext-dds-5.3.1 urdfdom_headers"

I have rerun the command several times and get one of a few different errors each time (seemingly at random) but it never succeeds.

For example, here is one of the errors I have seen:

The following packages have unmet dependencies:

     libopencv-dev : Depends: libopencv-calib3d-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-contrib-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-features2d-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-highgui-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-objdetect-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-stitching-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-superres-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-videoio-dev (= 4.2.0+dfsg-5) but it is not going to be installed
                     Depends: libopencv-videostab-dev (= 4.2.0+dfsg-5) but it is not going to be installed

I followed the dependencies down one of these lines and found that the version of libgphoto2-6 is newer than what is available in the repos. I'm not sure how this happened, but I need the older version and have the newer version installed.

Here is the installed version:

Package: libgphoto2-6
Version: 2.5.25-0ubuntu0.1
Status: install ok installed
Priority: optional
Section: libs
Source: libgphoto2
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>

And here is the version I see in the repos, which is the one I need to meet the dependencies:

Package: libgphoto2-6
Version: 2.5.24-1
Priority: optional
Section: libs
Source: libgphoto2
Origin: Ubuntu
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>

What went wrong? What can I do about this? Thanks in advance.

Oh, and one more thing I just remembered. I had trouble installing openssh-server and had to remove openssh-client first, and it seems like that could have been a similar issue. Packages being newer than the ones in the repo. I really don't know how that happened since this is just a basic 20.04 installation from the latest media. I ran updates from the graphical tool immediately after installation without changing any configs and I have not added any software sources other than the ones in the instructions I linked above.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2022-03-31 10:53:34 -0500

mechaniputer gravatar image

I believe I've fixed it.

I noticed that the versions of things I had installed were the latest correct versions, but apt was not seeing those versions for some reason. This seems to have been a problem with my /etc/apt/sources.list. I do not know how this occurred since I never modified it.

Essentially what happened was that I had newer packages from the updated installation media, but apt could only see old versions available for installation because of the incorrect sources.list.

I replaced it with a generic 20.04 sources.list and it got all the updates. Now it seems to be happy with the newer versions of packages I already had installed.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2022-03-31 10:05:34 -0500

Seen: 191 times

Last updated: Mar 31 '22