From 7fff33a13e279ef86e8daa4db789db00f44d6f27 Mon Sep 17 00:00:00 2001 From: Matthias Krack Date: Fri, 27 Sep 2024 10:33:42 +0200 Subject: [PATCH] Add check for OpenMPI 5 (fix for #3700) --- tools/toolchain/install_cp2k_toolchain.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tools/toolchain/install_cp2k_toolchain.sh b/tools/toolchain/install_cp2k_toolchain.sh index c88c78b01f..e76808d86f 100755 --- a/tools/toolchain/install_cp2k_toolchain.sh +++ b/tools/toolchain/install_cp2k_toolchain.sh @@ -331,7 +331,11 @@ if (command -v mpiexec > /dev/null 2>&1); then export MPI_MODE="mpich" with_mpich="__SYSTEM__" elif (mpiexec --version 2>&1 | grep -s -q "OpenRTE"); then - echo "MPI is detected and it appears to be OpenMPI" + echo "MPI is detected and it appears to be OpenMPI 4 (or older)" + export MPI_MODE="openmpi" + with_openmpi="__SYSTEM__" + elif (mpiexec --version 2>&1 | grep -s -q "Open MPI"); then + echo "MPI is detected and it appears to be OpenMPI 5" export MPI_MODE="openmpi" with_openmpi="__SYSTEM__" elif (mpiexec --version 2>&1 | grep -s -q "Intel"); then