mirror of
https://git.gfz-potsdam.de/naaice/poet.git
synced 2025-12-15 20:38:23 +01:00
Add OpenMP support and fix include paths
This commit is contained in:
parent
106f9c519e
commit
be7a861c78
@ -19,7 +19,7 @@ get_poet_version()
|
||||
# set(GCC_CXX_FLAGS "-D STRICT_R_HEADERS") add_definitions(${GCC_CXX_FLAGS})
|
||||
|
||||
find_package(MPI REQUIRED)
|
||||
|
||||
find_package(OpenMP)
|
||||
find_package(RRuntime REQUIRED)
|
||||
|
||||
add_subdirectory(src)
|
||||
|
||||
@ -39,6 +39,10 @@ if (POET_PHT_ADDITIONAL_INFO)
|
||||
target_compile_definitions(poetlib PRIVATE POET_PHT_ADD)
|
||||
endif()
|
||||
|
||||
if (OpenMP_FOUND)
|
||||
target_link_libraries(poetlib PUBLIC OpenMP::OpenMP_CXX)
|
||||
endif()
|
||||
|
||||
file(READ "${PROJECT_SOURCE_DIR}/R_lib/kin_r_library.R" R_KIN_LIB )
|
||||
|
||||
configure_file(poet.hpp.in poet.hpp @ONLY)
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
#include "AdvectionModule.hpp"
|
||||
|
||||
#include "../Base/Macros.hpp"
|
||||
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <cstdlib>
|
||||
|
||||
@ -23,6 +23,7 @@
|
||||
#include "Base/RInsidePOET.hpp"
|
||||
#include "Base/SimParams.hpp"
|
||||
#include "Chemistry/ChemistryModule.hpp"
|
||||
#include "Transport/AdvectionModule.hpp"
|
||||
#include "Transport/DiffusionModule.hpp"
|
||||
|
||||
#include <poet.hpp>
|
||||
|
||||
@ -17,5 +17,5 @@ add_custom_target(check
|
||||
)
|
||||
|
||||
add_executable(advection advection/testAdvection.cpp)
|
||||
target_include_directories(advection PRIVATE "${CMAKE_CURRENT_BINARY_DIR}")
|
||||
target_link_libraries(advection poet_lib)
|
||||
target_include_directories(advection PRIVATE "${CMAKE_CURRENT_BINARY_DIR}" "${PROJECT_SOURCE_DIR}/src")
|
||||
target_link_libraries(advection poetlib)
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
#include <Transport/AdvectionModule.hpp>
|
||||
|
||||
#include <cstddef>
|
||||
#include <poet/AdvectionModule.hpp>
|
||||
#include <string>
|
||||
|
||||
#include "InputFiles.hpp"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user