Examples: Use versioned CMake targets for Qt modules

Use e.g. Qt6::Core instead of Qt::Core. This is better matching the
find_package(Qt6 ...) call, and also avoids issues that the versionless
targets have.

Pick-to: 6.5
Task-number: QTBUG-113277
Change-Id: Ib4373036092163518a611bd5c688591d18096d7e
Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
This commit is contained in:
Kai Köhne 2023-04-28 13:24:35 +02:00
parent df862a940e
commit 9f9ff18ba9

View File

@ -26,11 +26,11 @@ set_target_properties(stereoqopenglwidget PROPERTIES
)
target_link_libraries(stereoqopenglwidget PUBLIC
Qt::Core
Qt::Gui
Qt::OpenGL
Qt::OpenGLWidgets
Qt::Widgets
Qt6::Core
Qt6::Gui
Qt6::OpenGL
Qt6::OpenGLWidgets
Qt6::Widgets
)