本人记录一下自己在升级glibc库的时候出现的问题,希望能够帮助其他网友。

1.先下载相对应版本的glibc项目 下载地址:Index of /gnu/glibc

2.解压之后进入解压之后的文件目录执行如下命令:

cd glibc-2.28
mkdir build
cd build
apt install bison
../configure --prefix=/usr/local --disable-sanity-checks //需要加参数
make -j4
make install

3.错误解决

在make install过程中出现如下错误:

Can’t open configuration file /usr/local/etc/ld.so.conf: No such file or directory

就是缺少了必要的编译文件 ld.so.conf。通过 find 命令找到对应的文件位置。

find / -name "ld.so.conf"
cp /etc/ld.so.conf /usr/local/etc/
make install

Logo

华为开发者空间,是为全球开发者打造的专属开发空间,汇聚了华为优质开发资源及工具,致力于让每一位开发者拥有一台云主机,基于华为根生态开发、创新。

更多推荐