Subject: [bug#59936] [PATCH] gnu: Add xdg-desktop-portal-lxqt.

From: Tobias Kortkamp <[email-masked]>
Date: Sat, 10 Dec 2022 05:11:51 +0100

* gnu/packages/lxqt.scm (xdg-desktop-portal-lxqt): New variable.
---
 gnu/packages/lxqt.scm | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)

Hi,

I would like to note that I have not tested this under lxqt. It works
fine under Sway with XDG_CURRENT_DESKTOP=LXQt (which I set to make
lxqt-qtplugin work properly) after manually starting the portal in my
Sway config. The portal is needed to get a file chooser dialog in
Flatpak apps.

Best regards,

Tobias

diff --git a/gnu/packages/lxqt.scm b/gnu/packages/lxqt.scm
index dde87382e8..cae4ab7384 100644
--- a/gnu/packages/lxqt.scm
+++ b/gnu/packages/lxqt.scm
@@ -11,6 +11,7 @@
 ;;; Copyright © 2020 Fakhri Sajadi <[email-masked]>
 ;;; Copyright © 2020 André Batista <[email-masked]>
 ;;; Copyright © 2021, 2022 Brendan Tildesley <[email-masked]>
+;;; Copyright © 2022 Tobias Kortkamp <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -1123,6 +1124,31 @@ (define-public lxqt-connman-applet
 desktop.")
       (license license:lgpl2.1+))))
 
+(define-public xdg-desktop-portal-lxqt
+  (package
+    (name "xdg-desktop-portal-lxqt")
+    (version "0.3.0")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "https://github.com/lxqt/xdg-desktop-portal-lxqt/releases/download/"
+                    version "/xdg-desktop-portal-lxqt-" version ".tar.xz"))
+              (sha256
+               (base32
+                "1qz71y5k5g3rwn4r2xifmbfhkgifghfknxl3hlljvpdd2yqf8p7p"))))
+    (build-system cmake-build-system)
+    (arguments
+     (list #:tests? #f))
+    (native-inputs (list))
+    (inputs (list kwindowsystem libfm-qt qtbase-5 qtx11extras))
+    (propagated-inputs (list xdg-desktop-portal))
+    (home-page "https://github.com/lxqt/xdg-desktop-portal-lxqt")
+    (synopsis "LXQt implementation of xdg-desktop-portal")
+    (description
+     "This package provides a backend implementation for xdg-desktop-portal that is
+using Qt/KF5/libfm-qt.")
+    (license license:lgpl2.1+)))
+
 ;; The LXQt Desktop Environment
 
 (define-public lxqt

base-commit: 0ffa501f2b3e83ae56e9c2bd31418439090e869a
-- 
2.38.1