Skip to content

Make parallel-netcdf an optional dependency, only compiled if MPAS is used #1613

@climbfuji

Description

@climbfuji

Is your feature request related to a problem? Please describe.

parallel-netcdf isn't needed unless the MPAS model is used. The interfaces to parallel-netcdf are already turned off in esmf and netcdf-c. But the default setting for parallelio is to enable the interface.

This package is causing increasing headaches, especially with the latest update to spack develop (#1607) on Cray systems. Also, it is one of the few packages that simply don't build if your shell isn't bash but ksh (yes, that case still exists).

1 error found in build log:
     19    checking for gawk... (cached) gawk
     20    checking for grep that handles long lines and -e... /usr/bin/grep
     21    checking for egrep... /usr/bin/grep -E
     22    checking for a sed that does not truncate output... /usr/bin/sed
     23    checking for sed handling option -i ... /usr/bin/sed -i''
     24    checking cc under /opt/cray/pe/mpich/8.1.26/ofi/intel/2022.1/bin... no
  >> 25    configure: error:
     26       -----------------------------------------------------------------------
     27         Specified MPI C compiler "cc" cannot be found under /opt/cray/pe/mpich/8.1.26/ofi/intel/2022.1
     28         PnetCDF requires a working MPI C compiler. Please specify the location
     29         of an MPI C compiler, either in the MPICC environment variable
     30         (not CC variable) or through --with-mpi configure flag. Abort.
     31       -----------------------------------------------------------------------

See build log for details:
  /p/work2/heinzell/spst-upd-spdev-20250415/cache/build_stage/spack-stage-parallel-netcdf-1.12.3-3issk2b4kp462j7u636t6vf774kppd5s/spack-build-out.txt

Describe the solution you'd like

  1. Fix parallel-netcdf so that it still builds on Cray (because it is used by MPAS and mpas-jedi-env).
  2. In parallel, prefer parallelio ~pnetcdf and enable the variant explicitly in mpas-jedi-env and others. I believe ufs-weather-model-env also wants this as the UFS is moving to MPAS in parts and won't have all the I/O capabilities in the native UFS IO layer (they may still be using the MPAS parallelio/parallel-netcdf I/O features for now)

Additional context

n/a

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions