all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Brice Waegeneire <brice@waegenei.re>
To: 41193@debbugs.gnu.org
Subject: [bug#41193] [PATCH v2 03/15] gnu: network-manager: Switch to meson-build-system.
Date: Fri, 22 May 2020 19:12:34 +0200	[thread overview]
Message-ID: <20200522171246.30959-4-brice@waegenei.re> (raw)
In-Reply-To: <20200522171246.30959-1-brice@waegenei.re>

---
 gnu/packages/gnome.scm | 134 ++++++++++++++++++++++-------------------
 1 file changed, 71 insertions(+), 63 deletions(-)

diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm
index 77dd669e97..33d4b38b14 100644
--- a/gnu/packages/gnome.scm
+++ b/gnu/packages/gnome.scm
@@ -6366,42 +6366,42 @@ users.")
                   (substitute* "src/devices/wwan/nm-modem-manager.c"
                     (("systemd") "elogind"))
                   #t))))
-    (build-system gnu-build-system)
+    (build-system meson-build-system)
     (outputs '("out"
                "doc")) ; 8 MiB of gtk-doc HTML
     (arguments
-     '(#:configure-flags
+     `(#:configure-flags
        (let ((out      (assoc-ref %outputs "out"))
-             (doc      (assoc-ref %outputs "doc"))
              (dhclient (string-append (assoc-ref %build-inputs "isc-dhcp")
                                       "/sbin/dhclient")))
-         (list "--with-libnm-glib" ; needed by network-manager-applet
-               "--with-systemd-journal=no"
-               "--with-session-tracking=elogind"
-               "--with-suspend-resume=elogind"
-               "--with-consolekit=no"
-               "--with-crypto=gnutls"
-               "--with-iwd=yes"
-               "--with-libaudit=yes"
-               "--with-resolvconf=yes"
-               "--sysconfdir=/etc"
-               "--localstatedir=/var"
-               (string-append "--with-udev-dir="
-                              out "/lib/udev")
-               (string-append "--with-dbus-sys-dir="
-                              out "/etc/dbus-1/system.d")
-               (string-append "--with-html-dir="
-                              doc "/share/gtk-doc/html")
-               (string-append "--with-dhclient=" dhclient)))
+         (list
+          ;; Otherwise, the RUNPATH will lack the final 'NetworkManager' path
+          ;; component.
+          (string-append "-Dc_link_args=-Wl,-rpath="
+                         out "/lib:"
+                         out "/lib/NetworkManager/" ,version)
+          "-Dsystemd_journal=false"
+          "-Dsession_tracking=elogind"
+          "-Dsuspend_resume=elogind"
+          "-Dsystemdsystemunitdir=no"
+          "-Dsession_tracking_consolekit=false"
+          "-Ddhcpcd=no"
+          "-Ddhcpcanon=no"
+          "-Dcrypto=gnutls"
+          "-Diwd=true"
+          "-Dlibaudit=yes"
+          "-Dqt=false"
+          "-Ddocs=true"
+          "--sysconfdir=/etc"
+          "--localstatedir=/var"
+          (string-append "-Dudev_dir="
+                         out "/lib/udev")
+          (string-append "-Ddbus_conf_dir="
+                         out "/etc/dbus-1/system.d")
+
+          (string-append "-Ddhclient=" dhclient)))
        #:phases
        (modify-phases %standard-phases
-         ;; This bare "ls" invocation breaks some tests.
-         (add-after 'unpack 'patch-ls-invocation
-           (lambda _
-             (substitute* "build-aux/ltmain.sh"
-               (("`ls -")
-                (string-append "`" (which "ls") " -")))
-             #t))
          (add-before 'configure 'pre-configure
            (lambda _
              ;; These tests try to test aspects of network-manager's
@@ -6409,61 +6409,64 @@ users.")
              ;; cope with being already in the Guix build jail as that jail
              ;; lacks some features that they would like to proxy over (like
              ;; a /sys mount).
-             (substitute* '("Makefile.in")
-               (("src/platform/tests/test-address-linux") " ")
-               (("src/platform/tests/test-cleanup-linux") " ")
-               (("src/platform/tests/test-link-linux") " ")
-               (("src/platform/tests/test-route-linux") " ")
-               (("src/devices/tests/test-acd") "")
-               (("src/devices/tests/test-arping") " ")
-               (("src/devices/tests/test-lldp") " ")
-               (("src/tests/test-route-manager-linux") " "))
-             #t))
-         (add-after 'unpack 'delete-failing-tests
-           (lambda _
-             ;; FIXME: These three tests fail for unknown reasons.
-             ;; ERROR:libnm-core/tests/test-general.c:5842:
-             ;;   _json_config_check_valid: assertion failed (res == expected): (1 == 0)
-             ;; ERROR:libnm-core/tests/test-keyfile.c:647:
-             ;;   test_team_conf_read_invalid: assertion failed: (nm_setting_team_get_config (s_team) == NULL)
-             ;; ERROR:libnm-core/tests/test-setting.c:907:
-             ;;   _test_team_config_sync: assertion failed: (nm_streq0 (nm_setting_team_get_runner (s_team), runner))
-             (substitute* "Makefile.in"
-               (("libnm-core/tests/test-general") " ")
-               (("libnm-core/tests/test-keyfile") " ")
-               (("libnm-core/tests/test-setting\\$\\(EXEEXT\\)") " "))
+             (substitute* "src/platform/tests/meson.build"
+               ((".*test-address-linux.*") "")
+               ((".*test-cleanup-linux.*") "")
+               ((".*test-link-linux.*") "")
+               ((".*test-route-linux.*") ""))
+             (substitute* "src/devices/tests/meson.build"
+               ((".*test-acd.*") "")
+               ((".*test-lldp.*") ""))
              #t))
+         (add-after 'unpack 'patch-docbook-xml
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((xmldoc (string-append (assoc-ref inputs "docbook-xml")
+                                          "/xml/dtd/docbook")))
+               (substitute* (find-files "." ".*\\.(xsl|xml)")
+                 (("http://.*/docbookx\\.dtd")
+                  (string-append xmldoc "/docbookx.dtd")))
+               #t)))
          (add-before 'check 'pre-check
            (lambda _
              ;; For the missing /etc/machine-id.
              (setenv "DBUS_FATAL_WARNINGS" "0")
              #t))
-         (replace 'install
+         (add-before 'install 'no-polkit-magic
+           ;; Meson ‘magically’ invokes pkexec, which fails (not setuid).
            (lambda _
-             (invoke "make"
-                     "sysconfdir=/tmp"
-                     "rundir=/tmp"
-                     "statedir=/tmp"
-                     "nmstatedir=/tmp/nm"
-                     "install")
-             #t)))))
+             (setenv "PKEXEC_UID" "something")
+             #t))
+         (add-after 'install 'move-doc
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out"))
+                   (doc (assoc-ref outputs "doc")))
+               (mkdir-p (string-append doc "/share"))
+               (for-each (lambda (directory)
+                           (copy-recursively (string-append out directory)
+                                             (string-append doc directory))
+                           (delete-file-recursively
+                            (string-append out directory)))
+                         '("/share/doc" "/share/gtk-doc"))
+               #t))))))
     (propagated-inputs
      `(("glib" ,glib)))
     (native-inputs
-     `(("glib:bin" ,glib "bin") ; for gdbus-codegen
+     `(("glib:bin" ,glib "bin")         ; for gdbus-codegen
+       ("gtk-doc" ,gtk-doc)
        ("gobject-introspection" ,gobject-introspection)
+       ("docbook-xml" ,docbook-xml)
        ("docbook-xsl" ,docbook-xsl)
        ("intltool" ,intltool)
        ("libxslt" ,libxslt)
        ("libxml2" ,libxml2)
        ("pkg-config" ,pkg-config)
+       ("vala" ,vala)
        ;; For testing.
        ("python" ,python-wrapper)
        ("python-dbus" ,python-dbus)
        ("python-pygobject" ,python-pygobject)))
     (inputs
-     `(("coreutils" ,coreutils) ; for ls
-       ("curl" ,curl)
+     `(("curl" ,curl)
        ("cyrus-sasl" ,cyrus-sasl)
        ("dbus-glib" ,dbus-glib)
        ("dnsmasq" ,dnsmasq)
@@ -6479,6 +6482,7 @@ users.")
        ("libndp" ,libndp)
        ("libnl" ,libnl)
        ("libsoup" ,libsoup)
+       ("mobile-broadband-provider-info" ,mobile-broadband-provider-info)
        ("modem-manager" ,modem-manager)
        ("newt" ,newt)                       ;for the 'nmtui' console interface
        ("openresolv" ,openresolv)           ; alternative resolv.conf manager
@@ -6495,7 +6499,11 @@ devices and connections, attempting to keep active network connectivity when
 available.  It manages ethernet, WiFi, mobile broadband (WWAN), and PPPoE
 devices, and provides VPN integration with a variety of different VPN
 services.")
-    (license license:gpl2+)
+    ;; “This NetworkManager project consists of the daemon, client tools, and
+    ;; libnm. libnm is licensed LGPL-2.1+, while the rest is licensed under
+    ;; GPL-2.0+.”
+    (license (list license:gpl2+
+                   license:lgpl2.1+))
     (properties '((upstream-name . "NetworkManager")))))
 
 (define-public network-manager-openvpn
-- 
2.26.2





  parent reply	other threads:[~2020-05-22 17:14 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-11 18:50 [bug#41193] [PATCH 00/13] Update network-manager suite Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 01/13] gnu: network-manager: Update to 1.24.0 Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 02/13] gnu: network-manager: Add iwd support Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 03/13] gnu: network-manager: Switch to meson-build-system Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 04/13] gnu: network-manager: Appease guix lint Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 05/13] gnu: modem-manager: Update to 1.12.10 Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 06/13] gnu: libnma: Update to 1.8.28 Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 07/13] gnu: libnma: Update inputs and licenses Brice Waegeneire
2020-05-11 20:00   ` Leo Famulari
2020-05-12 21:18     ` Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 08/13] gnu: libnma: Adjust indentation Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 09/13] gnu: network-manager-openvpn: Update to 1.8.12 Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 10/13] gnu: network-manager-openconnect: Use libnma Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 11/13] gnu: network-manager-vpnc: " Brice Waegeneire
2020-05-11 20:01   ` Leo Famulari
2020-05-22 18:20     ` Jonathan Brielmaier
2020-05-11 19:00 ` [bug#41193] [PATCH 12/13] gnu: network-manager-applet: Update to 1.16.0 Brice Waegeneire
2020-05-11 19:00 ` [bug#41193] [PATCH 13/13] gnu: network-manager-applet: Appease guix lint Brice Waegeneire
2020-05-11 20:05 ` [bug#41193] [PATCH 00/13] Update network-manager suite Leo Famulari
2020-05-12 21:12   ` Brice Waegeneire
2020-05-12 21:36     ` Leo Famulari
2020-05-22 16:35       ` Brice Waegeneire
2020-05-22 20:04         ` Leo Famulari
2020-05-22 17:12 ` [bug#41193] [PATCH v2 00/15] " Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 01/15] gnu: network-manager: Update to 1.24.0 Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 02/15] gnu: network-manager: Add iwd support Brice Waegeneire
2020-05-22 17:12   ` Brice Waegeneire [this message]
2020-05-22 17:12   ` [bug#41193] [PATCH v2 04/15] gnu: network-manager: Appease guix lint Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 05/15] gnu: modem-manager: Update to 1.12.10 Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 06/15] gnu: libnma: Update to 1.8.28 Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 07/15] gnu: libnma: Update inputs Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 08/15] gnu: libnma: Adjust indentation Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 09/15] gnu: network-manager-openvpn: Update to 1.8.12 Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 10/15] gnu: network-manager-openconnect: Use libnma Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 11/15] gnu: network-manager-vpnc: Use 'libnma' Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 12/15] gnu: network-manager-applet: Update to 1.16.0 Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 13/15] gnu: network-manager-applet: Appease guix lint Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 14/15] gnu: gnome-initial-setup: Use 'libnma' Brice Waegeneire
2020-05-22 17:12   ` [bug#41193] [PATCH v2 15/15] gnu: gnome-control-center: " Brice Waegeneire
2020-05-22 20:05   ` [bug#41193] [PATCH v2 00/15] Update network-manager suite Leo Famulari
2020-05-22 21:23     ` bug#41193: " Brice Waegeneire
2020-05-22 19:48 ` [bug#41193] [PATCH 11/13] gnu: network-manager-vpnc: Use libnma Brice Waegeneire

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200522171246.30959-4-brice@waegenei.re \
    --to=brice@waegenei.re \
    --cc=41193@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.