From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id KLTRKdVAvWP5gAEAbAwnHQ (envelope-from ) for ; Tue, 10 Jan 2023 11:41:25 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id sH/dKdVAvWPvBwEA9RJhRA (envelope-from ) for ; Tue, 10 Jan 2023 11:41:25 +0100 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 28B812068C for ; Tue, 10 Jan 2023 11:41:25 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pFBlr-0002iW-QE; Tue, 10 Jan 2023 05:22:19 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pFBle-0002gD-TA for guix-patches@gnu.org; Tue, 10 Jan 2023 05:22:12 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pFBla-0003Iq-JY for guix-patches@gnu.org; Tue, 10 Jan 2023 05:22:05 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pFBla-0006Ir-33 for guix-patches@gnu.org; Tue, 10 Jan 2023 05:22:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#60699] [PATCH 1/2] gnu: Add fwupd service. Resent-From: Jelle Licht Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 10 Jan 2023 10:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 60699 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: phodina , 60699@debbugs.gnu.org Cc: Ludovic =?UTF-8?Q?Court=C3=A8s?= Received: via spool by 60699-submit@debbugs.gnu.org id=B60699.167334611424200 (code B ref 60699); Tue, 10 Jan 2023 10:22:02 +0000 Received: (at 60699) by debbugs.gnu.org; 10 Jan 2023 10:21:54 +0000 Received: from localhost ([127.0.0.1]:38872 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pFBlS-0006IC-5T for submit@debbugs.gnu.org; Tue, 10 Jan 2023 05:21:54 -0500 Received: from mail1.fsfe.org ([217.69.89.151]:53880) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pFBlQ-0006Hz-AZ for 60699@debbugs.gnu.org; Tue, 10 Jan 2023 05:21:53 -0500 From: Jelle Licht DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fsfe.org; s=2021100501; t=1673346110; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=/5Xl3HL+ek+vJA+QNJDt17j6w2IMGz+0IsnF/cAPK5o=; b=LzPk4A9Hsp74roy9B9LA9NZxV6ZRMlcyyQzsXGupu5BUgOH6nFBZlooO+xYRnuKVgk8KYZ 1eCOgC/eAznVZHLd63RFva2JTin+vo/v8p6tqjfO9cWx2jRfTMnVUZ73LYgL82afIpDrLT l9UbOH/2SbT312GAKCg6w1dBkXNFq+4= In-Reply-To: <4jVXzFcbk7yONwfqid6qqilCgTRGy444TSoquZ-JyjNWsQ7wBLNZmrr221In95YehmkIVQGRFWaJSPIOHUx8jpr1V3JeXDuOQZ3WeRI-B6o=@protonmail.com> References: <4jVXzFcbk7yONwfqid6qqilCgTRGy444TSoquZ-JyjNWsQ7wBLNZmrr221In95YehmkIVQGRFWaJSPIOHUx8jpr1V3JeXDuOQZ3WeRI-B6o=@protonmail.com> Date: Tue, 10 Jan 2023 11:21:49 +0100 Message-ID: <87a62qbsg2.fsf@fsfe.org> MIME-Version: 1.0 Content-Type: text/plain 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-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Seal: i=1; s=key1; d=yhetil.org; t=1673347285; a=rsa-sha256; cv=none; b=qiPbgJvhndRz+cuiZoQe4JU5ZYg0AxcomDlOFO12fEIRrffPBP2EroOtbhHVGq6wvhQudC ZPONSnXC195fdd42W/cdFrN+VE8sGEMDl6VUHLI38+s6AIYXShQVBbRWz6w1Qv7Pnz3fVW 3aahVCv4oYiPMbz9WUG47bYTda2kKX0o1BDrW7QQlqZUe2Oc61M2oIY+NaAI6hA6Qb2Qkx aHU/3iMLF2tyYtRYUQd+cROaUUvXU1E/RxfIo7nD9PiWu2kPQKWIRXb6uxgxrEr/CLBzVt 7GGRl/kV8eZ+kytaQPjomGeXciZprjbc4Mo5DMQHbrWUpSaNnTNyXsd4gPMO9g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=fsfe.org header.s=2021100501 header.b=LzPk4A9H; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=fsfe.org (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1673347285; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: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=/5Xl3HL+ek+vJA+QNJDt17j6w2IMGz+0IsnF/cAPK5o=; b=QAXInZCAtqzOhaamlNbuqotx7g7kX27ipTd5OpXqG+uCLXq4kMosK3slq0FN34LRJeVjdL 7XessaJw2CHPoJNlIR61IWnpF4uMD1IGelAuDwFddN6s1Esdr0h8S1OR0YaxybyM3jz+bm zhI3SorkRTwaBEkZoxxbmdvJ1UGo9zeMs++NzGYOflw2qH/FEKCH6+jU/se6Sx0TXYorOg V6SnVAYDs2A9U2H/C+yPHWxJjXppPOnhCGXjcCWHVmtmohdKgtBXg8hEp4dQkD16sGMnUn dkRbpzEv+UbYqB7sI1w+ZaHnFW/cL71TL5Tb2TXv7KUaWfEI0KdySKInnbx43w== X-Migadu-Spam-Score: -1.98 X-Spam-Score: -1.98 X-Migadu-Queue-Id: 28B812068C X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=fsfe.org header.s=2021100501 header.b=LzPk4A9H; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=fsfe.org (policy=none) X-TUID: uJ/0Y6VlC+qc Hello Petr, phodina via Guix-patches via writes: > Hello, > > this patch adds the service for the fwupd package (commit 23152ff70f0ed4966d8207846f54c793d7cb4f86). > > Also the Gnome Shell provides nice GUI integration as shown in the attached screenshot. > > The package in the service configuration is there so users can choose the fwupd they want to use as the > one in Guix upstream does not support non-libre firmware. > > ---- > Petr > From 9eba8a2400ad296ed3ee8bc581528cabff969cd5 Mon Sep 17 00:00:00 2001 > From: Petr Hodina > Date: Wed, 7 Sep 2022 07:48:41 +0200 > Subject: [PATCH 1/2] gnu: Add fwupd service. > > * gnu/services/firmware.scm (fwupd): New variable. > > diff --git a/gnu/services/firmware.scm b/gnu/services/firmware.scm > new file mode 100644 > index 0000000000..7539c56202 > --- /dev/null > +++ b/gnu/services/firmware.scm > @@ -0,0 +1,70 @@ > +;;; GNU Guix --- Functional package management for GNU > +;;; Copyright ?? 2022 Petr Hodina ^ Something seems to have gone wrong with the encoding here. Could you try resending it? > +;;; > +;;; This file is part of GNU Guix. > +;;; > +;;; GNU Guix is free software; you can redistribute it and/or modify it > +;;; under the terms of the GNU General Public License as published by > +;;; the Free Software Foundation; either version 3 of the License, or (at > +;;; your option) any later version. > +;;; > +;;; GNU Guix is distributed in the hope that it will be useful, but > +;;; WITHOUT ANY WARRANTY; without even the implied warranty of > +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > +;;; GNU General Public License for more details. > +;;; > +;;; You should have received a copy of the GNU General Public License > +;;; along with GNU Guix. If not, see . > + > +(define-module (gnu services firmware) > + #:use-module (guix diagnostics) > + #:use-module (guix gexp) > + #:use-module (guix records) > + #:use-module (guix modules) > + #:use-module (guix i18n) > + #:use-module (guix ui) > + #:use-module (gnu services) > + #:use-module (gnu services base) > + #:use-module (gnu services shepherd) > + #:use-module (gnu packages firmware) > + #:use-module (srfi srfi-1) > + #:use-module (srfi srfi-26) > + #:use-module (srfi srfi-34) > + #:use-module (srfi srfi-35) > + #:use-module (ice-9 match) > + #:export (fwupd-configuration fwupd-service-type)) > + > + > +;;; > +;;; Fwupd daemon. > +;;; > + > +(define-record-type* fwupd-configuration > + make-fwupd-configuration fwupd-configuration? > + (fwupd fwupd-configuration-fwupd > + (default fwupd))) > + > +(define fwupd-activation-service > + #~(begin > + (use-modules (guix build utils)) > + (mkdir-p "/var/lib/fwupd"))) > + > +(define (fwupd-shepherd-service config) > + (shepherd-service (documentation "Run the fwupd daemon.") > + (provision '(fwupd)) > + (requirement '(dbus-system udev)) > + (start #~(make-forkexec-constructor (list (string-append #$fwupd > + "/libexec/fwupd/fwupd")))) > + (stop #~(make-kill-destructor)))) > + > +(define fwupd-service-type > + (service-type (name 'fwupd) > + (default-value (fwupd-configuration)) > + (extensions (list (service-extension activation-service-type > + (const > + fwupd-activation-service)) > + (service-extension > + shepherd-root-service-type > + (compose list fwupd-shepherd-service)))) > + (description > + "Run @command{fwupd}, the Firmware update daemon."))) Looks great! Does this actually work in practice though? I ran into some issues trying to run fwupd myself w.r.t. polkit (see https://issues.guix.gnu.org/60065). Never mind if it actually works for you though, IWBN if no further tweaks are required to get this to work. > base-commit: 437718442ca758a3857702cecfe5c80aa5df272b > -- > 2.38.1 > > From 108b4e57aa1682359195205e8b5679eae81445dd Mon Sep 17 00:00:00 2001 > From: Petr Hodina > Date: Tue, 6 Sep 2022 06:06:26 +0200 > Subject: [PATCH 2/2] gnu: Add gnome-firmware. > > * gnu/packages/gnome.scm (gnome-firmware): New variable. > > diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm > index 78e65d7400..f9c627b56a 100644 > --- a/gnu/packages/gnome.scm > +++ b/gnu/packages/gnome.scm > @@ -123,6 +123,7 @@ (define-module (gnu packages gnome) > #:use-module (gnu packages flex) > #:use-module (gnu packages fonts) > #:use-module (gnu packages file-systems) > + #:use-module (gnu packages firmware) > #:use-module (gnu packages fontutils) > #:use-module (gnu packages freedesktop) > #:use-module (gnu packages game-development) > @@ -2330,6 +2331,41 @@ (define-public gnome-disk-utility > (description "Disk management utility for GNOME.") > (license license:gpl2+))) > > +(define-public gnome-firmware > + (package > + (name "gnome-firmware") > + (version "42.2") > + (source (origin > + (method git-fetch) > + (uri (git-reference > + (url "https://gitlab.gnome.org/World/gnome-firmware") > + (commit version))) > + (sha256 > + (base32 > + "0p9fyqy3d5x6ap2ixw0wabmpdpzh7sdspaxl4f6qxx1sfnapci1g")))) > + (build-system meson-build-system) > + (arguments > + (list #:glib-or-gtk? #t > + #:configure-flags #~(list "-Dsystemd=false" "-Delogind=true"))) > + (native-inputs (list desktop-file-utils > + gettext-minimal > + `(,glib "bin") > + `(,gtk "bin") > + help2man > + pkg-config)) > + (inputs (list gtk fwupd libadwaita libxmlb elogind)) > + (synopsis "Manage firmware on devices") 'Manage' is a word that does not really with low signal-to-noise ratio. Would there be a way to rephrase this? > + (description > + "This package provides integration of firmware manager: > + @itemize > +@item Upgrade, Downgrade, & Reinstall firmware on devices supported by fwupd. > +@item Unlock locked fwupd devices > +@item Verify firmware on supported devices > +@item Display all releases for a fwupd device Releases of what? What's a fwupd device? Thanks for the patches! - Jelle