Installing Gfortran 8.0 on Ubuntu

For those wanting to use Fortran 2018 features on Gfortran, the latest Gfortran 8.0 is very good to have.

Linux

Note that Ubuntu ≥ 17.10 is required for GCC/Gfortran 8 via this PPA.

add-apt-repository ppa:ubuntu-toolchain-r/test
apt update
apt install gfortran-8

For Ubuntu ≤ 17.04, GCC/Gfortran 7 is the newest available via this PPA.

If you want older versions of gfortran

apt install gfortran-6

  Then select compiler version.

Mac

Gfortran is installed on Mac OS with:

brew install gcc

Windows

Install Windows Gfortran, GCC, Cmake, etc.

Categories:

Updated:

Leave a Comment