Skip to content

v4: Fix FMS Yaml detection, add color message and sync data

Choose a tag to compare

@mathomp4 mathomp4 released this 17 Jun 16:16
bfea7ae

This release of ESMA_cmake has some useful updates:

1. Build-Time S3 Data Sync (esma_sync_data)

  • Added esma_sync_data() and helper script to run S3 synchronization tasks at build time instead of configure time.

2. Colored Console Logs (color_message)

  • Added a new color_message() utility supporting common terminal colors (RED, GREEN, YELLOW, ORANGE, etc.).
  • Simplified F2PY compiler mismatch warning outputs to a once-only, highly visible orange status message.

3. Automatic FMS YAML Probe

  • Added compiler probe (check_fms_yaml_support.cmake / test_fms_yaml.f90) to dynamically check if the FMS library was built with YAML support. Automatically finds and links libyaml if supported, deprecating the legacy Findlibyaml.cmake module.

From CHANGELOG.md

Added

  • Added new esma_color_message.cmake which adds a color_message function
  • Added check_fms_yaml_support macro (external_libraries/check_fms_yaml_support.cmake + external_libraries/test_fms_yaml.f90) to autodetect whether FMS was built with YAML support via a try_compile probe, replacing the manual FMS_BUILT_WITH_YAML option. Note: once we move to FMS 2026.01 (NOAA-GFDL/FMS#1822), FMS will export libyaml as a proper find_dependency and this probe (along with Findlibyaml.cmake) can be removed.
  • Added esma_sync_data() CMake macro and build-time helper script to support build-time synchronization of data from AWS S3 buckets using temporary AWS credentials.

Changed

  • Update FindF2PY.cmake and FindF2PY3.cmake to use color_message instead of a message(WARNING) (as with Spack we would always trigger the warning)
  • Suppress duplicate f2py/Python executable mismatch warnings when find_package is called multiple times in the same configure run, using a global-property once-only guard.

What's Changed

  • v4: Add esma_sync_data CMake macro and script by @mathomp4 in #549
  • v4: Add color_message function and autodetect FMS YAML support by @mathomp4 in #548

Full Changelog: v4.39.0...v4.40.0