!===============================================
! compiler information
!===============================================

! #if "${par.prof}" in ["T","True"] :
! COMPIL : intel_c12.0.3_bullxmpi
! #else
!COMPIL : intel_c12.0.4_impi4.0.2.003
! #endif

! compiler specific settings
#include rc/compiler-ifort-14.0.1.rc

!my.default.fflags : -i4 -r8 -O2 -ip -xSSE4.2

! mpi wrappers:
mpi.compiler.fc                     :  mpif90
mpi.compiler.fc.openmp              :  mpif90

!===============================================
! libraries
! *.lib.*.fflags : for include when compiling Fortran code
! *.lib.*.libs   : for linking when building executable
!===============================================

!! root location of installed user libraries
!APPS_HOME :  /nfs_ltc/tm5_test/users/sager/BACKUP/LIBS
!SUBDIR    : COMPILATION_${COMPIL}

! Z library (used for compression in HDF)
compiler.lib.z.fflags     : 
compiler.lib.z.libs       :  -lz

! JPEG library (used for compression in HDF)
compiler.lib.jpeg.fflags  : 
compiler.lib.jpeg.libs    : -ljpeg

! SZ library (used for compression in HDF)
compiler.lib.sz.fflags    : -I${SZIP_HOME}/include
compiler.lib.sz.libs      : -L${SZIP_HOME}/lib -lsz

! HDF4 library (without netcdf interface)
compiler.lib.hdf4.fflags  :  -I${HDF4_HOME}/include
compiler.lib.hdf4.libs    :  -L${HDF4_HOME}/lib -lmfhdf -ldf

!! ! HDF5 library
!HDF5_VERSION                            :  hdf5-1.8.7
!HDF5_HOME                               :  ${APPS_HOME}/${HDF5_VERSION}/hdf5-1.8.7
!compiler.lib.hdf5.fflags                :  -I${HDF5_HOME}/include
!compiler.lib.hdf5.libs                  :  -L${HDF5_HOME}/lib -lhdf5_hl -lhdf5

! HDF5 library with parallel features enabled
compiler.lib.hdf5_par.fflags            :  -I${HDF5_MPI_HOME}/include
compiler.lib.hdf5_par.libs              :  -L${HDF5_MPI_HOME}/lib -lhdf5_hl -lhdf5

!! NetCDF library
!NETCDF_VERSION                          :  NETCDF.3.6.1/${SUBDIR}                                   
!NETCDF_HOME                             :  ${APPS_HOME}/${NETCDF_VERSION}/netcdf-3.6.1
!compiler.lib.netcdf.fflags              :  -I${NETCDF_HOME}/include                                      
!compiler.lib.netcdf.libs                :  -L${NETCDF_HOME}/lib -lnetcdf                                 
! 
!! NetCDF4 library
!NETCDF4_VERSION                         :  NETCDF.4.3.0/netcdf-4.3.0-C
!NETCDF4_HOME                            :  ${APPS_HOME}/${NETCDF4_PAR_VERSION}
!compiler.lib.netcdf4.fflags             :  -I${NETCDF4_HOME}/include                                       
!compiler.lib.netcdf4.libs               :  -L${NETCDF4_HOME}/lib -lnetcdff -lnetcdf
 
! NetCDF4 library with parallel IO enabled
compiler.lib.netcdf4_par.fflags         :  -I${NETCDF4_FORTRAN_HOME}/include
compiler.lib.netcdf4_par.libs           :  -L${NETCDF4_FORTRAN_HOME}/lib -lnetcdff \
                                           -L${NETCDF4_HOME}/lib -lnetcdf

!! Parallel-NetCDF library
!PNETCDF_VERSION                         :  PNETCDF.1.2.0/${SUBDIR}
!PNETCDF_HOME                            :  ${APPS_HOME}/${PNETCDF_VERSION}/parallel-netcdf-1.2.0
!compiler.lib.pnetcdf.fflags             :  -I${PNETCDF_HOME}/include
!compiler.lib.pnetcdf.libs               :  -L${PNETCDF_HOME}/lib -lpnetcdf
!
!! MPI library
!compiler.lib.mpi.fflags                 : 
!compiler.lib.mpi.libs                   : 
!
!! GRIB library: the EMOSLIB variable should be the real(8) version:
!!    EMOSLIB =  -L/usr/local/lib/metaps/lib/000370 -lemos.R64.D64.I32
!compiler.lib.grib.fflags                : 
!compiler.lib.grib.libs                  :  ${APPS_HOME}/EMOS
!
!! UDUNITS library:
!UDUNITS_VERSION                         :  udunits/1.12.11
!UDUNITS_HOME                            :  /nfs_ltc/tm5_test/users/sager/BACKUP/LIBS/UDUNITS-1.12.11/udunits-1.12.11-ifort
!compiler.lib.udunits.fflags             :  -I${UDUNITS_HOME}/include
!compiler.lib.udunits.libs               :  -L${UDUNITS_HOME}/lib -ludunits
!
!
!! Lapack library:
!!   -lessl               -lblacs           # serial
!!   -lesslsmp            -lblacssmp        # parallel with OpenMP
!!   -lessl    -lpessl    -lblacs           # parallel with MPI
!!   -lesslsmp -lpesslsmp -lblacssmp        # parallel with MPI and OpenMP
!!
!#if "${par.openmp}" in ["T","True"] :
!my.essl.ext   :  smp
!#else
!my.essl.ext   :  
!#endif
!#if "${par.mpi}" in ["T","True"] :
!my.pessl      :  -lpessl${my.essl.ext}
!#else
!my.pessl      :  
!#endif
!!
!compiler.lib.lapack.fflags    : 
!compiler.lib.lapack.libs      :  -lessl${my.essl.ext} ${my.pessl} -lblacs${my.essl.ext}

!===============================================
! settings for job manager
!===============================================

!
! Settings for LSF (BSUB) job manager
!
queue :  bsub

! arguments passed directly to 'bsub' command:
queue.bsub.submit.options  : 

! fixed:
my.bsub.queue     :  normal

! options for the 'build' job, enabled by 'build.make.submit' below:
queue.bsub.options.build        : J q cwd oo eo
queue.bsub.option.build.J	      : ${job.name}
queue.bsub.option.build.q	      : ${my.bsub.queue}
queue.bsub.option.build.cwd     : ${my.run.dir}
queue.bsub.option.build.n	      : ${build.jobs}
queue.bsub.option.build.Rspan   :  -R "span[hosts=1]"
queue.bsub.option.build.oo      : <auto>
queue.bsub.option.build.eo      : <auto>

! ensure correct environment for init step
queue.bsub.options.init	      : J q cwd oo eo
queue.bsub.option.init.J	    : ${job.name}
queue.bsub.option.init.q	    : ${my.bsub.queue}
queue.bsub.option.init.cwd    : ${my.run.dir}
queue.bsub.option.init.oo     : <auto>
queue.bsub.option.init.eo     : <auto>

! ensure correct environment for done step
queue.bsub.options.done	      : J q oo eo
queue.bsub.option.done.J	    : ${job.name}
queue.bsub.option.done.q	    : ${my.bsub.queue}
queue.bsub.option.done.cwd    : ${my.run.dir}
queue.bsub.option.done.oo     : <auto>
queue.bsub.option.done.eo     : <auto>

! ensure correct environment for run step
queue.bsub.options.run        : J q n Rspan Rmem oo eo
queue.bsub.option.run.J	      : ${job.name}
queue.bsub.option.run.q	      : ${my.bsub.queue}
queue.bsub.option.run.cwd     : ${my.run.dir}
queue.bsub.option.run.n	      : ${par.ntask}
queue.bsub.option.run.Rspan   :  -R "span[hosts=1]"
queue.bsub.option.run.Rmem    :  -R "rusage[mem=1700]"
queue.bsub.option.run.oo      : <auto>
queue.bsub.option.run.eo      : <auto>


!===============================================
! maker
!===============================================
! the setup script will insert the 'build.jobs' specified in the expert.rc
! or passed as argument to the setup script, and add Makefile and target to
! the command:
!maker               :  gmake -j %{build.jobs}
maker               :  gmake -j ${LSB_DJOB_NUMPROC}

! Submit compilation with a job script? 
! - if F (default), pycasso calls the ${maker} 
! - if T, then compilation is submitted according to "submit.to" key 
!   (default of which is set in expert.rc, and can be overwritten at the CLI): 
!   either "queue", or foreground.
build.make.submit        : F


!===============================================
! MPI runner
!===============================================

! command and arguments; no command file written, thus executable and arguments are added
mpirun.command     :  mpirun
mpirun.args        :  -np ${par.ntask}

! name of command file; if empty, then executable and arguments are added to the command line
mpirun.cmdfile     :  

! name of host file:
mpirun.hostfile    :  


!===============================================
! debugger
!===============================================
! debugger type: totalview | idb | kdbg
debugger                      :  

! command for debugger:
debugger.command              :  

!===============================================
! model data
!===============================================

! the user scratch directory:
my.scratch          :  ${SCRATCH}

! base path to various data files:
my.data.dir         :  ${MODAS_SCRATCH01}/models/TM5mp

! permanent archives to search for meteo files
my.meteo.search     :  

! extra install tasks
my.install.tasks     :


