Re-visit the xkbcommon dependency
QtGui doesn't expose xkbcommon as public dependency anymore. QtGuiPrivate, however does now, but only in the CMake build. Fix the qmake build by adding an explicit xkbcommon dependency to client.pro, like it's done for the compositor. Commented out the explicit xkbcommon dependencies in the CMakeLists.txt files of client and compositor. Mark the XKB packages as optional, such that qtwayland can actually be built if the feature xkbcommon is OFF and no libxkbcommon-dev package is installed. Change-Id: Ia1c7a8333dc8a93b4924e03f7f2284a709a9d65b Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
parent
769bef69c8
commit
f1b5619ca0
@ -89,6 +89,11 @@ qt6_generate_wayland_protocol_client_sources(WaylandClient
|
||||
## Scopes:
|
||||
#####################################################################
|
||||
|
||||
qt_extend_target(WaylandClient CONDITION QT_FEATURE_xkbcommon
|
||||
PUBLIC_LIBRARIES
|
||||
XKB::XKB
|
||||
)
|
||||
|
||||
qt_extend_target(WaylandClient CONDITION QT_FEATURE_clipboard
|
||||
SOURCES
|
||||
qwaylandclipboard.cpp qwaylandclipboard_p.h
|
||||
|
@ -89,6 +89,16 @@ qt6_generate_wayland_protocol_client_sources(WaylandClient
|
||||
## Scopes:
|
||||
#####################################################################
|
||||
|
||||
# special case begin
|
||||
#
|
||||
# Do not explicitly add XKB::XKB. This is already done by Qt::GuiPrivate.
|
||||
#
|
||||
# qt_extend_target(WaylandClient CONDITION QT_FEATURE_xkbcommon
|
||||
# PUBLIC_LIBRARIES
|
||||
# XKB::XKB
|
||||
# )
|
||||
# special case end
|
||||
|
||||
qt_extend_target(WaylandClient CONDITION QT_FEATURE_clipboard
|
||||
SOURCES
|
||||
qwaylandclipboard.cpp qwaylandclipboard_p.h
|
||||
|
@ -14,6 +14,8 @@ CONFIG -= precompile_header
|
||||
CONFIG += link_pkgconfig wayland-scanner
|
||||
|
||||
QMAKE_USE += wayland-client
|
||||
qtConfig(xkbcommon): \
|
||||
QMAKE_USE += xkbcommon
|
||||
|
||||
INCLUDEPATH += $$PWD/../shared
|
||||
|
||||
|
@ -26,7 +26,7 @@ if(NOT TARGET X11::X11)
|
||||
endif()
|
||||
# Same for XKB.
|
||||
if(NOT TARGET XKB::XKB)
|
||||
qt_find_package(XKB 0.5.0 PROVIDED_TARGETS XKB::XKB MODULE_NAME gui QMAKE_LIB xkbcommon)
|
||||
qt_find_package(XKB 0.5.0 PROVIDED_TARGETS XKB::XKB MODULE_NAME gui QMAKE_LIB xkbcommon MARK_OPTIONAL)
|
||||
endif()
|
||||
# special case end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user