To be a better coder
分类: LINUX
2021-01-20 15:14:04
cd gmp-6.1.0
./configure --prefix=/usr/local/gmp-6.1.0
make && make install cd mpfr-3.1.4
./configure --prefix=/usr/local/mpfr-3.1.4 --with-gmp=/usr/local/gmp-6.1.0
make && make install cd mpc-1.0.3
./configure --prefix=/usr/local/mpc-1.0.3 --with-gmp=/usr/local/gmp-6.1.0 --with-mpfr=/usr/local/mpfr-3.1.4
make && make install
cd isl-0.18/
./configure --prefix=/usr/local/isl-0.18 --with-gmp-prefix=/usr/local/gmp-6.1.0
make && make install
$ mkdir build && cd build
5.进入编译目录build后,通过gcc-8.3.0文件夹下的configure脚本生成makefile文件。
此时的设置可以参考前面的gcc-4.8.5的配置,-prefix配置make install的目录(安装目录),--enable-languages中去掉java(不支持),仅支持本机x64配置--disable-multilib(需要支持x86就去掉)。
$ ../configure --prefix=/usr/local/gcc-8.3.0 --with-gmp=/usr/local/gmp-6.1.0 --with-mpfr=/usr/local/mpfr-3.1.4 --with-mpc=/usr/local/mpc-1.0.3 --with-isl=/usr/local/isl-0.18 --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl= --enable-bootstrap --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-languages=c,c++,objc,obj-c++,fortran,ada,go,lto --enable-plugin --enable-initfini-array --enable-gnu-indirect-function --with-tune=generic --with-arch_32=x86-64 --build=x86_64-redhat-linux --disable-multilib
配置完成后,进行make和make install。
# make && make install