Ubuntu 13.04 with gcc/g++/gfortran 4.8 by default?

13,880

Solution 1

Yes, Raring has gcc 4.7.3 by default. However you can install gcc 4.8 from Ubuntu toolchain PPA.

You can even install latest gcc snapshot by installing gcc-snapshot package available in universe repository. (not recommended though)

Solution 2

The following should do the trick:

sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install g++-4.8

Note, if you receive an error saying that add-apt-repository does not exist, you can install it via:

sudo apt-get install software-properties-common
Share:
13,880

Related videos on Youtube

Ioannis Kavadakis
Author by

Ioannis Kavadakis

Researcher, astrophysicist, computer scientist, programming language expert, software architect and C++ standardization committee member. LinkedIn: https://www.linkedin.com/in/vincent-reverdy

Updated on September 18, 2022

Comments

  • Ioannis Kavadakis
    Ioannis Kavadakis over 1 year

    I plan to download and install Ubuntu 13.04 and I would like to have two compilers on my system.

    First question: what is the version of gcc/g++/gfortran shipped with ubuntu 13.04 ? (is it 4.7.3 ?).

    So, I would like to have gcc/g++/gfortran 4.8 as my default compiler (and 4.7.3 as a "backup"). Is there a well precompiled version avaible somewhere (compiled with the right optimizations and enabling std::thread) ? And how to download on install it ?