the majority of information on how to use FCM make to build NEMO executables can be found http://www.nemo-ocean.eu/Using-NEMO/User-Guides/Basics/NEMO-Quick-Start-Guide/Building-NEMO-executables-using-FCM-make, this page includes some additional informations for developers

Combining multiple branches on extract

If required is easy to use fcm make to combine multiple branches, list the base (usually the trunk) and a number of branches in the fcm-make.cfg file such as;

# Specify the location of the branch or your working copy
$nemo_location = fcm:nemo-br/dev/frdm/r9493_fcm-make
#$nemo_location = ~/my/working/directory
# Specify which set of CPP keys you want to use
# Choose from: amm12 gyre gyre_pisces orca2_lim orca2_lim_cfc
#              orca2_lim_pisces orca2_off_pisces orca2_sam_lim
$nemo_config = orca2_lim

include = $nemo_location/NEMOGCM/fcm-make/pwr7-xlf-meto.cfg

extract.location[nemo]  = fcm:nemo-tr@9519

extract.location{diff}[nemo] = \
       branches/dev/frsy/vn3.5_beta_BDY_bug_fixes@9519 \
       branches/dev/hadcv/vn3.5_beta_c1d_fixes@9519 \
       branches/dev/hadcv/vn3.5_beta_kara_mld@9519

However for this to work all branches much be branched from the same revision of the trunk as is used for the base.

Make configuration notes

  • Various source files from NEMO/LIM_SRC_2 & TOOLS/OBSTOOLS/src and also the entire TOOLS/REBUILD directory are excluded from the extract step. This is because they are all symbolic links or contain symbolic links. If these are not excluded FCM works fine (the extract step will just skip symbolic links) but gives lots of warnings. If fcm make is adopted it should be possible to remove all these symbolic links from the source tree in the future.
  • Various source files from EXTERNAL/IOIPSL/tools are excluded from the extract step since they are not used (and the pre-processing step is not configured to handle them).
  • NEMO/OPA_SRC/TRD/trdmod_trc.F90 is excluded from the extract step because it is a dummy version of NEMOGCM/NEMO/TOP_SRC/TRP/trdmod_trc.F90 and results in a duplicate target if this module is required.
  • TOOLS/WEIGHTS/SCRIP1.4 & TOOLS/WEIGHTS/nocsutil are excluded from the extract step since they are not used (and they result in duplicate targets if left in).
  • As noted above, the make configuration is set up to build all the executables in a single make. If this is not not considered useful then separate config files could be set up for each executable, or maybe one to build all the tools and one to build the main NEMO executable?
  • Currently the build is split into 2 steps because there are a number of cases where slightly different versions of the same program unit are used in different executables. If this could be avoided (perhaps by using runtime switches or optional arguments to handle any required differences in behaviour) then a single build step could be used which would simplify the configuration considerably and also speed up the make (the 2 build steps are run serially). The problem files are as follows:
    • domain.mod: NEMO/OPA_SRC/DOM/domain.F90 & TOOLS/GRIDGEN/src/domain.f90
    • par_oce.mod: NEMO/OPA_SRC/par_oce.F90 & TOOLS/OBSTOOLS/src/par_oce.F90
    • io_netcdf.mod: TOOLS/GRIDGEN/src/io_netcdf.f90 & TOOLS/NESTING/src/io_netcdf.f90
    • in_out_manager.mod: NEMO/OPA_SRC/IOM/in_out_manager.F90 & TOOLS/OBSTOOLS/src/in_out_manager.F90
Last modified 7 years ago Last modified on 2014-01-14T18:07:36+01:00