From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:8:6d80::]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id DLs7DatGfGBncgAAgWs5BA (envelope-from ) for ; Sun, 18 Apr 2021 16:48:11 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id GgnmBqtGfGDYYwAAB5/wlQ (envelope-from ) for ; Sun, 18 Apr 2021 14:48:11 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B34A523256 for ; Sun, 18 Apr 2021 16:48:10 +0200 (CEST) Received: from localhost ([::1]:58404 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lY8iX-0006xE-TY for larch@yhetil.org; Sun, 18 Apr 2021 10:48:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56764) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lY8iQ-0006x6-Ln for guix-patches@gnu.org; Sun, 18 Apr 2021 10:48:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:35854) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lY8iQ-0003Ot-3i for guix-patches@gnu.org; Sun, 18 Apr 2021 10:48:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lY8iP-0002bD-LE for guix-patches@gnu.org; Sun, 18 Apr 2021 10:48:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#47870] [PATCH 1/2] gnu: polkit-gnome: Add autostart .desktop file. Resent-From: Leo Prikler Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 18 Apr 2021 14:48:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47870 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Brendan Tildesley , 47870@debbugs.gnu.org Received: via spool by 47870-submit@debbugs.gnu.org id=B47870.16187572789982 (code B ref 47870); Sun, 18 Apr 2021 14:48:01 +0000 Received: (at 47870) by debbugs.gnu.org; 18 Apr 2021 14:47:58 +0000 Received: from localhost ([127.0.0.1]:47400 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY8iH-0002ar-6M for submit@debbugs.gnu.org; Sun, 18 Apr 2021 10:47:58 -0400 Received: from mailrelay.tugraz.at ([129.27.2.202]:38267) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lY8iE-0002ag-HD for 47870@debbugs.gnu.org; Sun, 18 Apr 2021 10:47:51 -0400 Received: from nijino.local (194-96-9-9.adsl.highway.telekom.at [194.96.9.9]) by mailrelay.tugraz.at (Postfix) with ESMTPSA id 4FNXqQ2gxgz1LLyL; Sun, 18 Apr 2021 16:47:45 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 mailrelay.tugraz.at 4FNXqQ2gxgz1LLyL DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tugraz.at; s=mailrelay; t=1618757266; bh=Oo5J2bfhvXJJQACATytNkVHitPFNqcL6mqiT16WSVwE=; h=Subject:From:To:Date:In-Reply-To:References:From; b=LtfkwG+jDDnMWzLJxnqb9FlStAvFUUL5lxBiCvI5ciRCi0ySIgjiUUXm4aPhR91/s tqF4EskO1xPIPzEFSPZ+jdw9Am88tX0oOroSCPp0+zNjIO8vbJtMXFyaSFCDQth9vE w5aQzGaYBrmsFDa1WRlIZVJ824nz8umd15k9aBvM= Message-ID: From: Leo Prikler Date: Sun, 18 Apr 2021 16:47:44 +0200 In-Reply-To: <20210418131727.6104-1-mail@brendan.scot> References: <20210418131727.6104-1-mail@brendan.scot> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.34.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TUG-Backscatter-control: bt4lQm5Tva3SBgCuw0EnZw X-Spam-Scanner: SpamAssassin 3.003001 X-Spam-Score-relay: -1.9 X-Scanned-By: MIMEDefang 2.74 on 129.27.10.117 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1618757290; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=Oo5J2bfhvXJJQACATytNkVHitPFNqcL6mqiT16WSVwE=; b=KfxHkJc3sxygROKXW92GT58NVczkbkKX6rqxNfZPi2ROGeBMhit5/d7Ume30bTNy+Myfl8 P+Gw3LWIlAmo4DiMu+TTQrv5/AYTA2KQ8wdEya/GDn4B4T19rAULtheed3RP1xMEhxsfEY C+bJgQTTV62LFoa/kVYOdGH6dj4WLAn1qUvL+L1m96E6YtgpfaJSU5PAWaB4z01SVUBuZf +nSnF3kdKFvcvhT+MshBDKiqkodHenQxhYQ6rfUXIDjpxVxMM/88VN4s/mvfJ7gI8ZBS2t jdIk3Fbi+7ZCIXyVxc7h+PEAydmLSxufQ3sotuiLA+jC+hyzMf0m8P4pV0tHQA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1618757290; a=rsa-sha256; cv=none; b=BI7PUGjt0JgNpkdVQ4q/sNCZkDd8RQHH3GmWfhjl5ZnF1TbkPNqwG/gyO3VevNTuB4xXIE 0I5lkUsmDH1E2Wg86Yx/b6j7ks28ciYRVFju1rPoH8Z+ia7YKSAHXVqEfl5/B6oocstrpl X6Msg1XMsoAry5Ra67LLzAXDifn5neqy1x5pCG7FHHlJyd1DLuHaB4pNmvQIyr9C5jTao6 lXrH9TOgOMYLt7cFEMYbvtZGp8vGKgX4oLjx82qxF8BQ3kFewUxkao/fXOOXHcEUujyBrq RMof8dIzbhUO0S1U+b+MIBPEXnQhliD3XernphJUEVdrOr3Z6qnhaF42FFOJPA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tugraz.at header.s=mailrelay header.b=LtfkwG+j; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -1.34 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=tugraz.at header.s=mailrelay header.b=LtfkwG+j; dmarc=fail reason="SPF not aligned (relaxed)" header.from=student.tugraz.at (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: B34A523256 X-Spam-Score: -1.34 X-Migadu-Scanner: scn0.migadu.com X-TUID: duMNEsLSTjrI Hi Brendan, Am Sonntag, den 18.04.2021, 23:17 +1000 schrieb Brendan Tildesley: > * gnu/packages/polkit.scm (polkit-gnome): > [inputs]: Source a translated .desktop file from Arch Linux. > [arguments]: Install the .desktop file into /etc/autostart and set > OnlyShowIn to XFCE so it will be autostarted only by XFCE. > [description]: Add a note clarifying that this package is currently > only > used for XFCE, not GNOME. > --- > gnu/packages/polkit.scm | 39 +++++++++++++++++++++++++++++++++++---- > 1 file changed, 35 insertions(+), 4 deletions(-) > > diff --git a/gnu/packages/polkit.scm b/gnu/packages/polkit.scm > index d868aceec2..1c5173921c 100644 > --- a/gnu/packages/polkit.scm > +++ b/gnu/packages/polkit.scm > @@ -6,6 +6,7 @@ > ;;; Copyright © 2017 Huang Ying > ;;; Copyright © 2018 Tobias Geerinckx-Rice > ;;; Copyright © 2018 Ricardo Wurmus > +;;; Copyright © 2021 Brendan Tildesley > ;;; > ;;; This file is part of GNU Guix. > ;;; > @@ -183,12 +184,42 @@ easily with PolicyKit.") > "0sckmcbxyj6sbrnfc5p5lnw27ccghsid6v6wxq09mgxqcd4lk10 > p")))) > (build-system gnu-build-system) > (inputs `(("gtk+" ,gtk+) > - ("polkit" ,polkit))) > + ("polkit" ,polkit) > + ("desktop-file" > + ,(origin > + (method url-fetch) > + (uri > + (string-append > + " > https://raw.githubusercontent.com/archlinux/svntogit-community/" > + "8963650797cfe0383ef510e9c0492b2cb22a2593/repos/ > community-x86_64/" > + "polkit-gnome-authentication-agent-1.desktop")) > + (sha256 > + (base32 > + "1rqy8jf01idaqnyrzjaapr7pzx8zg2x9kmw70n1p9cpalhi > wfx2h")))))) Instead of sourcing the desktop file from a really obscure location, would it be possible to express this in terms of `make-desktop-entry- file'? This also has the added advantage, that it could be inlined into the phase. > (native-inputs `(("intltool" ,intltool) > ("pkg-config" ,pkg-config))) > + (arguments > + `(#:phases > + (modify-phases %standard-phases > + (add-after 'install 'install-autostart-file > + (lambda* (#:key inputs outputs #:allow-other-keys) > + (let* ((out (assoc-ref outputs "out")) > + (autostart-dir (string-append out > "/etc/xdg/autostart")) > + (desktop (string-append > + autostart-dir > + "/polkit-gnome-authentication-agent- > 1.desktop"))) > + (mkdir-p autostart-dir) > + (copy-file (assoc-ref inputs "desktop-file") desktop) > + (substitute* desktop > + (("^Exec=.*") > + (string-append > + "Exec=" out "/libexec/polkit-gnome- > authentication-agent-1\n")) > + ;; This will mean the agent will only be started in > XFCE. > + (("^OnlyShowIn=.*") "OnlyShowIn=XFCE;\n")))))))) See above. > (synopsis "Legacy polkit authentication agent for GNOME") > - (description "PolicyKit-gnome provides a D-Bus session bus > service > -that is used to bring up authentication dialogs used for obtaining > -privileges.") > + (description "PolicyKit-gnome provides a D-Bus session bus > service that > +is used to bring up authentication dialogs used for obtaining > privileges. > +PolicyKit-gnome is no longer used in GNOME but has become the > default agent > +for XFCE.") Is that so? Even if this holds for GNOME 40, it's not true for Guix' GNOME until wip-gnome is merged, or does 3.34 already use something else? > (home-page "https://www.freedesktop.org/wiki/Software/polkit/") > (license lgpl2.0+))) Regards, Leo