我是一名 Linux 新手,我在 Ubuntu 13 上搞乱了我的 gcc 4.7 的符号链接,它应该安装,但我无法删除它或使用它:
paul@paul-linux:~$ sudo apt-get remove gcc-4.7
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
dkms : Depends: gcc but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
paul@paul-linux:~$ ls -l /usr/bin/gcc
ls: cannot access /usr/bin/gcc: No such file or directory
请问我该如何解决这个问题?
答案1
我不确定这是否能解决您的问题,但尝试下面的命令可能会解决您的问题。运行这些命令后,尝试再次安装 gcc。
sudo apt-get 更新
sudo apt-get 自动删除
sudo apt-get -f 安装