0

In recently istalled Ubuntu 18.04.4 on SSD hard disk and Intel Core i5-6500 I've try to install build-essential with this error:

The following packages have unmet dependencies:
  build-essential: Depends: dpkg-dev (> = 1.17.11) but will not install

If I try to install dpkg-dev, also several dependencies are shown. I've try to solve dependecies everyway (update, upgrade, clean, autoclean, autoremove) and reinstall with apt, apt-get, -y, ... even uncomenting the bionic-updates section in /etc/apt/sources.list as is said in Ubuntu 18.04, fresh install, cannot install build-essential!, but the same error persists.

Any idea? Thanks

  • 2
    To your question above, please add the complete output of `sudo apt update` and of `apt-cache policy dpkg-dev` and of `sudo apt install dpkg-dev` – user535733 Apr 04 '20 at 16:16
  • Try using `aptitude` to install the package. Aptitude will try to resolve dependencies for you. Please read [here](https://askubuntu.com/q/1155019/968501) – Raffa Apr 04 '20 at 17:14
  • 2
    Does this answer your question? [How do I restore the default repositories?](https://askubuntu.com/questions/124017/how-do-i-restore-the-default-repositories) – N0rbert Apr 04 '20 at 17:15

1 Answers1

1

I solved adding bionic-updates and bionic-security lines to my /etc/apt/sources.list

So, my /etc/apt/sources.list looks like:

deb http://de.archive.ubuntu.com/ubuntu/ bionic main restricted universe multiverse
deb http://de.archive.ubuntu.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse

AlbHam
  • 11
  • 2
  • worked for me. got me around the " libc6-dev : Depends: libc6 (= 2.35-0ubuntu3) but 2.35-0ubuntu3.1 is to be installed" problem with cmake. – pierrely Feb 16 '23 at 06:41