From 118b456c6b6bb81b879b4c8940414c0c10a57d4a Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Fri, 1 Dec 2017 19:25:43 +0100 Subject: configure: convert xlib to a proper library definition Change-Id: I1623aee9e8632e4bfd466e09e275cc23f94c6dab Reviewed-by: Gatis Paeglis --- src/gui/configure.json | 30 ++++++++++++---------- .../eglconvenience/eglconvenience.pro | 2 +- .../glxconvenience/glxconvenience.pro | 2 +- 3 files changed, 18 insertions(+), 16 deletions(-) (limited to 'src') diff --git a/src/gui/configure.json b/src/gui/configure.json index 3d0f75254a..123ef208a2 100644 --- a/src/gui/configure.json +++ b/src/gui/configure.json @@ -454,6 +454,19 @@ { "type": "pkgConfig", "args": "wayland-server" } ] }, + "xlib": { + "label": "XLib", + "test": { + "include": "X11/Xlib.h", + "main": [ + "Display *d = XOpenDisplay(NULL);", + "XCloseDisplay(d);" + ] + }, + "sources": [ + { "type": "makeSpec", "spec": "X11" } + ] + }, "x11sm": { "label": "X11 session management", "sources": [ @@ -626,7 +639,8 @@ "test": "x11/xrender", "sources": [ "-lXrender" - ] + ], + "use": "xlib" } }, @@ -913,18 +927,6 @@ "pkg-config-variable": "prefix", "value": "/usr", "log": "value" - }, - "xlib": { - "label": "XLib", - "type": "compile", - "test": { - "include": "X11/Xlib.h", - "main": [ - "Display *d = XOpenDisplay(NULL);", - "XCloseDisplay(d);" - ], - "qmake": "CONFIG += x11" - } } }, @@ -1374,7 +1376,7 @@ "xlib": { "label": "XLib", "autoDetect": "!config.darwin || features.xcb", - "condition": "tests.xlib", + "condition": "libs.xlib", "output": [ "privateFeature" ] }, "texthtmlparser": { diff --git a/src/platformsupport/eglconvenience/eglconvenience.pro b/src/platformsupport/eglconvenience/eglconvenience.pro index 4301d63574..aae72e8e27 100644 --- a/src/platformsupport/eglconvenience/eglconvenience.pro +++ b/src/platformsupport/eglconvenience/eglconvenience.pro @@ -34,7 +34,7 @@ qtConfig(xlib) { qxlibeglintegration_p.h SOURCES += \ qxlibeglintegration.cpp - LIBS_PRIVATE += $$QMAKE_LIBS_X11 + QMAKE_USE_PRIVATE += xlib } CONFIG += egl diff --git a/src/platformsupport/glxconvenience/glxconvenience.pro b/src/platformsupport/glxconvenience/glxconvenience.pro index 58fa9fc479..8367dc5e31 100644 --- a/src/platformsupport/glxconvenience/glxconvenience.pro +++ b/src/platformsupport/glxconvenience/glxconvenience.pro @@ -6,7 +6,7 @@ CONFIG += static internal_module DEFINES += QT_NO_CAST_FROM_ASCII -LIBS_PRIVATE += $$QMAKE_LIBS_X11 +QMAKE_USE_PRIVATE += xlib HEADERS += qglxconvenience_p.h SOURCES += qglxconvenience.cpp -- cgit v1.2.3