From: Boyuan Yang Subject: Request the Qt6 GuiPrivate CMake component src/CMakeLists.txt links the ksnip target against Qt6::GuiPrivate (needed for QtGui/private/qtx11extras_p.h), but that imported target only exists after find_package(Qt6 ... GuiPrivate) has been called. Without it the Qt6 build fails at generate time with "Target ksnip links to Qt6::GuiPrivate but the target was not found". Forwarded: no Last-Update: 2026-08-16 --- --- ksnip-1.10.1+git20260703.e8007559.orig/CMakeLists.txt +++ ksnip-1.10.1+git20260703.e8007559/CMakeLists.txt @@ -59,6 +59,12 @@ if (UNIX AND NOT APPLE) list(APPEND QT_COMPONENTS Concurrent) endif() +if (BUILD_WITH_QT6) + # src/ links against Qt6::GuiPrivate (for QtGui/private/qtx11extras_p.h), + # which is only defined once the GuiPrivate component has been requested. + list(APPEND QT_COMPONENTS GuiPrivate) +endif() + if (X11_FOUND AND NOT BUILD_WITH_QT6) list(APPEND QT_COMPONENTS X11Extras) elseif (WIN32)