centos7 install gcc-10.1.0

一、先安装依赖包,不然会报错
# yum install -y gcc 
# yum install -y perl-Thread-Queue
# yum install -y glibc-devel.i686
# yum install -y gmp-devel
# yum install -y glibc-headers gcc-c++

二、下载压缩包
# wget http://ftp.gnu.org/gnu/m4/m4-1.4.18.tar.gz
# wget http://ftp.gnu.org/gnu/autoconf/autoconf-latest.tar.gz
# wget http://ftp.gnu.org/gnu/automake/automake-1.16.2.tar.gz
# wget ftp://gcc.gnu.org/pub/gcc/infrastructure/gmp-6.1.0.tar.bz2
# wget https://gcc.gnu.org/pub/gcc/infrastructure/mpfr-3.1.4.tar.bz2
# wget https://gcc.gnu.org/pub/gcc/infrastructure/mpc-1.0.3.tar.gz
# wget http://ftp.gnu.org/gnu/gcc/gcc-10.1.0/gcc-10.1.0.tar.gz

三、解压
# tar xf m4-1.4.18.tar.gz
# tar xf autoconf-latest.tar.gz
# tar xf automake-1.16.2.tar.gz
# tar xf gmp-6.1.0.tar.bz2
# tar xf mpfr-3.1.4.tar.bz2
# tar xf mpc-1.0.3.tar.gz
# tar xf gcc-10.1.0.tar.gz

四、安装
# cd m4-1.4.18
# ./configure 
# make && make install
# cd ../autoconf-2.69/
# ./configure 
# make && make install
# cd ../automake-1.16.2/
# ./configure
# make && make install
# cd ../mpfr-3.1.4/
# ./configure 
# make && make install
# cd ../mpc-1.0.3/
# ./configure 
# make && make install
# cd ../gcc-10.1.0/
# ./configure 
# make && make install

 

©️2020 CSDN 皮肤主题: 大白 设计师:CSDN官方博客 返回首页