Skip to content
Snippets Groups Projects
Verified Commit 3077cadc authored by Lars Bilke's avatar Lars Bilke
Browse files

[CMake] Automatically install Conan when OGS_USE_CONAN=auto.

Is installed into the build dir's virtualenv (.venv/bin)
parent 4b4a5096
No related branches found
No related tags found
No related merge requests found
if(NOT OGS_USE_CONAN) if(NOT OGS_USE_CONAN)
return() return()
endif() endif()
find_program(CONAN_CMD conan) string(TOLOWER ${OGS_USE_CONAN} OGS_USE_CONAN_lower)
if(OGS_USE_CONAN_lower STREQUAL "auto" AND POETRY)
execute_process(
COMMAND poetry add conan=${ogs.minimum_version.conan}
WORKING_DIRECTORY ${PROJECT_BINARY_DIR}
)
endif()
find_program(CONAN_CMD conan HINTS ${PROJECT_BINARY_DIR}/.venv/bin)
if(NOT CONAN_CMD) if(NOT CONAN_CMD)
message(WARNING "conan executable not found. Consider installing Conan for " message(WARNING "conan executable not found. Consider installing Conan for "
"automatic third-party library handling. https://www.opengeosys.org/doc" "automatic third-party library handling. https://www.opengeosys.org/doc"
......
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