Changeset 6242 for CONFIG/UNIFORM


Ignore:
Timestamp:
09/19/22 18:06:34 (19 months ago)
Author:
lfairhead
Message:

copy of r6210 and r6212 from IPSLCM configuration to LMDZOR configuration
update compilation script to include new lmdz option : rad. Try to propose retrocompatibility
remove xios from ce0l compilation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • CONFIG/UNIFORM/v6/LMDZOR_v6.3/compile_lmdzor.sh

    r6112 r6242  
    2727# Compilation with rrtm or ecrad radiative code (default rad=rrtm) 
    2828rad=rrtm 
     29opt_rad="" 
    2930# Compilation with Cosp (cosp=NONE/v1/v2 ; default=NONE) 
    3031cosp=NONE 
     
    238239echo; echo "NOW COMPILE LMDZ REGULAR LAT-LON MODE. Resolution = ${resol_atm}" 
    239240echo >> $outfile ; echo " NOW COMPILE LMDZ REGULAR LAT-LON MODE. Resolution = ${resol_atm}"   >> $outfile  
     241# Retrieve the final svn release number, needed for radiative code suffix of executable 
     242lmdzsvn=`svnversion . | egrep -o "[0-9]+"  | awk 'NR==1'` 
    240243 
    241244# Check if the compilation of LMDZ was previsouly interupted prematured.  
     
    252255fi 
    253256 
    254 echo ./makelmdz_fcm -d ${resol_atm} -p lmd -rad $rad  $opt_cosp -$optmode -mem -parallel $parallel -io xios -v orchidee2.1 -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz gcm    >> $outfile  
    255 ./makelmdz_fcm -d ${resol_atm} -p lmd -rad $rad -$optmode -mem -parallel $parallel -io xios -v orchidee2.1 -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz gcm    >> $outfile 2>&1 
     257# Need to define the proper option for radiative code compilation. By default, we use rrtm 
     258case $rad in 
     259    oldrad) opt_rad="" ;; 
     260    rrtm)   if [ $lmdzsvn -le 4185 ] ; then opt_rad="-rrtm true" ; else opt_rad="-rad rrtm" ; fi ;; 
     261    ecrad)  opt_rad="-rad ecrad" ;; 
     262    *) echo Only oldrad rrtm ecrad for rad option ; exit 
     263esac 
     264 
     265if [ $lmdzsvn -le 4185 -a $rad = "ecrad" ] ; then echo "ecrad only available for LMDZ rev starting with 4186 " ; exit ; fi 
     266 
     267 
     268echo ./makelmdz_fcm -d ${resol_atm} -p lmd  $opt_rad $opt_cosp -$optmode -parallel $parallel -io xios -v orchidee2.1 -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz gcm    >> $outfile  
     269./makelmdz_fcm -d ${resol_atm} -p lmd  $opt_rad -$optmode -parallel $parallel -io xios -v orchidee2.1 -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz gcm    >> $outfile 2>&1 
    256270# Test if compiling finished 
    257271if [[ $? != 0 ]] ; then 
     
    267281echo >> $outfile 
    268282 
    269 # Find executable suffix 
     283suffix=${resol_atm}_phylmd 
     284if [ $lmdzsvn -ge 4186 ] ; then suffix=${suffix}_${rad} ; fi 
    270285if [ $parallel == seq ] || [ $parallel == none ] ; then 
    271     suffix=_${resol_atm}_phylmd_seq_orch.e 
     286    suffix=_${suffix}_seq_orch.e 
    272287else 
    273     suffix=_${resol_atm}_phylmd_para_mem_orch.e 
     288    suffix=_${suffix}_para_mem_orch.e 
    274289fi 
    275290echo gcm suffix = $suffix 
     
    289304    echo >> $outfile ; echo " NOW COMPILE CE0L OF LMDZ. Resolution = ${resol_atm}"   >> $outfile  
    290305     
    291     echo ./makelmdz_fcm -d ${resol_atm} -p lmd -rad $rad -$optmode -io xios -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz ce0l    >> $outfile  
    292     ./makelmdz_fcm -d ${resol_atm} -p lmd -rad $rad -$optmode -io xios -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz ce0l    >> $outfile 2>&1 
     306    echo ./makelmdz_fcm -d ${resol_atm} -p lmd  $opt_rad -$optmode -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz ce0l    >> $outfile  
     307    ./makelmdz_fcm -d ${resol_atm} -p lmd  $opt_rad -$optmode -arch $fcm_arch -arch_path $arch_path -j 8 $full_lmdz ce0l    >> $outfile 2>&1 
    293308    # Test if compiling finished 
    294309    if [[ $? != 0 ]] ; then 
     
    305320    echo >> $outfile 
    306321    suffix=_${resol_atm}_phylmd_seq.e 
     322    if [ $lmdzsvn -ge 4186 ] ; then suffix=_${resol_atm}_phylmd_${rad}_seq.e ; fi 
    307323    echo ce0l suffix = $suffix 
    308324 
Note: See TracChangeset for help on using the changeset viewer.