背景:
编译安装一个软件的时候,提示
configure: error: no acceptable C compiler found in $PATH ,一看应该知道应该是gcc没装,那准备yum安装gcc
yum安装gcc的时候报glibc 和glibc-common的版本冲突,centos6.3 x64 系统里面glibc-common有2个版本,glibc-common-2.12-1.107和glibc-common-2.12-1.80(至于为啥有2个版本的glibc-common无法追溯了),看报错,说要升级glibc的版本为 glibc-2.12-1.107.el6.x86_64
–> Running transaction check
—> Package glibc.x86_64 0:2.12-1.80.el6 will be updated
–> Processing Dependency: glibc = 2.12-1.80.el6 for package: glibc-common-2.12-1.80.el6.x86_64
—> Package kernel-headers.x86_64 0:2.6.32-358.11.1.el6 will be installed
–> Finished Dependency Resolution
Error: Package: glibc-common-2.12-1.80.el6.x86_64 (@anaconda-CentOS-201207061011.x86_64/6.3)
Requires: glibc = 2.12-1.80.el6
Removing: glibc-2.12-1.80.el6.x86_64 (@anaconda-CentOS-201207061011.x86_64/6.3)
glibc = 2.12-1.80.el6
Updated By: glibc-2.12-1.107.el6.x86_64 (base)
glibc = 2.12-1.107.el6
You could try using –skip-broken to work around the problem
** Found 3 pre-existing rpmdb problem(s), ‘yum check’ output follows:
glibc-common-2.12-1.107.el6.x86_64 is a duplicate with glibc-common-2.12-1.80.el6.x86_64
glibc-common-2.12-1.107.el6.x86_64 has missing requires of glibc = (‘0′, ‘2.12’, ‘1.107.el6′)
libgcc-4.4.7-3.el6.x86_64 is a duplicate with libgcc-4.4.6-4.el6.x86_64
—> Package glibc.x86_64 0:2.12-1.80.el6 will be updated
–> Processing Dependency: glibc = 2.12-1.80.el6 for package: glibc-common-2.12-1.80.el6.x86_64
—> Package kernel-headers.x86_64 0:2.6.32-358.11.1.el6 will be installed
–> Finished Dependency Resolution
Error: Package: glibc-common-2.12-1.80.el6.x86_64 (@anaconda-CentOS-201207061011.x86_64/6.3)
Requires: glibc = 2.12-1.80.el6
Removing: glibc-2.12-1.80.el6.x86_64 (@anaconda-CentOS-201207061011.x86_64/6.3)
glibc = 2.12-1.80.el6
Updated By: glibc-2.12-1.107.el6.x86_64 (base)
glibc = 2.12-1.107.el6
You could try using –skip-broken to work around the problem
** Found 3 pre-existing rpmdb problem(s), ‘yum check’ output follows:
glibc-common-2.12-1.107.el6.x86_64 is a duplicate with glibc-common-2.12-1.80.el6.x86_64
glibc-common-2.12-1.107.el6.x86_64 has missing requires of glibc = (‘0′, ‘2.12’, ‘1.107.el6′)
libgcc-4.4.7-3.el6.x86_64 is a duplicate with libgcc-4.4.6-4.el6.x86_64
下载glibc 107版本。
显示依赖libfreebl3.so,(其他依赖比如glibc-common我们已经装过了)
那继续下载libfreebl3.so
他依赖libc.so.6 正好就是上面glibc
下载这2个软件后,同时安装这2个软件
然后查看下现在glibc 和glibc-common 的版本已经一致了,目前在yum 安装gcc就正常了。