Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build ElmerIce with netCDF in CI on Ubuntu #589

Merged
merged 4 commits into from
Oct 17, 2024
Merged

Conversation

mmuetzel
Copy link
Contributor

@mmuetzel mmuetzel commented Oct 2, 2024

No description provided.

@mmuetzel
Copy link
Contributor Author

mmuetzel commented Oct 7, 2024

The issue with the CMake config file that is installed by netCDF for Fortran is already fixed upstream:
Unidata/netcdf-fortran#428

Until that change is included in a released version and that version finds its way into the packages that are distributed, it is probably be best to keep using the FindNETCDF.cmake module that is part of the ElmerFEM sources.

When these newer versions of netCDF for Fortran are starting to appear, it should be easy to adapt the FindNETCDF.cmake module to pick the fixed config file up if available.

ElmerIce requires MPI. So, install netCDF only for the jobs that build
with MPI.
Newer versions of netCDF install a CMake config file.
But the CMake config file of netCDF for Fortran cannot be used currently.
Make sure to use the CMake find module bundled with Elmer to detect
netCDF and netCDF for Fortran.
The netCDF Fortran library depends on the netCDF library. For some
linkers (e.g., ld.bfd), the linking order matters.
Make sure to have the netCDF Fortran library *before* the netCDF library
in the linker flags.
@raback raback merged commit 479e766 into ElmerCSC:devel Oct 17, 2024
6 of 10 checks passed
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.

2 participants