Commit 0b4397ea authored by Max Lyon's avatar Max Lyon

require newer cmake versions on windows and use target_link_directories

parent 4846888e
Pipeline #9209 passed with stages
in 7 minutes and 11 seconds
cmake_minimum_required (VERSION 3.9) cmake_minimum_required (VERSION 3.9)
if (WIN32)
cmake_minimum_required (VERSION 3.13)
endif()
#Only set project name if CoMISo is built as stand-alone library #Only set project name if CoMISo is built as stand-alone library
if("${PROJECT_NAME}" STREQUAL "") if("${PROJECT_NAME}" STREQUAL "")
...@@ -417,6 +420,10 @@ message("COMISO_LINK_DIRECTORIES: ${COMISO_LINK_DIRECTORIES}") ...@@ -417,6 +420,10 @@ message("COMISO_LINK_DIRECTORIES: ${COMISO_LINK_DIRECTORIES}")
if (COMISO_LINK_DIRECTORIES) if (COMISO_LINK_DIRECTORIES)
set_target_properties(CoMISo PROPERTIES LINK_DIRECTORIES ${COMISO_LINK_DIRECTORIES}) set_target_properties(CoMISo PROPERTIES LINK_DIRECTORIES ${COMISO_LINK_DIRECTORIES})
endif() endif()
if (WIN32)
#TODO: do this also for non windows platforms as soon as we can require cmake 3.13
target_link_directories(CoMISo PUBLIC ${COMISO_LINK_DIRECTORIES})
endif()
# generate dllexport macros on windows # generate dllexport macros on windows
if (WIN32) if (WIN32)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment