安装 Code::Blocks 时出现“软件包具有未满足的依赖关系”

安装 Code::Blocks 时出现“软件包具有未满足的依赖关系”

尝试安装时代码::块,我运行sudo apt-get install libwxgtk2.8-dev,但随后收到一个错误,列出了几个包的许多“未满足的依赖项”。

完整错误列表:

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).

对于每个包我都会遇到这些错误,而且在我尝试获取构建必需品之后就会发生这种情况。

编辑:经过继续努力,仍然有 2 个依赖关系无法修复。

  • libgcc1 (>=1:4.1.1) 但需要安装 1:4.8.1-10ubuntu9
  • codeblocks-common(=12.11-3) 但需要安装 13.12-1

我尝试重新安装。自动删除不起作用。

编辑:我-f install再次尝试发布我的结果。以下是我得到的结果:

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

我仍然无法安装 Code::Blocks 的最后两个依赖项。

答案1

您是否真的尝试过运行:sudo apt-get -f install?这应该通过安装未满足的依赖项来修复当前安装的软件包。

相关内容