Make the xcomposite the default gl integration backend
[profile/ivi/qtwayland.git] / src / plugins / platforms / wayland / gl_integration / gl_integration.pri
1 contains(QT_CONFIG, opengl) {
2     DEFINES += QT_WAYLAND_GL_SUPPORT
3     QT += opengl
4
5 HEADERS += \
6     $$PWD/qwaylandglintegration.h \
7     $$PWD/qwaylandglwindowsurface.h
8
9 SOURCES += \
10     $$PWD/qwaylandglintegration.cpp \
11     $$PWD/qwaylandglwindowsurface.cpp
12
13     QT_WAYLAND_GL_CONFIG = $$(QT_WAYLAND_GL_CONFIG)
14     contains(QT_CONFIG, opengles2) {
15         isEqual(QT_WAYLAND_GL_CONFIG, wayland_egl) {
16             QT_WAYLAND_GL_INTEGRATION = $$QT_WAYLAND_GL_CONFIG
17             CONFIG += wayland_egl
18         } else:isEqual(QT_WAYLAND_GL_CONFIG,readback) {
19             QT_WAYLAND_GL_INTEGRATION = readback_egl
20             CONFIG += readback_egl
21         } else {
22             QT_WAYLAND_GL_INTEGRATION = xcomposite_egl
23             CONFIG += xcomposite_egl
24         }
25     } else {
26         isEqual(QT_WAYLAND_GL_CONFIG, readback) {
27             QT_WAYLAND_GL_INTEGRATION = readback_glx
28             CONFIG += readback_glx
29         } else {
30             QT_WAYLAND_GL_INTEGRATION = xcomposite_glx
31             CONFIG += xcomposite_glx
32         }
33     }
34
35     message("Wayland GL Integration: $$QT_WAYLAND_GL_INTEGRATION")
36 }
37
38
39 wayland_egl {
40     include ($$PWD/wayland_egl/wayland_egl.pri)
41 }
42
43 readback_egl {
44     include ($$PWD/readback_egl/readback_egl.pri)
45 }
46
47 readback_glx {
48     include ($$PWD/readback_glx/readback_glx.pri)
49 }
50
51 xcomposite_glx {
52     include ($$PWD/xcomposite_glx/xcomposite_glx.pri)
53 }
54
55 xcomposite_egl {
56     include ($$PWD/xcomposite_egl/xcomposite_egl.pri)
57 }