XCB::CURSOR becomes a required dependency
It was only optional because build.kde.org did not provide it when the dependency got introduced.
This commit is contained in:
parent
be339d7ed3
commit
8a9bbf7ca3
5 changed files with 3 additions and 29 deletions
|
@ -196,9 +196,9 @@ find_package(XCB
|
||||||
IMAGE
|
IMAGE
|
||||||
SHM
|
SHM
|
||||||
GLX
|
GLX
|
||||||
|
CURSOR
|
||||||
OPTIONAL_COMPONENTS
|
OPTIONAL_COMPONENTS
|
||||||
ICCCM
|
ICCCM
|
||||||
CURSOR
|
|
||||||
)
|
)
|
||||||
set_package_properties(XCB PROPERTIES TYPE REQUIRED)
|
set_package_properties(XCB PROPERTIES TYPE REQUIRED)
|
||||||
|
|
||||||
|
@ -207,7 +207,6 @@ if (XCB_ICCCM_VERSION VERSION_LESS "0.4")
|
||||||
set(XCB_ICCCM_FOUND FALSE)
|
set(XCB_ICCCM_FOUND FALSE)
|
||||||
endif()
|
endif()
|
||||||
add_feature_info("XCB-ICCCM" XCB_ICCCM_FOUND "Required for building test applications for KWin")
|
add_feature_info("XCB-ICCCM" XCB_ICCCM_FOUND "Required for building test applications for KWin")
|
||||||
add_feature_info("XCB-CURSOR" XCB_CURSOR_FOUND "Required for XCursor support")
|
|
||||||
|
|
||||||
set(HAVE_XCB_SYNC TRUE)
|
set(HAVE_XCB_SYNC TRUE)
|
||||||
if (XCB_VERSION VERSION_LESS "1.10")
|
if (XCB_VERSION VERSION_LESS "1.10")
|
||||||
|
@ -308,12 +307,6 @@ if(NOT KWIN_HAVE_EGL)
|
||||||
set(HAVE_GBM FALSE)
|
set(HAVE_GBM FALSE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(XCB_CURSOR_FOUND)
|
|
||||||
set(HAVE_XCB_CURSOR ${XCB_CURSOR_FOUND})
|
|
||||||
else()
|
|
||||||
set(HAVE_XCB_CURSOR FALSE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
include(CheckIncludeFiles)
|
include(CheckIncludeFiles)
|
||||||
check_include_files(unistd.h HAVE_UNISTD_H)
|
check_include_files(unistd.h HAVE_UNISTD_H)
|
||||||
check_include_files(malloc.h HAVE_MALLOC_H)
|
check_include_files(malloc.h HAVE_MALLOC_H)
|
||||||
|
@ -538,6 +531,7 @@ set(kwin_XCB_LIBS
|
||||||
XCB::KEYSYMS
|
XCB::KEYSYMS
|
||||||
XCB::SHM
|
XCB::SHM
|
||||||
XCB::GLX
|
XCB::GLX
|
||||||
|
XCB::CURSOR
|
||||||
)
|
)
|
||||||
|
|
||||||
set(kwin_WAYLAND_LIBS
|
set(kwin_WAYLAND_LIBS
|
||||||
|
@ -555,10 +549,6 @@ if(KWIN_BUILD_ACTIVITIES)
|
||||||
set(kwin_KDE_LIBS ${kwin_KDE_LIBS} KF5::Activities)
|
set(kwin_KDE_LIBS ${kwin_KDE_LIBS} KF5::Activities)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(HAVE_XCB_CURSOR)
|
|
||||||
set(kwin_XCB_LIBS ${kwin_XCB_LIBS} XCB::CURSOR)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(kwinLibs
|
set(kwinLibs
|
||||||
${kwin_OWN_LIBS}
|
${kwin_OWN_LIBS}
|
||||||
${kwin_QT_LIBS}
|
${kwin_QT_LIBS}
|
||||||
|
|
|
@ -12,7 +12,6 @@
|
||||||
#cmakedefine01 HAVE_WAYLAND_CURSOR
|
#cmakedefine01 HAVE_WAYLAND_CURSOR
|
||||||
#cmakedefine01 HAVE_XKB
|
#cmakedefine01 HAVE_XKB
|
||||||
#cmakedefine01 HAVE_INPUT
|
#cmakedefine01 HAVE_INPUT
|
||||||
#cmakedefine01 HAVE_XCB_CURSOR
|
|
||||||
#cmakedefine01 HAVE_XCB_SYNC
|
#cmakedefine01 HAVE_XCB_SYNC
|
||||||
#cmakedefine01 HAVE_X11_XCB
|
#cmakedefine01 HAVE_X11_XCB
|
||||||
#cmakedefine01 HAVE_DRM
|
#cmakedefine01 HAVE_DRM
|
||||||
|
|
|
@ -35,9 +35,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#include <QTimer>
|
#include <QTimer>
|
||||||
// xcb
|
// xcb
|
||||||
#include <xcb/xfixes.h>
|
#include <xcb/xfixes.h>
|
||||||
#if HAVE_XCB_CURSOR
|
|
||||||
#include <xcb/xcb_cursor.h>
|
#include <xcb/xcb_cursor.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
namespace KWin
|
namespace KWin
|
||||||
{
|
{
|
||||||
|
@ -353,7 +351,6 @@ xcb_cursor_t X11Cursor::createCursor(const QByteArray &name)
|
||||||
if (name.isEmpty()) {
|
if (name.isEmpty()) {
|
||||||
return XCB_CURSOR_NONE;
|
return XCB_CURSOR_NONE;
|
||||||
}
|
}
|
||||||
#if HAVE_XCB_CURSOR
|
|
||||||
xcb_cursor_context_t *ctx;
|
xcb_cursor_context_t *ctx;
|
||||||
if (xcb_cursor_context_new(connection(), defaultScreen(), &ctx) < 0) {
|
if (xcb_cursor_context_new(connection(), defaultScreen(), &ctx) < 0) {
|
||||||
return XCB_CURSOR_NONE;
|
return XCB_CURSOR_NONE;
|
||||||
|
@ -460,9 +457,6 @@ xcb_cursor_t X11Cursor::createCursor(const QByteArray &name)
|
||||||
}
|
}
|
||||||
xcb_cursor_context_free(ctx);
|
xcb_cursor_context_free(ctx);
|
||||||
return cursor;
|
return cursor;
|
||||||
#else
|
|
||||||
return XCB_CURSOR_NONE;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QByteArray Cursor::cursorName(Qt::CursorShape shape) const
|
QByteArray Cursor::cursorName(Qt::CursorShape shape) const
|
||||||
|
|
|
@ -16,6 +16,7 @@ kf5_add_kdeinit_executable( kwin_rules_dialog ${kwin_rules_dialog_KDEINIT_SRCS})
|
||||||
set(kwin_kcm_rules_XCB_LIBS
|
set(kwin_kcm_rules_XCB_LIBS
|
||||||
XCB::XCB
|
XCB::XCB
|
||||||
XCB::XFIXES
|
XCB::XFIXES
|
||||||
|
XCB::CURSOR
|
||||||
)
|
)
|
||||||
|
|
||||||
set(kcm_libs
|
set(kcm_libs
|
||||||
|
@ -34,10 +35,6 @@ if(KWIN_BUILD_ACTIVITIES)
|
||||||
set(kcm_libs ${kcm_libs} KF5::Activities)
|
set(kcm_libs ${kcm_libs} KF5::Activities)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(HAVE_XCB_CURSOR)
|
|
||||||
set(kwin_kcm_rules_XCB_LIBS ${kwin_kcm_rules_XCB_LIBS} XCB::CURSOR)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
target_link_libraries(kdeinit_kwin_rules_dialog ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS})
|
target_link_libraries(kdeinit_kwin_rules_dialog ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS})
|
||||||
|
|
||||||
install(TARGETS kdeinit_kwin_rules_dialog ${INSTALL_TARGETS_DEFAULT_ARGS} )
|
install(TARGETS kdeinit_kwin_rules_dialog ${INSTALL_TARGETS_DEFAULT_ARGS} )
|
||||||
|
|
|
@ -1382,12 +1382,6 @@ QString Workspace::supportInformation() const
|
||||||
support.append(yes);
|
support.append(yes);
|
||||||
#else
|
#else
|
||||||
support.append(no);
|
support.append(no);
|
||||||
#endif
|
|
||||||
support.append(QStringLiteral("HAVE_XCB_CURSOR: "));
|
|
||||||
#if HAVE_XCB_CURSOR
|
|
||||||
support.append(yes);
|
|
||||||
#else
|
|
||||||
support.append(no);
|
|
||||||
#endif
|
#endif
|
||||||
support.append(QStringLiteral("HAVE_XCB_SYNC: "));
|
support.append(QStringLiteral("HAVE_XCB_SYNC: "));
|
||||||
#if HAVE_XCB_SYNC
|
#if HAVE_XCB_SYNC
|
||||||
|
|
Loading…
Reference in a new issue