我无法在新安装的Ubuntu 14.04.4 LTS上安装g ++。无法在ubuntu 14.04.4 LTS上安装g ++
当我使用命令sudo apt-get install g++
,终端告诉我:
[email protected]:~$ sudo apt-get install g++
[sudo] password for cluster:
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:
g++ : Depends: g++-4.8 (>= 4.8.2-5~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
我改变了来源,并再次尝试,失败了。
[email protected]:~$ sudo apt-get install g++
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:
g++:i386 : Depends: cpp:i386 (>= 4:4.7.3-1ubuntu10) but it is not going to be installed
Depends: gcc:i386 (>= 4:4.7.3-1ubuntu10) but it is not going to be installed
Depends: g++-4.7:i386 (>= 4.7.3-1~) but it is not going to be installed
Depends: gcc-4.7:i386 (>= 4.7.3-1~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
我使用的Ubuntu软件中心安装G ++,又失败了...... Figure: Use ubuntu software center to install g++
这个问题已经通过改变其它来源解决。
我已经尝试了4个来源,并且他们都有问题...... OMG!
查看https://askubuntu.com/questions/118749/package-system-is-broken-how-to-fix-it – sashoalm