3

I've just upgraded my ubuntu from 18.04 to 20.04 and immediately realized that I could not open settings. I read that the problem has to do with gnome-control-center, but when I use

sudo apt install gnome-control-center

I get

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 to resolve the situation:

The following packages have unmet dependencies: gnome-control-center : Depends: libcheese-gtk25 (>= 3.18.0) but it is not going to be installed Depends: libcheese8 (>= 3.28.0) but it is not going to be installed Depends: libgoa-backend-1.0-1 (>= 3.10.0) but it is not going to be installed Recommends: gnome-online-accounts (>= 3.25.3) but it is not going to be installed Recommends: gnome-user-docs but it is not going to be installed E: Unable to correct problems, you have held broken packages.

Then, I found this discussion here and tried to follow each presented solution to fix this unmet dependencies problem. Unfortunately, nothing worked.

My next attempt was to follow this instructions here. So I started adding each package dependecy in my sudo apt install command, and then new dependecies appeared and a repeted the process. My final command was

sudo apt-get install gnome-online-accounts gnome-control-center gnome-user-docs libcheese-gtk25 libcheese8 libgoa-backend-1.0-1 libwebkit2gtk-4.0-37 ubuntu-docs yelp libclutter-1.0-0 libclutter-gtk-1.0-0 libcogl20 gstreamer1.0-clutter-3.0 libgl1 libgstreamer-gl1.0-0 libgl1-mesa-dri libglvnd0 libglx0 libglapi-mesa libglx-mesa0

for which the output was

    Reading package lists... Done
Building dependency tree       
Reading state information... Done
libglapi-mesa is already the newest version (20.2.0~kisak1~b).
libglvnd0 is already the newest version (1.3.2-1~kisak~b).
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 to resolve the situation:

The following packages have unmet dependencies: libgl1 : Depends: libglvnd0 (= 1.3.1-1ubuntu0.20.04.1) but 1.3.2-1~kisak~b is to be installed libgl1-mesa-dri : Depends: libglapi-mesa (= 20.0.8-0ubuntu1~20.04.1) but 20.2.0~kisak1~b is to be installed libglx-mesa0 : Depends: libglapi-mesa (= 20.0.8-0ubuntu1~20.04.1) but 20.2.0~kisak1~b is to be installed libglx0 : Depends: libglvnd0 (= 1.3.1-1ubuntu0.20.04.1) but 1.3.2-1~kisak~b is to be installed E: Unable to correct problems, you have held broken packages.

After that, I get the same output if I add libglvnd0 and libglapi-mesa at the end of my sudo apt install command. I don't know what to do next and I am kind of desperate and very afraid of rebooting my computer.

ljfaga
  • 111
  • 1
  • 4
  • Have you checked about the broken packages, Synaptic package manager should list them. My fix was to install unity desktop, but maybe not of your liking. – crip659 Sep 29 '20 at 23:32
  • Thank you for the comment! Actually, I've just fixed it. For these last dependencies that ending with "but ... is to be installed" I removed them and installed again using aptitude. I wasn't being able to remove them using apt but aptitude worked just fine. I will add an answer to my question explaining better what I did. – ljfaga Sep 30 '20 at 01:42

2 Answers2

8

I solved my problem using the aptitude to remove and reinstall the two unmet dependencies libglvnd0 and libglapi-mesa. I was not being able to delete/install them using apt or apt-get, but aptitude worked pretty well. After that, I kept the same process of adding the new dependencies that eventually appeared to the sudo apt install command and reinstalling those more problematic when they appeared.

Long story short:

  • if the unmet dependence has a description like this:

    gnome-control-center : Depends: libcheese-gtk25 (>= 3.18.0) but it is not going to be installed

use sudo apt install package1 package2 to install all dependencies simultaneously; it won`t work if you install them one by one.

  • else, if the description is like this:

    libgl1 : Depends: libglvnd0 (= 1.3.1-1ubuntu0.20.04.1) but 1.3.2-1~kisak~b is to be installed

use aptitude to reinstall them. The following commands install aptitude, remove the problematic package and install it, respectively.

sudo apt install aptitude
sudo aptitude remove package
sudo aptitude install package

After solving this problem I immediately got another one. I tried to reboot my PC but it never reached the login screen. I must have delete some important packages accidentally when I was testing solutions. I fixed this problem by launching the recovery mode, opening the root shell and typing

sudo apt install --reinstall ubuntu-desktop
ljfaga
  • 111
  • 1
  • 4
0

I just had the same, resolved by 'sudo apt remove xxx' any package that has a "but" in the sentence as they are newer than expected 'sudo apt install gnome-control-center'