Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:junknot
libkscreen2
libkscreen-nowayland.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File libkscreen-nowayland.patch of Package libkscreen2
diff -ruN libkscreen-5.27.6/CMakeLists.txt libkscreen-5.27.6.nowayland/CMakeLists.txt --- libkscreen-5.27.6/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/CMakeLists.txt 2023-06-24 05:16:09.541508803 -0400 @@ -28,25 +28,13 @@ include(KDEGitCommitHooks) include(ECMDeprecationSettings) -find_package(Qt${QT_MAJOR_VERSION} ${QT_MIN_VERSION} CONFIG REQUIRED Core DBus Gui Test WaylandClient) +find_package(Qt${QT_MAJOR_VERSION} ${QT_MIN_VERSION} CONFIG REQUIRED Core DBus Gui Test) if (QT_MAJOR_VERSION EQUAL "5") find_package(Qt5 CONFIG REQUIRED X11Extras) - find_package(QtWaylandScanner REQUIRED) endif() -find_package(WaylandScanner) -# Wayland backend -find_package(KF5Wayland ${KF5_MIN_VERSION} CONFIG REQUIRED) -add_feature_info("KF5Wayland" KF5Wayland_FOUND "Required for building libkscreen's KWayland backend") find_package(KF5Config ${KF5_MIN_VERSION} CONFIG REQUIRED) -find_package(PlasmaWaylandProtocols 1.10.0 CONFIG) -set_package_properties(PlasmaWaylandProtocols PROPERTIES TYPE REQUIRED) - -find_package(Wayland 1.15 COMPONENTS Client) -set_package_properties(Wayland PROPERTIES - TYPE REQUIRED - ) # xrandr backend diff -ruN libkscreen-5.27.6/autotests/CMakeLists.txt libkscreen-5.27.6.nowayland/autotests/CMakeLists.txt --- libkscreen-5.27.6/autotests/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/autotests/CMakeLists.txt 2023-06-24 05:13:20.374927615 -0400 @@ -1,13 +1,13 @@ add_definitions(-DTEST_DATA="${CMAKE_CURRENT_SOURCE_DIR}/configs/") -include_directories(${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_SOURCE_DIR}/tests/kwayland/) +include_directories(${CMAKE_CURRENT_BINARY_DIR}) macro(KSCREEN_ADD_TEST) foreach(_testname ${ARGN}) - set(test_SRCS ${_testname}.cpp ${KSCREEN_WAYLAND_SRCS}) + set(test_SRCS ${_testname}.cpp) qt_add_dbus_interface(test_SRCS ${CMAKE_SOURCE_DIR}/interfaces/org.kde.KScreen.FakeBackend.xml fakebackendinterface) add_executable(${_testname} ${test_SRCS}) - target_link_libraries(${_testname} Qt::Core Qt::Gui Qt::Test Qt::DBus KF5::Screen ${KSCREEN_WAYLAND_LIBS}) + target_link_libraries(${_testname} Qt::Core Qt::Gui Qt::Test Qt::DBus KF5::Screen) add_test(NAME kscreen-${_testname} COMMAND dbus-launch $<TARGET_FILE:${_testname}> ) @@ -25,30 +25,6 @@ kscreen_add_test(testmodelistchange) kscreen_add_test(testedid) -if (NOT TARGET KF5::WaylandServer) - message(WARNING "Skipping KF5::WaylandServer based unit tests!") - return() -endif() - -set(KSCREEN_WAYLAND_LIBS - KF5::WaylandServer KF5::WaylandClient -) - -# For WaylandConfigReader and TestServer -set(KSCREEN_WAYLAND_SRCS - ${CMAKE_SOURCE_DIR}/tests/kwayland/waylandconfigreader.cpp - ${CMAKE_SOURCE_DIR}/tests/kwayland/waylandtestserver.cpp -) -include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../backends/kwayland) - -kscreen_add_test(testkwaylandbackend) -kscreen_add_test(testkwaylandconfig) -kscreen_add_test(testkwaylanddpms) - -set(KSCREEN_WAYLAND_LIBS "") -set(KSCREEN_WAYLAND_SRCS "") - - if (ENABLE_XRANDR_TESTS) kscreen_add_test(testxrandr) endif() diff -ruN libkscreen-5.27.6/autotests/testbackendloader.cpp libkscreen-5.27.6.nowayland/autotests/testbackendloader.cpp --- libkscreen-5.27.6/autotests/testbackendloader.cpp 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/autotests/testbackendloader.cpp 2023-06-24 05:13:20.374927615 -0400 @@ -66,11 +66,6 @@ QTest::addColumn<QString>("backend"); // clang-format off - QTest::newRow("all lower") << "kwayland" << "KSC_KWayland"; - QTest::newRow("camel case") << "KWayland" << "KSC_KWayland"; - QTest::newRow("all upper") << "KWAYLAND" << "KSC_KWayland"; - QTest::newRow("mixed") << "kwAYlaND" << "KSC_KWayland"; - QTest::newRow("xrandr 1.1") << "xrandr11" << "KSC_XRandR11"; QTest::newRow("qscreen") << "qscreen" << "KSC_QScreen"; QTest::newRow("mixed") << "fake" << "KSC_Fake"; diff -ruN libkscreen-5.27.6/backends/CMakeLists.txt libkscreen-5.27.6.nowayland/backends/CMakeLists.txt --- libkscreen-5.27.6/backends/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/backends/CMakeLists.txt 2023-06-24 05:13:20.374927615 -0400 @@ -1,6 +1,5 @@ add_subdirectory(fake) add_subdirectory(qscreen) -add_subdirectory(kwayland) if(${XCB_RANDR_FOUND}) message(STATUS "Will build xrandr backend.") diff -ruN libkscreen-5.27.6/src/backendmanager.cpp libkscreen-5.27.6.nowayland/src/backendmanager.cpp --- libkscreen-5.27.6/src/backendmanager.cpp 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/backendmanager.cpp 2023-06-24 05:13:37.575596783 -0400 @@ -126,7 +126,6 @@ * - backend argument is used if not empty * - env var KSCREEN_BACKEND is considered * - if platform is X11, the XRandR backend is picked - * - if platform is wayland, KWayland backend is picked * - if neither is the case, QScreen backend is picked * - the QScreen backend is also used as fallback * @@ -140,8 +139,6 @@ } else { if (QX11Info::isPlatformX11()) { backendFilter = QStringLiteral("XRandR"); - } else if (QGuiApplication::platformName().startsWith(QLatin1String("wayland"))) { - backendFilter = QStringLiteral("KWayland"); } else { backendFilter = QStringLiteral("QScreen"); } diff -ruN libkscreen-5.27.6/src/backendmanager_p.h libkscreen-5.27.6.nowayland/src/backendmanager_p.h --- libkscreen-5.27.6/src/backendmanager_p.h 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/backendmanager_p.h 2023-06-24 05:13:37.575596783 -0400 @@ -55,7 +55,6 @@ * - If the @p backend argument is specified and not empty it's used to filter the * available backend list * - If specified, the KSCREEN_BACKEND env var is considered (case insensitive) - * - Otherwise, the wayland backend is picked when the runtime platform is Wayland * (we assume kwin in this case * - Otherwise, if the runtime platform is X11, the XRandR backend is picked * - If neither is the case, we fall back to the QScreen backend, since that is the diff -ruN libkscreen-5.27.6/src/config.h libkscreen-5.27.6.nowayland/src/config.h --- libkscreen-5.27.6/src/config.h 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/config.h 2023-06-24 05:27:26.452098622 -0400 @@ -64,7 +64,6 @@ AutoRotation = 1 << 4, ///< The backend supports automatic rotation of outputs. TabletMode = 1 << 5, ///< The backend supports querying if a device is in tablet mode. SynchronousOutputChanges = 1 << 6, ///< The backend supports blocking until the output setting changes are applied - XwaylandScales = 1 << 7, ///< The backend supports adapting Xwayland clients to a certain scale }; Q_ENUM(Feature) Q_DECLARE_FLAGS(Features, Feature) @@ -204,7 +203,7 @@ /** Indicates features supported by the backend. This exists to allow the user * to find out which of the features offered by libkscreen are actually supported * by the backend. Not all backends are writable (QScreen, for example is - * read-only, only XRandR, but not KWayland support the primary display, etc.). + * read-only, only XRandR supports the primary display, etc.). * * @return Flags for features that are supported for this config, determined by * the backend. diff -ruN libkscreen-5.27.6/src/doctor/doctor.cpp libkscreen-5.27.6.nowayland/src/doctor/doctor.cpp --- libkscreen-5.27.6/src/doctor/doctor.cpp 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/doctor/doctor.cpp 2023-06-24 05:13:37.575596783 -0400 @@ -58,7 +58,6 @@ : QObject(parent) , m_config(nullptr) , m_changed(false) - , m_dpmsClient(nullptr) { } diff -ruN libkscreen-5.27.6/src/doctor/doctor.h libkscreen-5.27.6.nowayland/src/doctor/doctor.h --- libkscreen-5.27.6/src/doctor/doctor.h 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/doctor/doctor.h 2023-06-24 05:30:34.207486701 -0400 @@ -53,7 +53,6 @@ void configChanged(); private: - // static QString modeString(KWayland::Server::OutputDeviceInterface* outputdevice, int mid); void applyConfig(); void parseOutputArgs(); KScreen::ConfigPtr m_config; @@ -65,4 +64,4 @@ } // namespace -#endif // KSCREEN_WAYLAND_SCREEN_H +#endif // KSCREEN_DOCTOR_H diff -ruN libkscreen-5.27.6/src/doctor/main.cpp libkscreen-5.27.6.nowayland/src/doctor/main.cpp --- libkscreen-5.27.6/src/doctor/main.cpp 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/doctor/main.cpp 2023-06-24 05:13:49.300052906 -0400 @@ -96,7 +96,6 @@ parser.addOption(info); parser.addOption(json); parser.addOption(outputs); - parser.addOption(dpms); parser.addOption(log); parser.addOption(dpmsExcluded); parser.process(app); diff -ruN libkscreen-5.27.6/src/libdpms/CMakeLists.txt libkscreen-5.27.6.nowayland/src/libdpms/CMakeLists.txt --- libkscreen-5.27.6/src/libdpms/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/libdpms/CMakeLists.txt 2023-06-24 05:26:35.042075668 -0400 @@ -2,20 +2,13 @@ # SPDX-FileCopyrightText: 2022 Aleix Pol Gonzalez <aleixpol@kde.org> add_library(KF5ScreenDpms SHARED) -target_sources(KF5ScreenDpms PRIVATE dpms.cpp abstractdpmshelper.cpp waylanddpmshelper.cpp xcbdpmshelper.cpp waylanddpmshelper.cpp) +target_sources(KF5ScreenDpms PRIVATE dpms.cpp abstractdpmshelper.cpp xcbdpmshelper.cpp) target_link_libraries(KF5ScreenDpms PUBLIC Qt::Gui - PRIVATE XCB::XCB XCB::DPMS XCB::RANDR - Qt::GuiPrivate Qt::WaylandClient Wayland::Client + PRIVATE XCB::XCB XCB::DPMS XCB::RANDR Qt::GuiPrivate ) if (QT_MAJOR_VERSION EQUAL "5") target_link_libraries(KF5ScreenDpms PRIVATE Qt::X11Extras) - ecm_add_qtwayland_client_protocol(KF5ScreenDpms - PROTOCOL ${PLASMA_WAYLAND_PROTOCOLS_DIR}/dpms.xml - BASENAME dpms - ) -else() - qt6_generate_wayland_protocol_client_sources(KF5ScreenDpms FILES ${PLASMA_WAYLAND_PROTOCOLS_DIR}/dpms.xml) endif() set_target_properties(KF5ScreenDpms PROPERTIES diff -ruN libkscreen-5.27.6/src/libdpms/dpms.cpp libkscreen-5.27.6.nowayland/src/libdpms/dpms.cpp --- libkscreen-5.27.6/src/libdpms/dpms.cpp 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/src/libdpms/dpms.cpp 2023-06-24 05:23:35.018991822 -0400 @@ -4,7 +4,6 @@ #include "dpms.h" #include "kscreendpms_debug.h" -#include "waylanddpmshelper_p.h" #include "xcbdpmshelper_p.h" #include <QGuiApplication> @@ -19,8 +18,6 @@ { if (QX11Info::isPlatformX11()) { m_helper.reset(new XcbDpmsHelper); - } else if (QGuiApplication::platformName().startsWith(QLatin1String("wayland"), Qt::CaseInsensitive)) { - m_helper.reset(new WaylandDpmsHelper); } else { qCWarning(KSCREEN_DPMS) << "dpms unsupported on this system"; return; diff -ruN libkscreen-5.27.6/tests/CMakeLists.txt libkscreen-5.27.6.nowayland/tests/CMakeLists.txt --- libkscreen-5.27.6/tests/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/tests/CMakeLists.txt 2023-06-24 05:13:49.300052906 -0400 @@ -1,4 +1,2 @@ add_executable(printconfig testplugandplay.cpp testpnp.cpp) target_link_libraries(printconfig Qt::Gui KF5::Screen) - -add_subdirectory(kwayland) diff -ruN libkscreen-5.27.6/tests/kwayland/CMakeLists.txt libkscreen-5.27.6.nowayland/tests/kwayland/CMakeLists.txt --- libkscreen-5.27.6/tests/kwayland/CMakeLists.txt 2023-06-20 09:32:56.000000000 -0400 +++ libkscreen-5.27.6.nowayland/tests/kwayland/CMakeLists.txt 2023-06-24 05:13:49.300052906 -0400 @@ -2,9 +2,3 @@ message(WARNING "Skipping KF5::WaylandServer based tests!") return() endif() - -add_definitions(-DTEST_DATA="${CMAKE_SOURCE_DIR}/autotests/configs/") - -add_executable(waylandtestserver main.cpp waylandtestserver.cpp waylandconfigreader.cpp) -target_link_libraries(waylandtestserver KF5::Screen KF5::WaylandServer) -
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor