diff --git a/ports/kf6windowsystem/001_guard_ecm_qml_module_include.patch b/ports/kf6windowsystem/001_guard_ecm_qml_module_include.patch new file mode 100644 index 00000000000000..386dc975621de1 --- /dev/null +++ b/ports/kf6windowsystem/001_guard_ecm_qml_module_include.patch @@ -0,0 +1,23 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -26,7 +26,10 @@ + include(ECMDeprecationSettings) + include(ECMPoQmTools) + include(ECMGeneratePkgConfigFile) +-include(ECMQmlModule) ++option(KWINDOWSYSTEM_QML "Build QML bindings" ON) ++if(KWINDOWSYSTEM_QML) ++ include(ECMQmlModule) ++endif() + include(ECMGenerateQDoc) + + set(EXCLUDE_DEPRECATED_BEFORE_AND_AT 0 CACHE STRING "Control the range of deprecated API excluded from the build [default=0].") +@@ -45,8 +48,6 @@ + find_package(Qt6GuiPrivate ${REQUIRED_QT_VERSION} REQUIRED NO_MODULE) + endif() + +-option(KWINDOWSYSTEM_QML "Build QML bindings" ON) +- + if (KWINDOWSYSTEM_QML) + find_package(Qt6Qml ${REQUIRED_QT_VERSION} CONFIG REQUIRED) + endif() diff --git a/ports/kf6windowsystem/portfile.cmake b/ports/kf6windowsystem/portfile.cmake new file mode 100644 index 00000000000000..706e825dc439ce --- /dev/null +++ b/ports/kf6windowsystem/portfile.cmake @@ -0,0 +1,44 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO KDE/kwindowsystem + REF "v${VERSION}" + SHA512 3d72d5760f4492edc2a02aaac420c431ff4d54f74585f2257aa4171f3c1886584b20899e7178e29a1aca9b3aada26d998327f1b6b302f0dff405e2db625e6561 + HEAD_REF master + PATCHES + 001_guard_ecm_qml_module_include.patch +) + +# Prevent KDEClangFormat from writing to source effectively blocking parallel configure +file(WRITE "${SOURCE_PATH}/.clang-format" "DisableFormat: true\nSortIncludes: false\n") + +if(VCPKG_TARGET_IS_LINUX) + message(WARNING "${PORT} currently requires the following libraries from the system package manager:\n libx11-dev libxcb1-dev libxcb-keysyms1-dev libxcb-res0-dev libxcb-icccm4-dev\n libwayland-dev wayland-protocols\n\nThese can be installed on Ubuntu systems via apt-get install libx11-dev libxcb1-dev libxcb-keysyms1-dev libxcb-res0-dev libxcb-icccm4-dev libwayland-dev wayland-protocols") +endif() + +vcpkg_check_features( + OUT_FEATURE_OPTIONS FEATURE_OPTIONS + FEATURES + qml KWINDOWSYSTEM_QML + INVERTED_FEATURES + translations KF_SKIP_PO_PROCESSING +) + +vcpkg_cmake_configure( + SOURCE_PATH "${SOURCE_PATH}" + OPTIONS + -DBUILD_TESTING=OFF + -DKDE_INSTALL_PLUGINDIR=plugins + -DKDE_INSTALL_QMLDIR=qml + ${FEATURE_OPTIONS} +) + +vcpkg_cmake_install() +vcpkg_cmake_config_fixup(CONFIG_PATH lib/cmake/KF6WindowSystem) +vcpkg_copy_pdbs() +vcpkg_fixup_pkgconfig(SKIP_CHECK) + +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share") + +file(GLOB LICENSE_FILES "${SOURCE_PATH}/LICENSES/*") +vcpkg_install_copyright(FILE_LIST ${LICENSE_FILES}) diff --git a/ports/kf6windowsystem/vcpkg.json b/ports/kf6windowsystem/vcpkg.json new file mode 100644 index 00000000000000..31f08c9b63392d --- /dev/null +++ b/ports/kf6windowsystem/vcpkg.json @@ -0,0 +1,54 @@ +{ + "name": "kf6windowsystem", + "version": "6.23.0", + "description": "Access to the windowing system", + "homepage": "https://invent.kde.org/frameworks/kwindowsystem", + "documentation": "https://api.kde.org/kwindowsystem-index.html", + "dependencies": [ + "ecm", + { + "name": "plasma-wayland-protocols", + "platform": "linux" + }, + { + "name": "qtbase", + "default-features": false + }, + { + "name": "qtwayland", + "default-features": false, + "platform": "linux" + }, + { + "name": "vcpkg-cmake", + "host": true + }, + { + "name": "vcpkg-cmake-config", + "host": true + } + ], + "features": { + "qml": { + "description": "Build QML bindings", + "dependencies": [ + { + "name": "qtdeclarative", + "default-features": false + } + ] + }, + "translations": { + "description": "Build and install translation files", + "dependencies": [ + { + "name": "qttools", + "host": true, + "features": [ + "linguist" + ] + } + ] + } + } +} diff --git a/versions/baseline.json b/versions/baseline.json index 55e9f41a5147e4..076d6cfb49b623 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -4456,6 +4456,10 @@ "baseline": "6.23.0", "port-version": 0 }, + "kf6windowsystem": { + "baseline": "6.23.0", + "port-version": 0 + }, "kfr": { "baseline": "6.3.1", "port-version": 0 diff --git a/versions/k-/kf6windowsystem.json b/versions/k-/kf6windowsystem.json new file mode 100644 index 00000000000000..7bdbec430242e0 --- /dev/null +++ b/versions/k-/kf6windowsystem.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "575f01712f29d15296edad942291aa6febe6060e", + "version": "6.23.0", + "port-version": 0 + } + ] +}