Changeset 4411 for CONFIG/UNIFORM


Ignore:
Timestamp:
04/29/19 18:27:32 (5 years ago)
Author:
jgipsl
Message:

Copied script for compilation from ICOLMDZOR_v7 and adapt it to compile LMDZOR configuration. Version of IOIPSL with compilation with fcm is needed for this script.

File:
1 copied

Legend:

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

    r4410 r4411  
    1111modipsl=$submitdir/../.. 
    1212arch_path=$submitdir/ARCH  
    13 export ROOT=$modipsl/modeles/DYNAMICO 
    1413 
    1514#### Set default options  
     
    1716# optmode=prod/dev/debug 
    1817optmode=prod 
    19 # Resolution if compiling LMDZ in regular mode without DYNAMICO 
    20 # Use for example following "./compile_icolmdzor.sh -regular_lonlat 144x142x79" 
    21 regular_latlon=no 
     18# Resolution of LMDZ in regular mode 
     19regular_latlon=yes 
     20resol_atm_3d=144x142x79 
     21 
    2222# fcm_arch 
    2323fcm_arch=default 
     
    3030 
    3131# Output text file for compilation of each component 
    32 outfile=$submitdir/out_compile_icolmdzor 
     32outfile=$submitdir/out_compile_lmdzor 
    3333rm -f $outfile; echo > $outfile 
    34 echo; echo "Text output from compilation will be stored in file out_compile_icolmdzor"; echo  
     34echo; echo "Text output from compilation will be stored in file out_compile_lmdzor"; echo  
    3535 
    3636#### Read arguments  
     
    4141 
    4242######################################################################## 
    43 # Usage of the script compile_icolmdzor.sh 
     43# Usage of the script compile_lmdzor.sh 
    4444# 
    4545######################################################################## 
     
    4949Options: -full, -regular_latlon, -debug, -dev, -prod(default) 
    5050 
    51 Example 1: Default compilation of DYNAMICO-LMDZ-ORCHIDEE with XIOS and IOIPSL 
    52 ./compile_icolmdzor.sh 
     51Example 1: Default compilation of LMDZ-ORCHIDEE with XIOS and IOIPSL 
     52./compile_lmdzor.sh 
    5353 
    5454Example 2: Compile in debug mode 
    55 ./compile_icolmdzor.sh -debug 
     55./compile_lmdzor.sh -debug 
    5656 
    5757Example 3: Default compilation with full recompilation of all components 
    58 ./compile_icolmdzor.sh -full 
    59  
    60 Example 4: Compilation of LMDZ in regular lat-lon for dimension 144x142x79.  
    61 The dimension can be changed to any other 3d dimension. DYNAMICO is also compiled as default. 
    62 ./compile_icolmdzor.sh -regular_latlon 144x142x79 
     58./compile_lmdzor.sh -full 
     59 
     60Example 4: Compilation of LMDZ in regular lat-lon for other dimensions (default: 144x142x79)  
     61The dimension can be changed to any other 3d dimension. 
     62./compile_lmdzor.sh -regular_latlon 96x95x79 
    6363 
    6464fin 
     
    154154echo >> $outfile ; echo " NOW COMPILE IOIPSL"   >> $outfile  
    155155 
     156# Check if compilation with fcm is included in IOIPSL 
     157if [ ! -f makeioipsl_fcm ] ; then 
     158  echo "The file makeiopsl_fcm do not exist. Probably this is not the right version of IOIPSL." 
     159  echo "Version of IOIPSL with fcm compilation is needed to compile with this script. Stop now." 
     160  exit 
     161fi 
     162 
    156163echo ./makeioipsl_fcm -$optmode -parallel -arch ${fcm_arch} -arch_path $arch_path -j 8 $full_flag   >> $outfile  
    157164     ./makeioipsl_fcm -$optmode -parallel -arch ${fcm_arch} -arch_path $arch_path -j 8 $full_flag   >> $outfile 2>&1 
     
    195202fi 
    196203 
    197 ## 2.4 Compile lmdz 
    198 cd $modipsl/modeles/LMDZ 
    199 # Compile LMDZ as library to couple to DYNAMICO 
    200 echo; echo "NOW COMPILE LMDZ FOR COUPLING TO DYNAMICO" 
    201 echo >> $outfile ; echo " NOW COMPILE LMDZ FOR COUPLING TO DYNAMICO"   >> $outfile  
    202  
    203 echo ./makelmdz_fcm -p lmd -rrtm true -cosp true -$optmode -mem -parallel $parallel -libphy -v orchidee2.1 -io xios -arch $fcm_arch -j 8 $full_flag    >> $outfile  
    204      ./makelmdz_fcm -p lmd -rrtm true -cosp true -$optmode -mem -parallel $parallel -libphy -v orchidee2.1 -io xios -arch $fcm_arch -j 8 $full_flag    >> $outfile 2>&1 
    205 # Test if compiling finished 
    206 if [[ $? != 0 ]] ; then 
    207     echo "THERE IS A PROBLEM IN LMDZ PHYSICS COMPILATION - STOP" 
    208     exit 
    209 fi 
    210  
    211  
    212 ## 2.5 Compile DYNAMICO 
    213 cd $modipsl/modeles/DYNAMICO 
    214 echo; echo "NOW COMPILE DYNAMICO " 
    215 echo >> $outfile ; echo " NOW COMPILE DYNAMICO"   >> $outfile  
    216  
    217 echo ./make_icosa -$optmode -parallel $parallel -external_ioipsl -with_xios -arch $fcm_arch -arch_path $arch_path -job 8 $full_flag    >> $outfile  
    218      ./make_icosa -$optmode -parallel $parallel -external_ioipsl -with_xios -arch $fcm_arch -arch_path $arch_path -job 8 $full_flag    >> $outfile 2>&1 
    219 # Test if compiling finished 
    220 if [[ $? != 0 ]] ; then 
    221     echo "THERE IS A PROBLEM IN DYNAMICO COMPILATION - STOP" 
    222     exit 
    223 fi 
    224  
    225 ## 2.6 Compile interface ICOSA_LMDZ 
    226 cd $modipsl/modeles/ICOSA_LMDZ 
    227 echo; echo "NOW COMPILE ICOSA_LMDZ " 
    228 echo >> $outfile ; echo " NOW COMPILE ICOSA_LMDZ"   >> $outfile  
    229  
    230 echo ./make_icosa_lmdz -nodeps -p lmd -$optmode -parallel $parallel -with_orchidee -arch ${fcm_arch} -arch_path ${arch_path} -job 8 $full_flag    >> $outfile  
    231      ./make_icosa_lmdz -nodeps -p lmd -$optmode -parallel $parallel -with_orchidee -arch ${fcm_arch} -arch_path ${arch_path} -job 8 $full_flag    >> $outfile 2>&1 
    232 # Test if compiling finished 
    233 if [[ $? != 0 ]] ; then 
    234     echo "THERE IS A PROBLEM IN ICOSA_LMDZ COMPILATION - STOP" 
    235     exit 
    236 fi 
    237 # Move executables to modipsl/bin 
    238 if [ $modipsl/modeles/ICOSA_LMDZ/bin/icosa_lmdz.exe ] ; then  
    239     mv $modipsl/modeles/ICOSA_LMDZ/bin/icosa_lmdz.exe $modipsl/bin/.  
    240 else 
    241     echo "THERE IS A PROBLEM IN ICOSA_LMDZ COMPILATION EXECUTABLE MISSING - STOP" 
    242     exit 
    243 fi 
    244  
    245  
    246  
    247 ## 2.7 Compile LMDZ for regular latlon configuration 
     204 
     205## 2.4 Compile LMDZ for regular latlon configuration 
    248206if [ $regular_latlon = yes ] ; then 
    249207 
Note: See TracChangeset for help on using the changeset viewer.