Skip to content

Commit

Permalink
Retain the original path to Kokkos and ArborX
Browse files Browse the repository at this point in the history
  • Loading branch information
aprokop committed Dec 11, 2023
1 parent 973e7d0 commit 6c55942
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions cmake/CabanaConfig.cmakein
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,24 @@
include(CMakeFindDependencyMacro)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}" )
list(APPEND CMAKE_PREFIX_PATH @CMAKE_PREFIX_PATH@)
find_dependency(Kokkos REQUIRED)
find_package(Kokkos QUIET)
if(NOT Kokkos_FOUND)
# If Kokkos was not found, try to use Kokkos used when building Cabana
set(Kokkos_DIR @Kokkos_DIR@)
find_dependency(Kokkos)
endif()
set(Cabana_ENABLE_MPI @Cabana_ENABLE_MPI@)
if(Cabana_ENABLE_MPI)
find_dependency(MPI REQUIRED CXX)
endif()
set(Cabana_ENABLE_ARBORX @Cabana_ENABLE_ARBORX@)
if(Cabana_ENABLE_ARBORX)
find_dependency(ArborX REQUIRED)
find_package(ArborX QUIET)
if(NOT ArborX_FOUND)
# If ArborX was not found, try to use ArborX used when building Cabana
set(ArborX_DIR @ArborX_DIR@)
find_dependency(ArborX)
endif()
endif()
set(Cabana_ENABLE_GRID @Cabana_ENABLE_GRID@)
set(Cabana_ENABLE_CAJITA @Cabana_ENABLE_CAJITA@) # FIXME: remove in next release
Expand Down

0 comments on commit 6c55942

Please sign in to comment.