Skip to content

Commit

Permalink
add ats to cmake build chain
Browse files Browse the repository at this point in the history
  • Loading branch information
rfiorella committed Nov 7, 2024
1 parent ba18b2e commit 92c501b
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions components/cmake/build_model.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,19 @@ macro(build_model COMP_CLASS COMP_NAME)
target_include_directories(${TARGET_NAME} PRIVATE ${MOAB_INCLUDE_DIRS})
endif()

# ATS-ELM Interface
# ultimately want to replace this with USE_ATS defined in env_build.xml
# requires ATS and TPLs to be installed prior to building E3SM!
# RPF / ETC - 241106
set(ATS_DIR "$ENV{ATS_DIR}")
if (NOT ATS_DIR STREQUAL "")
set(Amanzi_DIR "${ATS_DIR}/lib")
find_package(HDF5 REQUIRED)
find_package(NETCDF REQUIRED)
find_package(Amanzi REQUIRED)
target_link_libraries(${TARGET_NAME} amanzi_elm_ats)
endif()

# Make sure we link blas/lapack
if (NOT DEFINED ENV{SKIP_BLAS})
target_link_libraries(${TARGET_NAME} BLAS::BLAS LAPACK::LAPACK)
Expand Down

0 comments on commit 92c501b

Please sign in to comment.