Skip to content

Instantly share code, notes, and snippets.

@daronco
Last active October 14, 2020 15:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save daronco/86f34c3f180c9749282a1090bc2c5c74 to your computer and use it in GitHub Desktop.
Save daronco/86f34c3f180c9749282a1090bc2c5c74 to your computer and use it in GitHub Desktop.
Dependency errors trying to install aptitude on Ubuntu 18.04 on DigitalOcean

Got the following errors trying to install aptitude on a clean Ubuntu 18.04 on DigitalOcean:

$ sudo apt install aptitude

The following packages have unmet dependencies:
 aptitude : Depends: libapt-pkg6.0 (>= 1.9.11~) but it is not installable
            Depends: libboost-iostreams1.71.0 but it is not installable
            Depends: libcwidget4 (>= 0.5.18-1) but it is not going to be installed
            Depends: libgcc-s1 (>= 3.0) but it is not installable
            Depends: libncursesw6 (>= 6.1+20180210) but it is not installable
            Depends: libstdc++6 (>= 9) but 8.4.0-1ubuntu1~18.04 is to be installed
            Depends: libtinfo6 (>= 6.1+20180210) but it is not installable
            Depends: libxapian30 (>= 1.4.14~) but it is not going to be installed
            Recommends: libparse-debianchangelog-perl but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

There was a file pointing apt to focal instead of bionic. Find it, edit it and just change to bionic:

$ grep focal -r /etc/apt/
/etc/apt/sources.list.d/archive_ubuntu_com_ubuntu.list:deb http://archive.ubuntu.com/ubuntu/ focal universe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment