OpenGL API refactor.
[profile/ivi/qtbase.git] / src / plugins / platforms / xcb / xcb.pro
1 TARGET = xcb
2
3 load(qt_plugin)
4 QTDIR_build:DESTDIR = $$QT_BUILD_TREE/plugins/platforms
5
6 QT += core-private gui-private platformsupport-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         qxcbbackingstore.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         qxcbbackingstore.h \
35         qxcbwmsupport.h \
36         qxcbnativeinterface.h \
37         qxcbcursor.h \
38         qxcbimage.h
39
40
41 # needed by GLX, Xcursor, XLookupString, ...
42 contains(QT_CONFIG, xcb-xlib) {
43     DEFINES += XCB_USE_XLIB
44     LIBS += -lX11 -lX11-xcb
45 }
46
47 # to support custom cursors with depth > 1
48 contains(QT_CONFIG, xcb-render) {
49     DEFINES += XCB_USE_RENDER
50     LIBS += -lxcb-render -lxcb-render-util
51 }
52
53 contains(QT_CONFIG, opengl) {
54     QT += opengl
55
56 #    DEFINES += XCB_USE_DRI2
57     contains(DEFINES, XCB_USE_DRI2) {
58         LIBS += -lxcb-dri2 -lEGL
59
60         CONFIG += link_pkgconfig
61         PKGCONFIG += libdrm
62
63         HEADERS += qdri2context.h
64         SOURCES += qdri2context.cpp
65
66     } else {
67         contains(QT_CONFIG, opengles2) {
68             DEFINES += XCB_USE_EGL
69             LIBS += -lEGL
70             HEADERS += qxcbeglsurface.h
71         } else {
72             DEFINES += XCB_USE_GLX
73             HEADERS += qglxintegration.h
74             SOURCES += qglxintegration.cpp
75         }
76     }
77 }
78
79 LIBS += -lxcb -lxcb-image -lxcb-keysyms -lxcb-icccm -lxcb-sync -lxcb-xfixes
80
81 DEFINES += $$QMAKE_DEFINES_XCB
82 LIBS += $$QMAKE_LIBS_XCB
83 QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB
84
85 CONFIG += qpa/genericunixfontdatabase
86
87 target.path += $$[QT_INSTALL_PLUGINS]/platforms
88 INSTALLS += target