先查看make版本:
root@:~/clickhouse/gcc-build# make --version
GNU Make 3.82
Built for x86_64-redhat-linux-gnu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
要求版本:
* GNU 'make' 4.0 or newer
As of relase time, GNU 'make' 4.2.1 is the newest verified to work
to build the GNU C Library.
编译安装make:
你需要先安装make,才能使用make进行编译安装make
wget https://ftp.gnu.org/gnu/make/make-4.2.tar.gz
tar xvf make-4.2.tar.gz
cd make-4.2/
./configure
make
sudo make install
查看版本:
root@:~/clickhouse/ft_local/make-4.2# /usr/local/bin/make --version
GNU Make 4.2
Built for x86_64-pc-linux-gnu
Copyright (C) 1988-2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
你可以把旧版本卸载了,链接新版本过去:
yum remove make
ln -s /usr/local/bin/make /usr/bin/
make --version
参考链接:makefile - how to update make 3.81 linux - Stack Overflow
然后安装最新版GNU ‘binutils’ (as and ld)
gnu binutils中有很多,但是编译glibc只需之2个:
* GNU 'binutils' 2.25 or later
You must use GNU 'binutils' (as and ld) to build the GNU C Library.
No other assembler or linker has the necessary functionality at the
moment. As of release time, GNU 'binutils' 2.31.1 is the newest
verified to work to build the GNU C Library.
编译安装方法:
wget https://ftp.gnu.org/gnu/binutils/binutils-2.32.tar.gz
tar xvf binutils-2.32.tar.gz
cd binutils-2.32/
./configure =
make
sudo make install
查看版本:
root@:~/clickhouse/binutils-2.32# /usr/local/bin/ld --version
GNU ld (GNU Binutils) 2.32
Copyright (C) 2019 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) a later version.
This program has absolutely no warranty.