Совместимость c CMake 3.7

This commit is contained in:
Andrei Astafev 2024-02-12 16:45:38 +03:00
parent 42216b4f4f
commit 2260a5ac5f

View File

@ -111,7 +111,9 @@ function(myx_target_setup TARGET_NAME)
endif() endif()
endif() endif()
else() else()
target_link_libraries(${TARGET_NAME} PRIVATE ${__link_library}) if((${CMAKE_VERSION} VERSION_GREATER "3.7.99") OR (NOT __target_type STREQUAL "OBJECT_LIBRARY"))
target_link_libraries(${TARGET_NAME} PRIVATE ${__link_library})
endif()
endif() endif()
endforeach() endforeach()
endif() endif()