File xdg-desktop-portal-kde6.spec of Package xdg-desktop-portal-kde6

#
# spec file for package xdg-desktop-portal-kde6
#
# Copyright (c) 2025 SUSE LLC and contributors
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


# Internal QML import
%global __requires_exclude qt6qmlimport\\(org\\.kde\\.xdgdesktopportal.*

%define kf6_version 6.18.0
%define qt6_version 6.9.0

%define rname xdg-desktop-portal-kde

# Full Plasma 6 version (e.g. 6.0.0)
%{!?_plasma6_bugfix: %global _plasma6_bugfix %{version}}
# Latest ABI-stable Plasma (e.g. 6.0 in KF6, but 6.0.80 in KUF)
%{!?_plasma6_version: %define _plasma6_version %(echo %{_plasma6_bugfix} | awk -F. '{print $1"."$2}')}
%bcond_without released
Name:           xdg-desktop-portal-kde6
Version:        6.5.2
Release:        kf.74.1
Summary:        QT/KF6 backend for xdg-desktop-portal
License:        LGPL-2.1-or-later
URL:            https://www.kde.org
Source:         https://download.kde.org/stable/plasma/%{version}/%{rname}-%{version}.tar.xz
%if %{with released}
Source1:        https://download.kde.org/stable/plasma/%{version}/%{rname}-%{version}.tar.xz.sig
Source2:        plasma.keyring
%endif
BuildRequires:  kf6-extra-cmake-modules >= %{kf6_version}
BuildRequires:  pkgconfig
BuildRequires:  qt6-gui-private-devel >= %{qt6_version}
BuildRequires:  qt6-printsupport-private-devel >= %{qt6_version}
BuildRequires:  cmake(KF6Config) >= %{kf6_version}
BuildRequires:  cmake(KF6CoreAddons) >= %{kf6_version}
BuildRequires:  cmake(KF6Crash) >= %{kf6_version}
BuildRequires:  cmake(KF6GlobalAccel) >= %{kf6_version}
BuildRequires:  cmake(KF6GuiAddons) >= %{kf6_version}
BuildRequires:  cmake(KF6I18n) >= %{kf6_version}
BuildRequires:  cmake(KF6IconThemes) >= %{kf6_version}
BuildRequires:  cmake(KF6KIO) >= %{kf6_version}
BuildRequires:  cmake(KF6KirigamiPlatform) >= %{kf6_version}
BuildRequires:  cmake(KF6Notifications) >= %{kf6_version}
BuildRequires:  cmake(KF6StatusNotifierItem) >= %{kf6_version}
BuildRequires:  cmake(KF6WidgetsAddons) >= %{kf6_version}
BuildRequires:  cmake(KF6WindowSystem) >= %{kf6_version}
BuildRequires:  cmake(KWayland) >= %{_plasma6_bugfix}
BuildRequires:  cmake(PlasmaWaylandProtocols) >= 1.7.0
BuildRequires:  cmake(Qt6Concurrent) >= %{qt6_version}
BuildRequires:  cmake(Qt6Core) >= %{qt6_version}
BuildRequires:  cmake(Qt6DBus) >= %{qt6_version}
BuildRequires:  cmake(Qt6PrintSupport) >= %{qt6_version}
BuildRequires:  cmake(Qt6Qml) >= %{qt6_version}
BuildRequires:  cmake(Qt6Quick) >= %{qt6_version}
BuildRequires:  cmake(Qt6QuickControls2) >= %{qt6_version}
BuildRequires:  cmake(Qt6QuickWidgets) >= %{qt6_version}
BuildRequires:  cmake(Qt6Test) >= %{qt6_version}
BuildRequires:  cmake(Qt6WaylandClient) >= %{qt6_version}
BuildRequires:  cmake(Qt6Widgets) >= %{qt6_version}
BuildRequires:  pkgconfig(wayland-client) >= 1.15
BuildRequires:  pkgconfig(wayland-protocols) >= 1.25
BuildRequires:  pkgconfig(xkbcommon)
Requires:       kf6-kiconthemes-imports >= %{kf6_version}
Requires:       kpipewire6-imports >= %{_plasma6_bugfix}
# For org.kde.plasma.workspace.dialogs.1 import
Requires:       plasma6-workspace >= %{_plasma6_bugfix}
Requires:       xdg-desktop-portal
Supplements:    (xdg-desktop-portal and plasma6-desktop)
Provides:       xdg-desktop-portal-kde = %{version}
Obsoletes:      xdg-desktop-portal-kde < %{version}
Obsoletes:      xdg-desktop-portal-kde-lang < %{version}

%description
A Qt/KF backend implementation for xdg-desktop-portal

%lang_package

%prep
%autosetup -p1 -n %{rname}-%{version}

%build
%cmake_kf6

%kf6_build

%install
%kf6_install

%find_lang xdg-desktop-portal-kde --with-man --all-name

%post
%{systemd_user_post plasma-xdg-desktop-portal-kde.service}

%preun
%{systemd_user_preun plasma-xdg-desktop-portal-kde.service}

%postun
%{systemd_user_postun plasma-xdg-desktop-portal-kde.service}

%files
%license LICENSES/*
%{_kf6_applicationsdir}/org.freedesktop.impl.portal.desktop.kde.desktop
%{_kf6_debugdir}/xdp-kde.categories
%{_kf6_notificationsdir}/xdg-desktop-portal-kde.notifyrc
%{_kf6_sharedir}/dbus-1/services/org.freedesktop.impl.portal.desktop.kde.service
%dir %{_kf6_sharedir}/xdg-desktop-portal/
%dir %{_kf6_sharedir}/xdg-desktop-portal/portals
%{_kf6_sharedir}/xdg-desktop-portal/portals/kde.portal
%{_libexecdir}/xdg-desktop-portal-kde
%{_userunitdir}/plasma-xdg-desktop-portal-kde.service

%files lang -f xdg-desktop-portal-kde.lang

%changelog
* Tue Nov  4 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.5.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.5.2
- Changes since 6.5.1:
  * Update version for new release 6.5.2
  * screencasting: Let the compositor pick the scale of a region stream (kde#511039)
  * Update version for new release 6.5.2
* Tue Oct 28 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.5.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.5.1
- Changes since 6.5.0:
  * Update version for new release 6.5.1
  * inputcapture: de-duplicate input capture zones
  * AppChooserDialog: Show NoDisplay services (kde#510546)
  * AppChooserPortal: Support "modal" dialog
* Thu Oct 16 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.5.0:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.5.0
- Changes since 6.4.91:
  * Update version for new release 6.5.0
  * inhibit: Fix races between requests and calls to powerdevil
  * Request: drop unused members
  * inhibit: Create error reply to the correct message
* Thu Oct  2 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.91:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.91
- Changes since 6.4.90:
  * Update version for new release 6.4.91
  * [dynamiclauncher] Also reply with name/icon when not editable (kde#509959)
  * Use state config to store file dialog size
* Tue Sep 23 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.90:
  * New feature release
  * For more details see https://kde.org/announcements/plasma/6/6.4.90
- Too many changes to list here
* Tue Sep  9 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.5:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.5
- Changes since 6.4.4:
  * Update version for new release 6.4.5
* Wed Aug  6 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.4:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.4
- Changes since 6.4.3:
  * Update version for new release 6.4.4
  * globalshortcuts: Return shortcuts when dialog is accepted
* Tue Jul 15 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.3:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.3
- Changes since 6.4.2:
  * Update version for new release 6.4.3
* Tue Jul  1 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.2
- Changes since 6.4.1:
  * Update version for new release 6.4.2
  * Fix screenshot delay (kde#496964)
* Tue Jun 24 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.1
- Changes since 6.4.0:
  * Update version for new release 6.4.1
  * filechooser: Do not parent the optionswidget (kde#505746)
  * globalshortcuts: Set main window after creating it
  * remotedesktop: Guard against session going away
* Thu Jun 12 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.4.0:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.4.0
- Changes since 6.3.91:
  * Update version for new release 6.4.0
  * filechooser: Normalize name filters to something more common (kde#475668)
  * Initialize the whole array
  * print: Make qt_keyForPageSizeId more robust
  * Added a warning to comment about code copied from Qt
  * Copied bit fields from Qt commit 65b62d2
  * Updated qt_pageSizes[] for Qt 6 Synchronised with Qt 6 changes to QPageSize::PageSizeId. The user's paper size selection should now be respected again. BUG: 492681 (kde#492681)
  * filechooser: Ignore non absolute current_folder urls
  * screencast: Guard against session closing while creating stream (kde#500577)
  * screencast: Make sure we send a message reply when restoring (kde#504384)
* Thu May 29 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.91:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.91
- Changes since 6.3.90:
  * Update version for new release 6.3.91
  * fix: avoid empty applicationName in remote control dialog
* Mon May 19 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.90:
  * New feature release
  * For more details see https://kde.org/announcements/plasma/6/6.3.90
- Too many changes to list here
* Tue May  6 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.5:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.5
- Changes since 6.3.4:
  * update version for new release
* Wed Apr  2 2025 Christophe Marin <christophe@krop.fr>
- Update to 6.3.4
  * New bugfix release
  * For more details please see:
  * https://kde.org/announcements/plasma/6/6.3.4
- Changes since 6.3.3:
  * [AppChooser] Correctly set m_autoRemember
  * Add input capture notification to notifyrc (kde#500130)
  * update version for new release
* Tue Mar 11 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.3:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.3
- Changes since 6.3.2:
  * update version for new release
* Tue Feb 25 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.2
- Changes since 6.3.1:
  * update version for new release
* Tue Feb 18 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.1
- Changes since 6.3.0:
  * update version for new release
  * outputsmodel: Handle screens going away (kde#495160)
  * WaylandIntegration: disconnect from stream after leaving event loop to fix crash
* Thu Feb  6 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.3.0:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.3.0
- Changes since 6.2.91:
  * update version for new release
  * access: The dialog need to be modal by default
  * screenshot: The dialog needs to be modal by default
  * [AppChooser] Don't use KBuildSycocaProgressDialog to rebuild sycoca (kde#484739)
* Thu Jan 23 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.91:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.91
- Changes since 6.2.90:
  * update version for new release
  * account: Always send a valid URI
  * Guard against session closed while dialogs are shown
  * inputcapture: Fix crash due to wrong context arg (kde#494410)
  * Make the component name for GlobalShortcuts only consist of appId if provided (kde#492992)
  * implement a secondary permission system
* Sat Jan 11 2025 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.90:
  * New feature release
  * For more details see https://kde.org/announcements/plasma/6/6.2.90
- Changes since 6.2.5:
  * update version for new release
  * ScreenChooserDialog: Set Accessible.role for Cards
  * ScreenChooserDialog: make items keyboard-accessible
  * inputcapture: Show a notification when capture starts
  * [FileChooser] Don't ignore current_filter parameter with multiple name patterns
  * Add missing license file
  * ScreenShot: Don't access the result of a cancelled future
  * Notification: Allow dbus-activating applications that are not running
  * Make use of KWindowSystem::setMainWindow
  * Dont clear shortcuts in GlobalShortcutsSession::setActions
  * Fix i18nc usage (kde#496633)
  * Allow restoring virtual outputs
  * Give virtual outputs a more stable and unique id
  * Give virtual outputs a better name
  * screencast: Allow restoring regions
  * Register list of WindowRestoreInfo as meta type
  * Don't include quiet packages in feature_summary
  * add a replace option
  * Update git blame ignore file
  * Reformat code with clang-format
  * [FileChooser] Properly pass along requested current filter
  * Create region selection window before calling setScreen (kde#493293)
  * screencast: Improve window stream restoration
  * update version for new release
  * AppChooserDialog: allow accepting terminal commands (kde#493150)
* Tue Dec 31 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.5:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.5
- Changes since 6.2.4:
  * update version for new release
  * [FileChooser] Don't ignore current_filter parameter with multiple name patterns
  * ScreenShot: Don't access the result of a cancelled future
  * Notification: Allow dbus-activating applications that are not running
  * update version for new release
* Tue Nov 26 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.4:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.4
- Changes since 6.2.3:
  * update version for new release
* Tue Nov  5 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.3:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.3
- Changes since 6.2.2:
  * update version for new release
  * [FileChooser] Properly pass along requested current filter
  * Create region selection window before calling setScreen (kde#493293)
* Tue Oct 22 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.2
- Changes since 6.2.1:
  * update version for new release
* Tue Oct 15 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.1
- Changes since 6.2.0:
  * update version for new release
* Sat Oct  5 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.2.0:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.2.0
- Changes since 6.1.90:
  * update version for new release
  * AppChooserDialog: allow accepting terminal commands (kde#493150)
* Tue Sep 17 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.90:
  * New feature release
  * For more details see https://kde.org/announcements/plasma/6/6.1.90
- Changes since 6.1.5:
  * update version for new release
  * appchooser: Send activation token when selecting an app
  * Generate wayland code with PRIVATE_CODE
  * Set up crash handling
  * Fix inputcapture signal string connection typo
  * Set up translation for FileDialog
  * Set timeout on DBus calls to KWin
  * Inhibit: Forward the correct inhibition flags to PolicyAgent (kde#486506)
  * Remove kde-portals.conf which moves to plasma-workspace
  * remotedesktop: Only show the restore checkbox if the app wants to persist
  * appchooser: bring private interface to feature parity with kopenwithdialog
  * InputCapture: Fix retrieving of cursor position out of QVariantMap
  * InputCapture: activation_id needs to be unsigned
  * Fix remote desktop restoring (kde#480235)
  * Fixed wrong input passed to y1
  * Initialize input capture state properly
  * Make the file chooser dialog consistent with plasma-integration
  * Send error replys not the original messages
  * Fix screencast window restoration check (kde#485697)
  * colorschemetest: Test just built binary instead of host installed one
  * update version for new release
* Tue Sep 10 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.5:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.5
- Changes since 6.1.4:
  * update version for new release
  * appchooser: Send activation token when selecting an app
  * Fix inputcapture signal string connection typo
  * update version for new release
* Tue Aug  6 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.4:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.4
- Changes since 6.1.3:
  * update version for new release
  * Set up translation for FileDialog
  * Set timeout on DBus calls to KWin
  * Inhibit: Forward the correct inhibition flags to PolicyAgent (kde#486506)
  * remotedesktop: Only show the restore checkbox if the app wants to persist
* Tue Jul 16 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.3:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.3
- Changes since 6.1.2:
  * update version for new release
* Tue Jul  2 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.2
- Changes since 6.1.1:
  * update version for new release
* Tue Jun 25 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.1
- Changes since 6.1.0:
  * update version for new release
  * InputCapture: Fix retrieving of cursor position out of QVariantMap
  * InputCapture: activation_id needs to be unsigned
  * update version for new release
* Thu Jun 13 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.1.0:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.1.0
- Changes since 6.0.90:
  * update version for new release
  * Fix remote desktop restoring (kde#480235)
  * Fixed wrong input passed to y1
  * update version for new release
  * Initialize input capture state properly
  * Make the file chooser dialog consistent with plasma-integration
  * Send error replys not the original messages
  * Fix screencast window restoration check (kde#485697)
* Sat May 25 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.90:
  * New feature release
  * For more details see https://kde.org/announcements/plasma/6/6.0.90
- Too many changes to list here
* Wed May 22 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.5:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.0.5
- Changes since 6.0.4:
  * update version for new release
* Wed Apr 17 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.4:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.0.4
- Changes since 6.0.3:
  * update version for new release
* Tue Mar 26 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.3:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.0.3
- Changes since 6.0.2:
  * update version for new release
  * AppChooserDialog: Reload model when Sycoca database changes
* Wed Mar 13 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.2:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.0.2
- Changes since 6.0.1:
  * update version for new release
  * GlobalShortcuts: Fix shortcut register on session load
  * GlobalShortcuts: Load existing shortcuts at session creation
  * GlobalShortcuts: Set shortcuts in BindShortcuts (kde#474741)
  * update version for new release
* Wed Mar  6 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.1:
  * New bugfix release
  * For more details see https://kde.org/announcements/plasma/6/6.0.1
- Changes since 6.0.0:
  * update version for new release
* Mon Mar  4 2024 Christophe Marin <christophe@krop.fr>
- Add Provides/Obsoletes to replace Plasma 5
* Wed Feb 21 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 6.0.0:
  * New bugfix release
  * Release announcement not available yet
- Changes since 5.93.0:
  * update version for new release
  * RegionSelectOverlay: Adapt to FloatingTextBox property change
  * Format better human readable output descriptions (kde#473338)
  * Fix connector type detection
  * Create fake input device on demand
  * update version for new release
* Wed Jan 31 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 5.93.0 (6.0 RC 2):
  * New bugfix release
  * See https://kde.org/announcements/megarelease/6/rc2/ for details
- Changes since 5.92.0:
  * RC 1 version dep
  * add a version for dependencies so it does not break CI https://invent.kde.org/plasma/bluedevil/-/merge_requests/156
  * RemoteDesktop: Include clipboard_enabled and the restore data even when no screens are requested
  * ScreenChooserDialog: doubleclick to select&confirm (kde#470211)
  * Fix ScreenChooserDialog Layout (kde#479304)
  * Don't call toggled twice
  * qml cleanup: removed duplicate toggled signal
* Mon Jan 15 2024 Fabian Vogt <fabian@ritter-vogt.de>
- Update to 5.92.0 (6.0 RC 1)
  * For more details please see:
    https://kde.org/announcements/megarelease/6/rc1/
* Sat Jul 15 2023 Christophe Marin <christophe@krop.fr>
- Init xdg-desktop-portal-kde6
openSUSE Build Service is sponsored by