Install latest GFortran on Linux
Newer version of compilers generally have more useful and detailed warning messages.
As with any compiler, newer versions of Gfortran may require rebuilding other libraries linked with the Fortran compiler if the ABI presented by
On Linux, one can switch Gfortran versions with
If experiencing errors getting any version of
gfortran installed in Ubuntu, try:
The latest GCC / Gfortran for Ubuntu is available from the Ubuntu-test PPA. Add Ubuntu-test PPA by:
add-apt-repository ppa:ubuntu-toolchain-r/test apt update
Install the most recent Gfortran listed at the PPA. Switch between compiler versions with update-alternatives.
- Windows: Install latest Gfortran
- MacOS: get latest gfortran by
brew install gcc