系统为centos7,在安装wget时,执行命令:yum -y install gcc-c++
,提示如下错误:
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirrors.aliyun.com
* extras: mirrors.aliyun.com
* updates: mirrors.aliyun.com
Package gcc-c++-4.8.5-39.el7.x86_64 already installed and latest version
Nothing to do
根据提示猜测是,gcc-c++
已经安装但没有正常启动,所以就先删除再重新安装,删除执行如下:
yum remove gcc-4.8.5-39.el7.x86_64
执行成功后,再执行安装gcc-c++
操作,命令如下:
yum -y install gcc-c++
安装成功,如下:
思路来源于https://blog.youkuaiyun.com/u010502101/article/details/98473522