diff mbox series

[bug#60699,1/2] gnu: Add fwupd service.

Message ID 2QY4qmI1HEY8z5nFzdmKy4dh65q6GHmMaOl1KXu0u3tL3EnVVuwL3IkCHjAjI6P9axsRfEsEU33HcRARJLDj4u_-uw6-GwokEtNMkok9HF4=@protonmail.com
State New
Headers show
Series [bug#60699,1/2] gnu: Add fwupd service. | expand

Commit Message

phodina Jan. 10, 2023, 12:06 p.m. UTC
Hi Jelle,

I've tested the fwupd on my Asus Zenbook machine - see the attached screenshot.

Without the service running the gnome-firmware or fwupdtool didn't work.

With the service running I get some information about the firmware, EFI... It hasn't been battle tested by updating anything as the firmware there is the latest.

I've also tried adding polkit extension but it seems to run without it in my case. Could you please test the patch if it works also for you, if not we can add it :-)

Check the rewritten synposis for gnome-firmware.


----
Petr

Comments

Jelle Licht Jan. 11, 2023, 2:31 p.m. UTC | #1
phodina <phodina@protonmail.com> writes:

> Hi Jelle,
>
> I've tested the fwupd on my Asus Zenbook machine - see the attached screenshot.
>
> Without the service running the gnome-firmware or fwupdtool didn't work.
>
> With the service running I get some information about the firmware, EFI... It hasn't been battle tested by updating anything as the firmware there is the latest.
>
> I've also tried adding polkit extension but it seems to run without it in my case. Could you please test the patch if it works also for you, if not we can add it :-)
>

From my system logs:
--8<---------------cut here---------------start------------->8---
Jan 11 15:17:09 localhost shepherd[1]: [fwupd] 14:17:09:0330 FuMain
another service has claimed the dbus name org.freedesktop.fwupd
Jan 11 15:17:09 localhost shepherd[1]: Respawning fwupd.
--8<---------------cut here---------------end--------------->8---
(and this repeated till shepherd disables the fwupd service).

Note that 'another service has claimed the dbus name' seems to be a
misleading error message:

Running `sudo herd enable fwupd', `sudo herd start fwupd', while paying
attention to the output of `sudo dbus-monitor --system' (/w `guix shell
dbus') in another terminal:

--8<---------------cut here---------------start------------->8---
method call time=1673446874.805907 sender=:1.162 -> destination=org.freedesktop.DBus serial=645 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=RequestName
   string "org.freedesktop.fwupd"
   uint32 3
error time=1673446874.805914 sender=org.freedesktop.DBus -> destination=:1.162 error_name=org.freedesktop.DBus.Error.AccessDenied reply_serial=645
   string "Connection ":1.162" is not allowed to own the service "org.freedesktop.fwupd" due to security policies in the configuration file"
--8<---------------cut here---------------end--------------->8---

WDYT about adding a system test that verifies that fwupd can be started?
Then we will know whether it's an anomaly on either of our respective
machines :-). 

Additionally, would you be able to write documentation for the new
service as well?

> Check the rewritten synposis for gnome-firmware.
LGTM.

Thanks!
- Jelle
diff mbox series

Patch

From 108b4e57aa1682359195205e8b5679eae81445dd Mon Sep 17 00:00:00 2001
From: Petr Hodina <phodina@protonmail.com>
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 "Update, reinstall and downgrade firmware on devices supported
+by fwupd")
+    (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
+@end itemize")
+    (home-page "https://gitlab.gnome.org/World/gnome-firmware")
+    (license license:gpl2+)))
+
 (define-public gnome-font-viewer
   (package
     (name "gnome-font-viewer")
-- 
2.38.1