- 积分
- 5
- 贡献
-
- 精华
- 在线时间
- 小时
- 注册时间
- 2018-9-19
- 最后登录
- 1970-1-1
|

楼主 |
发表于 2018-9-28 15:51:04
|
显示全部楼层
# set the conpileroption
if ( $#argv == 1 ) then
setenv compiler $1
setenv compilerVrsn Empty
else if ( $#argv == 2 ) then
setenv compiler $1
setenv compilerVrsn $2
else if ( $#argv == 0 ) then
if ( ! $?compiler ) then
echo "Error: 'compiler' should be set either in the"
echo " environment or as input to config.cmaq"
echo " Example:> ./config.cmaq [compiler]"
echo " Options: intel | gcc | pgi"
exit
else if ( ! $?compilerVrsn ) then
setenv compilerVrsn Empty
endif
else
echo "Error: Too many inputs to config.cmaq. This script"
echo " is expecting one input (the name of the"
echo " desired compiler. In some installations, you "
echo " may also be able to specify the compiler version "
echo " as the second input, but this is not by default."
exit
endif
echo "Compiler is set to $compiler"
# Compiler flags and settings
switch ( $compiler )
case intel:
setenv IOAPI_MOD_DIR /public/home/lipengfei/lib/ioapi-3.1/ #> I/O API precompiled modules
setenv IOAPI_INCL_DIR /public/home/lipengfei/lib/ioapi-3.1/ #> I/O API include header files
setenv IOAPI_LIB_DIR /public/home/lipengfei/lib/ioapi-3.1/ #> I/O API libraries
setenv NETCDF_LIB_DIR /public/home/lipengfei/lib/netcdf-4.1.3 #> netCDF directory path
setenv NETCDF_INCL_DIR /public/home/lipengfei/lib/netcdf-4.1.3 #> netCDF directory path
setenv MPI_LIB_DIR /public/software/mpi/mvapich2-2.1-intel #> MPI directory path
#> Compiler Aliases and Flags
setenv myFC mpiifort
setenv myCC icc
setenv myFSTD "-O3 -fno-alias -mp1 -fp-model source"
setenv myDBG "-O0 -g -check bounds -check uninit -fpe0 -fno-alias -ftrapuv -traceback"
setenv myLINK_FLAG "-openmp"
setenv myFFLAGS "-fixed -132"
setenv myFRFLAGS "-free"
setenv myCFLAGS "-O2"
setenv extra_lib "-lcurl"
#setenv extra_lib ""
setenv mpi_lib "-lmpich" #> No Library specification needed for mpiifort
#> -lmpich for mvapich
breaksw
|
|