Skip to content

Latest commit

 

History

History
50 lines (37 loc) · 1.65 KB

login-env-compilers.rst

File metadata and controls

50 lines (37 loc) · 1.65 KB

Set environment variables for compilers

The sample GNU <env-files-gnu10> and Intel <env-files-intel19> environment files set the environment variables listed below in order to select the desired C, C++, and Fortran compilers:

Note

GEOS-Chem Classic only requires the Fortran compiler. But you will also need the C and C++ compilers if you plan to build other software packages (such as KPP <kppguide>) or install libraries manually <build-libraries-with-spack>.

Environment variables that specify compilers
Variable Specifies the: GNU name Intel name
CC C compiler gcc icc
CXX C++ compiler g++ icpc
FC Fortran compiler gfortran ifort

The commands used to define CC, CXX, and FC are:

# for GNU
export CC=gcc
export CXX=g++
export FC=gfortran

or

# for Intel
export CC=icc
export CXX=icpc
export FC=ifort