遇到这个问题好几次了,每次都得重新搜索解决方案,索性记录一下吧。
问题:
用apt安装build-essential时,遇到以下报错:
$ sudo apt-get install build-essential
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version (12.8ubuntu1.1).
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
autoconf : Depends: m4 (>= 1.4.13)
automake : Depends: autotools-dev (>= 20020320.1) but it is not going to be installed
bison : Depends: m4
cmake-doc : Depends: libjs-sphinxdoc (>= 1.0) but it is not going to be installed
Recommends: doc-base but it is not going to be installed
flex : Depends: m4
Recommends: libfl-dev but it is not going to be installed
g++-multilib : Depends: g++-9-multilib (>= 9.3.0-3~) but it is not going to be installed
gcc-doc : Depends: gcc-9-doc (>= 9.3.0-3~) but it is not going to be in

文章讲述了用户在使用sudoapt-getinstallbuild-essential时遇到的依赖问题,提示安装的包由于第三方依赖未被安装。提供了解决方案:运行sudoapt--fix-brokeninstall修复依赖并安装缺失的包,以及提及离线安装时常出现此问题。
最低0.47元/天 解锁文章
3828

被折叠的 条评论
为什么被折叠?



