diff options
author | afzpatel <122491982+afzpatel@users.noreply.github.com> | 2024-10-07 23:48:50 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-10-08 05:48:50 +0200 |
commit | 95b46dca3d73c77c13502a6360e552a65daba95a (patch) | |
tree | 4770e638eab7fdd11f68547a67c3f44d335bba6d | |
parent | 7f6ae2a51e7a75bfa56d17bb0a634e209753d89c (diff) | |
download | spack-95b46dca3d73c77c13502a6360e552a65daba95a.tar.gz spack-95b46dca3d73c77c13502a6360e552a65daba95a.tar.bz2 spack-95b46dca3d73c77c13502a6360e552a65daba95a.tar.xz spack-95b46dca3d73c77c13502a6360e552a65daba95a.zip |
kokkos: modify standlone test to run with +rocm (#46779)
-rw-r--r-- | var/spack/repos/builtin/packages/kokkos/package.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/kokkos/package.py b/var/spack/repos/builtin/packages/kokkos/package.py index ed95535469..7944a9d403 100644 --- a/var/spack/repos/builtin/packages/kokkos/package.py +++ b/var/spack/repos/builtin/packages/kokkos/package.py @@ -416,8 +416,12 @@ class Kokkos(CMakePackage, CudaPackage, ROCmPackage): raise SkipTest(f"{cmake_path} is missing") cmake = self.spec["cmake"].command - cmake(cmake_path, "-DEXECUTABLE_OUTPUT_PATH=" + cmake_path) + cmake_args = ["-DEXECUTABLE_OUTPUT_PATH=" + cmake_path] + if self.spec.satisfies("+rocm"): + prefix_paths = ";".join(spack.build_environment.get_cmake_prefix_path(self)) + cmake_args.append("-DCMAKE_PREFIX_PATH={0}".format(prefix_paths)) + cmake(cmake_path, *cmake_args) make = which("make") make() make(cmake_path, "test") |