1

I am trying to install libgtk-3-dev and receving the following message:

user@nvidia-jetson-tx2:~/projects/realsense/librealsense$ sudo apt-get install libgtk-3-dev
[sudo] password for user: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help resolve the situation:

The following packages have unmet dependencies: libgtk-3-dev : Depends: libgtk-3-0 (= 3.22.30-1ubuntu1) but 3.22.30-1ubuntu4 is to be installed Depends: gir1.2-gtk-3.0 (= 3.22.30-1ubuntu1) but 3.22.30-1ubuntu4 is to be installed Depends: libpango1.0-dev (>= 1.40.5) but it is not going to be installed Depends: libatk-bridge2.0-dev but it is not going to be installed Depends: libcairo2-dev (>= 1.14.0) but it is not going to be installed Depends: libxkbcommon-dev but it is not going to be installed E: Unable to correct problems, you have held broken packages.

If my understanding is correct, the defined dependencies in libgtk-3-dev are looking for older version of libgtk-3-0 and gir1.2-gtk-3.0. What would be the best course of action for these two packages:

  • donwgrade libgtk-3-0 and gir1.2-gtk-3.0
  • force the installation of libgtk-3-dev by somehow ignoring the dependencies (not sure if this is possible at all)
  • modify the dependency (if possible)
  • something else?

What about the other 4 packages (libpango1.0-dev, libatk-bridge2.0-dev, libcairo2-dev, libxkbcommon-dev)? Where they not installed because version criteria for libgtk-3-0 and gir1.2-gtk-3.0 was not met or potentially there is some other issue with those as well?

Can anyone give me some guidence on how to proceed?

Thanks a lot in advance!

  • Does sudo apt install libgtk-3-dev=3.22.30-1ubuntu4 work? – Terrance Mar 05 '21 at 22:30
  • [sudo] password for user: Reading package lists... Done Building dependency tree Reading state information... Done E: Version '3.22.30-1ubuntu4' for 'libgtk-3-dev' was not found``` – Francis1133 Mar 05 '21 at 22:46
  • Hmmmm, that version is found in the focal-updates repository. Make sure to run sudo apt update before trying the install again. Also, make sure that your default repositories are all enabled in your Settings -> Software & Updates -> Ubuntu Software. – Terrance Mar 05 '21 at 22:58

1 Answers1

3

Thank you Terrance for pointing me to the right direction.

Had to enable "Recommended updates (bionic-update)" under Software & Updates->Updates and after that I was able to install libgtk-3-dev 3.22.30-1ubuntu4 even without explicitly specifying the version.

Recommended updates (bionic-update)