1.下载gcc源码
2.配置编译源码
3.安装
下载地址:GCC mirror sites - GNU Project
- France (no snapshots):?ftp.lip6.fr, thanks to ftpmaint@lip6.fr
- France, Brittany:?ftp.irisa.fr, thanks to ftpmaint@irisa.fr
- Germany, Berlin:?ftp.fu-berlin.de, thanks to ftp@fu-berlin.de
- Germany:?ftp.gwdg.de, thanks to ftp@gwdg.de
- Germany:?mpi-sb.mpg.de, thanks to ftpadmin@mpi-sb.mpg.de
- Germany:?http://gcc.cybermirror.org, thanks to Sascha Schwarz (cm@cybermirror.org)
- Greece:?ntua.gr, thanks to ftpadm@ntua.gr
- Hungary, Budapest:?robotlab.itk.ppke.hu, thanks to Adam Rak (neurhlp@gmail.com)
- Japan:?ftp.tsukuba.wide.ad.jp, thanks to Kohei Takahashi (tsukuba-ftp-servers@tsukuba.wide.ad.jp)
- Morocco:?mirror.marwan.ma?(rsync://mirror.marwan.ma/gcc/), thanks to Sami Ait Ali Oulahcen (sami@marwan.ma)
- The Netherlands, Dronten: ??Index of /gcc?| ??rsync://mirror.koddos.net/gcc/, ? thanks to Martin (mirror@koddos.net) at KoDDoS.
- The Netherlands, Nijmegen:?ftp.nluug.nl, thanks to Jan Cristiaan van Winkel (jc@ATComputing.nl)
- Russia, Novosibirsk:?Index of /gnu/gcc, thanks to Daniel Volchixin (daniel@volchixin.co.uk)
- Slovakia, Bratislava:?gcc.fyxm.net, thanks to Jan Teluch (admin@2600.sk)
- UK:?mirrorservice.org, thanks to mirror@mirrorservice.org
- US, San Francisco:?Index of /mirrors/gcc, thanks to info@bigsearcher.com
- US, San Jose:?http://www.netgull.com, thanks to admin@netgull.com
- US, Michigan:?Index of /gcc, thanks to admin@mirrors.concertpass.com.
里面那个快选那个我用的俄罗斯的
?#wget??https://mirror.linux-ia64.org/gnu/gcc/releases/gcc-5.5.0/gcc-5.5.0.tar.xz
#tar xvf?gcc-5.5.0.tar.xz
#mkdir gcc_build
#cd?gcc-5.5.0
#$./contrib/download_prerequisites
#cd ../gcc_build
#$PWD/../gcc-5.5.0/configure --prefix=/usr --enable-checking=release --enable-languages=c,c++ --disable-multilib
#make -j2
#make install