Create custom cursors via XRender.
[profile/ivi/qtbase.git] / src / plugins / platforms / xcb / xcb.pro
1 TARGET = xcb
2
3 load(qpa/plugin)
4 QTDIR_build:DESTDIR = $$QT_BUILD_TREE/plugins/platforms
5
6 QT += core-private gui-private
7
8 SOURCES = \
9         qxcbclipboard.cpp \
10         qxcbconnection.cpp \
11         qxcbintegration.cpp \
12         qxcbkeyboard.cpp \
13         qxcbmime.cpp \
14         qxcbdrag.cpp \
15         qxcbscreen.cpp \
16         qxcbwindow.cpp \
17         qxcbwindowsurface.cpp \
18         qxcbwmsupport.cpp \
19         main.cpp \
20         qxcbnativeinterface.cpp \
21         qxcbcursor.cpp \
22         qxcbimage.cpp
23
24 HEADERS = \
25         qxcbclipboard.h \
26         qxcbconnection.h \
27         qxcbintegration.h \
28         qxcbkeyboard.h \
29         qxcbdrag.h \
30         qxcbmime.h \
31         qxcbobject.h \
32         qxcbscreen.h \
33         qxcbwindow.h \
34         qxcbwindowsurface.h \
35         qxcbwmsupport.h \
36         qxcbnativeinterface.h \
37         qxcbcursor.h \
38         qxcbimage.h
39
40 QT += gui-private core-private
41
42 # needed by GLX, Xcursor, ...
43 DEFINES += XCB_USE_XLIB
44
45 # to support custom cursors with depth > 1
46 DEFINES += XCB_USE_RENDER
47
48 contains(QT_CONFIG, opengl) {
49     QT += opengl
50
51 #    DEFINES += XCB_USE_DRI2
52     contains(DEFINES, XCB_USE_DRI2) {
53         LIBS += -lxcb-dri2 -lEGL
54
55         CONFIG += link_pkgconfig
56         PKGCONFIG += libdrm
57
58         HEADERS += qdri2context.h
59         SOURCES += qdri2context.cpp
60
61     } else {
62         contains(QT_CONFIG, opengles2) {
63             DEFINES += XCB_USE_EGL
64             load(qpa/egl/convenience)
65             load(qpa/egl/context)
66             load(qpa/egl/xlibintegration)
67
68             LIBS += -lEGL
69         } else {
70             DEFINES += XCB_USE_GLX
71             load(qpa/glx/convenience)
72             HEADERS += qglxintegration.h
73             SOURCES += qglxintegration.cpp
74         }
75     }
76 }
77
78 LIBS += -lxcb -lxcb-image -lxcb-keysyms -lxcb-icccm -lxcb-sync -lxcb-xfixes
79 contains(DEFINES, XCB_USE_XLIB): LIBS += -lX11 -lX11-xcb
80 contains(DEFINES, XCB_USE_RENDER): LIBS += -lxcb-render -lxcb-render-util
81
82 DEFINES += $$QMAKE_DEFINES_XCB
83 LIBS += $$QMAKE_LIBS_XCB
84 QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB
85
86 load(qpa/fontdatabases/genericunix)
87 load(qpa/printersupport/genericunix)
88
89 target.path += $$[QT_INSTALL_PLUGINS]/platforms
90 INSTALLS += target