diff options
author | kwryankrattiger <80296582+kwryankrattiger@users.noreply.github.com> | 2022-08-20 08:45:03 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-20 15:45:03 +0200 |
commit | fff929d5ab08fc21a3fbe795c10e255f993aa39e (patch) | |
tree | 0e3d654c8a8a6354549861a60e3f82b97fa19166 | |
parent | 51619fdb00bd23400dba70635e7a9a8d5b9257b0 (diff) | |
download | spack-fff929d5ab08fc21a3fbe795c10e255f993aa39e.tar.gz spack-fff929d5ab08fc21a3fbe795c10e255f993aa39e.tar.bz2 spack-fff929d5ab08fc21a3fbe795c10e255f993aa39e.tar.xz spack-fff929d5ab08fc21a3fbe795c10e255f993aa39e.zip |
WarpX: Add hints for FindMPI (#31842)
This seems to be needed on some cray systems and is safe on normal
desktops.
-rw-r--r-- | var/spack/repos/builtin/packages/warpx/package.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/warpx/package.py b/var/spack/repos/builtin/packages/warpx/package.py index 933093f60c..f4b8c66c35 100644 --- a/var/spack/repos/builtin/packages/warpx/package.py +++ b/var/spack/repos/builtin/packages/warpx/package.py @@ -189,13 +189,18 @@ class Warpx(CMakePackage): self.define_from_variant("WarpX_QED_TABLE_GEN", "qedtablegen"), ] - with when("+openpmd"): + # FindMPI needs an extra hint sometimes, particularly on cray systems + if "+mpi" in spec: + args.append(self.define("MPI_C_COMPILER", spec["mpi"].mpicc)) + args.append(self.define("MPI_CXX_COMPILER", spec["mpi"].mpicxx)) + + if "+openpmd" in spec: args.append("-DWarpX_openpmd_internal=OFF") # Work-around for SENSEI 4.0: wrong install location for CMake config # https://github.com/SENSEI-insitu/SENSEI/issues/79 if "+sensei" in spec: - args.append(self.define("SENSEI_DIR", join_path(spec["sensei"].prefix.lib, "cmake"))) + args.append(self.define("SENSEI_DIR", spec["sensei"].prefix.lib.cmake)) return args |