Advance Wayland and KDE package bring-up

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-04-14 10:51:06 +01:00
parent 51f3c21121
commit cf12defd28
15214 changed files with 20594243 additions and 269 deletions
@@ -0,0 +1,45 @@
#
# SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
#
# SPDX-License-Identifier: BSD-3-Clause
cmake_minimum_required(VERSION 3.16)
project(extra-cmake-modules)
set(ECM_MODULE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/../../modules)
set(CMAKE_MODULE_PATH "${ECM_FIND_MODULE_DIR}" "${ECM_MODULE_DIR}")
include(QtVersionOption)
find_package(Qt${QT_MAJOR_VERSION} REQUIRED COMPONENTS Qml)
include(ECMQmlModule)
set(CMAKE_AUTOMOC ON)
if(QML_ONLY)
ecm_add_qml_module(TestModule URI Test NO_PLUGIN)
else()
if (QT_MAJOR_VERSION LESS 6 OR NOT DEPENDS)
ecm_add_qml_module(TestModule URI Test)
else ()
ecm_add_qml_module(TestModule URI Test DEPENDENCIES OtherTest)
endif()
target_sources(TestModule PRIVATE qmlmodule.cpp)
target_link_libraries(TestModule PRIVATE Qt${QT_MAJOR_VERSION}::Qml)
endif()
if (QT_MAJOR_VERSION LESS 6 AND DEPENDS)
ecm_add_qml_module_dependencies(TestModule DEPENDS OtherTest)
endif()
ecm_target_qml_sources(TestModule SOURCES QmlModule.qml)
ecm_target_qml_sources(TestModule VERSION 2.0 SOURCES QmlModule2.qml)
ecm_finalize_qml_module(TestModule DESTINATION "test")
# this will be run by CTest
if (BUILD_SHARED_LIBS)
get_target_property(MODULE_OUTPUT_PATH TestModule LIBRARY_OUTPUT_DIRECTORY)
else()
get_target_property(MODULE_OUTPUT_PATH TestModule ARCHIVE_OUTPUT_DIRECTORY)
endif()
configure_file(check.cmake.in "${CMAKE_CURRENT_BINARY_DIR}/check.cmake" @ONLY)
@@ -0,0 +1,12 @@
/**
* SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
*
* SPDX-License-Identifier: BSD-3-Clause
*/
import QtQuick 2.15
Item {
}
@@ -0,0 +1,11 @@
/**
* SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
*
* SPDX-License-Identifier: BSD-3-Clause
*/
import QtQuick 2.15
Item {
}
@@ -0,0 +1,3 @@
#include <qglobal.h>
#include <QDebug>
void initQmlResourceTestModule() {Q_INIT_RESOURCE(TestModule); qWarning()<<Q_FUNC_INFO;};
@@ -0,0 +1,84 @@
#
# SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
#
# SPDX-License-Identifier: BSD-3-Clause
set(SOURCE_DIR "@CMAKE_CURRENT_SOURCE_DIR@")
set(INSTALL_DIR "@CMAKE_INSTALL_PREFIX@/test")
set(SHARED "@BUILD_SHARED_LIBS@")
set(QML_ONLY "@QML_ONLY@")
set(DEPENDS "@DEPENDS@")
set(QT_VERSION "@QT_MAJOR_VERSION@")
set(TEST_INSTALL_DIR "${INSTALL_DIR}/Test")
function(check_file_exists file)
if (NOT EXISTS ${file})
message(FATAL_ERROR "File \"${file}\" does not exist")
endif()
endfunction()
function (check_file_contents)
cmake_parse_arguments(ARGS "" "GENERATED;EXPECTED" "" ${ARGN})
if (NOT EXISTS "${ARGS_GENERATED}")
message(FATAL_ERROR "${ARGS_GENERATED} was not generated")
endif()
file(READ "${ARGS_GENERATED}" generated_contents)
if (NOT EXISTS "${ARGS_EXPECTED}")
message(FATAL_ERROR "Original ${ARGS_EXPECTED} was not found")
endif()
file(READ "${ARGS_EXPECTED}" original_contents)
if (NOT "${generated_contents}" STREQUAL "${original_contents}")
message(FATAL_ERROR "${generated_file} contains '${generated_contents}' instead of '${original_contents}'")
endif()
endfunction()
if (SHARED)
check_file_contents(
GENERATED "${TEST_INSTALL_DIR}/QmlModule.qml"
EXPECTED "${SOURCE_DIR}/QmlModule.qml"
)
if (QML_ONLY AND NOT DEPENDS)
check_file_contents(
GENERATED "${TEST_INSTALL_DIR}/qmldir"
EXPECTED "${SOURCE_DIR}/qmldir_expected_qmlonly_qt${QT_VERSION}"
)
endif()
if (DEPENDS)
check_file_contents(
GENERATED "${TEST_INSTALL_DIR}/qmldir"
EXPECTED "${SOURCE_DIR}/qmldir_expected_depends_qt${QT_VERSION}"
)
endif()
if (NOT QML_ONLY AND NOT DEPENDS)
check_file_contents(
GENERATED "${TEST_INSTALL_DIR}/qmldir"
EXPECTED "${SOURCE_DIR}/qmldir_expected_full_qt${QT_VERSION}"
)
endif()
if (NOT QML_ONLY OR ${QT_VERSION} GREATER_EQUAL 6)
if (WIN32)
check_file_exists("${TEST_INSTALL_DIR}/TestModule.dll")
else()
check_file_exists("${TEST_INSTALL_DIR}/libTestModule.so")
endif()
endif()
else()
if (${QT_VERSION} LESS 6)
if (WIN32)
check_file_exists("${TEST_INSTALL_DIR}/TestModule.lib")
else()
check_file_exists("${TEST_INSTALL_DIR}/libTestModule.a")
endif()
else()
if (WIN32)
check_file_exists("@MODULE_OUTPUT_PATH@/TestModule.lib")
else()
check_file_exists("@MODULE_OUTPUT_PATH@/libTestModule.a")
endif()
endif()
endif()
@@ -0,0 +1,8 @@
# This file was automatically generated by ECMQmlModule and should not be modified
module Test
plugin TestModule
classname TestModule
depends OtherTest
QmlModule 1.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
# KDE-qmldir-Version: 1.0
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,10 @@
module Test
linktarget TestModule
optional plugin TestModule
classname TestPlugin
typeinfo TestModule.qmltypes
depends OtherTest
prefer :/qt/qml/Test/
QmlModule 254.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2023 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,7 @@
# This file was automatically generated by ECMQmlModule and should not be modified
module Test
plugin TestModule
classname TestModule
QmlModule 1.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
# KDE-qmldir-Version: 1.0
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,9 @@
module Test
linktarget TestModule
optional plugin TestModule
classname TestPlugin
typeinfo TestModule.qmltypes
prefer :/qt/qml/Test/
QmlModule 254.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2023 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,5 @@
# This file was automatically generated by ECMQmlModule and should not be modified
module Test
QmlModule 1.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
# KDE-qmldir-Version: 1.0
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,9 @@
module Test
linktarget TestModule
optional plugin TestModule
classname TestPlugin
typeinfo TestModule.qmltypes
prefer :/qt/qml/Test/
QmlModule 254.0 QmlModule.qml
QmlModule2 2.0 QmlModule2.qml
@@ -0,0 +1,2 @@
SPDX-FileCopyrightText: 2023 Arjen Hiemstra <ahiemstra@heimr.nl>
SPDX-License-Identifier: CC0-1.0
@@ -0,0 +1,14 @@
/**
* SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#include "qmlmodule.h"
#include <QtQml/QQmlEngine>
void QmlModule::registerTypes(const char* uri)
{
Q_ASSERT(QLatin1String(uri) == QLatin1String("Test"));
}
@@ -0,0 +1,21 @@
/**
* SPDX-FileCopyrightText: 2021 Arjen Hiemstra <ahiemstra@heimr.nl>
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef QMLMODULE_H
#define QMLMODULE_H
#include <QtQml/QQmlExtensionPlugin>
class QmlModule : public QQmlExtensionPlugin
{
Q_OBJECT
Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QQmlExtensionInterface")
public:
void registerTypes(const char* uri) override;
};
#endif