Skip to content

Commit

Permalink
Merge pull request #294 from LLNL/bugfix/export_chai
Browse files Browse the repository at this point in the history
Add find_package for chai in spheral export config
  • Loading branch information
ldowen authored Aug 1, 2024
2 parents e36c091 + d53eca2 commit 5a2bb03
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions cmake/spheral_cxx-config.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ if(NOT SPHERAL_FOUND)
if(NOT TARGET axom)
find_package(axom REQUIRED QUIET NO_DEFAULT_PATH PATHS ${axom_DIR} ${axom_DIR}/lib ${axom_DIR}/lib/cmake)
endif()
if(NOT TARGET chai)
if (@USE_EXTERNAL_CHAI@)
set(SPHERAL_CHAI_DIR "@chai_DIR@/lib/cmake/chai")
else()
set(SPHERAL_CHAI_DIR "${SPHERAL_CXX_INSTALL_PREFIX}/lib/cmake/chai")
endif()
find_package(chai REQUIRED QUIET NO_DEFAULT_PATH PATHS ${SPHERAL_CHAI_DIR})
endif()
if(SPHERALC_STANDALONE)
set(CMAKE_C_COMPILER "@CMAKE_C_COMPILER@" CACHE PATH "Spheral C compiler path")
set(CMAKE_CXX_COMPILER "@CMAKE_CXX_COMPILER@" CACHE PATH "Spheral C++ compiler path")
Expand Down

0 comments on commit 5a2bb03

Please sign in to comment.