Add optional support for download of geomech dependencies

This commit is contained in:
Magne Sjaastad 2023-04-30 13:48:24 +02:00
parent 3bca1507b2
commit b447ff86bb

View File

@ -129,6 +129,23 @@ set(RESINSIGHT_ODB_API_DIR
PATH
"Optional path to the ABAQUS ODB API from Simulia. Needed for support of geomechanical models"
)
if (MSVC)
option(RESINSIGHT_DONWLOAD_ODB_FROM_SERVER "Download ODB library from inhouse build server" OFF)
mark_as_advanced(FORCE RESINSIGHT_DONWLOAD_ODB_FROM_SERVER)
if (RESINSIGHT_DONWLOAD_ODB_FROM_SERVER)
FetchContent_Declare(
odb-library-from-server
URL http://10.10.0.26:8080/job/resinsight-dependencies/ws/odb-api-2020.zip
)
FetchContent_Populate(odb-library-from-server)
set(RESINSIGHT_ODB_API_DIR ${odb-library-from-server_SOURCE_DIR})
endif()
endif()
if(NOT ${RESINSIGHT_ODB_API_DIR} EQUAL "")
add_definitions(-DUSE_ODB_API)
set(RESINSIGHT_USE_ODB_API 1)