packages:
  all:
    providers:
      mpi: [openmpi, intel-oneapi-mpi]
      jpeg: [libjpeg]
    require:
      - spec: ^intel-oneapi-mpi
        when: '%oneapi ^mpi'

      - spec: ^openmpi
        when: '%gcc ^mpi'

  # System dependencies  # ----------------------------------------------------------------------------
  rdma-core:
    buildable: false
    externals:
    - spec: rdma-core@44.1
      prefix: /usr

  slurm:
    buildable: false
    externals:
    - spec: slurm@23-11-0-1
      prefix: /usr

  pmix:
    buildable: false
    externals:
    - spec: pmix@5.0.1
      prefix: /usr


  # ----------------------------------------------------------------------------
  # Requirements
  # ----------------------------------------------------------------------------
  cmake:
    require:
    - spec: +ownlibs

  cuda:
    require:
    - spec: '@12.4.0'

  hdf5:
    variants: +hl +threadsafe +szip +cxx +fortran

  openmpi:
    require:
    - spec: fabrics=ofi,ucx,verbs schedulers=slurm ~rsh +romio romio-filesystem=gpfs
    - spec: ^ucx +cuda
      when: +cuda

  ucx:
    require:
    - spec: +rdmacm +rc +dc +ud +cma +verbs
    - spec: +gdrcopy
      when: +cuda

  libfabric:
    require:
    - spec: fabris=mlx,mrail,psm2,psm3,verbs,udp,tcp,sockets,shm
