commit:     7090fcd34877abca9b315684c949fbde160fabc8
Author:     Jory Pratt <anarchy <AT> gentoo <DOT> org>
AuthorDate: Mon Apr 27 18:53:33 2020 +0000
Commit:     Jory Pratt <anarchy <AT> gentoo <DOT> org>
CommitDate: Mon Apr 27 18:53:47 2020 +0000
URL:        https://gitweb.gentoo.org/proj/musl.git/commit/?id=7090fcd3

net-misc/networkmanager: Bump for latest stable

Package-Manager: Portage-2.3.89, Repoman-2.3.20
Signed-off-by: Jory Pratt <anarchy <AT> gentoo.org>

 net-misc/networkmanager/Manifest                   |  2 +-
 ...top.NetworkManager.settings.modify.system.rules |  7 --
 .../networkmanager/files/1.18.4-iwd1-compat.patch  | 81 ++++++++++++++++++++++
 net-misc/networkmanager/files/10-openrc-status-r4  | 35 ----------
 .../networkmanager/files/conf.d.NetworkManager     |  4 --
 .../files/fix-busted-configure.patch               | 25 -------
 .../networkmanager/files/init.d.NetworkManager-r1  | 58 ----------------
 net-misc/networkmanager/files/musl-basic.patch     | 48 ++++++-------
 .../networkmanager/files/musl-fix-includes.patch   | 32 ++++-----
 .../files/musl-has-not-secure-gentenv.patch        | 25 -------
 .../files/musl-network-support.patch               | 12 ++--
 .../networkmanager/files/musl-process-util.patch   | 14 ++--
 ...ager-data-fix-the-ID_NET_DRIVER-udev-rule.patch | 33 +++++++++
 ...16.2.ebuild => networkmanager-1.18.4-r3.ebuild} | 50 ++++++-------
 14 files changed, 194 insertions(+), 232 deletions(-)

diff --git a/net-misc/networkmanager/Manifest b/net-misc/networkmanager/Manifest
index 8d8275c..28743c1 100644
--- a/net-misc/networkmanager/Manifest
+++ b/net-misc/networkmanager/Manifest
@@ -1 +1 @@
-DIST NetworkManager-1.16.2.tar.xz 4820392 BLAKE2B 
f85fa4ff27cb2f0fc7d58052c810d4c20ca51d6e77e400c44270f941de6b4878b0c645053b9ffb02c3587b6c7b17631f9a6c6c15b630da4747051e1745d1dae8
 SHA512 
b3e874786d0bce58b967677fe82980aac58023fd4e913345acb63d7a7f253cd8fa6c044e788dd337a52f0fb026ce5fbd333d738dc9c3644d696e85498120f6d2
+DIST NetworkManager-1.18.4.tar.xz 4875196 BLAKE2B 
9c58d6d7317562332dfa9639f8e236a0a7f6b58e7dad5af83916b1c6178899a6bcf12bc289fb401d84fd6420306364b4c4c0a25eda2a08eef812acde1862a18a
 SHA512 
9fd22775a400ee8d20c75ebddfee842bfbd8780966444dd537e371a65918f41640e921d2c441853afe8f72d693e9b4c1415435136a07004666a6af4799fd3350

diff --git 
a/net-misc/networkmanager/files/01-org.freedesktop.NetworkManager.settings.modify.system.rules
 
b/net-misc/networkmanager/files/01-org.freedesktop.NetworkManager.settings.modify.system.rules
deleted file mode 100644
index d00b268..0000000
--- 
a/net-misc/networkmanager/files/01-org.freedesktop.NetworkManager.settings.modify.system.rules
+++ /dev/null
@@ -1,7 +0,0 @@
-// Let users in plugdev group modify NetworkManager
-polkit.addRule(function(action, subject) {
-    if (action.id == "org.freedesktop.NetworkManager.settings.modify.system" &&
-        subject.isInGroup("plugdev") && subject.active) {
-        return "yes";
-    }
-});

diff --git a/net-misc/networkmanager/files/1.18.4-iwd1-compat.patch 
b/net-misc/networkmanager/files/1.18.4-iwd1-compat.patch
new file mode 100644
index 0000000..12c8b87
--- /dev/null
+++ b/net-misc/networkmanager/files/1.18.4-iwd1-compat.patch
@@ -0,0 +1,81 @@
+From 59923ad85d1a1cf2216a4f14649702d24d3f2360 Mon Sep 17 00:00:00 2001
+From: Lubomir Rintel <[email protected]>
+Date: Sat, 2 Nov 2019 06:55:54 +0100
+Subject: [PATCH 1/2] iwd: add some missing error handling
+
+g_dbus_object_manager_get_interface() can happily return NULL and we
+need to check for that.
+---
+ src/devices/wifi/nm-iwd-manager.c | 10 ++++++++++
+ 1 file changed, 10 insertions(+)
+
+diff --git a/src/devices/wifi/nm-iwd-manager.c 
b/src/devices/wifi/nm-iwd-manager.c
+index dd1cad480..e83f8063c 100644
+--- a/src/devices/wifi/nm-iwd-manager.c
++++ b/src/devices/wifi/nm-iwd-manager.c
+@@ -136,6 +136,11 @@ agent_dbus_method_cb (GDBusConnection *connection,
+       network = g_dbus_object_manager_get_interface (priv->object_manager,
+                                                      network_path,
+                                                      
NM_IWD_NETWORK_INTERFACE);
++      if (!network) {
++              _LOGE ("unable to find the network object");
++              return;
++      }
++
+ 
+       device_path = get_property_string_or_null (G_DBUS_PROXY (network), 
"Device");
+       if (!device_path) {
+@@ -260,6 +265,11 @@ register_agent (NMIwdManager *self)
+                                                            "/",
+                                                            
NM_IWD_AGENT_MANAGER_INTERFACE);
+ 
++      if (!agent_manager) {
++              _LOGE ("unable to register the IWD Agent: PSK/8021x Wi-Fi 
networks may not work");
++              return;
++      }
++
+       /* Register our agent */
+       g_dbus_proxy_call (G_DBUS_PROXY (agent_manager),
+                          "RegisterAgent",
+-- 
+2.20.1
+
+
+From 186d22a9634e2bf94658ed6f1cf2b332ecb3a32c Mon Sep 17 00:00:00 2001
+From: Lubomir Rintel <[email protected]>
+Date: Sat, 2 Nov 2019 07:01:28 +0100
+Subject: [PATCH 2/2] iwd: unbreak iwd-1.0
+
+The upstream apparently thought it's a great idea to change the agent
+manager path. This fixes things for those unfortunate enough to run
+IWD.
+---
+ src/devices/wifi/nm-iwd-manager.c | 10 +++++++++-
+ 1 file changed, 9 insertions(+), 1 deletion(-)
+
+diff --git a/src/devices/wifi/nm-iwd-manager.c 
b/src/devices/wifi/nm-iwd-manager.c
+index e83f8063c..470cb1c90 100644
+--- a/src/devices/wifi/nm-iwd-manager.c
++++ b/src/devices/wifi/nm-iwd-manager.c
+@@ -262,9 +262,17 @@ register_agent (NMIwdManager *self)
+       GDBusInterface *agent_manager;
+ 
+       agent_manager = g_dbus_object_manager_get_interface 
(priv->object_manager,
+-                                                           "/",
++                                                           "/net/connman/iwd",
+                                                            
NM_IWD_AGENT_MANAGER_INTERFACE);
+ 
++      if (!agent_manager) {
++              /* IWD prior to 1.0 dated 30 October, 2019 has the agent 
manager on a
++               * different path. */
++              agent_manager = g_dbus_object_manager_get_interface 
(priv->object_manager,
++                                                                   "/",
++                                                                   
NM_IWD_AGENT_MANAGER_INTERFACE);
++      }
++
+       if (!agent_manager) {
+               _LOGE ("unable to register the IWD Agent: PSK/8021x Wi-Fi 
networks may not work");
+               return;
+-- 
+2.20.1
+

diff --git a/net-misc/networkmanager/files/10-openrc-status-r4 
b/net-misc/networkmanager/files/10-openrc-status-r4
deleted file mode 100644
index e195ccc..0000000
--- a/net-misc/networkmanager/files/10-openrc-status-r4
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/bin/sh
-# Copyright (c) 2012 Alexandre Rostovtsev
-# Released under the 2-clause BSD license.
-
-# Ensures that the NetworkManager OpenRC service is marked as started and
-# providing net only when it has a successful connection.
-
-if [ ! -e "/run/openrc/softlevel" ]; then
-       # OpenRC is not running
-       exit 0
-fi
-
-# Ensure rc-service is in PATH
-PATH="${PATH}:@EPREFIX@/sbin:@EPREFIX@/usr/sbin"
-
-# Exit if the NetworkManager OpenRC service is not running
-rc-service NetworkManager status 2>&1 | grep -Eq "status: 
(starting|started|inactive|stopping)" || exit 0
-
-# Call rc-service in background mode so that the start/stop functions update
-# NetworkManager service status to started or inactive instead of actually
-# starting or stopping the daemon
-export IN_BACKGROUND=YES
-
-case "$2" in
-       up) nm-online -t 0 -x &&
-               ! rc-service NetworkManager status 2>&1 | grep -q started &&
-               exec rc-service NetworkManager start ;;
-       down) nm-online -t 0 -x ||
-               rc-service NetworkManager status 2>&1 | grep -q stopped ||
-               exec rc-service NetworkManager stop ;;
-       pre-sleep) rc-service NetworkManager status 2>&1 | grep -q stopped ||
-               exec rc-service NetworkManager stop ;;
-esac
-exit 0
-# vim: set ts=4:

diff --git a/net-misc/networkmanager/files/conf.d.NetworkManager 
b/net-misc/networkmanager/files/conf.d.NetworkManager
deleted file mode 100644
index 4a99229..0000000
--- a/net-misc/networkmanager/files/conf.d.NetworkManager
+++ /dev/null
@@ -1,4 +0,0 @@
-# If NetworkManager does not establish a connection within $INACTIVE_TIMEOUT
-# seconds after starting, the service will be marked as inactive, and it will
-# continue to wait for a connection in background mode.
-INACTIVE_TIMEOUT=1

diff --git a/net-misc/networkmanager/files/fix-busted-configure.patch 
b/net-misc/networkmanager/files/fix-busted-configure.patch
deleted file mode 100644
index a447814..0000000
--- a/net-misc/networkmanager/files/fix-busted-configure.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 9ce527c9e179ecd3c01c684ca4c6747349a7ec99 Mon Sep 17 00:00:00 2001
-From: Jory Pratt <[email protected]>
-Date: Thu, 28 Mar 2019 14:21:48 -0500
-Subject: [PATCH] Fix up configure
-
----
- configure | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/configure b/configure
-index b3e14a3..dde9a93 100755
---- a/configure
-+++ b/configure
-@@ -21127,7 +21127,7 @@ return dlopen ();
- _ACEOF
- for ac_lib in '' dl dld; do
-   if test -z "$ac_lib"; then
--    ac_res="none required"
-+    ac_res=""
-   else
-     ac_res=-l$ac_lib
-     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
--- 
-2.21.0
-

diff --git a/net-misc/networkmanager/files/init.d.NetworkManager-r1 
b/net-misc/networkmanager/files/init.d.NetworkManager-r1
deleted file mode 100644
index 3209644..0000000
--- a/net-misc/networkmanager/files/init.d.NetworkManager-r1
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/sbin/openrc-run
-# Copyright (c) 2008 Saleem Abdulrasool <[email protected]>
-# Copyright 2013-2017 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-description="NetworkManager daemon. The service is marked as started only \
-when a network connection is established."
-
-depend() {
-       need dbus
-       use consolekit
-       provide net
-}
-
-start() {
-       # If we are re-called by a dispatcher event, we want to mark the service
-       # as started without starting the daemon again
-       yesno "${IN_BACKGROUND}" && return 0
-
-       [ -z "${INACTIVE_TIMEOUT}" ] && INACTIVE_TIMEOUT="1"
-
-       ebegin "Starting NetworkManager"
-       start-stop-daemon --start --quiet --pidfile 
/run/NetworkManager/NetworkManager.pid \
-               --exec /usr/sbin/NetworkManager -- --pid-file 
/run/NetworkManager/NetworkManager.pid
-       local _retval=$?
-       eend "${_retval}"
-       if [ "x${_retval}" = 'x0' ] && ! nm-online -t "${INACTIVE_TIMEOUT}"; 
then
-               einfo "Marking NetworkManager as inactive. It will 
automatically be marked"
-               einfo "as started after a network connection has been 
established."
-               mark_service_inactive
-       fi
-       return "${_retval}"
-}
-
-stop() {
-       # If we are re-called by a dispatcher event, we want to mark the service
-       # as inactive without stopping the daemon
-       if yesno "${IN_BACKGROUND}"; then
-               mark_service_inactive "${SVCNAME}"
-               return 0
-       fi
-
-       ebegin "Stopping NetworkManager"
-       local pidfile=/run/NetworkManager/NetworkManager.pid
-       if [ ! -e "${pidfile}" ] && [ -e /var/run/NetworkManager.pid ]; then 
-               # Try stopping the pid file used by <0.9.7
-               pidfile=/var/run/NetworkManager.pid
-               start-stop-daemon --stop --quiet --pidfile "${pidfile}"
-               ret=$?
-               [ ${ret} = 0 ] && [ -e "${pidfile}" ] && rm "${pidfile}"
-               eend ${ret}
-       else
-               start-stop-daemon --stop --quiet --pidfile "${pidfile}"
-               eend $?
-       fi
-}
-
-# vim: set ft=gentoo-init-d ts=4 :

diff --git a/net-misc/networkmanager/files/musl-basic.patch 
b/net-misc/networkmanager/files/musl-basic.patch
index e26ad4a..8b78354 100644
--- a/net-misc/networkmanager/files/musl-basic.patch
+++ b/net-misc/networkmanager/files/musl-basic.patch
@@ -1,15 +1,32 @@
-From 8d5abcd3f0ef99cb7551d2db400c0645812a54ab Mon Sep 17 00:00:00 2001
-From: 
-Date: Thu, 28 Mar 2019 11:48:38 -0500
-Subject: [PATCH 1/5] Basic musl fixes
+From d12f0c518b10a3be0357c9242a2491c0904b51d6 Mon Sep 17 00:00:00 2001
+From: Jory Pratt <[email protected]>
+Date: Mon, 29 Jul 2019 23:24:11 -0500
+Subject: [PATCH 1/5] Usual musl fixes
 
 ---
+ shared/systemd/src/basic/sort-util.h  | 6 ++++++
  shared/systemd/src/basic/stdio-util.h | 2 ++
- shared/systemd/src/basic/util.h       | 6 ++++++
  2 files changed, 8 insertions(+)
 
+diff --git a/shared/systemd/src/basic/sort-util.h 
b/shared/systemd/src/basic/sort-util.h
+index e029f86..e876241 100644
+--- a/shared/systemd/src/basic/sort-util.h
++++ b/shared/systemd/src/basic/sort-util.h
+@@ -5,6 +5,12 @@
+ 
+ #include "macro.h"
+ 
++#if !defined(__GLIBC__)
++typedef int (*__compar_fn_t) (const void*, const void*);
++typedef __compar_fn_t comparison_fn_t;
++typedef int (*__compar_d_fn_t) (const void *, const void *, void *);
++#endif
++
+ void *xbsearch_r(const void *key, const void *base, size_t nmemb, size_t size,
+                  __compar_d_fn_t compar, void *arg);
+ 
 diff --git a/shared/systemd/src/basic/stdio-util.h 
b/shared/systemd/src/basic/stdio-util.h
-index dc67b6e..6336243 100644
+index c3b9448..e80a938 100644
 --- a/shared/systemd/src/basic/stdio-util.h
 +++ b/shared/systemd/src/basic/stdio-util.h
 @@ -1,7 +1,9 @@
@@ -22,23 +39,6 @@ index dc67b6e..6336243 100644
  #include <stdarg.h>
  #include <stdio.h>
  #include <sys/types.h>
-diff --git a/shared/systemd/src/basic/util.h b/shared/systemd/src/basic/util.h
-index dc33d66..fbdf291 100644
---- a/shared/systemd/src/basic/util.h
-+++ b/shared/systemd/src/basic/util.h
-@@ -27,6 +27,12 @@
- #include "macro.h"
- #include "time-util.h"
- 
-+#if !defined(__GLIBC__)
-+typedef int (*__compar_fn_t) (const void*, const void*);
-+typedef __compar_fn_t comparison_fn_t;
-+typedef int (*__compar_d_fn_t) (const void *, const void *, void *);
-+#endif
-+
- size_t page_size(void) _pure_;
- #define PAGE_ALIGN(l) ALIGN_TO((l), page_size())
- 
 -- 
-2.21.0
+2.22.0
 

diff --git a/net-misc/networkmanager/files/musl-fix-includes.patch 
b/net-misc/networkmanager/files/musl-fix-includes.patch
index 9c1e240..9ee2f7f 100644
--- a/net-misc/networkmanager/files/musl-fix-includes.patch
+++ b/net-misc/networkmanager/files/musl-fix-includes.patch
@@ -1,7 +1,7 @@
-From 757c618b86fec884d9f9cb0abdbe31ba680ff863 Mon Sep 17 00:00:00 2001
-From: 
-Date: Thu, 28 Mar 2019 11:49:20 -0500
-Subject: [PATCH 2/5] Fix includes for musl users
+From f0d90910d8a8bde7608221b4e34ff12096a4d951 Mon Sep 17 00:00:00 2001
+From: Jory Pratt <[email protected]>
+Date: Mon, 29 Jul 2019 23:25:11 -0500
+Subject: [PATCH 2/5] fix includes for musl
 
 ---
  src/devices/nm-device.c          | 4 ++++
@@ -10,7 +10,7 @@ Subject: [PATCH 2/5] Fix includes for musl users
  3 files changed, 10 insertions(+), 1 deletion(-)
 
 diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c
-index 7514fa7..f041382 100644
+index 42e4688..3b9da98 100644
 --- a/src/devices/nm-device.c
 +++ b/src/devices/nm-device.c
 @@ -32,7 +32,11 @@
@@ -26,7 +26,7 @@ index 7514fa7..f041382 100644
  #include <linux/pkt_sched.h>
  
 diff --git a/src/nm-manager.c b/src/nm-manager.c
-index 0bf6a75..e392507 100644
+index 7d77144..dc143ba 100644
 --- a/src/nm-manager.c
 +++ b/src/nm-manager.c
 @@ -26,6 +26,7 @@
@@ -35,10 +35,10 @@ index 0bf6a75..e392507 100644
  #include <unistd.h>
 +#include <asm/types.h>
  
- #include "nm-utils/nm-c-list.h"
+ #include "nm-glib-aux/nm-c-list.h"
  
 diff --git a/src/platform/nm-linux-platform.c 
b/src/platform/nm-linux-platform.c
-index 2f5c75b..f086245 100644
+index 7d66a88..b9a7b30 100644
 --- a/src/platform/nm-linux-platform.c
 +++ b/src/platform/nm-linux-platform.c
 @@ -20,6 +20,7 @@
@@ -49,26 +49,26 @@ index 2f5c75b..f086245 100644
  
  #include <arpa/inet.h>
  #include <dlfcn.h>
-@@ -27,7 +28,11 @@
- #include <fcntl.h>
+@@ -28,7 +29,11 @@
  #include <libudev.h>
+ #include <linux/fib_rules.h>
  #include <linux/ip.h>
 +#if defined(__GLIBC__)
  #include <linux/if_arp.h>
 +#else
 +#include <linux/if.h>
 +#endif
+ #include <linux/if_bridge.h>
  #include <linux/if_link.h>
  #include <linux/if_tun.h>
- #include <linux/if_tunnel.h>
-@@ -53,7 +58,6 @@
+@@ -58,7 +63,6 @@
  #include "nm-platform-private.h"
  #include "wifi/nm-wifi-utils.h"
  #include "wifi/nm-wifi-utils-wext.h"
 -#include "wpan/nm-wpan-utils.h"
- #include "nm-utils/unaligned.h"
- #include "nm-utils/nm-io-utils.h"
- #include "nm-utils/nm-udev-utils.h"
+ #include "nm-glib-aux/nm-io-utils.h"
+ #include "nm-udev-aux/nm-udev-utils.h"
+ 
 -- 
-2.21.0
+2.22.0
 

diff --git a/net-misc/networkmanager/files/musl-has-not-secure-gentenv.patch 
b/net-misc/networkmanager/files/musl-has-not-secure-gentenv.patch
deleted file mode 100644
index 38eec9c..0000000
--- a/net-misc/networkmanager/files/musl-has-not-secure-gentenv.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From b5649534943137ddbb97f1735e8d5ced24b1e36e Mon Sep 17 00:00:00 2001
-From: 
-Date: Thu, 28 Mar 2019 11:49:44 -0500
-Subject: [PATCH 3/5] Musl does not have secure getenv
-
----
- src/systemd/sd-adapt-core/nm-sd-adapt-core.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/systemd/sd-adapt-core/nm-sd-adapt-core.h 
b/src/systemd/sd-adapt-core/nm-sd-adapt-core.h
-index 8c07c53..d043afc 100644
---- a/src/systemd/sd-adapt-core/nm-sd-adapt-core.h
-+++ b/src/systemd/sd-adapt-core/nm-sd-adapt-core.h
-@@ -65,7 +65,7 @@
- #  ifdef HAVE___SECURE_GETENV
- #    define secure_getenv __secure_getenv
- #  else
--#    error neither secure_getenv nor __secure_getenv is available
-+#    define secure_getenv getenv
- #  endif
- #endif
- 
--- 
-2.21.0
-

diff --git a/net-misc/networkmanager/files/musl-network-support.patch 
b/net-misc/networkmanager/files/musl-network-support.patch
index feca98d..ca242e2 100644
--- a/net-misc/networkmanager/files/musl-network-support.patch
+++ b/net-misc/networkmanager/files/musl-network-support.patch
@@ -1,7 +1,7 @@
-From 530814cb0d4f3369c18a88a31b5f14f2ed6544bc Mon Sep 17 00:00:00 2001
-From: 
-Date: Thu, 28 Mar 2019 11:50:06 -0500
-Subject: [PATCH 4/5] musl network support
+From e5e2e822a6daab4af1710fb8044072dc2327d002 Mon Sep 17 00:00:00 2001
+From: Jory Pratt <[email protected]>
+Date: Mon, 29 Jul 2019 23:26:46 -0500
+Subject: [PATCH 4/5] add network support for musl libc
 
 ---
  libnm-core/nm-utils.h                  | 4 ++++
@@ -26,7 +26,7 @@ index 2b5baba..976850c 100644
  
  #include "nm-core-enum-types.h"
 diff --git a/shared/systemd/src/basic/socket-util.h 
b/shared/systemd/src/basic/socket-util.h
-index d2246a8..4cb0807 100644
+index 15443f1..b9c3291 100644
 --- a/shared/systemd/src/basic/socket-util.h
 +++ b/shared/systemd/src/basic/socket-util.h
 @@ -12,6 +12,11 @@
@@ -58,5 +58,5 @@ index 36148b5..d282eb2 100644
  #include "nm-dbus-interface.h"
  #include "nm-setting-wireless.h"
 -- 
-2.21.0
+2.22.0
 

diff --git a/net-misc/networkmanager/files/musl-process-util.patch 
b/net-misc/networkmanager/files/musl-process-util.patch
index 0b67a78..6267019 100644
--- a/net-misc/networkmanager/files/musl-process-util.patch
+++ b/net-misc/networkmanager/files/musl-process-util.patch
@@ -1,6 +1,6 @@
-From 0777360a2d8baa5c297bfa017bfaa1caf111d720 Mon Sep 17 00:00:00 2001
-From: 
-Date: Thu, 28 Mar 2019 11:50:23 -0500
+From 23613c07ff805744aaee22c352b24731ec4b2c69 Mon Sep 17 00:00:00 2001
+From: Jory Pratt <[email protected]>
+Date: Mon, 29 Jul 2019 23:27:58 -0500
 Subject: [PATCH 5/5] musl process util
 
 ---
@@ -8,7 +8,7 @@ Subject: [PATCH 5/5] musl process util
  1 file changed, 11 insertions(+), 1 deletion(-)
 
 diff --git a/shared/systemd/src/basic/process-util.c 
b/shared/systemd/src/basic/process-util.c
-index b0afb5c..f72e346 100644
+index 7431be3..f9e6d49 100644
 --- a/shared/systemd/src/basic/process-util.c
 +++ b/shared/systemd/src/basic/process-util.c
 @@ -21,6 +21,9 @@
@@ -21,7 +21,7 @@ index b0afb5c..f72e346 100644
  #if 0 /* NM_IGNORED */
  #if HAVE_VALGRIND_VALGRIND_H
  #include <valgrind/valgrind.h>
-@@ -1168,11 +1171,13 @@ void reset_cached_pid(void) {
+@@ -1183,11 +1186,13 @@ void reset_cached_pid(void) {
          cached_pid = CACHED_PID_UNSET;
  }
  
@@ -35,7 +35,7 @@ index b0afb5c..f72e346 100644
  
  pid_t getpid_cached(void) {
          static bool installed = false;
-@@ -1201,7 +1206,12 @@ pid_t getpid_cached(void) {
+@@ -1216,7 +1221,12 @@ pid_t getpid_cached(void) {
                           * only half-documented (glibc doesn't document it 
but LSB does — though only superficially)
                           * we'll check for errors only in the most generic 
fashion possible. */
  
@@ -50,5 +50,5 @@ index b0afb5c..f72e346 100644
                                  cached_pid = CACHED_PID_UNSET;
                                  return new_pid;
 -- 
-2.21.0
+2.22.0
 

diff --git 
a/net-misc/networkmanager/files/networkmanager-data-fix-the-ID_NET_DRIVER-udev-rule.patch
 
b/net-misc/networkmanager/files/networkmanager-data-fix-the-ID_NET_DRIVER-udev-rule.patch
new file mode 100644
index 0000000..1b94ab4
--- /dev/null
+++ 
b/net-misc/networkmanager/files/networkmanager-data-fix-the-ID_NET_DRIVER-udev-rule.patch
@@ -0,0 +1,33 @@
+From 27d380b70ea839c7badab420361e4e65e023e8e9 Mon Sep 17 00:00:00 2001
+From: Lubomir Rintel <[email protected]>
+Date: Fri, 16 Aug 2019 13:22:09 +0200
+Subject: [PATCH] data: fix the ID_NET_DRIVER udev rule
+
+Systemd v243 is complaining about the wrong substitution there. That is
+sort of harmless, because systemd-udevd in that version doesn't need the
+rule anyway. But still fix it, to avoid a warning.
+
+Also, newer udevd's $PATH doesn't include sbin. That is also okay,
+because we don't need the rule to actually work there. But fix it
+anyway.
+
+https://bugzilla.redhat.com/show_bug.cgi?id=1740655
+---
+ data/84-nm-drivers.rules | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/data/84-nm-drivers.rules b/data/84-nm-drivers.rules
+index d246ef6ce..e398cb9f2 100644
+--- a/data/84-nm-drivers.rules
++++ b/data/84-nm-drivers.rules
+@@ -7,6 +7,6 @@ ACTION!="add|change", GOTO="nm_drivers_end"
+ # Determine ID_NET_DRIVER if there's no ID_NET_DRIVER or DRIVERS (old udev?)
+ ENV{ID_NET_DRIVER}=="?*", GOTO="nm_drivers_end"
+ DRIVERS=="?*", GOTO="nm_drivers_end"
+-PROGRAM="/bin/sh -c 'ethtool -i $1 | sed -n s/^driver:\ //p' -- 
$env{INTERFACE}", RESULT=="?*", ENV{ID_NET_DRIVER}="%c"
++PROGRAM="/bin/sh -c '/usr/sbin/ethtool -i $$1 |/usr/bin/sed -n s/^driver:\ 
//p' -- $env{INTERFACE}", ENV{ID_NET_DRIVER}="%c"
+ 
+ LABEL="nm_drivers_end"
+-- 
+2.21.0
+

diff --git a/net-misc/networkmanager/networkmanager-1.16.2.ebuild 
b/net-misc/networkmanager/networkmanager-1.18.4-r3.ebuild
similarity index 92%
rename from net-misc/networkmanager/networkmanager-1.16.2.ebuild
rename to net-misc/networkmanager/networkmanager-1.18.4-r3.ebuild
index 27f057c..64e5a52 100644
--- a/net-misc/networkmanager/networkmanager-1.16.2.ebuild
+++ b/net-misc/networkmanager/networkmanager-1.18.4-r3.ebuild
@@ -1,14 +1,13 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
 GNOME_ORG_MODULE="NetworkManager"
 GNOME2_LA_PUNT="yes"
 VALA_USE_DEPEND="vapigen"
-PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6,3_7} )
+PYTHON_COMPAT=( python{3_6,3_7} )
 
-inherit bash-completion-r1 gnome2 linux-info multilib python-any-r1 systemd \
-       user readme.gentoo-r1 vala virtualx udev multilib-minimal flag-o-matic
+inherit bash-completion-r1 gnome2 linux-info multilib python-any-r1 systemd 
readme.gentoo-r1 vala virtualx udev multilib-minimal
 
 DESCRIPTION="A set of co-operative tools that make networking simple and 
straightforward"
 HOMEPAGE="https://wiki.gnome.org/Projects/NetworkManager";
@@ -17,17 +16,18 @@ LICENSE="GPL-2+"
 SLOT="0" # add subslot if libnm-util.so.2 or libnm-glib.so.4 bumps soname 
version
 
 IUSE="audit bluetooth connection-sharing consolekit +dhclient dhcpcd elogind 
gnutls +introspection iwd json kernel_linux +nss +modemmanager ncurses ofono 
ovs policykit +ppp resolvconf selinux systemd teamd test vala +wext +wifi"
+RESTRICT="!test? ( test )"
 
 REQUIRED_USE="
        bluetooth? ( modemmanager )
        iwd? ( wifi )
        vala? ( introspection )
        wext? ( wifi )
-       ^^ ( nss gnutls )
+       || ( nss gnutls )
        ?? ( consolekit elogind systemd )
 "
 
-KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
+KEYWORDS="amd64 arm arm64 ppc ppc64 x86"
 
 # gobject-introspection-0.10.3 is needed due to gnome bug 642300
 # wpa_supplicant-0.7.3-r3 is needed due to bug 359271
@@ -40,7 +40,7 @@ COMMON_DEPEND="
        >=net-misc/curl-7.24
        net-misc/iputils
        sys-apps/util-linux[${MULTILIB_USEDEP}]
-       sys-libs/readline:0=[${MULTILIB_USEDEP}]
+       sys-libs/readline:0=
        >=virtual/libudev-175:=[${MULTILIB_USEDEP}]
        audit? ( sys-process/audit )
        bluetooth? ( >=net-wireless/bluez-5 )
@@ -51,14 +51,14 @@ COMMON_DEPEND="
        dhclient? ( >=net-misc/dhcp-4[client] )
        dhcpcd? ( net-misc/dhcpcd )
        elogind? ( >=sys-auth/elogind-219 )
-       gnutls? (
-               dev-libs/libgcrypt:0=[${MULTILIB_USEDEP}]
-               >=net-libs/gnutls-2.12:=[${MULTILIB_USEDEP}] )
        introspection? ( >=dev-libs/gobject-introspection-0.10.3:= )
        json? ( >=dev-libs/jansson-2.5[${MULTILIB_USEDEP}] )
        modemmanager? ( >=net-misc/modemmanager-0.7.991:0= )
        ncurses? ( >=dev-libs/newt-0.52.15 )
        nss? ( >=dev-libs/nss-3.11:=[${MULTILIB_USEDEP}] )
+       !nss? ( gnutls? (
+               dev-libs/libgcrypt:0=[${MULTILIB_USEDEP}]
+               >=net-libs/gnutls-2.12:=[${MULTILIB_USEDEP}] ) )
        ofono? ( net-misc/ofono )
        ovs? ( dev-libs/jansson )
        ppp? ( >=net-dialup/ppp-2.4.5:=[ipv6] )
@@ -71,6 +71,7 @@ COMMON_DEPEND="
        )
 "
 RDEPEND="${COMMON_DEPEND}
+       acct-group/plugdev
        || (
                net-misc/iputils[arping(+)]
                net-analyzer/arping
@@ -102,11 +103,13 @@ DEPEND="${COMMON_DEPEND}
 "
 
 PATCHES=(
-       "${FILESDIR}"/fix-busted-configure.patch
+       "${FILESDIR}"/${PN}-data-fix-the-ID_NET_DRIVER-udev-rule.patch
+       "${FILESDIR}"/${PV}-iwd1-compat.patch # included in 1.21.3+
+
+       # Required to build on musl
        "${FILESDIR}"/musl-basic.patch
-       "${FILESDIR}"/musl-fix-includes.patch
-       "${FILESDIR}"/musl-has-not-secure-gentenv.patch
        "${FILESDIR}"/musl-network-support.patch
+       "${FILESDIR}"/musl-fix-includes.patch
        "${FILESDIR}"/musl-process-util.patch
 )
 
@@ -148,10 +151,13 @@ pkg_pretend() {
 
 pkg_setup() {
        if use connection-sharing; then
-               CONFIG_CHECK="~NF_NAT_IPV4 ~NF_NAT_MASQUERADE_IPV4"
+               if kernel_is lt 5 1; then
+                       CONFIG_CHECK="~NF_NAT_IPV4 ~NF_NAT_MASQUERADE_IPV4"
+               else
+                       CONFIG_CHECK="~NF_NAT ~NF_NAT_MASQUERADE"
+               fi
                linux-info_pkg_setup
        fi
-       enewgroup plugdev
        if use introspection || use test; then
                python-any-r1_pkg_setup
        fi
@@ -178,7 +184,7 @@ multilib_src_configure() {
                # We need --with-libnm-glib (and dbus-glib dep) as reverse deps 
are
                # still not ready for removing that lib, bug #665338
                --with-libnm-glib
-               --with-nmcli=yes
+               $(multilib_native_with nmcli)
                --with-udev-dir="$(get_udevdir)"
                --with-config-plugins-default=keyfile
                --with-iptables=/sbin/iptables
@@ -201,6 +207,8 @@ multilib_src_configure() {
                $(multilib_native_use_with ncurses nmtui)
                $(multilib_native_use_with ofono)
                $(multilib_native_use_enable ovs)
+               $(multilib_native_use_enable policykit polkit)
+               $(multilib_native_use_enable policykit polkit-agent)
                $(multilib_native_use_with resolvconf)
                $(multilib_native_use_with selinux)
                $(multilib_native_use_with systemd systemd-journal)
@@ -213,12 +221,6 @@ multilib_src_configure() {
                $(multilib_native_use_enable wifi)
        )
 
-       if multilib_is_native_abi && use policykit; then
-               myconf+=( --enable-polkit=yes )
-       else
-               myconf+=( --enable-polkit=disabled )
-       fi
-
        # Same hack as net-dialup/pptpd to get proper plugin dir for ppp, bug 
#519986
        if use ppp; then
                local PPPD_VER=`best_version net-dialup/ppp`
@@ -237,8 +239,6 @@ multilib_src_configure() {
                ln -s "${S}/man" man || die
        fi
 
-       append-cflags -DRTLD_DEEPBIND=0
-
        ECONF_SOURCE=${S} runstatedir="/run" gnome2_src_configure "${myconf[@]}"
 }
 
@@ -267,6 +267,8 @@ multilib_src_install() {
        if multilib_is_native_abi; then
                # Install completions at proper place, bug #465100
                gnome2_src_install completiondir="$(get_bashcompdir)"
+               insinto /usr/lib/NetworkManager/conf.d #702476
+               doins "${S}"/examples/nm-conf.d/31-mac-addr-change.conf
        else
                local targets=(
                        install-libLTLIBRARIES

Reply via email to