6

When i try to install the gnutls libraries (libgnutls26), and the generic linux kernel headers (linux-headers-generic), I get the following error:

The following packages have unmet dependencies:

libgnutls26: Depends: libc6 (>= 2.14) but 2.15-0ubuntu10.4 is installed
             Depends: zlib1g (>= 1:1.1.4) but 1:1.2.3.4.dfsg-3ubuntu4 is installed
libgnutls26:i386: Depends: zlib1g (>= 1:1.1.4) but 1:1.2.3.4.dfsg-3ubuntu4 is installed
linux-headers-generic: Depends: linux-headers-3.2.0-41-generic but it is not installed

How can I fix this error?

Thomas Ward
  • 74,764
Saran
  • 61
  • 1
  • 1
  • 2

3 Answers3

6

Install aptitude using:

sudo apt-get install aptitude

Then do:

sudo aptitude install libgnutls26

Aptitude will show the problems and propose a solution.

The first proposed solution will be to keep everything as-is. Answer 'n' to that question.

The next proposed solution will be to downgrade all of the dependencies that are currently too new. Answer Y to that.

Then, try installing libgnutls26 again.

AzkerM
  • 10,270
  • 6
  • 32
  • 51
blurfocus
  • 69
  • 1
  • 1
  • Dude, THIS. FINALLY something that actually prints HELPFUL MESSAGES. Thank you so much. –  Nov 07 '14 at 20:58
  • Installing a completely separate tool isn't really "fixing this error" like the OP asked. – Eric Dand Jun 10 '22 at 19:06
5

Not sure if there is conflicting dependencies already installed, but go to the terminal and type sudo apt-get update and then sudo apt-get upgrade

Tell me what message (if any you get like a 'warning...' or 'error..') you get. Also if you are trying to install GnuTLS go to synaptic package manager in your system tools menu, and do a search for it. When you find it right click and select install, and it will bring up the dependencies you need and install them as well.

  • when i am run a command "sudo apt-get update" im getting this error. Hit http://in.archive.ubuntu.com precise-backports/universe Translation-en
    Fetched 3,883 kB in 1min 3s (60.8 kB/s)
    W: Failed to fetch gzip:/var/lib/apt/lists/partial/www.geekconnection.org_remastersys_repository_karmic_Sources Encountered a section with no Package: header

    E: Some index files failed to download. They have been ignored, or old ones used instead.

    – Saran Jun 28 '13 at 06:25
  • i am run this command sudo apt-get upgrade this the error Reading package lists... Done Building dependency tree
    Reading state information... Done You might want to run 'apt-get -f install' to correct these. The following packages have unmet dependencies: libgnutls26 : Breaks: libgnutls26:i386 (!= 2.12.14-5ubuntu3.3) but 2.12.14-5ubuntu3.4 is installed libgnutls26:i386 : Breaks: libgnutls26 (!= 2.12.14-5ubuntu3.4) but 2.12.14-5ubuntu3.3 is installed linux-headers-generic : Depends: linux-headers-3.2.0-41-generic but it is not installed E: Unmet dependencies. Try using -f.
    – Saran Jun 28 '13 at 06:30
  • 1
    sudo apt-get -f install should resolve your dependency issues. The manual way to get them is sudo apt-get install linux-headers-generic sudo apt-get install zlib1g and sudo apt-get install libc6 The first (or last dependency in your list) is an important one for Ubuntu and Linux in general it contains information many programs depend upon and is usually installed as part of an update when you first install the OS. –  Jun 29 '13 at 06:03
1

Welcome to AskUbuntu!

In order to resolve dependencies, type in a terminal sudo apt-get -f install.

If all fails, simply manually install missing packages (by typing sudo apt-get install <name of package>).

Farid
  • 708