diff mbox series

[oe,meta-networking,2/2] linux-atm: Fix build with linux 5.x headers

Message ID 20190308190058.18583-2-raj.khem@gmail.com
State Accepted
Commit ec3307cebe5b6c2a020b535aa222f3220f97ce33
Headers show
Series [oe,meta-networking,1/2] miniupnpd: Upgrade to 2.1.20190210 release | expand

Commit Message

Khem Raj March 8, 2019, 7 p.m. UTC
Fixes
error: 'IFNAMSIZ' undeclared here

Signed-off-by: Khem Raj <raj.khem@gmail.com>

---
 ...0001-IFNAMSIZ-is-defined-in-net-if.h.patch | 48 +++++++++++++++++++
 .../linux-atm/linux-atm_2.5.2.bb              |  1 +
 2 files changed, 49 insertions(+)
 create mode 100644 meta-networking/recipes-support/linux-atm/linux-atm/0001-IFNAMSIZ-is-defined-in-net-if.h.patch

-- 
2.21.0

-- 
_______________________________________________
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel
diff mbox series

Patch

diff --git a/meta-networking/recipes-support/linux-atm/linux-atm/0001-IFNAMSIZ-is-defined-in-net-if.h.patch b/meta-networking/recipes-support/linux-atm/linux-atm/0001-IFNAMSIZ-is-defined-in-net-if.h.patch
new file mode 100644
index 0000000000..a7c7093e09
--- /dev/null
+++ b/meta-networking/recipes-support/linux-atm/linux-atm/0001-IFNAMSIZ-is-defined-in-net-if.h.patch
@@ -0,0 +1,48 @@ 
+From 29b37e45577c0921846c1709a190f08a3b032666 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Fri, 8 Mar 2019 09:08:38 -0800
+Subject: [PATCH] IFNAMSIZ is defined in net/if.h
+
+Fixes
+/mnt/a/yoe/build/tmp/work/qemuriscv64-yoe-linux-musl/linux-atm/2.5.2-r0/recipe-sysroot/usr/include/linux/if_arp.h:121:16: error: 'IFNAMSIZ' undeclared here (not in a function)
+|  char  arp_dev[IFNAMSIZ];
+|                ^~~~~~~~
+In file included from ../../../linux-atm-2.5.2/src/arpd/itf.c:17:
+/mnt/a/yoe/build/tmp/work/qemuriscv64-yoe-linux-musl/linux-atm/2.5.2-r0/recipe-sysroot/usr/include/linux/if_arp.h:121:16: error: 'IFNAMSIZ' undeclared here (not in a function)
+|  char  arp_dev[IFNAMSIZ];
+|                ^~~~~~~~
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/arpd/arp.c | 1 +
+ src/arpd/itf.c | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/src/arpd/arp.c b/src/arpd/arp.c
+index 92d3787..ff1574c 100644
+--- a/src/arpd/arp.c
++++ b/src/arpd/arp.c
+@@ -17,6 +17,7 @@
+ #include <netinet/in.h> /* for ntohs, etc. */
+ #define _LINUX_NETDEVICE_H /* very crude hack for glibc2 */
+ #include <linux/types.h>
++#include <net/if.h>
+ #include <linux/if_arp.h>
+ #include <linux/if_ether.h>
+ #include <atm.h>
+diff --git a/src/arpd/itf.c b/src/arpd/itf.c
+index 92f0951..d285e3b 100644
+--- a/src/arpd/itf.c
++++ b/src/arpd/itf.c
+@@ -14,6 +14,7 @@
+ #include <sys/socket.h>
+ #define _LINUX_NETDEVICE_H /* glibc2 */
+ #include <linux/types.h>
++#include <net/if.h>
+ #include <linux/if_arp.h>
+ 
+ #include "atmd.h"
+-- 
+2.21.0
+
diff --git a/meta-networking/recipes-support/linux-atm/linux-atm_2.5.2.bb b/meta-networking/recipes-support/linux-atm/linux-atm_2.5.2.bb
index 9fce4fba63..51682b1ed1 100644
--- a/meta-networking/recipes-support/linux-atm/linux-atm_2.5.2.bb
+++ b/meta-networking/recipes-support/linux-atm/linux-atm_2.5.2.bb
@@ -14,6 +14,7 @@  SRC_URI = "http://nchc.dl.sourceforge.net/project/${BPN}/${BPN}/${PV}/${BPN}-${P
            file://0001-ttcp-Add-printf-format-string.patch \
            file://0002-sigd-Replace-on_exit-API-with-atexit.patch \
            file://0003-mpoad-Drop-old-hack-to-compile-with-very-old-glibc.patch \
+           file://0001-IFNAMSIZ-is-defined-in-net-if.h.patch \
 "
 
 SRC_URI[md5sum] = "d49499368c3cf15f73a05d9bce8824a8"