MPAS-Dev / MPAS-Model

Repository for MPAS models and shared framework releases.
238 stars 317 forks source link

Fix MPAS-A dycore-only build in version 8.2.0 #1221

Closed kuanchihwang closed 1 month ago

kuanchihwang commented 1 month ago

When building MPAS-A as a dycore, all physics-related components are disabled. An example scenario of this is for use with CAM/CAM-SIMA.

However, the MPAS-A registry file in version 8.2.0 contains the following regressions, which cause the dycore-only build to break:

This PR fixes MPAS-A dycore-only build by guarding the above regions with the DO_PHYSICS macro.

For stand-alone MPAS-A, this PR is an NFC (No Functional Change).

gdicker1 commented 1 month ago

I've confirmed that CAM using MPAS v8.2.0[^1] fail to build and give the message

ERROR: Dimension on variable acc_etrani in var_struct diag_physics_noahmp not defined.

After merging these changes, builds can now succeed!

[^1]: requires some code updates that I'll make a PR for in ESCOMP/CAM