Skip to content

Commit

Permalink
Add COSIMA_VERSION pre-processor flag for including version hash in b…
Browse files Browse the repository at this point in the history
…uild
  • Loading branch information
aidanheerdegen committed Aug 4, 2023
1 parent 66ef4a3 commit 4d88f8b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions exp/MOM_compile.csh
Expand Up @@ -151,6 +151,7 @@ if ( $cosima_version ) then
echo "Including COSIMA version in build"
# Build version. This prevents builds outside a git repo, so only enabled for COSIMA builds
source ./version_compile.csh
set cppDefs = "$cppDefs -DCOSIMA_VERSION"
endif

# Build FMS.
Expand Down
4 changes: 3 additions & 1 deletion src/mom5/ocean_core/ocean_model.F90
Expand Up @@ -334,7 +334,9 @@ module ocean_model_mod
use ocean_drifters_mod, only: ocean_drifters_init, update_ocean_drifters, ocean_drifters_end
use wave_types_mod, only: ocean_wave_type
use ocean_wave_mod, only: ocean_wave_init, ocean_wave_end, ocean_wave_model
use version_mod, only: MOM_COMMIT_HASH
#if defined(COSIMA_VERSION)
use version_mod, only: MOM_COMMIT_HASH
#endif

#if defined(ACCESS_CM) || defined(ACCESS_OM)
use auscom_ice_mod, only: auscom_ice_init
Expand Down

0 comments on commit 4d88f8b

Please sign in to comment.