解决“libc.so.6: version GLIBC_2.14 not found”报错问题

找了很多博客,但是解决过程中经常碰到一些问题,博主也不说明怎么解决这些问题。。。。导致无法继续执行接下来的步骤,总结了一下:

wget http://ftp.gnu.org/gnu/glibc/glibc-2.14.tar.gz 
wget http://ftp.gnu.org/gnu/glibc/glibc-ports-2.14.tar.gz 
tar -xvf  glibc-2.14.tar.gz 
tar -xvf  glibc-ports-2.14.tar.gz
mv glibc-ports-2.14 glibc-2.14/ports
mkdir glibc-2.14/build
cd glibc-2.14/build 
../configure  --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin
make
make install

可能会出现这个问题:

../configure  --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin

错误:
checking LD_LIBRARY_PATH variable... contains current directory
configure: error: 
*** LD_LIBRARY_PATH shouldn t contain the current directory when
*** building glibc. Please change the environment variable
*** and run configure again.

解决方法如下:

echo $LD_LIBRARY_PATH
/public/software/mpi/openmpi-16-intel/lib:/public/software/intel/composer_xe_2011_sp1.7.256/compiler/lib/intel64:/public/software/intel/composer_xe_2011_sp1.7.256/mkl/lib/intel64:/opt/gridview//pbs/dispatcher427/lib

LD_LIBRARY_PATH不能以终结符作为开始和最后一个字符,不能有2个终结符连在一起,所以修改下LD_LIBRARY_PATH即可:/usr/local/lib64:/usr/local/lib


#上面都是废话,使用下面这一句即可
export LD_LIBRARY_PATH=/public/software/mpi/openmpi-16-intel/lib:/public/software/intel/composer_xe_2011_sp1.7.256/compiler/lib/intel64:/public/software/intel/composer_xe_2011_sp1.7.256/mkl/lib/intel64:/opt/gridview/pbs/dispatcher427/lib:/usr/local/lib64:/usr/local/lib

然后重新运行

../configure  --prefix=/usr --disable-profile --enable-add-ons --with-headers=/usr/include --with-binutils=/usr/bin
make
make install

make 等的时间有点长。。。

make的时候,可能会碰到如下错误:

make[2]: 警告:检测到时钟错误。您的创建可能是不完整的。

原因是有文件的时间比当前时间还要晚(比如现在系统时钟时间是2013年1月24日 12:00:00, make所依赖的文件中存在文件的时间比这个时间还晚,比如是2014年2月21日 12:05:00),可以用"touch *"来更新文件时间,进而解决这个问题.
    尝试了一下touch这个方法,touch完第一次没有报这个警告,之后又有这个警告了.根据make的处理方法,发现即使文件没变动也会编译某一个cpp文件,在顺着警告信息往上找,发现有这么一条警告:
"make: Warning: File `shttpd/include/shttpd.h' has modification time 3e+07 s in the future"
因此断定比系统时间还要晚的文件就是这个shttpd.h

对症下药:
    touch /shttpd/include/shttpd.h
再重新make,没有再出现这个问题.



我自己使用的是 touch * -----修改全局的时间

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值