出现stdio.h文件找不到的问题,使用如下命令:
root@chenxiaojian:/etc/apt# apt-get install libc6-dev
这个时候按道理能够成功解决,但是却出现如下错误:
root@chenxiaojian:/etc/apt# apt-get install libc6-dev
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
有一些软件包无法被安装。如果您用的是 unstable 发行版,这也许是
因为系统无法达到您要求的状态造成的。该版本中可能会有一些您需要的软件
包尚未被创建或是它们已被从新到(Incoming)目录移出。
下列信息可能会对解决问题有所帮助:
下列软件包有未满足的依赖关系:
libc6-dev : 依赖: libc6 (= 2.23-0ubuntu11) 但是 2.27-3ubuntu1 正要被安装
依赖: libc-dev-bin (= 2.23-0ubuntu11)
E: 无法修正错误,因为您要求某些软件包保持现状,就是它们破坏了软件包间的依赖关系。
解决方法:更换软件源;需要注意的问题就是:根据自己linux的版本进行更换才能成功
- 查看ubantu版本,使用命令
root@chenxiaojian:/etc/apt# lsb_release -c
Codename: bionic
-
bionic:表示的ubantu的18.04的版本
-
更换软件源:/etc/apt/sources.list 文件,阿里云的软件源
deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
-
执行命令
apt-get update apt-get upgrade
-
问题解决