From 160184d6a5d0b89d9b885581f2d93a5650eede0a Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Mon, 24 Feb 2020 14:24:25 +0100 Subject: CMake: Fix X11 and xkb library usage in the platform projects This is a prerequisite for building the bundled 3rd party libraries. Because the feature evaluation will be moved into src/CMakeLists.txt, some of the X11 packages were found in the src dir, and then a second time inside the x11-related projects. These qt_find_package calls in the x11 related projects tried to promote the imported targets to global, which failed, because they were created in a different directory scope. To avoid this, the special case qt_find_package calls are removed from the nested projects. Also, fix the mapping of some of the x11 libraries to be correct - xkbcommon_x11 was incorrectly mapped to XKB::XKB instead of the xkb common x11 library - xlib was mapped to xcb, whereas X11 is the correct CMake target Change-Id: I30781b2ecbdd478c98419b14baa0492037e49c61 Reviewed-by: Leander Beernaert Reviewed-by: Simon Hausmann --- src/platformsupport/eglconvenience/.prev_CMakeLists.txt | 2 +- src/platformsupport/eglconvenience/CMakeLists.txt | 2 +- src/platformsupport/glxconvenience/.prev_CMakeLists.txt | 2 +- src/platformsupport/glxconvenience/CMakeLists.txt | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/platformsupport') diff --git a/src/platformsupport/eglconvenience/.prev_CMakeLists.txt b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt index f8efacd7cb..c00cc30d62 100644 --- a/src/platformsupport/eglconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/eglconvenience/.prev_CMakeLists.txt @@ -36,7 +36,7 @@ qt_extend_target(EglSupport CONDITION QT_FEATURE_egl_x11 SOURCES qxlibeglintegration.cpp qxlibeglintegration_p.h LIBRARIES - X11::XCB + X11::X11 ) qt_extend_target(EglSupport CONDITION NOT QT_FEATURE_egl_x11 diff --git a/src/platformsupport/eglconvenience/CMakeLists.txt b/src/platformsupport/eglconvenience/CMakeLists.txt index b18a1470ec..1858dc7e90 100644 --- a/src/platformsupport/eglconvenience/CMakeLists.txt +++ b/src/platformsupport/eglconvenience/CMakeLists.txt @@ -39,7 +39,7 @@ qt_extend_target(EglSupport CONDITION QT_FEATURE_egl_x11 SOURCES qxlibeglintegration.cpp qxlibeglintegration_p.h LIBRARIES - X11::XCB + X11::X11 ) qt_extend_target(EglSupport CONDITION NOT QT_FEATURE_egl_x11 diff --git a/src/platformsupport/glxconvenience/.prev_CMakeLists.txt b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt index f9a2fed5b2..d3d2c87910 100644 --- a/src/platformsupport/glxconvenience/.prev_CMakeLists.txt +++ b/src/platformsupport/glxconvenience/.prev_CMakeLists.txt @@ -14,7 +14,7 @@ qt_add_module(GlxSupport PUBLIC_LIBRARIES Qt::CorePrivate Qt::GuiPrivate - X11::XCB + X11::X11 ) #### Keys ignored in scope 1:.:.:glxconvenience.pro:: diff --git a/src/platformsupport/glxconvenience/CMakeLists.txt b/src/platformsupport/glxconvenience/CMakeLists.txt index 00bc78d429..00d2e6c754 100644 --- a/src/platformsupport/glxconvenience/CMakeLists.txt +++ b/src/platformsupport/glxconvenience/CMakeLists.txt @@ -16,7 +16,7 @@ qt_add_module(GlxSupport PUBLIC_LIBRARIES Qt::CorePrivate Qt::GuiPrivate - X11::X11 # special case + X11::X11 ) #### Keys ignored in scope 1:.:.:glxconvenience.pro:: -- cgit v1.2.3