packages:
  all:
    providers:
      mpi: [openmpi, intel-oneapi-mpi]
      jpeg: [libjpeg]

    require:
    - spec: cuda_arch=70
      when: +cuda target=cascadelake

    - spec: cuda_arch=90
      when: +cuda target=icelake
    - spec: cuda_arch=90
      when: +cuda target=cannonlake

  # 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'

  # cuda:
  #   variants: "+allow-unsupported-compilers"

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

  libfabric:
    require:
    - spec: fabrics=mlx,tcp,udp,verbs,sockets,shm

  intel-oneapi-mpi:
    require:
    - any_of: ['%oneapi', '%intel']

  openmpi:
    require:
    - any_of: ['%gcc']
    - spec: fabrics=ofi,ucx,verbs schedulers=slurm ~rsh +gpfs
    - spec: cuda_arch=70 ^ucx +cuda
      when: +cuda

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

  binutils:
    externals:
    - spec: binutils@2.35.2
      prefix: /usr
  coreutils:
    externals:
    - spec: coreutils@8.32
      prefix: /usr
  findutils:
    externals:
    - spec: findutils@4.8.0
      prefix: /usr
  gawk:
    externals:
    - spec: gawk@5.1.0
      prefix: /usr
  openssh:
    externals:
    - spec: openssh@8.7p1
      prefix: /usr
  openssl:
    externals:
    - spec: openssl@3.0.7
      prefix: /usr
  tar:
    externals:
    - spec: tar@1.34
      prefix: /usr
  curl:
    externals:
    - spec: curl@7.76.1+gssapi+nghttp2
      prefix: /usr
  git:
    externals:
    - spec: git@2.39.3~tcltk
      prefix: /usr
  gmake:
    externals:
    - spec: gmake@4.3
      prefix: /usr
  groff:
    externals:
    - spec: groff@1.22.4
      prefix: /usr
  pkgconf:
    externals:
    - spec: pkgconf@1.7.3
      prefix: /usr
  subversion:
    externals:
    - spec: subversion@1.14.1
      prefix: /usr
