"packages have unmet dependencies" while installing Code::Blocks

11,005

Have you actually tried running: sudo apt-get -f install? That should fix current installed packages by installing unmet dependencies.

Share:
11,005

Related videos on Youtube

user3033693
Author by

user3033693

Updated on September 18, 2022

Comments

  • user3033693
    user3033693 over 1 year

    While trying to install Code::Blocks, I run sudo apt-get install libwxgtk2.8-dev, but then receive an error listing many "unmet dependencies" for several packages.

    The full list of errors:

    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:
     codeblocks:i386 : Depends: libatk1.0-0:i386 (>= 1.12.4) but it is not going to be installed
                       Depends: libc6:i386 (>= 2.4) but it is not going to be installed
                       Depends: libcairo2:i386 (>= 1.2.4) but it is not going to be installed
                       Depends: libfontconfig1:i386 (>= 2.9.0) but it is not going to be installed
                       Depends: libfreetype6:i386 (>= 2.2.1) but it is not going to be installed
                       Depends: libgcc1:i386 (>= 1:4.1.1) but it is not going to be installed
                       Depends: libgdk-pixbuf2.0-0:i386 (>= 2.22.0) but it is not going to be installed
                       Depends: libglib2.0-0:i386 (>= 2.12.0) but it is not going to be installed
                       Depends: libgtk2.0-0:i386 (>= 2.8.0) but it is not going to be installed
                       Depends: libpango1.0-0:i386 (>= 1.14.0) but it is not going to be installed
                       Depends: libstdc++6:i386 (>= 4.6) but it is not going to be installed
                       Depends: libwxbase2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                       Depends: libwxgtk2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                       Depends: codeblocks-common:i386 (= 13.12-1) but it is not installable
                       Recommends: gcc:i386 but it is not going to be installed or
                                   g++:i386 but it is not going to be installed
                       Recommends: gdb:i386 but it is not going to be installed
     codeblocks-contrib:i386 : Depends: libatk1.0-0:i386 (>= 1.12.4) but it is not going to be installed
                               Depends: libbz2-1.0:i386 but it is not going to be installed
                               Depends: libc6:i386 (>= 2.4) but it is not going to be installed
                               Depends: libcairo2:i386 (>= 1.2.4) but it is not going to be installed
                               Depends: libfontconfig1:i386 (>= 2.9.0) but it is not going to be installed
                               Depends: libfreetype6:i386 (>= 2.2.1) but it is not going to be installed
                               Depends: libgamin0:i386 but it is not going to be installed
                               Depends: libgcc1:i386 (>= 1:4.1.1) but it is not going to be installed
                               Depends: libgdk-pixbuf2.0-0:i386 (>= 2.22.0) but it is not going to be installed
                               Depends: libglib2.0-0:i386 (>= 2.12.0) but it is not going to be installed
                               Depends: libgtk2.0-0:i386 (>= 2.8.0) but it is not going to be installed
                               Depends: libhunspell-1.3-0:i386 but it is not going to be installed
                               Depends: libpango1.0-0:i386 (>= 1.14.0) but it is not going to be installed
                               Depends: libstdc++6:i386 (>= 4.6) but it is not going to be installed
                               Depends: libwxbase2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                               Depends: libwxgtk2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                               Depends: libx11-6:i386 but it is not going to be installed
                               Depends: zlib1g:i386 (>= 1:1.2.3.3) but it is not going to be installed
                               Depends: codeblocks-contrib-common:i386 (= 13.12-1) but it is not installable
                               Recommends: valgrind:i386 but it is not going to be installed
                               Recommends: cppcheck:i386 but it is not going to be installed
                               Recommends: cscope:i386 but it is not going to be installed
                               Recommends: cccc:i386 but it is not going to be installed
     codeblocks-dev:i386 : Depends: codeblocks-headers:i386 (= 13.12-1) but it is not installable
     codeblocks-headers : Depends: codeblocks-dev (>= 13.12-1) but it is not going to be installed
                          Depends: codeblocks-dev (< 13.12-1.1~) but it is not going to be installed
     codeblocks-libwxcontrib0:i386 : Depends: libc6:i386 (>= 2.3.6-6~) but it is not going to be installed
                                     Depends: libgcc1:i386 (>= 1:4.1.1) but it is not going to be installed
                                     Depends: libstdc++6:i386 (>= 4.1.1) but it is not going to be installed
                                     Depends: libwxbase2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                                     Depends: libwxgtk2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                                     Depends: binutils:i386 (>= 2.14.90.0.7) but it is not going to be installed
     codeblocks-wxcontrib-headers : Depends: codeblocks-wxcontrib-dev (>= 13.12-1) but it is not installable
                                    Depends: codeblocks-wxcontrib-dev (< 13.12-1.1~) but it is not installable
     libcodeblocks0:i386 : Depends: libc6:i386 (>= 2.11) but it is not going to be installed
                           Depends: libgcc1:i386 (>= 1:4.1.1) but it is not going to be installed
                           Depends: libstdc++6:i386 (>= 4.6) but it is not going to be installed
                           Depends: libwxbase2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                           Depends: libwxgtk2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                           Depends: binutils:i386 (>= 2.14.90.0.7) but it is not going to be installed
     libwxgtk2.8-dev : Depends: wx-common but it is not going to be installed
                       Depends: wx2.8-headers (= 2.8.12.1-14ubuntu1.1) but it is not going to be installed
                       Depends: libwxgtk2.8-0 (= 2.8.12.1-14ubuntu1.1) but it is not going to be installed
                       Depends: libwxbase2.8-dev (= 2.8.12.1-14ubuntu1.1) but it is not going to be installed
     libwxsmithlib0:i386 : Depends: libc6:i386 (>= 2.4) but it is not going to be installed
                           Depends: libgcc1:i386 (>= 1:4.1.1) but it is not going to be installed
                           Depends: libstdc++6:i386 (>= 4.1.1) but it is not going to be installed
                           Depends: libwxbase2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
                           Depends: libwxgtk2.8-0:i386 (>= 2.8.12.1) but it is not going to be installed
     wxsmith-headers : Depends: wxsmith-dev (>= 13.12-1) but it is not installable
                       Depends: wxsmith-dev (< 13.12-1.1~) but it is not installable
    E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).
    

    I get these errors for every single package and it happens after I try to get build essentials.

    EDIT: After continuing to toil, there are still 2 dependencies that nothing can fix.

    • libgcc1 (>=1:4.1.1) but 1:4.8.1-10ubuntu9 is to be installed
    • codeblocks-common(=12.11-3) but 13.12-1 is to be installed

    I tried re-installing. Auto remove didn't work.

    EDIT: I tried -f install again to post my results. Here is what I get:

    somepackages 
    Use 'apt-get autoremove' to remove them.
    0 upgraded, 0 newly installed, 0 to remove and 240 not upgraded.
    

    I still can't install the final two dependencies for Code::Blocks.

    • AzkerM
      AzkerM over 10 years
      possible duplicate of How do I resolve unmet dependencies?. As in your end results explains that you've unmet dependencies and to try sudo apt-get -f install. Try it first & Also refer the link specified in this comment.
    • AzkerM
      AzkerM over 10 years
      Open a terminal with CTRL+ALT+T & type sudo apt-get -f install. If you get any error, please edit your question and post the output separate. :)
  • user3033693
    user3033693 over 10 years
    restarting worked! need 30mb of downloads :( no other choice! downloading and will see what happened! my net is data limited ! and its so expensive! EDIT: worked ! thanks so much!! sorry for this please don't give me ban or something it wont happen again! it was mostly because it was long error and i didn't know what to search for!
  • user3033693
    user3033693 over 10 years
    theres still 2 other dependies that nothing can fix ! libgcc1 (>=1:4.1.1) but 1:4.8.1-10ubuntu9 is to be isntalled codeblocks-common(=12.11-3) but 13.12-1 is to be isntalled
  • DavidGamba
    DavidGamba about 10 years
    Try installing those two manually, maybe there are security updates that won't allow you to install an older version.