1

When I try to install a package, for example firefox, using:

sudo apt install firefox

I get asked for entering my password. After entering it, I get:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 libglvnd-dev : Depends: libgles-dev (>= 1.3.0-1) but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

I enter:

sudo apt --fix-broken install

as the error output suggests, but I get:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  libglvnd-core-dev libx11-xcb-dev libxcb-dri2-0-dev libxcb-dri3-dev
  libxcb-glx0-dev libxdamage-dev libxshmfence-dev x11proto-damage-dev
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  libgles-dev
The following NEW packages will be installed:
  libgles-dev
0 upgraded, 1 newly installed, 0 to remove and 707 not upgraded.
4 not fully installed or removed.
Need to get 0 B/50.4 kB of archives.
After this operation, 718 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 354422 files and directories currently installed.)
Preparing to unpack .../libgles-dev_1.3.2-1~kisak~b_amd64.deb ...
Unpacking libgles-dev:amd64 (1.3.2-1~kisak~b) ...
dpkg: error processing archive /var/cache/apt/archives/libgles-dev_1.3.2-1~kisak~b_amd64.deb (--unpack):
 trying to overwrite '/usr/include/GLES2/gl2.h', which is also in package libgles2-mesa-dev:amd64 20.0.8-0ubuntu1~18.04.1
Errors were encountered while processing:
 /var/cache/apt/archives/libgles-dev_1.3.2-1~kisak~b_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

When I enter:

sudo apt-cache policy libgles-dev libgles2-mesa-dev

the output shows:

libgles-dev:
  Installed: (none) 
  Candidate: 1.3.2-1~kisak~b 
  Version table:
     1.3.2-1~kisak~b 500
        500 ppa.launchpad.net/kisak/kisak-mesa/ubuntu bionic/main amd64 Packages 
libgles2-mesa-dev:
  Installed: 20.0.8-0ubuntu1~18.04.1
  Candidate: 20.2.1~kisak1~b 
  Version table:
     20.2.1~kisak1~b 500
        500 ppa.launchpad.net/kisak/kisak-mesa/ubuntu bionic/main amd64 Packages *** 
     20.0.8-0ubuntu1~18.04.1 500
        500 in.archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages
        100 /var/lib/dpkg/status 19.2.8-0ubuntu0~18.04.2 500
        500 security.ubuntu.com/ubuntu bionic-security/main amd64 Packages
     18.0.0~rc5-1ubuntu1 500 500 in.archive.ubuntu.com/ubuntu bionic/main amd64 Packages

What should I do?

BeastOfCaerbannog
  • 12,964
  • 10
  • 49
  • 77
Aswanth DS
  • 35
  • 1
  • 8
  • 2
    Does this answer your question? [dpkg error: "trying to overwrite file, which is also in..."](https://askubuntu.com/questions/176121/dpkg-error-trying-to-overwrite-file-which-is-also-in) – karel Nov 10 '20 at 04:12
  • @karel: No.Because in that answer the output of first command was to try apt-get -f install.For me it is apt --fix-broken install.When i had entered sudo apt-get -f install it shows same error.. – Aswanth DS Nov 10 '20 at 13:35

1 Answers1

1
  1. Open Software & Updates and go to Other Software.
  2. There must be a check box near http://ppa.launchpad.net/kisak/kisak-mesa/ubuntu bionic/main. Turn it off.

Now try installing firefox and check if it's working.

BeastOfCaerbannog
  • 12,964
  • 10
  • 49
  • 77
Random Person
  • 1,488
  • 1
  • 14
  • 33
  • You may want to use `ppa-purge` instead to remove all packages that have been intalled from that `ppa` .... – pLumo May 25 '21 at 15:08