mirror of
https://git.gfz-potsdam.de/naaice/poet.git
synced 2025-12-15 12:28:22 +01:00
removed find_package for it conflicts with conda
This commit is contained in:
parent
a4be284b1d
commit
31316f3609
@ -39,17 +39,37 @@ FetchContent_Declare(
|
||||
FetchContent_MakeAvailable(cli11)
|
||||
|
||||
## MDL: adding fmtlib
|
||||
find_package(FMT QUIET)
|
||||
## find_package conflicts with conda on few servers, I am opting to just download it as dep
|
||||
## find_package(FMT QUIET)
|
||||
|
||||
if (NOT ${FMT_FOUND})
|
||||
FetchContent_Declare(
|
||||
# if (NOT ${FMT_FOUND})
|
||||
FetchContent_Declare(
|
||||
FMT
|
||||
QUIET
|
||||
GIT_REPOSITORY https://github.com/fmtlib/fmt
|
||||
GIT_TAG 0c9fce2ffefecfdce794e1859584e25877b7b592 # 11.0.2
|
||||
)
|
||||
FetchContent_MakeAvailable(fmt)
|
||||
endif()
|
||||
FetchContent_MakeAvailable(fmt)
|
||||
# endif()
|
||||
|
||||
target_compile_definitions(POETLib PUBLIC STRICT_R_HEADERS OMPI_SKIP_MPICXX)
|
||||
|
||||
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/kin_r_library.R" R_KIN_LIB )
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/init_r_lib.R" R_INIT_LIB)
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/ai_surrogate_model.R" R_AI_SURROGATE_LIB)
|
||||
|
||||
configure_file(poet.hpp.in poet.hpp @ONLY)
|
||||
|
||||
add_executable(poet poet.cpp)
|
||||
target_link_libraries(poet PRIVATE POETLib MPI::MPI_C RRuntime CLI11::CLI11 fmt::fmt)
|
||||
target_include_directories(poet PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
|
||||
add_executable(poet_init initializer.cpp)
|
||||
target_link_libraries(poet_init PRIVATE POETLib RRuntime CLI11::CLI11 fmt::fmt)
|
||||
target_include_directories(poet_init PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
|
||||
install(TARGETS poet poet_init DESTINATION bin)
|
||||
|
||||
# add_library(poetlib
|
||||
# Base/Grid.cpp
|
||||
@ -75,8 +95,6 @@ endif()
|
||||
# tug
|
||||
# )
|
||||
|
||||
target_compile_definitions(POETLib PUBLIC STRICT_R_HEADERS OMPI_SKIP_MPICXX)
|
||||
|
||||
# mark_as_advanced(PHREEQCRM_BUILD_MPI PHREEQCRM_DISABLE_OPENMP)
|
||||
# set(PHREEQCRM_DISABLE_OPENMP ON CACHE BOOL "" FORCE)
|
||||
|
||||
@ -91,19 +109,3 @@ target_compile_definitions(POETLib PUBLIC STRICT_R_HEADERS OMPI_SKIP_MPICXX)
|
||||
# if (POET_PHT_ADDITIONAL_INFO)
|
||||
# target_compile_definitions(poetlib PRIVATE POET_PHT_ADD)
|
||||
# endif()
|
||||
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/kin_r_library.R" R_KIN_LIB )
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/init_r_lib.R" R_INIT_LIB)
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/ai_surrogate_model.R" R_AI_SURROGATE_LIB)
|
||||
|
||||
configure_file(poet.hpp.in poet.hpp @ONLY)
|
||||
|
||||
add_executable(poet poet.cpp)
|
||||
target_link_libraries(poet PRIVATE POETLib MPI::MPI_C RRuntime CLI11::CLI11 fmt::fmt)
|
||||
target_include_directories(poet PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
|
||||
add_executable(poet_init initializer.cpp)
|
||||
target_link_libraries(poet_init PRIVATE POETLib RRuntime CLI11::CLI11 fmt::fmt)
|
||||
target_include_directories(poet_init PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
|
||||
install(TARGETS poet poet_init DESTINATION bin)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user