guix_mirror_bot pushed a commit to branch gnome-team
in repository guix.

commit b6cdea6773c027a705262593347a29921badad67
Author: Maxim Cournoyer <[email protected]>
AuthorDate: Sat May 17 18:08:00 2025 +0900

    gnu: xdg-desktop-portal: Update to 1.20.1.
    
    * gnu/packages/freedesktop.scm (xdg-desktop-portal): Update to 1.20.1.
    [source] <patches>: Remove xdg-desktop-portal-disable-portal-tests.patch.
    [arguments]: Use gexps.
    <#:phases> {po-chmod, relax-gcc-14-strictness}: Delete phases.
    {patch-libumockdev-preload.so-file-name}: New phase.
    {prepare-for-tests}: Likewise.
    [native-inputs]: Add gst-plugins-good and umockdev.
    [inputs]: Add gst-plugins-base.
    * gnu/packages/patches/\
    xdg-desktop-portal-disable-configuration-search-exit.patch: Update patch.
    * gnu/packages/patches/xdg-desktop-portal-disable-portal-tests.patch: Delete
    file.
    * gnu/local.mk (dist_patch_DATA): Adjust accordingly.
    
    Change-Id: I956df6f52600e7301ba2776c7508488bed92d9ec
---
 gnu/local.mk                                       |  5 +-
 gnu/packages/freedesktop.scm                       | 52 +++++++++++---------
 ...-portal-disable-configuration-search-exit.patch | 23 +++------
 .../xdg-desktop-portal-disable-portal-tests.patch  | 56 ----------------------
 4 files changed, 38 insertions(+), 98 deletions(-)

diff --git a/gnu/local.mk b/gnu/local.mk
index cbee0b5671..3d0d33032f 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -2469,9 +2469,8 @@ dist_patch_DATA =                                         
\
   %D%/packages/patches/wordnet-CVE-2008-3908-pt2.patch                 \
   %D%/packages/patches/wpa-supplicant-dbus-group-policy.patch          \
   %D%/packages/patches/x265-arm-flags.patch                    \
-  %D%/packages/patches/xdg-desktop-portal-disable-portal-tests.patch\
-  
%D%/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch\
-  %D%/packages/patches/xdg-desktop-portal-wlr-harcoded-length.patch\
+  
%D%/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch 
     \
+  %D%/packages/patches/xdg-desktop-portal-wlr-harcoded-length.patch    \
   %D%/packages/patches/xf86-video-siliconmotion-fix-ftbfs.patch \
   %D%/packages/patches/xfig-Enable-error-message-for-missing-libraries.patch   
        \
   %D%/packages/patches/xfig-Fix-double-free-when-requesting-MediaBox.patch     
        \
diff --git a/gnu/packages/freedesktop.scm b/gnu/packages/freedesktop.scm
index 0b1832c953..8687c7464c 100644
--- a/gnu/packages/freedesktop.scm
+++ b/gnu/packages/freedesktop.scm
@@ -3137,7 +3137,7 @@ compatible with the well-known scripts of the same name.")
 (define-public xdg-desktop-portal
   (package
     (name "xdg-desktop-portal")
-    (version "1.18.4")
+    (version "1.20.1")
     (source
      (origin
        (method url-fetch)
@@ -3146,37 +3146,42 @@ compatible with the well-known scripts of the same 
name.")
              version "/xdg-desktop-portal-" version ".tar.xz"))
        (sha256
         (base32
-         "0r8y8qmzcfj7b7brqcxr9lg8pavfds815ffvj0kqc378fhgaln5q"))
-       (patches (search-patches
-                 ;; Disable portal tests since they try to use fuse.
-                 "xdg-desktop-portal-disable-portal-tests.patch"
-                 
"xdg-desktop-portal-disable-configuration-search-exit.patch"))))
+         "1pn0q7nn9xzd2wva9zpxn1dd2kqxwjm2a68yv9gaaa4alh9cvkb6"))
+       (patches
+        (search-patches
+         "xdg-desktop-portal-disable-configuration-search-exit.patch"))))
     (build-system meson-build-system)
     (arguments
-     `(#:configure-flags
-       (list "-Dsystemd=disabled")
-       #:phases
-       (modify-phases %standard-phases
-         (add-after 'unpack 'po-chmod
-           (lambda _
-             ;; Make sure 'msgmerge' can modify the PO files.
-             (for-each (lambda (po)
-                         (chmod po #o666))
-                       (find-files "po" "\\.po$"))))
-         (add-before 'configure 'relax-gcc-14-strictness
-           (lambda _
-             (setenv "CFLAGS"
-                     "-g -O2 -Wno-error=incompatible-pointer-types")))
-         (add-after 'unpack 'set-home-directory
-           (lambda _ (setenv "HOME" "/tmp"))))))
+     (list
+      #:configure-flags #~(list "-Dsystemd=disabled")
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'patch-libumockdev-preload.so-file-name
+            (lambda* (#:key native-inputs inputs #:allow-other-keys)
+              (substitute* "tests/conftest.py"
+                (("libumockdev-preload.so")
+                 (search-input-file (or native-inputs inputs)
+                                    "lib/libumockdev-preload.so")))))
+          (add-after 'unpack 'set-home-directory
+            (lambda _ (setenv "HOME" "/tmp")))
+          (add-before 'check 'prepare-for-tests
+            (lambda _
+              ;; These environment variables must be set when running the
+              ;; tests in an unprivileged container.  It avoids using
+              ;; bubblewrap to validate icon and sound files, which would fail
+              ;; in such an environment.
+              (setenv "XDP_VALIDATE_ICON_INSECURE" "1")
+              (setenv "XDP_VALIDATE_SOUND_INSECURE" "1"))))))
     (native-inputs
      (list gettext-minimal
            `(,glib "bin")
+           gst-plugins-good             ;for wavparse plugin
            pkg-config
            python
            python-dbusmock
            python-pytest
-           python-pytest-xdist))
+           python-pytest-xdist
+           umockdev))
     (inputs
      (list bubblewrap
            dbus
@@ -3186,6 +3191,7 @@ compatible with the well-known scripts of the same name.")
            gdk-pixbuf
            geoclue
            glib
+           gst-plugins-base
            json-glib
            libportal
            pipewire))
diff --git 
a/gnu/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch
 
b/gnu/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch
index eba07f8c35..80d5d777a9 100644
--- 
a/gnu/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch
+++ 
b/gnu/packages/patches/xdg-desktop-portal-disable-configuration-search-exit.patch
@@ -1,17 +1,10 @@
-From 37003d1f99246c88cbe7cf2f83616642e0fdf3fb Mon Sep 17 00:00:00 2001
-From: Rodion Goritskov <[email protected]>
-Date: Fri, 27 Sep 2024 00:44:07 +0400
-Subject: [PATCH] portal-impl: Check if there are any configuration files in 
XDG_DESKTOP_PORTAL_DIR before exiting configuration search
+Upstream-status: https://github.com/flatpak/xdg-desktop-portal/pull/1716
 
----
- src/portal-impl.c | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git a/src/portal-impl.c b/src/portal-impl.c
-index 8c1fd53..8708409 100644
---- a/src/portal-impl.c
-+++ b/src/portal-impl.c
-@@ -438,9 +438,8 @@ load_portal_configuration (gboolean opt_verbose)
+diff --git a/src/xdp-portal-impl.c b/src/xdp-portal-impl.c
+index 48a221d..389773a 100644
+--- a/src/xdp-portal-impl.c
++++ b/src/xdp-portal-impl.c
+@@ -501,9 +501,8 @@ load_portal_configuration (gboolean opt_verbose)
  
    if (portal_dir != NULL)
      {
@@ -19,9 +12,7 @@ index 8c1fd53..8708409 100644
 -      /* All other config directories are ignored when this is set */
 -      return;
 +      if (load_config_directory (portal_dir, desktops, opt_verbose))
-+      return;
++        return;
      }
  
    /* $XDG_CONFIG_HOME/xdg-desktop-portal/(DESKTOP-)portals.conf */
--- 
-2.46.0
diff --git a/gnu/packages/patches/xdg-desktop-portal-disable-portal-tests.patch 
b/gnu/packages/patches/xdg-desktop-portal-disable-portal-tests.patch
deleted file mode 100644
index 5e13493613..0000000000
--- a/gnu/packages/patches/xdg-desktop-portal-disable-portal-tests.patch
+++ /dev/null
@@ -1,56 +0,0 @@
-From b7750fa99c31c5f28ac2053fa154bef4038b5cc0 Mon Sep 17 00:00:00 2001
-From: dan <[email protected]>
-Date: Tue, 2 Jul 2024 19:37:38 +0800
-Subject: [PATCH] tests: remove portal tests.
-
----
- tests/meson.build | 24 ------------------------
- 1 file changed, 24 deletions(-)
-
-diff --git a/tests/meson.build b/tests/meson.build
-index a2dafee..bcd87be 100644
---- a/tests/meson.build
-+++ b/tests/meson.build
-@@ -181,18 +181,6 @@ portal_tests = [
- 
- test_env = env_tests
- test_env.set('XDG_CURRENT_DESKTOP', 'test')
--foreach p : portal_tests
--    test(
--      'test-portals-@0@'.format(p),
--      test_portals,
--      args: ['--verbose', '--keep-going', '--tap', '-p', 
'/portal/@0@'.format(p)],
--      depends: [test_backends, test_portals],
--      env: test_env,
--      is_parallel: false,
--      protocol: test_protocol,
--      suite: 'portals',
--    )
--endforeach
- 
- # Split the portal tests into one test per portal, this makes debugging a lot
- # easier.
-@@ -204,18 +192,6 @@ portal_limited = [
- 
- limited_env = env_tests
- limited_env.set('XDG_CURRENT_DESKTOP', 'limited')
--foreach p : portal_limited
--    test(
--      'limited-portals-@0@'.format(p),
--      limited_portals,
--      args: ['--verbose', '--keep-going', '--tap', '-p', 
'/limited/@0@'.format(p)],
--      depends: [test_backends, limited_portals],
--      env: limited_env,
--      is_parallel: false,
--      protocol: test_protocol,
--      suite: 'portals',
--    )
--endforeach
- 
- if enable_installed_tests
-   install_data(
-
-base-commit: 11c8a96b147aeae70e3f770313f93b367d53fedd
--- 
-2.41.0
-

Reply via email to