Subject: Re: bug#40572: installer networking: Connman detects no technologies on Acer Aspire

From: Ludovic Courtès <[email-masked]>
Date: Mon, 13 Apr 2020 15:18:29 +0200

Hi Florian,

(+Cc: Mathieu, who’s probably more familiar with Connman.)

"pelzflorian (Florian Pelz)" <[email-masked]> skribis:

> Nothing.  However, by now I burned a new image to DVD with the
> attached patch.  But I realize my mistake now; due to dbus-daemon
> eventually starting after networking failed, the logs are lost.

I don’t think so, because currently shepherd opens #:log-file in append
mode.  So I believe everything is there.

Nothing caught my eye in the log (but there’s a lot of stuff in there),
except (but I don’t know if it’s relevant):

  229: 0x7f98cd08d400: 1586778311.080442 [connection.c(2626):bus_transaction_send_error_reply] Sending error reply org.freedesktop.DBus.Error.ServiceUnknown "The name net.connman was not provided by any .service files"

And indeed, there’s no ‘.service’ file for that:

--8<---------------cut here---------------start------------->8---
$ find $(guix build connman) -name \*.service
/gnu/store/vclzrvbxac8ipc8g1ncq5gjjj8gdvxw3-connman-1.38/share/dbus-1/system-services/net.connman.vpn.service
--8<---------------cut here---------------end--------------->8---

The attach patch changes connman so that ‘net.connman.service’ is
installed.

Does it make any difference?

Thanks,
Ludo’.

diff --git a/gnu/packages/connman.scm b/gnu/packages/connman.scm
index 5f17a0ea95..4a5c4e6d3c 100644
--- a/gnu/packages/connman.scm
+++ b/gnu/packages/connman.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2017 Clément Lassieur <[email-masked]>
 ;;; Copyright © 2017 Ricardo Wurmus <[email-masked]>
 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <[email-masked]>
+;;; Copyright © 2020 Ludovic Courtès <[email-masked]>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -50,8 +51,18 @@
         (method url-fetch)
         (uri (string-append "mirror://kernel.org/linux/network/connman/"
                             "connman-" version ".tar.xz"))
-    (sha256
-     (base32 "0awkqigvhwwxiapw0x6yd4whl465ka8a4al0v2pcqy9ggjlsqc6b"))))
+        (sha256
+         (base32 "0awkqigvhwwxiapw0x6yd4whl465ka8a4al0v2pcqy9ggjlsqc6b"))
+        (modules '((guix build utils)))
+        (snippet
+         '(begin
+            ;; Install the D-Bus 'net.connman.service' file.  Note that we're
+            ;; patching something that is within an "if VPN", but that's OK
+            ;; since we build VPN support.
+            (substitute* "Makefile.in"
+              (("dbusservice_DATA =")
+               "dbusservice_DATA = src/net.connman.service "))
+            #t))))
     (build-system gnu-build-system)
     (arguments
      `(#:configure-flags