[Mitgcm-support] New search order for source code

mitgcm-support at dev.mitgcm.org mitgcm-support at dev.mitgcm.org
Wed Jul 9 15:36:31 EDT 2003


I'm changing the search order for finding source code.

'Til now (c36) genmake searches
  -mods=dir,..., eesupp, model, diags, pkg/*
in that order to selects the first occurance of a file.

It now searches in this order
  -mods=dir1,..., pkg/*, model, eesupp, diags

This is so that we can add replacement or optionally replacement
code via packages for code in model/eesupp/diag as well as via -mods.

e.g. I'm creating a package "pkg/mom_fluxform" which has a
copy of calc_mom_rhs.F in it.  The pkg is disabled by default and
uses "model/src/calc_mom_rhs.F".  When enabled (-enable=mom_fluxform)
it then uses "pkg/mom_fluxform/calc_mom_rhs.F" and disregards the
original in "model/src".

I'm doing this for the convenience of adding code that we intend
to be mainstream in the future but need to make available as an
option in the interim for more than one experiment.

e.g. I originally tested the mom_fluxform routines by putting them
in the "./code" directory of exp2 but now want to test them in all
the other experiments.

Alternatively, the current genmake could have done the same
simply by using "-mods=../../../pkg/mom_fluxform" but I think
the "-enable" option is clearer.

Any objections?



More information about the MITgcm-support mailing list