summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/xcb/CMakeLists.txt
blob: 90c924b4b1aaac7dbc05f6f4543ad9f4575e105f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
# Generated from xcb_qpa_lib.pro.

#####################################################################
## QtXcbQpa Module:
#####################################################################
find_package(X11_XCB)
find_package(X11)
find_package(XCB)
find_package(XKB)
find_package(PkgConfig)

pkg_check_modules(XKB_COMMON_X11 xkbcommon-x11>=0.4.1 IMPORTED_TARGET)

add_qt_module(XcbQpa
    NO_MODULE_HEADERS
    SOURCES
        gl_integrations/qxcbglintegration.cpp gl_integrations/qxcbglintegration.h
        gl_integrations/qxcbglintegrationfactory.cpp gl_integrations/qxcbglintegrationfactory.h
        gl_integrations/qxcbglintegrationplugin.h
        gl_integrations/qxcbnativeinterfacehandler.cpp gl_integrations/qxcbnativeinterfacehandler.h
        qxcbbackingstore.cpp qxcbbackingstore.h
        qxcbclipboard.cpp qxcbclipboard.h
        qxcbconnection.cpp qxcbconnection.h
        qxcbcursor.cpp qxcbcursor.h
        qxcbimage.cpp qxcbimage.h
        qxcbintegration.cpp qxcbintegration.h
        qxcbkeyboard.cpp qxcbkeyboard.h
        qxcbmime.cpp qxcbmime.h
        qxcbnativeinterface.cpp qxcbnativeinterface.h
        qxcbobject.h
        qxcbscreen.cpp qxcbscreen.h
        qxcbsystemtraytracker.cpp qxcbsystemtraytracker.h
        qxcbwindow.cpp qxcbwindow.h
        qxcbwmsupport.cpp qxcbwmsupport.h
        qxcbxkbcommon.h
        qxcbxsettings.cpp qxcbxsettings.h
    DEFINES
        QT_NO_FOREACH
        QT_BUILD_XCB_PLUGIN
    INCLUDE_DIRECTORIES
        gl_integrations/
    LIBRARIES
        Qt::CorePrivate
        Qt::GuiPrivate
        Qt::ServiceSupportPrivate
        Qt::ThemeSupportPrivate
        Qt::EventDispatcherSupportPrivate
        Qt::FontDatabaseSupportPrivate
        Qt::EdidSupportPrivate
        X11::XCB
        XCB::XCB
        XCB::SHAPE
        XCB::ICCCM
        XCB::RANDR
        XCB::XKB
        XCB::SYNC
        XCB::XFIXES
        XCB::XINERAMA
        XCB::SHM
        XCB::IMAGE
        XCB::RENDER
        XCB::RENDERUTIL
        XCB::KEYSYMS
        XKB::XKB
        PkgConfig::XKB_COMMON_X11
)

## Scopes:
#####################################################################

extend_target(XcbQpa CONDITION TARGET Qt::linuxaccessibility_support_private
    LIBRARIES
        linuxaccessibility_supportPrivate
)

extend_target(XcbQpa CONDITION QT_FEATURE_vulkan
    LIBRARIES
        vulkan_supportPrivate
)

extend_target(XcbQpa CONDITION QT_FEATURE_draganddrop
    SOURCES
        qxcbdrag.cpp qxcbdrag.h
)
#
#extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xlib
#)

extend_target(XcbQpa CONDITION QT_FEATURE_xcb_xinput
    SOURCES
        qxcbconnection_xi2.cpp
)

extend_target(XcbQpa CONDITION QT_FEATURE_xcb_sm
    SOURCES
        qxcbsessionmanager.cpp qxcbsessionmanager.h
    LIBRARIES
        ${X11_SM_LIB} ${X11_ICE_LIB}
)

extend_target(XcbQpa CONDITION QT_FEATURE_vulkan
    SOURCES
        qxcbvulkaninstance.cpp qxcbvulkaninstance.h
        qxcbvulkanwindow.cpp qxcbvulkanwindow.h
)
#
#extend_target(XcbQpa CONDITION NOT QT_FEATURE_system_xcb
#)
#
#extend_target(XcbQpa CONDITION NOT NOT QT_FEATURE_system_xcb
#)
#
#extend_target(XcbQpa CONDITION (NOT NOT QT_FEATURE_system_xcb) AND (QT_FEATURE_xkb)
#)
#
#extend_target(XcbQpa CONDITION (NOT NOT QT_FEATURE_system_xcb) AND (QT_FEATURE_xcb_render)
#)
#
#extend_target(XcbQpa CONDITION (NOT NOT QT_FEATURE_system_xcb) AND (QT_FEATURE_xcb_xinput)
#)
#
#extend_target(XcbQpa CONDITION NOT QT_FEATURE_xkbcommon_system
#)

extend_target(XcbQpa CONDITION (NOT QT_FEATURE_xkbcommon_system) AND (QT_FEATURE_xkb)
    INCLUDE_DIRECTORIES
        ../../../3rdparty/xkbcommon/src/x11
)

extend_target(XcbQpa CONDITION (NOT QT_FEATURE_xkbcommon_system) AND (NOT QT_FEATURE_xkb)
    INCLUDE_DIRECTORIES
        ../../../3rdparty/xkbcommon
        ../../../3rdparty/xkbcommon/xkbcommon
        ../../../3rdparty/xkbcommon/src
        ../../../3rdparty/xkbcommon/src/xkbcomp
)
#
#extend_target(XcbQpa CONDITION NOT NOT QT_FEATURE_xkbcommon_system
#)
#
#extend_target(XcbQpa CONDITION QT_FEATURE_dlopen
#)

extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting
    SOURCES
        nativepainting/qbackingstore_x11.cpp nativepainting/qbackingstore_x11_p.h
        nativepainting/qcolormap_x11.cpp nativepainting/qcolormap_x11_p.h
        nativepainting/qpaintengine_x11.cpp nativepainting/qpaintengine_x11_p.h
        nativepainting/qpixmap_x11.cpp nativepainting/qpixmap_x11_p.h
        nativepainting/qt_x11_p.h
        nativepainting/qtessellator.cpp nativepainting/qtessellator_p.h
        nativepainting/qxcbnativepainting.cpp nativepainting/qxcbnativepainting.h
    INCLUDE_DIRECTORIES
        nativepainting/
)
#
#extend_target(XcbQpa CONDITION (QT_FEATURE_xcb_native_painting) AND (QT_FEATURE_xrender)
#)

extend_target(XcbQpa CONDITION (QT_FEATURE_xcb_native_painting) AND (QT_FEATURE_fontconfig)
    LIBRARIES
        freetype
)

add_qt_plugin(qxcb
    TYPE platforms
    SOURCES
        qxcbmain.cpp
    LIBRARIES
        Qt::XcbQpa
        Qt::GuiPrivate
)