New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
user/techene/TP_NEMO (diff) – NEMO

Changes between Version 1 and Version 2 of user/techene/TP_NEMO


Ignore:
Timestamp:
2021-01-21T17:34:08+01:00 (3 years ago)
Author:
techene
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • user/techene/TP_NEMO

    v1 v2  
    1 == Ensure proper lib are at proper places  == 
    21 
     2 
     3== Make sure proper libs are at proper places  == 
     4 
     5'''File tree ''' [[BR]] 
     6 
     7Note that in the provided environment XIOS and softwares from INSTALL should be already compiled.  
    38{{{ 
    4 - NEMO 
    5 - XIOS 
    6 - INSTALL 
     9HOME 
     10  |-- XIOS 
     11  |-- INSTALL 
     12  |-- NEMO 
     13        |-- arch 
     14             |-- arch-MY_ENV.fcm 
     15             |-- arch-linux_gfortran.fcm 
     16             |-- ... 
     17        |-- tests 
     18             |-- CANAL 
     19             |-- ... 
     20        |-- cfgs 
     21             |-- ORCA2_ICE_PISCES 
     22             |-- ... 
    723}}} 
    824 
    9 == Get the code  == 
     25'''arch-MY_ENV.fcm ''' [[BR]] 
     26 
     27In arch-MY_ENV.fcm you must specify where is what, you must also specify compilers and compilers option :  
     28{{{ 
     29%NCDF_HOME           $HOME/INSTALL 
     30%HDF5_HOME           $HOME/INSTALL 
     31%XIOS_HOME           $HOME/XIOS 
     32... 
     33%CPP                 cpp -Dkey_nosignedzero 
     34%FC                  /usr/bin/mpif90 -c -cpp 
     35%FCFLAGS             -fdefault-real-8 -O3 -funroll-all-loops -fcray-pointer -ffree-line-length-none 
     36%FFLAGS              %FCFLAGS 
     37%LD                  /usr/bin/mpif90 -Wl,-rpath=$HOME/INSTALL/lib:/usr/lib 
     38... 
     39}}} 
     40 
     41 
     42== Get NEMO code for users == 
    1043 
    1144{{{#!sh 
     45# root 
     46cd HOME 
    1247# my login 
    13 me=smasson 
    14 # svn path to NEMO trunk 
    15 svnpath=svn+ssh://${me}@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/NEMO/trunk 
    16 # get the revision number of the HEAD 
    17 rev=$( svn info $svnpath | grep "Last Changed Rev" | sed -e "s/.*: *//" ) 
    18 # directory name given to the local trunk 
    19 dirnemo=trunk_test_perf_${rev} 
    20 # checkout the trunk into $dirnemo 
    21 svn co $svnpath $dirnemo 
    22 # 
    23 cd $dirnemo 
    24 # 
     48me=techene 
     49# get last trunk revision  
     50svn co forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/NEMO/release/r4.0/r4.0.5 NEMO 
     51# let's go ! 
     52cd NEMO 
    2553}}} 
     54 
     55== Get NEMO code for developers == 
     56 
     57{{{#!sh 
     58# root 
     59cd HOME 
     60# my login 
     61me=techene 
     62# get last trunk revision  
     63svn co svn+ssh://${ME}@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/NEMO/trunk NEMO 
     64# let's go ! 
     65cd NEMO 
     66}}} 
     67 
     68== Compile NEMO  == 
     69generic example : ./makenemo -n MY_CONFIG -j 6 -m MY_ENV 
     70- Replace -n MY_CONFIG by names you find in NEMO/tests prefixed with -a or NEMO/cfgs prefixed with -r. 
     71- Replace MY_ENV by linux_gfortran or by any name you chose when you created your arch file. 
     72{{{ 
     73# Let's go ! 
     74cd NEMO 
     75# generic example : ./makenemo -n MY_CONFIG -j 6 -m MY_ENV  
     76./makenemo -h 
     77# compile ORCA2 configuration in the preset environment 
     78./makenemo -r ORCA2_ICE_PISCES -j 6 -m linux_gfortran 
     79# compile CANAL configuration in the preset environment 
     80./makenemo -a CANAL -j 6 -m linux_gfortran 
     81}}}