Skip to content

Conversation

@marshallward
Copy link
Member

This patch significantly modifies the Autoconf-based builds to separate external content in pkg/ from the main MOM6 source code.

These changes are meant to address the challenges with analysis of source code which is outside of our control. Such content is now built separately, isolating it from the usual MOM6 code requirements.

A secondary benefit is that a submodule checkout is no longer required for ocean-only builds.

The patch includes the following specific changes.

  • Builds relying on ac/deps/ now build libraries for GibbsSeaWater (libgsw.a) and CVMix (libcvmix.a) alongside libFMS.a. This replaces any content placed externally into pkg/.

  • A new macro, MOM6_FC_CHECK_LIB, improves library detection tests by including support for both subroutines and functions, as well as generic argument lists.

    It still relies on implicit typing, so only reals and integers are supported. We can hopefully fix this in the future.

  • Makefiles across the build system (ac/deps/, .testing/, etc.) have been updated to generate and use the new libraries.

These changes are not intended to break existing builds, as summarized below.

  • src/parameters/CVMix/ and TEOS10/ are explicitly excluded from the makedep source trees, but the symbolic links to pkg/ are retained, and existing builds which assume their presence should still work.

  • The legacy AX_FC_CHECK_LIB macro has been retained, so that it remains available to any external MOM6-examples builds.

  • The git submodules have not been removed, although the GitHub Actions no longer uses then in testing.

The patch also includes the following related minor modifications.

  • The GitHub Actions FMS build stages now includes GSW and CVMix

  • .gitignore files are modified to target files produced by the build system, rather than globbing of various incidental files.

  • A non-POSIX shell operation == in configure.ac has been replaced.

This patch significantly modifies the Autoconf-based builds to separate
external content in `pkg/` from the main MOM6 source code.

These changes are meant to address the challenges with analysis of
source code which is outside of our control.  Such content is now built
separately, isolating it from the usual MOM6 code requirements.

A secondary benefit is that a submodule checkout is no longer required
for ocean-only builds.

The patch includes the following specific changes.

* Builds relying on `ac/deps/` now build libraries for GibbsSeaWater
  (`libgsw.a`) and CVMix (`libcvmix.a`) alongside `libFMS.a`.  This
  replaces any content placed externally into `pkg/`.

* A new macro, `MOM6_FC_CHECK_LIB`, improves library detection tests by
  including support for both subroutines and functions, as well as
  generic argument lists.

  It still relies on implicit typing, so only reals and integers are
  supported.  We can hopefully fix this in the future.

* Makefiles across the build system (`ac/deps/`, `.testing/`, etc.) have
  been updated to generate and use the new libraries.

These changes are not intended to break existing builds, as summarized
below.

* `src/parameters/CVMix/` and `TEOS10/` are explicitly excluded from the
  makedep source trees, but the symbolic links to `pkg/` are retained,
  and existing builds which assume their presence should still work.

* The legacy `AX_FC_CHECK_LIB` macro has been retained, so that it
  remains available to any external MOM6-examples builds.

* The git submodules have not been removed, although the GitHub Actions
  no longer uses then in testing.

The patch also includes the following related minor modifications.

* The GitHub Actions FMS build stages now includes GSW and CVMix

* `.gitignore` files are modified to target files produced by the build
  system, rather than globbing of various incidental files.

* A non-POSIX shell operation `==` in `configure.ac` has been replaced.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant