转载自:https://blog.csdn.net/weixin_33804582/article/details/94657169
但是我这边,是通过换成aptitude 去安装就行了
sudo aptitude install
其他参考:https://www.jianshu.com/p/c641040464df
/**
这个自动修复依赖,有时候管用
If sudo apt-get install -f doesn’t work, try aptitude:
sudo apt-get install aptitude
sudo aptitude install
*/

当出现类似这类错误:

The following packages have unmet dependencies:
 python-dev : Depends: python (= 2.7.5-5ubuntu3) but 2.7.12-1~16.04 is to be installed
              Depends: libpython-dev (= 2.7.5-5ubuntu3) but it is not going to be installed
              Depends: python2.7-dev (>= 2.7.5-1~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

这是由于安装包的版本太新,其依赖包和旧版本冲突导致。

网上常见解决方法:apt-get -f install,but it doesn't work for me,或者说使用aptitude的,试了下很慢。

 

后来我把阿里源换回Ubuntu原生的源就可以安装了,因为阿里源的包太新。

转载于:https://www.cnblogs.com/willaty/p/9522591.html

GitHub 加速计划 / de / Dependencies
8.6 K
704
下载
A rewrite of the old legacy software "depends.exe" in C# for Windows devs to troubleshoot dll load dependencies issues.
最近提交(Master分支:1 个月前 )
1997a400 - 2 年前
2f423539 - 2 年前
Logo

旨在为数千万中国开发者提供一个无缝且高效的云端环境,以支持学习、使用和贡献开源项目。

更多推荐