This PR will track changes needed for using ESMA_cmake with codes that don't need MPI, netCDF, ESMF, etc.
This was spurred by the work of @amdasilva with AeroML which is (for the moment) pure Python/C/Fortran. No need for external libraries.
Note that I'll definitely be pinging @rmontuoro of UFS and @lizziel and @LiamBindle of Harvard as I work on this. I think they are actually good to go as they have shown @tclune and myself the right path forward.
Indeed, part of this PR is undoing some things I did for Spack work because, well, I was trying to be cute and clean. But sometimes CMake is ugly for good reasons!
ETA: Issues to consider:
What if you build an ESMF_COMM=mpiuni version of Baselibs. This is obviously not going to work with GEOS/MAPL, but it is a valid Baselibs that could be useful for other projects. So MPI should be QUIET
You could build a Baselibs without ESMF and just netCDF and this will currently fail as it assumes all Baselibs will have ESMF. This might not be true. → We need to put each lib in Baselibs in its own little detection area.
Note that what is here is very alpha. I need to test with GEOSgcm, MAPL, etc. to make sure it's all good and that I don't royally hork up things for external users.
This PR will track changes needed for using ESMA_cmake with codes that don't need MPI, netCDF, ESMF, etc.
This was spurred by the work of @amdasilva with AeroML which is (for the moment) pure Python/C/Fortran. No need for external libraries.
Note that I'll definitely be pinging @rmontuoro of UFS and @lizziel and @LiamBindle of Harvard as I work on this. I think they are actually good to go as they have shown @tclune and myself the right path forward.
Indeed, part of this PR is undoing some things I did for Spack work because, well, I was trying to be cute and clean. But sometimes CMake is ugly for good reasons!
ETA: Issues to consider:
ESMF_COMM=mpiuni
version of Baselibs. This is obviously not going to work with GEOS/MAPL, but it is a valid Baselibs that could be useful for other projects. So MPI should be QUIET