diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index dc887877646..f5c075cad3b 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -25,8 +25,13 @@ function(_find_all_includes _ret_includes _ret_framework_paths) # framework path if (APPLE) - # version-less target Qt::Core is an interface library that links to QtX::Core - get_target_property(_qt_core Qt::Core INTERFACE_LINK_LIBRARIES) + get_target_property(_qt_type Qt::Core TYPE) + if ("${_qt_type}" STREQUAL "INTERFACE_LIBRARY") + # version-less target Qt::Core is an interface library that links to QtX::Core + get_target_property(_qt_core Qt::Core INTERFACE_LINK_LIBRARIES) + else() + set(_qt_core "Qt::Core") + endif() get_target_property(_qt_target ${_qt_core} LOCATION) # /QtCore.framework/QtCore get_filename_component(_qt_loc "${_qt_target}" DIRECTORY) set("${_ret_framework_paths}" "${_qt_loc}/.." PARENT_SCOPE)