From c041ed7170ab8fc1af48b8ba5dd2d981669651e8 Mon Sep 17 00:00:00 2001 From: anagainaru Date: Tue, 6 Jun 2023 13:33:09 -0400 Subject: [PATCH] Guard the GPU memory space to be available only when ADIOS2 has GPU support --- bindings/CXX11/adios2/cxx11/KokkosView.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bindings/CXX11/adios2/cxx11/KokkosView.h b/bindings/CXX11/adios2/cxx11/KokkosView.h index f092e51c9f..e83560bd14 100644 --- a/bindings/CXX11/adios2/cxx11/KokkosView.h +++ b/bindings/CXX11/adios2/cxx11/KokkosView.h @@ -8,6 +8,7 @@ namespace adios2 namespace detail { +#ifdef ADIOS2_HAVE_GPU_SUPPORT template struct memspace_kokkos_to_adios2 { @@ -19,6 +20,13 @@ struct memspace_kokkos_to_adios2 { static constexpr adios2::MemorySpace value = adios2::MemorySpace::Host; }; +#else +template +struct memspace_kokkos_to_adios2 +{ + static constexpr adios2::MemorySpace value = adios2::MemorySpace::Host; +}; +#endif } // namespace detail