Skip to content
Victor Escorcia Castillo edited this page Sep 11, 2016 · 2 revisions

Who does not use gcc?

Let's compile it. With detail instructions (copy-paste) for Fedora so far.

1. Install requirements

Fedora 24

sudo dnf install binutils-devel-2.26 gzip bzip2-devel make gmp-devel mpfr-devel libmpc-devel isl-devel 

2. Download source code

Use one of the official mirrors here.

3. Compilation

Let's assume that your shell is on the root folder of the source code that you download i.e. cd the-awesome-gcc-version

mkdir build; cd build
../configure --prefix=~/bin/gcc --disable-multilib
make -j 12
make install

The previous command creates a compiler for your particular architecture. You may remove it if you know what I'm talking.

Useful URLs

Guide for Fedora with helpful comments

GCC prerequisites

Clone this wiki locally