If not something has gone wrong and do not proceed until you have worked out why it failed (for me this has only happened when using the ‘wrong’ version of ESMF). You can then build the library, and check that it built correctly (the ‘-j4’ command is not necessary, but specifies the number of cores to use for gmake):Įvery test should pass. You should see at the top our non-default options you have passed. First navigate to the ESMF directory and you can check what settings are going to be used: You can test this has worked by typing into a terminal:Īnd ‘mpiuni’ should be returned. The final line will make sure the bashrc file is reloaded. You can do this with the following commands:Įcho 'export ESMF_DIR=~/esmf' > ~/.bashrcĮcho 'export ESMF_COMM=mpiuni' > ~/.bashrcĮcho 'export ESMF_F90COMPILER=gfortran' > ~/.bashrcĮcho 'export ESMF_CXXCOMPILER=g++' > ~/.bashrc You need to add to the bottom of your bashrc file the ESMF directory (ESMF_DIR) and details of the compilers being used (ESMF_COMM, ESMF_F90COMPILER, ESMF_CXXCOMPILER). We then need to update some environment variables. This will create a folder called ‘esmf’ containing everything we need (so there is a folder in the location ‘/home/sean/esmf’ in my case). Once it is downloaded extract it to a location of choice, in this example I’ll just drop it in my home directory: It can be downloaded from the ESMF website.
![install gfortran compiler ubuntu install gfortran compiler ubuntu](https://i.ytimg.com/vi/w1lVo7Z7xb8/maxresdefault.jpg)
I have tested TIE-GCM on Ubuntu 14.04 – 18.04 with ESMF version 7.0.2 (this is not the latest release), and Ubuntu 20.04 with ESMF version 8.1.0. This step can cause a lot of trouble because using the wrong version of ESMF seems to cause problems.
#INSTALL GFORTRAN COMPILER UBUNTU INSTALL#
Sudo apt install csh libnetcdf* libopenmpi* curl libcurl3-dev gfortran g++ makeīefore we can build the model we need the Earth System Modeling Framework (ESMF) library. You can install the model on Linux systems other than Ubuntu but you will need to download and build some packages which are included in the Ubuntu repository.įirst we make sure we have the necessary packages installed: There are a couple of steps that are needed, but the method below is tested with versions of Ubuntu from 14.04-20.04. I get a couple of emails a week asking me for help with installing NCARs TIE-GCM v2.0 with GFortran (rather than the standard IFORT).
#INSTALL GFORTRAN COMPILER UBUNTU HOW TO#
It is about how to install the ionosphere/thermosphere model TIE-GCM on Ubuntu computers using gfortran. This is a very specific post, most people will want to skip over it entirely.