Skip to content
Snippets Groups Projects
Commit 7af85e2f authored by Lars Bilke's avatar Lars Bilke
Browse files

[cmake] Install OpenGeoSys python module.

Add install dir to PYTHONPATH of the test ogs_python_module.

Fixes https://gitlab.opengeosys.org/ufz-bgr/hpc/docs/-/issues/18.
parent 6df6974b
No related branches found
No related tags found
No related merge requests found
...@@ -67,6 +67,8 @@ if(OGS_USE_PYTHON) ...@@ -67,6 +67,8 @@ if(OGS_USE_PYTHON)
OpenGeoSys PRIVATE ApplicationsLib BaseLib GitInfoLib tclap OpenGeoSys PRIVATE ApplicationsLib BaseLib GitInfoLib tclap
pybind11::pybind11 pybind11::pybind11
) )
install(TARGETS OpenGeoSys LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})
endif() endif()
endif() endif()
...@@ -107,9 +109,13 @@ if(OGS_BUILD_PYTHON_MODULE AND NOT (WIN32 AND "${CMAKE_BUILD_TYPE}" STREQUAL ...@@ -107,9 +109,13 @@ if(OGS_BUILD_PYTHON_MODULE AND NOT (WIN32 AND "${CMAKE_BUILD_TYPE}" STREQUAL
) )
set_tests_properties( set_tests_properties(
ogs_python_module ogs_python_module
PROPERTIES LABELS "default" ENVIRONMENT_MODIFICATION PROPERTIES
PYTHONPATH=path_list_append:$<TARGET_FILE_DIR:OpenGeoSys> LABELS
DISABLED $<NOT:$<TARGET_EXISTS:LiquidFlow>> "default"
ENVIRONMENT_MODIFICATION
PYTHONPATH=path_list_append:$<TARGET_FILE_DIR:OpenGeoSys>:${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}
DISABLED
$<NOT:$<TARGET_EXISTS:LiquidFlow>>
) )
endif() endif()
# ---- Installation ---- # ---- Installation ----
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment