Changeset 381 for XIOS/trunk/make_xios


Ignore:
Timestamp:
10/23/12 09:00:43 (12 years ago)
Author:
ymipsl
Message:

add choice of using sequential or parallel netcdf4 library

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/make_xios

    r377 r381  
    55use_oasis="false" 
    66job="1" 
     7netcdf_lib="netcdf4_par" 
     8compil_mode="prod" 
    79 
    810# Traitement de la ligne de commande 
     
    1416            echo "make_xios [options]" 
    1517            echo "options :" 
    16             echo "       [--prod] : compilation in production mode" 
     18            echo "       [--prod] : compilation in production mode (default)" 
    1719            echo "       [--dev] : compilation in development mode" 
    1820            echo "       [--debug] : compilation in debug mode" 
     
    2325            echo "       [--doc] : to generate Doxygen documentation (not available yet)" 
    2426            echo "       [--job ntasks] : to use parallel compilation with ntasks" 
     27            echo "       [--netcdf_lib 'netcdf4_par'/'netcdf4_seq' : default netcdf4_par] : choice of netcdf library" 
    2528            echo "Example : ./make_xios --prod --arch PW6_VARGAS" 
    2629            echo "Example : ./make_xios --avail" 
     
    3033         "--debug") compil_mode="debug" ; shift ;; 
    3134         "--arch")  arch=$2     ; shift ; shift ;; 
    32          "--avail") ls arch/*.fcm | cut -d"-" -f2 | cut -d"." -f1 ; exit ;;  
     35         "--") ls arch/*.fcm | cut -d"-" -f2 | cut -d"." -f1 ; exit ;;  
    3336         "--full")  compil_full="true"  ; shift ;; 
    3437         "--use_oasis")  use_oasis="true"  ; shift  ;; 
    3538         "--doc")   doc="true"          ; shift ;; 
    3639         "--job")   job=$2              ; shift ; shift ;; 
     40         "--netcdf_lib")   netcdf_lib=$2 ; shift ; shift ;; 
    3741         *)         code="$1"           ; shift ;; 
    3842      esac 
     
    8084      source $install_dir/arch.path 
    8185  else 
    82       echo "Veuillez definir une architecture cible !" 
     86      echo "Please choose a target achitecture --> list all available architecture using make_xios --avail!" 
    8387      exit 1 
    8488fi 
     
    98102      COMPIL_CFLAGS="%DEBUG_CFLAGS" 
    99103      COMPIL_FFLAGS="%DEBUG_FFLAGS" 
    100 else  
    101    echo "Veuillez definir un mode de compilation [debug|dev|prod] !" 
    102    exit 1 
     104fi 
     105 
     106if [[ "$netcdf_lib" == "netcdf4_par" ]] 
     107   then 
     108      XMLIO_CPPKEY="$XMLIO_CPPKEY USING_NETCDF_PAR" 
     109elif [[ "$netcdf_lib" == "netcdf4_seq" ]] 
     110  then  
     111    set nothing   
     112else 
     113   echo "Bad choice for --netcdf_lib argument : choose between 'netcdf4_par' or 'netcdf4_seq'" 
     114   exit 
    103115fi 
    104116 
     
    124136echo "%ARCH_LD       $XMLIO_LIB" >> config.fcm  
    125137 
    126 echo "=> Activation du mode "$compil_mode" pour la distribution sous l'architecture \""$arch"\" !" 
     138echo "=> Using "$compil_mode" mode for compiling under architecture \""$arch"\" !" 
    127139 
    128140# Création de la documentation doxygen. 
    129141if [[ !(-z $doc) ]] 
    130142   then 
    131       echo -e "- Création de la documentation de code doxygen (désactivée)..." 
     143      echo -e "- Create Doxygen documentation (disabled)..." 
    132144      #doxygen -s 
    133145fi 
Note: See TracChangeset for help on using the changeset viewer.