net-misc/dibbler: fix build with -fno-common
authorBernard Cafarelli <voyageur@gentoo.org>
Wed, 29 Jan 2020 18:26:47 +0000 (19:26 +0100)
committerBernard Cafarelli <voyageur@gentoo.org>
Wed, 29 Jan 2020 18:27:00 +0000 (19:27 +0100)
Thanks jer for patch

Closes: https://bugs.gentoo.org/706806
Package-Manager: Portage-2.3.86, Repoman-2.3.20
Signed-off-by: Bernard Cafarelli <voyageur@gentoo.org>
net-misc/dibbler/dibbler-1.0.1.ebuild
net-misc/dibbler/files/dibbler-1.0.1-fno-common.patch [new file with mode: 0644]

index 6e7824899da471994d32a1b9f96ec5bac32f9d27..e4bbf0482849312810f3eabd6a3c6c97e3d566d1 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2017 Gentoo Foundation
+# Copyright 1999-2020 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI="5"
@@ -23,6 +23,7 @@ DOC_CONTENTS="Make sure that you modify client.conf, server.conf and/or relay.co
 to suit your needs. They are stored in /etc/dibbler"
 
 src_prepare() {
+       epatch "${FILESDIR}"/${P}-fno-common.patch
        epatch_user
 }
 
diff --git a/net-misc/dibbler/files/dibbler-1.0.1-fno-common.patch b/net-misc/dibbler/files/dibbler-1.0.1-fno-common.patch
new file mode 100644 (file)
index 0000000..d08b6bb
--- /dev/null
@@ -0,0 +1,25 @@
+--- a/Port-linux/interface.c
++++ b/Port-linux/interface.c
+@@ -43,6 +43,9 @@
+ #include <linux/sockios.h>
+ #include <linux/if_ether.h>
++int interface_auto_up;
++int interface_do_message;
++
+ void daemon_log(int loglevel, const char *fmt,...)
+ {
+     char buf[255];
+--- a/Port-linux/interface.h
++++ b/Port-linux/interface.h
+@@ -23,8 +23,8 @@
+ extern "C" {
+ #endif
+-int interface_auto_up;
+-int interface_do_message;
++extern int interface_auto_up;
++extern int interface_do_message;
+ typedef enum { IFSTATUS_UP, IFSTATUS_DOWN, IFSTATUS_ERR } interface_status_t;