Due to the current gap in continued funding from the U.S. National Science Foundation (NSF), the NSF Unidata Program Center has temporarily paused most operations. See NSF Unidata Pause in Most Operations for details.

Re: [netcdfgroup] netcdf-mpi build

Jim,

In the PISM build system (which also uses CMake) I check for the
presence of netcdf_par.h:

  # Try to find netcdf_par.h. We assume that NetCDF was compiled with
  # parallel I/O if this header is present.
  find_file(NETCDF_PAR_H netcdf_par.h HINTS ${NETCDF_INCLUDES} NO_DEFAULT_PATH)

  if (NOT NETCDF_PAR_H)
    set (Pism_USE_PARALLEL_NETCDF4 OFF CACHE BOOL "Enables parallel
NetCDF-4 I/O." FORCE)
    message(STATUS "Selected NetCDF library does not support parallel I/O.")
  endif()

I don't know how reliable this is and would love to hear from NetCDF
developers, but it works so far. (Should work in a cross-compiling
setup, too, as far as I can tell.)

-- 
Constantine

On Wed, Jan 15, 2014 at 2:13 PM, Jim Edwards <jedwards@xxxxxxxx> wrote:
> Hi,
>
> I'm trying to figure out with cmake whether netcdf was built with hdf5 mpi
> parallel IO support, I can compile a test program but I cannot expect it to
> run as many of the systems I run on use cross compiling.
>
> Variables like NC_MPIIO and NC_COLLECTIVE  appear to be defined even if this
> mode is not available as is the function nc_var_par_access.
>
> On some systems I can try linking without mpi and look for the link errors,
> but the compiler wrappers on other systems (eg cray) don't make it easy to
> compile without mpi.
>
> Any suggestions?
>
>
> --
> Jim Edwards
>
> CESM Software Engineering Group
> National Center for Atmospheric Research
> Boulder, CO
> 303-497-1842
>
> _______________________________________________
> netcdfgroup mailing list
> netcdfgroup@xxxxxxxxxxxxxxxx
> For list information or to unsubscribe,  visit:
> http://www.unidata.ucar.edu/mailing_lists/



  • 2014 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the netcdfgroup archives: