From 494ba677049382e133340aefe4fe6ffb13d79d64 Mon Sep 17 00:00:00 2001 From: Simon Pintarelli <1237199+simonpintarelli@users.noreply.github.com> Date: Fri, 29 Oct 2021 20:31:56 +0200 Subject: [PATCH] sirius: add mpi datatypes patch for recent cray mpich (#27065) --- .../packages/sirius/mpi_datatypes.patch | 22 +++++++++++++++++++ .../repos/builtin/packages/sirius/package.py | 1 + 2 files changed, 23 insertions(+) create mode 100644 var/spack/repos/builtin/packages/sirius/mpi_datatypes.patch diff --git a/var/spack/repos/builtin/packages/sirius/mpi_datatypes.patch b/var/spack/repos/builtin/packages/sirius/mpi_datatypes.patch new file mode 100644 index 0000000000..47ddeeec24 --- /dev/null +++ b/var/spack/repos/builtin/packages/sirius/mpi_datatypes.patch @@ -0,0 +1,22 @@ +diff --git a/src/mpi/communicator.hpp b/src/mpi/communicator.hpp +index 709e56cfc..a05375bda 100644 +--- a/src/mpi/communicator.hpp ++++ b/src/mpi/communicator.hpp +@@ -111,7 +111,7 @@ struct mpi_type_wrapper> + { + static MPI_Datatype kind() + { +- return MPI_CXX_DOUBLE_COMPLEX; ++ return MPI_C_DOUBLE_COMPLEX; + } + }; + +@@ -174,7 +174,7 @@ struct mpi_type_wrapper + { + static MPI_Datatype kind() + { +- return MPI_CXX_BOOL; ++ return MPI_C_BOOL; + } + }; + diff --git a/var/spack/repos/builtin/packages/sirius/package.py b/var/spack/repos/builtin/packages/sirius/package.py index e53fec9aae..7574b01048 100644 --- a/var/spack/repos/builtin/packages/sirius/package.py +++ b/var/spack/repos/builtin/packages/sirius/package.py @@ -147,6 +147,7 @@ class Sirius(CMakePackage, CudaPackage): patch("strip-spglib-include-subfolder.patch", when='@6.1.5') patch("link-libraries-fortran.patch", when='@6.1.5') patch("cmake-fix-shared-library-installation.patch", when='@6.1.5') + patch("mpi_datatypes.patch", when="@:7.2.6") @property def libs(self):