在win10的wsl下安装g++时遇到问题
发表于 : 2016-08-03 15:23
我先装了gcc,然后嫌自带的源太慢,就改用了163的源,结果安装g++时遇到问题了,如下:
dyn@DELL:/etc/apt$ sudo apt-get install g++
sudo: unable to resolve host DELL
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.
dyn@DELL:/etc/apt$ sudo apt-get install g++-4.8
sudo: unable to resolve host DELL
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++-4.8 : Depends: gcc-4.8-base (= 4.8.4-2ubuntu1~14.04) but 4.8.4-2ubuntu1~14.04.3 is to be installed
Depends: gcc-4.8 (= 4.8.4-2ubuntu1~14.04) but 4.8.4-2ubuntu1~14.04.3 is to be installed
Depends: libstdc++-4.8-dev (= 4.8.4-2ubuntu1~14.04) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
dyn@DELL:/etc/apt$ sudo apt-get install g++
sudo: unable to resolve host DELL
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.
dyn@DELL:/etc/apt$ sudo apt-get install g++-4.8
sudo: unable to resolve host DELL
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++-4.8 : Depends: gcc-4.8-base (= 4.8.4-2ubuntu1~14.04) but 4.8.4-2ubuntu1~14.04.3 is to be installed
Depends: gcc-4.8 (= 4.8.4-2ubuntu1~14.04) but 4.8.4-2ubuntu1~14.04.3 is to be installed
Depends: libstdc++-4.8-dev (= 4.8.4-2ubuntu1~14.04) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.