Ignore:
Timestamp:
Jun 14, 2015, 9:13:32 PM (9 years ago)
Author:
Laurent Fairhead
Message:

Merged trunk changes -r2237:2291 into testing branch

Location:
LMDZ5/branches/testing
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • LMDZ5/branches/testing

  • LMDZ5/branches/testing/makelmdz_fcm

    r2220 r2298  
    3838LIBOGCM=$LMDGCM/libo
    3939LIBFGCM=$LMDGCM/libf
     40DYN_COMMON_PATH=$LIBFGCM/dyn3d_common
    4041# path for optional packages, but default set to ".void_dir"
     42FILTRE_PATH=$LMDGCM/.void_dir
     43DYN_PHYS_PATH=$LMDGCM/.void_dir
     44DYN_PHYS_SUB_PATH=$LMDGCM/.void_dir
    4145RRTM_PATH=$LMDGCM/.void_dir
    4246SISVAT_PATH=$LMDGCM/.void_dir
     
    7882          true        : (obsolete; for backward compatibility) use ORCHIDEE tag 1.9-1.9.6
    7983[-chimie INCA/false]       : with INCA chemistry model or without (default: false)
     84[-cosp true/false]    : compile with/without cosp package (default: false)
     85[-sisvat true/false]  : compile with/without sisvat package (default: false)
     86[-rrtm true/false]    : compile with/without rrtm package (default: false)
    8087[-parallel none/mpi/omp/mpi_omp] : parallelism (default: none) : mpi, openmp or mixted mpi_openmp
    8188[-g GRI]                   : grid configuration in dyn3d/GRI_xy.h  (default: reg, inclues a zoom)
     
    176183done
    177184
     185if [[ $code = ce0l && $paramem = mem ]]
     186then
     187    echo "There is no parallel version of ce0l at the moment."
     188    echo "Please compile the sequential version of the code to produce the" \
     189        "executable ce0l."
     190    exit 1
     191fi
     192
    178193###############################################################
    179194# path to fcm
     
    219234fi
    220235
     236phys_root=$physique
     237if [[ "${physique:0:3}" == "lmd" ]] ; then phys_root=lmd ; fi
     238if [[ "${physique:0:4}" == "mars" ]] ; then phys_root=mars ; fi
     239if [[ "${physique:0:3}" == "std" ]] ; then phys_root=std ; fi
     240if [[ "${physique:0:5}" == "venus" ]] ; then phys_root=venus ; fi
     241if [[ "${physique:0:5}" == "titan" ]] ; then phys_root=titan ; fi
     242if [[ "${physique:0:3}" == "mar" ]] ; then phys_root=mar ; fi
     243if [[ "${physique:0:3}" == "dev" ]] ; then phys_root=dev ; fi
     244
    221245if [[ "$physique" != "nophys" ]]
    222246then
    223247   #We'll use some physics
    224248   CPP_KEY="$CPP_KEY CPP_PHYS"
    225    if [[ "${physique:0:3}" == "lmd" ]]
     249   if [[ "${phys_root}" == "lmd" ]]
    226250   then
    227251   #For lmd physics, default planet type is Earth
    228252   CPP_KEY="$CPP_KEY CPP_EARTH"
    229253   fi
     254   # set the dyn/phys interface path
     255   DYN_PHYS_PATH="${LIBFGCM}/dynlonlat_phylonlat"
     256   DYN_PHYS_SUB_PATH="${LIBFGCM}/dynlonlat_phylonlat/phy${phys_root}"
     257fi
     258
     259if [[ "$filtre" == "filtrez" ]]
     260then
     261   FILTRE_PATH=${LIBFGCM}/$filtre
    230262fi
    231263
     
    339371then
    340372   CPP_KEY="$CPP_KEY CPP_COSP"
    341    COSP_PATH="$LIBFGCM/cosp"
     373   COSP_PATH="$LIBFGCM/phylmd/cosp"
    342374#   LIB="${LIB} -l${LIBPREFIX}cosp"
    343375fi
     
    407439  \rm fxyprim.h
    408440  cp -p fxy_${grille}.h fxyprim.h
    409 else
    410   echo "Probleme dans les dimensions de la dynamique !!"
    411   echo "Non reactive pour l'instant !!!"
     441#else
     442#  echo "Probleme dans les dimensions de la dynamique !!"
     443#  echo "Non reactive pour l'instant !!!"
     444fi
     445
     446if (( $dimension == 1 ))
     447then
     448  CPP_KEY="$CPP_KEY CPP_1D"
     449##in 1D, add dyn3d to include path (because main prog is in physics)
     450  INCLUDE="$INCLUDE -Ilibf/dyn3d -Ilibf/dyn3d_common"
     451## no filtre in 1d:
     452  FILTRE_PATH=$LMDGCM/.void_dir
     453## no need to compile all routines in dyn3d_common either:
     454  DYN_COMMON_PATH=$LMDGCM/.void_dir
     455## no need to compile all routines in dynlmdz_phy... ;
     456## (because key ones are included in 1D main program)
     457  DYN_PHYS_PATH=$LMDGCM/.void_dir
     458  DYN_PHYS_SUB_PATH=$LMDGCM/.void_dir
    412459fi
    413460
     
    470517else
    471518  SUFF_NAME=${SUFF_NAME}_seq
    472   DYN=dyn${dimc}d
     519  if (( $dimension == 1 ))
     520  then
     521    # dynamics-related routines in"dyn1d" subdirectory of phy${physique}
     522    DYN=phy${physique}/dyn1d
     523  else
     524    DYN=dyn${dimc}d
     525  fi
    473526fi
    474527
     
    503556echo "%LIBO          $LIBOGCM"       >> $config_fcm
    504557echo "%DYN           $DYN"           >> $config_fcm
     558echo "%DYN_COMMON    $DYN_COMMON_PATH" >> $config_fcm
     559echo "%FILTRE        $FILTRE_PATH"   >> $config_fcm
    505560echo "%PHYS          phy${physique}" >> $config_fcm
     561echo "%DYN_PHYS      $DYN_PHYS_PATH" >> $config_fcm
     562echo "%DYN_PHYS_SUB  $DYN_PHYS_SUB_PATH" >> $config_fcm
    506563echo "%RRTM          $RRTM_PATH"     >> $config_fcm
    507564echo "%SISVAT        $SISVAT_PATH"   >> $config_fcm
     
    525582fi
    526583
    527 
    528584rm -f $LIBOGCM/${arch}${SUFF_NAME}/.config/fcm.bld.lock
    529585./build_gcm ${fcm_path} -j $job $full
Note: See TracChangeset for help on using the changeset viewer.