summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--config.tests/brcm_egl/brcm_egl.pro13
-rw-r--r--config.tests/brcm_egl/main.cpp71
-rw-r--r--config.tests/drm_egl_server/drm_egl_server.pro13
-rw-r--r--config.tests/glx/glx.pro13
-rw-r--r--config.tests/libhybris_egl_server/libhybris_egl_server.pro13
-rw-r--r--config.tests/wayland/wayland.pro13
-rw-r--r--config.tests/wayland_cursor/wayland_cursor.pro11
-rw-r--r--config.tests/wayland_egl/wayland_egl.pro14
-rw-r--r--config.tests/wayland_scanner/wayland_scanner.pro7
-rw-r--r--config.tests/xcomposite/xcomposite.pro13
-rw-r--r--config.tests/xkbcommon/main.cpp67
-rw-r--r--config.tests/xkbcommon/xkbcommon.pro12
-rw-r--r--configure.json6
-rw-r--r--examples/wayland/custom-extension/client-common/client.pro7
-rw-r--r--examples/wayland/custom-extension/compositor/compositor.pro7
-rw-r--r--examples/wayland/custom-extension/cpp-client/cpp-client.pro9
-rw-r--r--examples/wayland/custom-extension/qml-client/qml-client.pro10
-rw-r--r--examples/wayland/server-buffer/client/client.pro8
-rw-r--r--examples/wayland/server-buffer/compositor/compositor.pro7
-rw-r--r--examples/wayland/wayland.pro18
-rw-r--r--qtwayland.pro36
-rw-r--r--src/client/client.pro17
-rw-r--r--src/client/configure.json134
-rw-r--r--src/compositor/compositor.pro9
-rw-r--r--src/compositor/compositor_api/compositor_api.pri2
-rw-r--r--src/compositor/configure.json99
-rw-r--r--src/compositor/wayland_wrapper/wayland_wrapper.pri8
-rw-r--r--src/hardwareintegration/client/brcm-egl/brcm-egl.pri9
-rw-r--r--src/hardwareintegration/client/drm-egl-server/drm-egl-server.pri9
-rw-r--r--src/hardwareintegration/client/libhybris-egl-server/libhybris-egl-server.pri7
-rw-r--r--src/hardwareintegration/client/wayland-egl/wayland-egl.pri9
-rw-r--r--src/hardwareintegration/client/xcomposite-egl/xcomposite-egl.pri8
-rw-r--r--src/hardwareintegration/client/xcomposite-glx/xcomposite-glx.pri7
-rw-r--r--src/hardwareintegration/client/xcomposite_share/xcomposite_share.pri1
-rw-r--r--src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri7
-rw-r--r--src/hardwareintegration/compositor/drm-egl-server/drm-egl-server.pri9
-rw-r--r--src/hardwareintegration/compositor/libhybris-egl-server/libhybris-egl-server.pri9
-rw-r--r--src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri8
-rw-r--r--src/hardwareintegration/compositor/xcomposite-egl/xcomposite-egl.pri9
-rw-r--r--src/hardwareintegration/compositor/xcomposite-glx/xcomposite-glx.pri7
-rw-r--r--src/hardwareintegration/compositor/xcomposite_share/xcomposite_share.pri1
-rw-r--r--src/plugins/decorations/bradient/bradient.pro7
-rw-r--r--src/plugins/hardwareintegration/client/client.pro24
-rw-r--r--src/plugins/hardwareintegration/compositor/compositor.pro23
-rw-r--r--src/plugins/platforms/platforms.pro16
-rw-r--r--src/plugins/shellintegration/ivi-shell/ivi-shell.pro17
-rw-r--r--src/src.pro46
-rw-r--r--tests/auto/auto.pro8
-rw-r--r--tests/auto/client/client/client.pro6
-rw-r--r--tests/auto/compositor/compositor/compositor.pro14
50 files changed, 341 insertions, 557 deletions
diff --git a/config.tests/brcm_egl/brcm_egl.pro b/config.tests/brcm_egl/brcm_egl.pro
deleted file mode 100644
index a6b416f1a..000000000
--- a/config.tests/brcm_egl/brcm_egl.pro
+++ /dev/null
@@ -1,13 +0,0 @@
-TARGET = brcm_egl
-CONFIG -= qt
-
-INCLUDEPATH += $$QMAKE_INCDIR_EGL
-
-for(p, QMAKE_LIBDIR_EGL) {
- exists($$p):LIBS += -L$$p
-}
-
-LIBS += $$QMAKE_LIBS_EGL
-
-# Input
-SOURCES += main.cpp
diff --git a/config.tests/brcm_egl/main.cpp b/config.tests/brcm_egl/main.cpp
deleted file mode 100644
index bb3cab73a..000000000
--- a/config.tests/brcm_egl/main.cpp
+++ /dev/null
@@ -1,71 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2015 The Qt Company Ltd.
-** Contact: http://www.qt.io/licensing/
-**
-** This file is part of the Qt Compositor.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** You may use this file under the terms of the BSD license as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-** * Redistributions of source code must retain the above copyright
-** notice, this list of conditions and the following disclaimer.
-** * Redistributions in binary form must reproduce the above copyright
-** notice, this list of conditions and the following disclaimer in
-** the documentation and/or other materials provided with the
-** distribution.
-** * Neither the name of The Qt Company Ltd nor the names of its
-** contributors may be used to endorse or promote products derived
-** from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include <stdio.h>
-
-#include <EGL/egl.h>
-#include <EGL/eglext.h>
-
-#include <EGL/eglext_brcm.h>
-
-int main()
-{
- EGLDisplay display = eglGetDisplay((EGLNativeDisplayType)EGL_DEFAULT_DISPLAY);
- if (!display) {
- fprintf(stderr, "No EGL display");
- return -1;
- }
-
- EGLint major, minor;
- if (!eglInitialize(display, &major, &minor)) {
- fprintf(stderr, "Failed to initialize EGL");
- return -1;
- }
-
- EGLint pixel_format = EGL_PIXEL_FORMAT_ARGB_8888_BRCM;
-
- EGLint id[2];
- PFNEGLCREATEGLOBALIMAGEBRCMPROC createImage = (PFNEGLCREATEGLOBALIMAGEBRCMPROC)eglGetProcAddress("eglCreateGlobalImageBRCM");
- createImage(32, 32, pixel_format, 0, 32 * 4, id);
-
- eglTerminate(display);
-
- return 0;
-}
diff --git a/config.tests/drm_egl_server/drm_egl_server.pro b/config.tests/drm_egl_server/drm_egl_server.pro
index 328354eb2..28dcadcbf 100644
--- a/config.tests/drm_egl_server/drm_egl_server.pro
+++ b/config.tests/drm_egl_server/drm_egl_server.pro
@@ -1,14 +1 @@
-TARGET = drm_egl_server
-QT = core
-
-!contains(QT_CONFIG, opengl): error("drm_egl_server support requires Qt configured with OpenGL")
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += egl
-} else {
- LIBS += -legl
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/glx/glx.pro b/config.tests/glx/glx.pro
index 74cc60837..28dcadcbf 100644
--- a/config.tests/glx/glx.pro
+++ b/config.tests/glx/glx.pro
@@ -1,14 +1 @@
-TARGET = glx
-QT = core
-
-!contains(QT_CONFIG, opengl): error("glx support requires Qt configured with OpenGL")
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += x11 gl
-} else {
- LIBS += -lX11 -lGL
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/libhybris_egl_server/libhybris_egl_server.pro b/config.tests/libhybris_egl_server/libhybris_egl_server.pro
index bc358d559..28dcadcbf 100644
--- a/config.tests/libhybris_egl_server/libhybris_egl_server.pro
+++ b/config.tests/libhybris_egl_server/libhybris_egl_server.pro
@@ -1,14 +1 @@
-TARGET = libhybris_egl_server
-QT = core
-
-!contains(QT_CONFIG, opengl): error("libhybris_egl_server support requires Qt configured with OpenGL")
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += egl
-} else {
- LIBS += -legl
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/wayland/wayland.pro b/config.tests/wayland/wayland.pro
index 5873d92db..28dcadcbf 100644
--- a/config.tests/wayland/wayland.pro
+++ b/config.tests/wayland/wayland.pro
@@ -1,12 +1 @@
-TARGET = wayland
-QT = core
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
-
-# Input
-SOURCES += main.cpp \ No newline at end of file
+SOURCES += main.cpp
diff --git a/config.tests/wayland_cursor/wayland_cursor.pro b/config.tests/wayland_cursor/wayland_cursor.pro
index aa38d32fb..28dcadcbf 100644
--- a/config.tests/wayland_cursor/wayland_cursor.pro
+++ b/config.tests/wayland_cursor/wayland_cursor.pro
@@ -1,12 +1 @@
-TARGET = wayland_cursor
-QT = core
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-cursor
-} else {
- LIBS += -lwayland-cursor
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/wayland_egl/wayland_egl.pro b/config.tests/wayland_egl/wayland_egl.pro
index 42d6b131e..28dcadcbf 100644
--- a/config.tests/wayland_egl/wayland_egl.pro
+++ b/config.tests/wayland_egl/wayland_egl.pro
@@ -1,15 +1 @@
-TARGET = wayland_egl
-QT = core
-
-!contains(QT_CONFIG, opengl): error("wayland_egl support requires Qt configured with OpenGL")
-!contains(QT_CONFIG, egl): error("wayland_egl support requires Qt configured with EGL")
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-egl
-} else {
- LIBS += -lwayland-egl
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/wayland_scanner/wayland_scanner.pro b/config.tests/wayland_scanner/wayland_scanner.pro
index 300e439ef..03da69dca 100644
--- a/config.tests/wayland_scanner/wayland_scanner.pro
+++ b/config.tests/wayland_scanner/wayland_scanner.pro
@@ -2,13 +2,6 @@ TARGET = wayland_scanner
isEmpty(QMAKE_WAYLAND_SCANNER):error("QMAKE_WAYLAND_SCANNER not defined for this mkspec")
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
-
# Input
SOURCES += main.cpp
diff --git a/config.tests/xcomposite/xcomposite.pro b/config.tests/xcomposite/xcomposite.pro
index 6838970a6..28dcadcbf 100644
--- a/config.tests/xcomposite/xcomposite.pro
+++ b/config.tests/xcomposite/xcomposite.pro
@@ -1,14 +1 @@
-TARGET = xcomposite
-QT = core
-
-!contains(QT_CONFIG, opengl): error("xcomposite support requires Qt configured with OpenGL")
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += xcomposite
-} else {
- LIBS += -lXcomposite
-}
-
-# Input
SOURCES += main.cpp
diff --git a/config.tests/xkbcommon/main.cpp b/config.tests/xkbcommon/main.cpp
deleted file mode 100644
index 97162f3d0..000000000
--- a/config.tests/xkbcommon/main.cpp
+++ /dev/null
@@ -1,67 +0,0 @@
-/****************************************************************************
-**
-** Copyright (C) 2015 The Qt Company Ltd.
-** Contact: http://www.qt.io/licensing/
-**
-** This file is part of the Qt Compositor.
-**
-** $QT_BEGIN_LICENSE:BSD$
-** You may use this file under the terms of the BSD license as follows:
-**
-** "Redistribution and use in source and binary forms, with or without
-** modification, are permitted provided that the following conditions are
-** met:
-** * Redistributions of source code must retain the above copyright
-** notice, this list of conditions and the following disclaimer.
-** * Redistributions in binary form must reproduce the above copyright
-** notice, this list of conditions and the following disclaimer in
-** the documentation and/or other materials provided with the
-** distribution.
-** * Neither the name of The Qt Company Ltd nor the names of its
-** contributors may be used to endorse or promote products derived
-** from this software without specific prior written permission.
-**
-**
-** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
-** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
-** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
-** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
-** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
-** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
-** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
-** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
-** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
-**
-** $QT_END_LICENSE$
-**
-****************************************************************************/
-
-#include <xkbcommon/xkbcommon.h>
-#include <xkbcommon/xkbcommon-keysyms.h>
-#include <string.h>
-
-int main()
-{
- xkb_rule_names names;
- names.rules = strdup("evdev");
- names.model = strdup("pc105");
- names.layout = strdup("us");
- names.variant = strdup("");
- names.options = strdup("");
-
- xkb_context *context = xkb_context_new(xkb_context_flags(0));
- if (context) {
- xkb_keymap * keymap = xkb_map_new_from_names(context, &names, xkb_map_compile_flags(0));
- if (keymap) {
- xkb_state *state = xkb_state_new(keymap);
- if (state)
- xkb_state_unref(state);
- xkb_map_unref(keymap);
- }
- xkb_context_unref(context);
- }
-
- return 0;
-}
diff --git a/config.tests/xkbcommon/xkbcommon.pro b/config.tests/xkbcommon/xkbcommon.pro
deleted file mode 100644
index af6668bc1..000000000
--- a/config.tests/xkbcommon/xkbcommon.pro
+++ /dev/null
@@ -1,12 +0,0 @@
-TARGET = xkbcommon
-QT = core
-
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += xkbcommon
-} else {
- LIBS += -lxkbcommon
-}
-
-# Input
-SOURCES += main.cpp
diff --git a/configure.json b/configure.json
new file mode 100644
index 000000000..42bfa9d9d
--- /dev/null
+++ b/configure.json
@@ -0,0 +1,6 @@
+{
+ "subconfigs": [
+ "src/client",
+ "src/compositor"
+ ]
+}
diff --git a/examples/wayland/custom-extension/client-common/client.pro b/examples/wayland/custom-extension/client-common/client.pro
index 9ba72bc9c..95b99578a 100644
--- a/examples/wayland/custom-extension/client-common/client.pro
+++ b/examples/wayland/custom-extension/client-common/client.pro
@@ -1,14 +1,7 @@
CONFIG += wayland-scanner
-CONFIG += link_pkgconfig
-
TARGET = custom-wayland
QT += waylandclient-private
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
WAYLANDCLIENTSOURCES += ../protocol/custom.xml
diff --git a/examples/wayland/custom-extension/compositor/compositor.pro b/examples/wayland/custom-extension/compositor/compositor.pro
index 4ffafdb8b..b0ff7b2f7 100644
--- a/examples/wayland/custom-extension/compositor/compositor.pro
+++ b/examples/wayland/custom-extension/compositor/compositor.pro
@@ -18,13 +18,6 @@ WAYLANDSERVERSOURCES += \
RESOURCES += compositor.qrc
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-server
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server
-}
-
TARGET = custom-compositor
HEADERS += \
diff --git a/examples/wayland/custom-extension/cpp-client/cpp-client.pro b/examples/wayland/custom-extension/cpp-client/cpp-client.pro
index 54fead078..b700f2367 100644
--- a/examples/wayland/custom-extension/cpp-client/cpp-client.pro
+++ b/examples/wayland/custom-extension/cpp-client/cpp-client.pro
@@ -1,17 +1,8 @@
QT += waylandclient-private gui-private
-
-CONFIG += c++11
CONFIG += wayland-scanner
-CONFIG += link_pkgconfig
WAYLANDCLIENTSOURCES += ../protocol/custom.xml
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
-
SOURCES += main.cpp \
../client-common/customextension.cpp
diff --git a/examples/wayland/custom-extension/qml-client/qml-client.pro b/examples/wayland/custom-extension/qml-client/qml-client.pro
index aec29d2b3..d45067e5a 100644
--- a/examples/wayland/custom-extension/qml-client/qml-client.pro
+++ b/examples/wayland/custom-extension/qml-client/qml-client.pro
@@ -1,19 +1,9 @@
TEMPLATE = app
-
QT += qml quick waylandclient-private
-
-CONFIG += c++11
CONFIG += wayland-scanner
-CONFIG += link_pkgconfig
WAYLANDCLIENTSOURCES += ../protocol/custom.xml
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
-
SOURCES += main.cpp \
../client-common/customextension.cpp
diff --git a/examples/wayland/server-buffer/client/client.pro b/examples/wayland/server-buffer/client/client.pro
index 6e5cc87e6..459a407a4 100644
--- a/examples/wayland/server-buffer/client/client.pro
+++ b/examples/wayland/server-buffer/client/client.pro
@@ -3,14 +3,6 @@ TARGET = client
INCLUDEPATH += .
QT += waylandclient-private
-
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-client
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-}
-
CONFIG += wayland-scanner
WAYLANDCLIENTSOURCES += ../share-buffer.xml
diff --git a/examples/wayland/server-buffer/compositor/compositor.pro b/examples/wayland/server-buffer/compositor/compositor.pro
index 28a781bd0..45240af91 100644
--- a/examples/wayland/server-buffer/compositor/compositor.pro
+++ b/examples/wayland/server-buffer/compositor/compositor.pro
@@ -1,12 +1,5 @@
QT += core-private gui-private quick-private waylandcompositor-private
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-server
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server
-}
-
SOURCES += \
main.cpp \
serverbufferitem.cpp
diff --git a/examples/wayland/wayland.pro b/examples/wayland/wayland.pro
index 2a5395004..6024dd2dd 100644
--- a/examples/wayland/wayland.pro
+++ b/examples/wayland/wayland.pro
@@ -1,17 +1,21 @@
+requires(qtHaveModule(waylandcompositor))
+requires(qtConfig(opengl))
TEMPLATE=subdirs
-contains(QT_CONFIG, opengl) {
- SUBDIRS += qwindow-compositor
- SUBDIRS += minimal-cpp
-}
+SUBDIRS += \
+ qwindow-compositor
+ minimal-cpp
-contains(QT_CONFIG, opengl):qtHaveModule(quick) {
+qtHaveModule(quick) {
SUBDIRS += minimal-qml
SUBDIRS += spanning-screens
SUBDIRS += pure-qml
SUBDIRS += multi-output
SUBDIRS += multi-screen
- SUBDIRS += custom-extension
- SUBDIRS += server-buffer
SUBDIRS += ivi-compositor
+ qtHaveModule(waylandclient) {
+ SUBDIRS += \
+ custom-extension \
+ server-buffer
+ }
}
diff --git a/qtwayland.pro b/qtwayland.pro
index f71b842d8..0401ab02f 100644
--- a/qtwayland.pro
+++ b/qtwayland.pro
@@ -1,38 +1,2 @@
requires(linux:!android)
-
-load(configure)
-qtCompileTest(wayland)
-qtCompileTest(xkbcommon)
-qtCompileTest(wayland_cursor)
-qtCompileTest(wayland_scanner)
-qtCompileTest(wayland_egl)
-qtCompileTest(brcm_egl)
-qtCompileTest(glx)
-qtCompileTest(xcomposite)
-qtCompileTest(drm_egl_server)
-qtCompileTest(libhybris_egl_server)
-
load(qt_parts)
-
-!config_wayland {
- warning("QtWayland requires Wayland 1.6.0 or higher, QtWayland will not be built")
- SUBDIRS =
-}
-
-!config_xkbcommon {
- warning("No xkbcommon 0.2.0 or higher found, disabling support for it")
-}
-
-!config_wayland_scanner {
- warning("QtWayland requires wayland-scanner, QtWayland will not be built")
- SUBDIRS =
-}
-
-!config_wayland_cursor {
- warning("QtWayland requires wayland-cursor, QtWayland will not be built")
- SUBDIRS =
-}
-
-!config_wayland_egl {
- message("no wayland-egl support detected, cross-toolkit compatibility disabled");
-}
diff --git a/src/client/client.pro b/src/client/client.pro
index 5ae01c044..749e3b6a3 100644
--- a/src/client/client.pro
+++ b/src/client/client.pro
@@ -15,26 +15,17 @@ use_gold_linker: CONFIG += no_linker_version_script
CONFIG -= precompile_header
CONFIG += link_pkgconfig wayland-scanner
-contains(QT_CONFIG, opengl) {
+qtConfig(opengl) {
DEFINES += QT_WAYLAND_GL_SUPPORT
}
-config_xkbcommon {
- !contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG_PRIVATE += xkbcommon
- } else {
- LIBS_PRIVATE += -lxkbcommon
- }
+qtConfig(xkbcommon-evdev) {
+ QMAKE_USE_PRIVATE += xkbcommon_evdev
} else {
DEFINES += QT_NO_WAYLAND_XKB
}
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG_PRIVATE += wayland-client wayland-cursor
- contains(QT_CONFIG, glib): PKGCONFIG_PRIVATE += glib-2.0
-} else {
- LIBS_PRIVATE += -lwayland-client -lwayland-cursor $$QT_LIBS_GLIB
-}
+QMAKE_USE += wayland-client wayland-cursor
INCLUDEPATH += $$PWD/../shared
diff --git a/src/client/configure.json b/src/client/configure.json
new file mode 100644
index 000000000..b2a8fbc0b
--- /dev/null
+++ b/src/client/configure.json
@@ -0,0 +1,134 @@
+{
+ "module": "waylandclient",
+ "depends": [
+ "gui-private"
+ ],
+ "testDir": "../../config.tests",
+
+ "libraries": {
+ "wayland-client": {
+ "label": "Wayland client library",
+ "test": "wayland",
+ "sources": [
+ { "type": "pkgConfig", "args": "wayland-client" },
+ "-lwayland-client"
+ ]
+ },
+ "wayland-cursor": {
+ "label": "Wayland cursor library",
+ "test": "wayland_cursor",
+ "use": "wayland-client",
+ "sources": [
+ { "type": "pkgConfig", "args": "wayland-cursor" },
+ "-lwayland-cursor"
+ ]
+ },
+ "wayland-egl": {
+ "label": "Wayland EGL library",
+ "test": "wayland_egl",
+ "sources": [
+ { "type": "pkgConfig", "args": "wayland-egl" },
+ "-lwayland-egl"
+ ]
+ },
+ "xcomposite": {
+ "label": "XComposite",
+ "test": "xcomposite",
+ "sources": [
+ { "type": "pkgConfig", "args": "xcomposite" },
+ "-lxcomposite"
+ ]
+ },
+ "glx": {
+ "label": "GLX",
+ "test": "glx",
+ "sources": [
+ { "type": "pkgConfig", "args": "x11 gl" },
+ "-lX11 -lGl"
+ ]
+ }
+ },
+
+ "tests": {
+ "wayland-scanner": {
+ "label": "wayland-scanner",
+ "type": "compile",
+ "test": "wayland_scanner",
+ "use": "wayland-client"
+ },
+ "drm-egl-server": {
+ "label": "DRM EGL Server",
+ "type": "compile",
+ "test": "drm_egl_server",
+ "use": "egl"
+ },
+ "libhybris-egl-server": {
+ "label": "libhybris EGL Server",
+ "type": "compile",
+ "test": "libhybris_egl_server",
+ "use": "egl"
+ }
+ },
+
+ "features": {
+ "wayland-client": {
+ "label": "Qt Wayland Client",
+ "condition": "!config.win32 && libs.wayland-client && libs.wayland-cursor && tests.wayland-scanner",
+ "output": [ "privateFeature" ]
+ },
+ "wayland-egl": {
+ "label": "EGL",
+ "condition": "features.wayland-client && features.opengl && features.egl && libs.wayland-egl",
+ "output": [ "privateFeature" ]
+ },
+ "wayland-brcm": {
+ "label": "Rasberry Pi",
+ "condition": "features.wayland-client && features.eglfs_brcm",
+ "output": [ "privateFeature" ]
+ },
+ "xcomposite-egl": {
+ "label": "XComposite EGL",
+ "condition": "features.wayland-client && features.opengl && features.egl && libs.xcomposite",
+ "output": [ "privateFeature" ]
+ },
+ "xcomposite-glx": {
+ "label": "XComposite GLX",
+ "condition": "features.wayland-client && features.opengl && !features.opengles2 && libs.xcomposite && libs.glx",
+ "output": [ "privateFeature" ]
+ },
+ "drm-egl-server": {
+ "label": "DRM EGL",
+ "condition": "features.wayland-client && features.opengl && features.egl && tests.drm-egl-server",
+ "output": [ "privateFeature" ]
+ },
+ "libhybris-egl-server": {
+ "label": "libhybris EGL",
+ "condition": "features.wayland-client && features.opengl && features.egl && tests.libhybris-egl-server",
+ "output": [ "privateFeature" ]
+ }
+ },
+
+ "report": [
+ {
+ "type": "note",
+ "condition": "!libs.wayland-egl",
+ "message": "No wayland-egl support detected. Cross-toolkit compatibility disabled."
+ }
+ ],
+
+ "summary": [
+ {
+ "section": "Qt Wayland Drivers",
+ "condition": "features.wayland-client",
+ "entries": [
+ "wayland-egl",
+ "wayland-brcm",
+ "xcomposite-egl",
+ "xcomposite-glx",
+ "drm-egl-server",
+ "libhybris-egl-server"
+ ]
+ },
+ "wayland-client"
+ ]
+}
diff --git a/src/compositor/compositor.pro b/src/compositor/compositor.pro
index 251d757e2..935fc2527 100644
--- a/src/compositor/compositor.pro
+++ b/src/compositor/compositor.pro
@@ -5,19 +5,14 @@ QT = core gui-private
qtHaveModule(quick): QT += quick
-contains(QT_CONFIG, opengl):MODULE_DEFINES = QT_WAYLAND_COMPOSITOR_GL
+qtConfig(opengl):MODULE_DEFINES = QT_WAYLAND_COMPOSITOR_GL
CONFIG -= precompile_header
CONFIG += link_pkgconfig
-DEFINES += QT_WAYLAND_WINDOWMANAGER_SUPPORT
QMAKE_DOCS = $$PWD/doc/qtwaylandcompositor.qdocconf
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG_PRIVATE += wayland-server
-} else {
- LIBS += -lwayland-server
-}
+QMAKE_USE += wayland-server
INCLUDEPATH += ../shared
diff --git a/src/compositor/compositor_api/compositor_api.pri b/src/compositor/compositor_api/compositor_api.pri
index 0253cd0ee..1e9284c62 100644
--- a/src/compositor/compositor_api/compositor_api.pri
+++ b/src/compositor/compositor_api/compositor_api.pri
@@ -52,7 +52,7 @@ SOURCES += \
QT += core-private
-qtHaveModule(quick):contains(QT_CONFIG, opengl) {
+qtHaveModule(quick):qtConfig(opengl) {
DEFINES += QT_WAYLAND_COMPOSITOR_QUICK
SOURCES += \
diff --git a/src/compositor/configure.json b/src/compositor/configure.json
new file mode 100644
index 000000000..2ddccd98d
--- /dev/null
+++ b/src/compositor/configure.json
@@ -0,0 +1,99 @@
+{
+ "module": "waylandcompositor",
+ "depends": [
+ "gui-private"
+ ],
+ "testDir": "../../config.tests",
+
+ "libraries": {
+ "wayland-server": {
+ "label": "wayland-server",
+ "test": "wayland",
+ "sources": [
+ { "type": "pkgConfig", "args": "wayland-server" },
+ "-lwayland-server"
+ ]
+ },
+ "wayland-egl": {
+ "test": "wayland_egl",
+ "sources": [
+ { "type": "pkgConfig", "args": "wayland-egl" },
+ "-lwayland-egl"
+ ]
+ },
+ "xcomposite": {
+ "test": "xcomposite",
+ "sources": [
+ { "type": "pkgConfig", "args": "xcomposite" },
+ "-lxcomposite"
+ ]
+ },
+ "glx": {
+ "test": "glx",
+ "sources": [
+ { "type": "pkgConfig", "args": "x11 gl" },
+ "-lX11 -lGl"
+ ]
+ }
+ },
+
+ "tests": {
+ "wayland-scanner": {
+ "type": "compile",
+ "test": "wayland_scanner",
+ "use": "wayland-server"
+ },
+ "drm-egl-server": {
+ "type": "compile",
+ "test": "drm_egl_server",
+ "use": "egl"
+ },
+ "libhybris-egl-server": {
+ "type": "compile",
+ "test": "libhybris_egl_server",
+ "use": "egl"
+ }
+ },
+
+ "features": {
+ "wayland-server": {
+ "label": "Qt Wayland Compositor",
+ "condition": "!config.win32 && libs.wayland-server && tests.wayland-scanner",
+ "output": [ "privateFeature" ]
+ },
+ "wayland-egl": {
+ "label": "EGL",
+ "condition": "features.wayland-server && features.opengl && features.egl && libs.wayland-egl",
+ "output": [ "privateFeature" ]
+ },
+ "wayland-brcm": {
+ "label": "Rasberry Pi",
+ "condition": "features.wayland-server && features.eglfs_brcm",
+ "output": [ "privateFeature" ]
+ },
+ "xcomposite-egl": {
+ "label": "XComposite EGL",
+ "condition": "features.wayland-server && features.egl && features.opengl && libs.xcomposite",
+ "output": [ "privateFeature" ]
+ },
+ "xcomposite-glx": {
+ "label": "XComposite EGL",
+ "condition": "features.wayland-server && features.opengl && !features.opengles2 && libs.xcomposite && libs.glx",
+ "output": [ "privateFeature" ]
+ },
+ "drm-egl-server": {
+ "label": "DRM EGL",
+ "condition": "features.wayland-server && features.opengl && features.egl && tests.drm-egl-server",
+ "output": [ "privateFeature" ]
+ },
+ "libhybris-egl-server": {
+ "label": "libhybris EGL",
+ "condition": "features.wayland-server && features.opengl && features.egl && tests.libhybris-egl-server",
+ "output": [ "privateFeature" ]
+ }
+ },
+
+ "summary": [
+ "wayland-server"
+ ]
+}
diff --git a/src/compositor/wayland_wrapper/wayland_wrapper.pri b/src/compositor/wayland_wrapper/wayland_wrapper.pri
index fa5d76291..388303405 100644
--- a/src/compositor/wayland_wrapper/wayland_wrapper.pri
+++ b/src/compositor/wayland_wrapper/wayland_wrapper.pri
@@ -24,12 +24,8 @@ SOURCES += \
INCLUDEPATH += wayland_wrapper
-config_xkbcommon {
- !contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG_PRIVATE += xkbcommon
- } else {
- LIBS_PRIVATE += -lxkbcommon
- }
+qtConfig(xkbcommon-evdev) {
+ QMAKE_USE += xkbcommon_evdev
} else {
DEFINES += QT_NO_WAYLAND_XKB
}
diff --git a/src/hardwareintegration/client/brcm-egl/brcm-egl.pri b/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
index e4fd68f3b..64cb44677 100644
--- a/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
+++ b/src/hardwareintegration/client/brcm-egl/brcm-egl.pri
@@ -1,13 +1,6 @@
INCLUDEPATH += $$PWD
-contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-} else {
- LIBS += -lwayland-client
-}
-
-CONFIG += egl
+QMAKE_USE += egl wayland-client
QT += egl_support-private
SOURCES += $$PWD/qwaylandbrcmeglintegration.cpp \
diff --git a/src/hardwareintegration/client/drm-egl-server/drm-egl-server.pri b/src/hardwareintegration/client/drm-egl-server/drm-egl-server.pri
index c3d592a98..700e95e32 100644
--- a/src/hardwareintegration/client/drm-egl-server/drm-egl-server.pri
+++ b/src/hardwareintegration/client/drm-egl-server/drm-egl-server.pri
@@ -1,13 +1,6 @@
INCLUDEPATH += $$PWD
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-client
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-}
-
-CONFIG += egl
+QMAKE_USE += egl wayland-client
SOURCES += \
$$PWD/drmeglserverbufferintegration.cpp
diff --git a/src/hardwareintegration/client/libhybris-egl-server/libhybris-egl-server.pri b/src/hardwareintegration/client/libhybris-egl-server/libhybris-egl-server.pri
index 55e0ffd2a..bc8215745 100644
--- a/src/hardwareintegration/client/libhybris-egl-server/libhybris-egl-server.pri
+++ b/src/hardwareintegration/client/libhybris-egl-server/libhybris-egl-server.pri
@@ -1,11 +1,6 @@
INCLUDEPATH += $$PWD
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lEGL -lwayland-client
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += egl wayland-client
-}
+QMAKE_USE += egl wayland-client
SOURCES += \
$$PWD/libhybriseglserverbufferintegration.cpp
diff --git a/src/hardwareintegration/client/wayland-egl/wayland-egl.pri b/src/hardwareintegration/client/wayland-egl/wayland-egl.pri
index 276b7b54f..f812144a1 100644
--- a/src/hardwareintegration/client/wayland-egl/wayland-egl.pri
+++ b/src/hardwareintegration/client/wayland-egl/wayland-egl.pri
@@ -1,13 +1,8 @@
INCLUDEPATH += $$PWD
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client wayland-egl
-} else {
- LIBS += -lwayland-client -lwayland-egl
-}
+
+QMAKE_USE += egl wayland-client wayland-egl
DEFINES += QT_EGL_WAYLAND
-CONFIG += egl
QT += egl_support-private
SOURCES += $$PWD/qwaylandeglclientbufferintegration.cpp \
diff --git a/src/hardwareintegration/client/xcomposite-egl/xcomposite-egl.pri b/src/hardwareintegration/client/xcomposite-egl/xcomposite-egl.pri
index 3a5fcb543..f2beb1e03 100644
--- a/src/hardwareintegration/client/xcomposite-egl/xcomposite-egl.pri
+++ b/src/hardwareintegration/client/xcomposite-egl/xcomposite-egl.pri
@@ -1,15 +1,9 @@
INCLUDEPATH += $$PWD
include($$PWD/../xcomposite_share/xcomposite_share.pri)
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client xcomposite x11
-} else {
- LIBS += -lXcomposite -lX11
-}
+QMAKE_USE += egl wayland-client
QT += egl_support-private
-CONFIG += egl
SOURCES += \
$$PWD/qwaylandxcompositeeglcontext.cpp \
diff --git a/src/hardwareintegration/client/xcomposite-glx/xcomposite-glx.pri b/src/hardwareintegration/client/xcomposite-glx/xcomposite-glx.pri
index bc072bf05..067378af1 100644
--- a/src/hardwareintegration/client/xcomposite-glx/xcomposite-glx.pri
+++ b/src/hardwareintegration/client/xcomposite-glx/xcomposite-glx.pri
@@ -1,12 +1,7 @@
INCLUDEPATH += $$PWD
include ($$PWD/../xcomposite_share/xcomposite_share.pri)
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client xcomposite gl x11
-} else {
- LIBS += -lXcomposite -lGL -lX11
-}
+QMAKE_USE += wayland-client glx
QT += glx_support-private
diff --git a/src/hardwareintegration/client/xcomposite_share/xcomposite_share.pri b/src/hardwareintegration/client/xcomposite_share/xcomposite_share.pri
index be3c9fc1b..f255f5c57 100644
--- a/src/hardwareintegration/client/xcomposite_share/xcomposite_share.pri
+++ b/src/hardwareintegration/client/xcomposite_share/xcomposite_share.pri
@@ -1,5 +1,6 @@
INCLUDEPATH += $$PWD
+QMAKE_USE += xcomposite
CONFIG += wayland-scanner
WAYLANDCLIENTSOURCES += $$PWD/../../../extensions/xcomposite.xml
diff --git a/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri b/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri
index f4780710a..2658e84b2 100644
--- a/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri
+++ b/src/hardwareintegration/compositor/brcm-egl/brcm-egl.pri
@@ -4,12 +4,7 @@ INCLUDEPATH += $$PWD
DEFINES += QT_NO_OPENGL_ES_3
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server
-} else {
- LIBS += -lwayland-server
-}
+QMAKE_USE_PRIVATE += wayland-server
for(p, QMAKE_LIBDIR_EGL) {
exists($$p):LIBS += -L$$p
diff --git a/src/hardwareintegration/compositor/drm-egl-server/drm-egl-server.pri b/src/hardwareintegration/compositor/drm-egl-server/drm-egl-server.pri
index 2ed5db686..7d6841748 100644
--- a/src/hardwareintegration/compositor/drm-egl-server/drm-egl-server.pri
+++ b/src/hardwareintegration/compositor/drm-egl-server/drm-egl-server.pri
@@ -1,13 +1,6 @@
INCLUDEPATH += $$PWD
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-server
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server
-}
-
-CONFIG += egl
+QMAKE_USE_PRIVATE += egl wayland-server
SOURCES += \
$$PWD/drmeglserverbufferintegration.cpp
diff --git a/src/hardwareintegration/compositor/libhybris-egl-server/libhybris-egl-server.pri b/src/hardwareintegration/compositor/libhybris-egl-server/libhybris-egl-server.pri
index 5cbcb6b7c..125be9c54 100644
--- a/src/hardwareintegration/compositor/libhybris-egl-server/libhybris-egl-server.pri
+++ b/src/hardwareintegration/compositor/libhybris-egl-server/libhybris-egl-server.pri
@@ -1,13 +1,6 @@
INCLUDEPATH += $$PWD
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-server
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server
-}
-
-CONFIG += egl
+QMAKE_USE_PRIVATE += egl wayland-server
SOURCES += \
$$PWD/libhybriseglserverbufferintegration.cpp
diff --git a/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri b/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri
index f36474890..df3aead3e 100644
--- a/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri
+++ b/src/hardwareintegration/compositor/wayland-egl/wayland-egl.pri
@@ -1,13 +1,7 @@
INCLUDEPATH += $$PWD
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-server wayland-egl
-} else {
- LIBS += -lwayland-egl -lwayland-server
-}
+QMAKE_USE_PRIVATE += wayland-server wayland-egl
-CONFIG += egl
QT += egl_support-private
SOURCES += \
diff --git a/src/hardwareintegration/compositor/xcomposite-egl/xcomposite-egl.pri b/src/hardwareintegration/compositor/xcomposite-egl/xcomposite-egl.pri
index d748c2b57..6d0f81659 100644
--- a/src/hardwareintegration/compositor/xcomposite-egl/xcomposite-egl.pri
+++ b/src/hardwareintegration/compositor/xcomposite-egl/xcomposite-egl.pri
@@ -1,13 +1,6 @@
include($$PWD/../xcomposite_share/xcomposite_share.pri)
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += xcomposite x11 wayland-server
-} else {
- LIBS += -lXcomposite -lX11
-}
-
-CONFIG += egl
+QMAKE_USE_PRIVATE += egl wayland-server x11
INCLUDEPATH += $$PWD
diff --git a/src/hardwareintegration/compositor/xcomposite-glx/xcomposite-glx.pri b/src/hardwareintegration/compositor/xcomposite-glx/xcomposite-glx.pri
index ccbbe46a6..423ae1815 100644
--- a/src/hardwareintegration/compositor/xcomposite-glx/xcomposite-glx.pri
+++ b/src/hardwareintegration/compositor/xcomposite-glx/xcomposite-glx.pri
@@ -1,11 +1,6 @@
include($$PWD/../xcomposite_share/xcomposite_share.pri)
-!contains(QT_CONFIG, no-pkg-config) {
- CONFIG += link_pkgconfig
- PKGCONFIG += xcomposite gl x11 wayland-server
-} else {
- LIBS += -lXcomposite -lGL -lX11
-}
+QMAKE_USE_PRIVATE += wayland-server glx
INCLUDEPATH += $$PWD
diff --git a/src/hardwareintegration/compositor/xcomposite_share/xcomposite_share.pri b/src/hardwareintegration/compositor/xcomposite_share/xcomposite_share.pri
index 06937c412..69ab6aa10 100644
--- a/src/hardwareintegration/compositor/xcomposite_share/xcomposite_share.pri
+++ b/src/hardwareintegration/compositor/xcomposite_share/xcomposite_share.pri
@@ -1,5 +1,6 @@
INCLUDEPATH += $$PWD
+QMAKE_USE += xcomposite
CONFIG += wayland-scanner
WAYLANDSERVERSOURCES += $$PWD/../../../extensions/xcomposite.xml $$PWD/../../../3rdparty/protocol/wayland.xml
diff --git a/src/plugins/decorations/bradient/bradient.pro b/src/plugins/decorations/bradient/bradient.pro
index 0f62db9cc..843149e08 100644
--- a/src/plugins/decorations/bradient/bradient.pro
+++ b/src/plugins/decorations/bradient/bradient.pro
@@ -5,12 +5,7 @@ OTHER_FILES += \
SOURCES += main.cpp
-contains(QT_CONFIG, no-pkg-config) {
- LIBS += -lwayland-client
-} else {
- CONFIG += link_pkgconfig
- PKGCONFIG += wayland-client
-}
+QMAKE_USE += wayland-client
PLUGIN_TYPE = wayland-decoration-client
load(qt_plugin)
diff --git a/src/plugins/hardwareintegration/client/client.pro b/src/plugins/hardwareintegration/client/client.pro
index 37a90ab0d..a5967c710 100644
--- a/src/plugins/hardwareintegration/client/client.pro
+++ b/src/plugins/hardwareintegration/client/client.pro
@@ -1,21 +1,15 @@
TEMPLATE=subdirs
+QT_FOR_CONFIG += waylandclient-private
-config_wayland_egl: \
+qtConfig(wayland-egl): \
SUBDIRS += wayland-egl
-
-config_brcm_egl: \
+qtConfig(wayland-brcm): \
SUBDIRS += brcm-egl
-
-config_xcomposite {
- contains(QT_CONFIG, egl): \
- SUBDIRS += xcomposite-egl
-
- !contains(QT_CONFIG, opengles2):config_glx: \
- SUBDIRS += xcomposite-glx
-}
-
-config_drm_egl_server: \
+qtConfig(xcomposite-egl): \
+ SUBDIRS += xcomposite-egl
+qtConfig(xcomposite-glx): \
+ SUBDIRS += xcomposite-glx
+qtConfig(drm-egl-server): \
SUBDIRS += drm-egl-server
-
-config_libhybris_egl_server: \
+qtConfig(libhybris-egl-server): \
SUBDIRS += libhybris-egl-server
diff --git a/src/plugins/hardwareintegration/compositor/compositor.pro b/src/plugins/hardwareintegration/compositor/compositor.pro
index 1ecfe37a0..299116257 100644
--- a/src/plugins/hardwareintegration/compositor/compositor.pro
+++ b/src/plugins/hardwareintegration/compositor/compositor.pro
@@ -1,20 +1,15 @@
TEMPLATE = subdirs
+QT_FOR_CONFIG += waylandcompositor-private
-config_wayland_egl: \
+qtConfig(wayland-egl): \
SUBDIRS += wayland-egl
-config_brcm_egl: \
+qtConfig(wayland-brcm): \
SUBDIRS += brcm-egl
-
-config_xcomposite {
- contains(QT_CONFIG, egl): \
- SUBDIRS += xcomposite-egl
-
- !contains(QT_CONFIG, opengles2):config_glx: \
- SUBDIRS += xcomposite-glx
-}
-
-config_drm_egl_server: \
+qtConfig(xcomposite-egl): \
+ SUBDIRS += xcomposite-egl
+qtConfig(xcomposite-glx): \
+ SUBDIRS += xcomposite-glx
+qtConfig(drm-egl-server): \
SUBDIRS += drm-egl-server
-
-config_libhybris_egl_server: \
+qtConfig(libhybris-egl-server): \
SUBDIRS += libhybris-egl-server
diff --git a/src/plugins/platforms/platforms.pro b/src/plugins/platforms/platforms.pro
index 4bee89291..ec589ae83 100644
--- a/src/plugins/platforms/platforms.pro
+++ b/src/plugins/platforms/platforms.pro
@@ -1,19 +1,17 @@
TEMPLATE=subdirs
CONFIG+=ordered
+QT_FOR_CONFIG += waylandclient-private
SUBDIRS += qwayland-generic
-config_wayland_egl {
+qtConfig(wayland-egl): \
SUBDIRS += qwayland-egl
-}
#The following integrations are only useful with QtWaylandCompositor
-config_brcm_egl: \
+qtConfig(wayland-brcm): \
SUBDIRS += qwayland-brcm-egl
-config_xcomposite {
- contains(QT_CONFIG, egl): \
- SUBDIRS += qwayland-xcomposite-egl
- !contains(QT_CONFIG, opengles2):config_glx: \
- SUBDIRS += qwayland-xcomposite-glx
-}
+qtConfig(xcomposite-egl): \
+ SUBDIRS += qwayland-xcomposite-egl
+qtConfig(xcomposite-glx): \
+ SUBDIRS += qwayland-xcomposite-glx
diff --git a/src/plugins/shellintegration/ivi-shell/ivi-shell.pro b/src/plugins/shellintegration/ivi-shell/ivi-shell.pro
index 8fd774736..d254b9fc1 100644
--- a/src/plugins/shellintegration/ivi-shell/ivi-shell.pro
+++ b/src/plugins/shellintegration/ivi-shell/ivi-shell.pro
@@ -1,22 +1,13 @@
PLUGIN_TYPE = wayland-shell-integration
load(qt_plugin)
-QT += waylandclient-private
+QT += gui-private waylandclient-private
CONFIG += wayland-scanner
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client wayland-cursor
- CONFIG += link_pkgconfig
-} else {
- LIBS += -lwayland-client -lwayland-cursor
-}
+QMAKE_USE += wayland-client
-config_xkbcommon {
- !contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += xkbcommon
- } else {
- LIBS += -lxkbcommon
- }
+qtConfig(xkbcommon-evdev) {
+ QMAKE_USE += xkbcommon_evdev
} else {
DEFINES += QT_NO_WAYLAND_XKB
}
diff --git a/src/src.pro b/src/src.pro
index bf5ffe36a..4ecbc71b9 100644
--- a/src/src.pro
+++ b/src/src.pro
@@ -1,25 +1,33 @@
TEMPLATE=subdirs
+include($$OUT_PWD/client/qtwaylandclient-config.pri)
+include($$OUT_PWD/compositor/qtwaylandcompositor-config.pri)
+QT_FOR_CONFIG += waylandclient-private waylandcompositor-private
-sub_qtwaylandscanner.subdir = qtwaylandscanner
-sub_qtwaylandscanner.target = sub-qtwaylandscanner
-SUBDIRS += sub_qtwaylandscanner
+qtConfig(wayland-client) {
+ sub_qtwaylandscanner.subdir = qtwaylandscanner
+ sub_qtwaylandscanner.target = sub-qtwaylandscanner
+ SUBDIRS += sub_qtwaylandscanner
-sub_compositor.subdir = compositor
-sub_compositor.depends = sub-qtwaylandscanner
-sub_compositor.target = sub-compositor
-SUBDIRS += sub_compositor
+ sub_client.subdir = client
+ sub_client.depends = sub-qtwaylandscanner
+ sub_client.target = sub-client
+ SUBDIRS += sub_client
-sub_imports.subdir = imports
-sub_imports.depends += sub-compositor
-sub_imports.target = sub-imports
-SUBDIRS += sub_imports
+ qtConfig(wayland-server) {
+ sub_compositor.subdir = compositor
+ sub_compositor.depends = sub-qtwaylandscanner
+ sub_compositor.target = sub-compositor
+ SUBDIRS += sub_compositor
-sub_client.subdir = client
-sub_client.depends = sub-qtwaylandscanner
-sub_client.target = sub-client
-SUBDIRS += sub_client
+ sub_imports.subdir = imports
+ sub_imports.depends += sub-compositor
+ sub_imports.target = sub-imports
+ SUBDIRS += sub_imports
+
+ sub_plugins.subdir = plugins
+ sub_plugins.depends = sub-qtwaylandscanner sub-client sub-compositor
+ sub_plugins.target = sub-plugins
+ SUBDIRS += sub_plugins
+ }
+}
-sub_plugins.subdir = plugins
-sub_plugins.depends = sub-qtwaylandscanner sub-client sub-compositor
-sub_plugins.target = sub-plugins
-SUBDIRS += sub_plugins
diff --git a/tests/auto/auto.pro b/tests/auto/auto.pro
index a704c7322..79ad29bd5 100644
--- a/tests/auto/auto.pro
+++ b/tests/auto/auto.pro
@@ -1,5 +1,7 @@
TEMPLATE=subdirs
+QT_FOR_CONFIG += waylandclient-private
-SUBDIRS += client
-SUBDIRS += cmake
-SUBDIRS += compositor
+qtConfig(wayland-client): \
+ SUBDIRS += client cmake
+qtHaveModule(waylandcompositor): \
+ SUBDIRS += compositor
diff --git a/tests/auto/client/client/client.pro b/tests/auto/client/client/client.pro
index 006d130a0..34fc67474 100644
--- a/tests/auto/client/client/client.pro
+++ b/tests/auto/client/client/client.pro
@@ -4,11 +4,7 @@ TARGET = tst_client
QT += testlib
QT += core-private gui-private
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client wayland-server
-} else {
- LIBS += -lwayland-client -lwayland-server
-}
+QMAKE_USE += wayland-client wayland-server
CONFIG += wayland-scanner
WAYLANDSERVERSOURCES += \
diff --git a/tests/auto/compositor/compositor/compositor.pro b/tests/auto/compositor/compositor/compositor.pro
index 1d4456f6f..c0b919631 100644
--- a/tests/auto/compositor/compositor/compositor.pro
+++ b/tests/auto/compositor/compositor/compositor.pro
@@ -5,18 +5,10 @@ TARGET = tst_compositor
QT += testlib
QT += core-private gui-private waylandcompositor waylandcompositor-private
-!contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG += wayland-client wayland-server
-} else {
- LIBS += -lwayland-client -lwayland-server
-}
+QMAKE_USE += wayland-client wayland-server
-config_xkbcommon {
- !contains(QT_CONFIG, no-pkg-config) {
- PKGCONFIG_PRIVATE += xkbcommon
- } else {
- LIBS_PRIVATE += -lxkbcommon
- }
+qtConfig(xkbcommon-evdev) {
+ QMAKE_USE += xkbcommon_evdev
} else {
DEFINES += QT_NO_WAYLAND_XKB
}