这是本文档旧的修订版!
CentOS 6.8 (64 bits), CentOS 7.6 (64 bits)
> wget http://ftp.gnu.org/gnu/gcc/gcc-10.2.0/gcc-10.2.0.tar.gz > tar -zxvf gcc-10.2.0.tgz
> cd gcc-10.2.0 > ./contrib/download_prerequisites
> mkdir gcc-build-10.2.0 > cd gcc-build-10.2.0 > ../configure -enable-checking=release -enable-language=c,c++ -disable-multilib > make -j4 # for multi-core optimization > make install > ls /usr/local/bin |grep gcc # check whether it is installed successfully or not
To restart the operation system,and then check the version.
> gcc -v
评论