gnu: mate-polkit: Enable autostart for the Xfce desktop environment.

* gnu/packages/mate.scm (mate-polkit) [arguments]: Add
enable-autostart-for-xfce phase.
(mate-polkit-for-xfce): Remove variable.
* gnu/packages/xfce.scm (xfce) [propagated-inputs]: Replace
mate-polkit-for-xfce with mate-polkit.

Change-Id: I07e48d0cd70aeec8ee3cab081226adaa0fe175be
This commit is contained in:
宋文武 2025-08-23 19:58:44 +08:00
parent bd3a3d0066
commit 164b8b67a5
No known key found for this signature in database
GPG key ID: D415BF253B515976
2 changed files with 13 additions and 19 deletions

View file

@ -1555,6 +1555,18 @@ MATE Desktop to monitor your system resources and usage.")
(base32
"1s2ac2p5smiwr7lf4snciyb9waclychjmzrw32f2qspdm381s2im"))))
(build-system glib-or-gtk-build-system)
(arguments
(list
#:phases
#~(modify-phases %standard-phases
(add-after 'install 'enable-autostart-for-xfce
(lambda _
;; We also use mate-polkit in Xfce.
(substitute* (string-append
#$output
"/etc/xdg/autostart/"
"polkit-mate-authentication-agent-1.desktop")
(("OnlyShowIn=MATE;") "OnlyShowIn=MATE;XFCE;")))))))
(native-inputs
(list gettext-minimal gtk-doc/stable intltool libtool pkg-config))
(inputs
@ -1571,24 +1583,6 @@ MATE Desktop to monitor your system resources and usage.")
used to bring up authentication dialogs.")
(license license:lgpl2.1)))
(define-public mate-polkit-for-xfce
(package/inherit mate-polkit
(arguments
`(#:phases
(modify-phases %standard-phases
(add-after 'install 'patch-desktop
(lambda* (#:key outputs #:allow-other-keys)
(let* ((common (string-append
(assoc-ref outputs "out") "/etc/xdg/autostart/"
"polkit-mate-authentication-agent-"))
(old (string-append common "1.desktop"))
(new (string-append common "for-xfce-1.desktop")))
(substitute* old (("MATE;") "XFCE;"))
;; To avoid a conflict if both MATE and XFCE are installed.
(rename-file old new)))))))
(properties `((hidden? . #t)))))
(define-public mozo
(package
(name "mozo")

View file

@ -1360,7 +1360,7 @@ for and start applications.")
font-dejavu ;default font
greybird-gtk-theme
hicolor-icon-theme
mate-polkit-for-xfce
mate-polkit
mousepad
ristretto
shared-mime-info