forked from E3SM-Project/E3SM
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Alquimia code and compilation with EMI
- Loading branch information
Showing
6 changed files
with
3,312 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
components/elm/src/external_models/emi/src/em/alquimia/CMakeLists.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
set(EMI_EM_ALQUIMIA_SOURCES | ||
ExternalModelAlquimiaMod.F90 | ||
) | ||
|
||
include_directories(${CMAKE_BINARY_DIR}/elm_stub/shr) | ||
include_directories(${CMAKE_BINARY_DIR}/elm_stub/utils) | ||
include_directories(${CMAKE_BINARY_DIR}/elm_stub/elm_types_stub) | ||
include_directories(${CMAKE_BINARY_DIR}/constants) | ||
include_directories(${CMAKE_BINARY_DIR}/emi_data_types) | ||
include_directories(${CMAKE_BINARY_DIR}/emi_data_definition) | ||
include_directories(${CMAKE_BINARY_DIR}/em/base) | ||
|
||
# Find PETSC stuff | ||
# Not necessary for Crunch? | ||
find_package(PETSc) | ||
if (NOT PETSC_FOUND) | ||
message(FATAL_ERROR "PETSc was not found.") | ||
endif() | ||
include_directories(${PETSC_INCLUDES}) | ||
|
||
# Include PETSc in the rpath. | ||
set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_RPATH}:${PETSC_DIR}/${PETSC_ARCH}/lib") | ||
|
||
include_directories(${ALQUIMIA_DIR}) | ||
link_libraries(${ALQUIMIA_DIR}/libalquimia.so ${PETSC_LIBRARIES}) | ||
#link_libraries(${PETSC_DIR}/${PETSC_ARCH}/lib/libmpifort.dylib)) # This was necessary on Mac | ||
link_libraries($ENV{PFLOTRAN_DIR}/libpflotranchem.a) | ||
|
||
|
||
include(add_emi_library) | ||
add_emi_library(emi_em_alquimia ${EMI_EM_ALQUIMIA_SOURCES} ) | ||
|
||
|
||
|
||
|
||
set(EMI_LIBRARIES emi_em_alquimia;${EMI_LIBRARIES} PARENT_SCOPE) | ||
set(EMI_LIBRARIES emi_em_alquimia;${EMI_LIBRARIES}) | ||
|
||
|
||
if (NOT CMAKE_INSTALL_PREFIX STREQUAL "INSTALL_DISABLED") | ||
install(TARGETS emi_em_alquimia DESTINATION lib) | ||
file(GLOB HEADERS *.h) | ||
install(FILES ${HEADERS} DESTINATION include/) | ||
endif() |
Oops, something went wrong.