Verify that the system binutils (which includes the GNU linker and assembler) is up-to-date. Might as well update the system gcc as well.
% sudo yum update binutils
% sudo yum update gcc
[make sure /usr/bin is ahead of /util/bin in your PATH variable, so you make the new gcc with the system gcc rather than the existing /util gcc.]
% cd /src/util
util% bunzip2 gcc-5.2.0.tar.bz2
util% tar -xvf gcc-5.2.0.tar
util% cd gcc-5.2.0
gcc-5.2.0% ./contrib/download_prerequisites
gcc-5.2.0% cd ..
util% mkdir gcc-5.2.0-build
gcc-5.2.0% cd gcc-5.2.0-build
gcc-5.2.0-build% ../gcc-5.2.0/configure --prefix=/util/gcc-5.2.0 --disable-multilib
gcc-5.2.0-build% make
[wait six hours while the software builds]
gcc-5.2.0-build% sudo make install clean
gcc-5.2.0-build% cd /util
/util% sudo ln -s gcc-5.2.0 gcc
-
First, we highly recommend that GCC be built into a separate directory from the sources which does not reside within the source tree. This is how we generally build GCC; building where srcdir == objdir should still work, but doesn't get extensive testing; building where objdir is a subdirectory of srcdir is unsupported.
- Do we need 32-bit compatible libraries?
- http://gcc.gnu.org/mirrors.html
- http://gcc.gnu.org/install/configure.html
- http://gist.github.com/jeetsukumaran/5224956
- http://www.netgull.com/gcc/releases/
- http://gcc.gnu.org/wiki/FAQ#configure
- http://gcc.gnu.org/install/prerequisites.html
- ftp://gcc.gnu.org/pub/gcc/infrastructure/