User Tools

Site Tools


Table of Contents


Various compilers are available on the GNU/Linux workstations. The system-wide default is always the GNU Compiler collection (gcc, g++, gfortran). Other compilers, and other versions of the compilers, are available through environment modules (See sfinx for details).


module avail

to get a list of available modules. This list may include:


In order to load a specific compiler environment (e.g. intel/10.1), use

module load intel/10.1

or, since 10.1 is marked as the default for the intel module:

module load intel


In the same way, MPI is available on all systems. This of course includes the MPI compilers. The default version is currently MPICH, but among the available modules, you will see


Here, since one version is already loadced, you will need to use the module switch command to switch to the other version (unload MPICH, load OpenMPI):

module switch mpi/openmpi-x86_64

Of course, if you always use a specific version, you can add this command to your login environment (e.g. .bashrc or .cshrc).

Note: if you need to combine MPI with python, you may want to check out the section in Sfinx modules about the additional module files. The default MPI modules set up the PYTHONPATH for the system default version of python (currently 2.7); for use with e.g. python 3.4, load the appropriate module.

Fortran 77

In most cases, gfortran can be made to compile programs written in Fortran 77. If all else fails, the latest version of g77, the previous GNU fortran compiler, can be installed on your system. However, this compiler is not always able to link with newer libraries, and there is no guarantee it will be maintained for much longer. So it is usually better to spend some time figuring out how to use the current compilers to compile your code, in stead of depending on an obsolete compiler.

linux/compilers.txt · Last modified: 2016/04/12 07:27 by lenocil