Newer version of compilers generally have more useful and detailed warning messages.
Recent GCC versions have been steadily improving
Fortran 2018 support.
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 (similarly for
apt install gfortran-10
Switch between compiler versions with update-alternatives.
- Windows: Install latest Gfortran
- MacOS: get latest gfortran by
brew install gcc