libux atm

This commit is contained in:
Rmys
2021-07-02 19:55:10 +03:00
committed by GitHub
parent f44c75331e
commit 15fa188b1c
3 changed files with 83 additions and 4 deletions
@@ -0,0 +1,59 @@
From 4456e13880803a300e4b6f263ad22a37481b5df5 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Thu, 29 Aug 2019 09:33:43 -0700
Subject: [PATCH] saaldump,atmdump: Include linux/sockios.h for SIOCGSTAMP
In linux kernel commit 0768e17073dc527ccd18ed5f96ce85f9985e9115
the asm-generic/sockios.h header no longer defines SIOCGSTAMP.
Instead it provides only SIOCGSTAMP_OLD.
The linux/sockios.h header now defines SIOCGSTAMP using either
SIOCGSTAMP_OLD or SIOCGSTAMP_NEW as appropriate. This linux only
header file is not pulled so we get a build failure.
Fixes
../../../linux-atm-2.5.2/src/maint/atmdump.c:142:18: error: use of undeclared identifier 'SIOCGSTAMP'
if (ioctl(s,SIOCGSTAMP,&stamp) < 0) {
^
1 error generated.
make[3]: *** [Makefile:623: atmdump.o] Error 1
make[3]: *** Waiting for unfinished jobs....
../../../linux-atm-2.5.2/src/maint/saaldump.c:169:14: error: use of undeclared identifier 'SIOCGSTAMP'
if (ioctl(s,SIOCGSTAMP,&stamp) < 0) {
^
Upstream-Status: Pending
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
src/maint/atmdump.c | 2 +-
src/maint/saaldump.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/maint/atmdump.c b/src/maint/atmdump.c
index 8b17826..9e4853b 100644
--- a/src/maint/atmdump.c
+++ b/src/maint/atmdump.c
@@ -5,7 +5,7 @@
#if HAVE_CONFIG_H
#include <config.h>
#endif
-
+#include <linux/sockios.h>
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
diff --git a/src/maint/saaldump.c b/src/maint/saaldump.c
index 83bdde9..69429a8 100644
--- a/src/maint/saaldump.c
+++ b/src/maint/saaldump.c
@@ -5,7 +5,7 @@
#if HAVE_CONFIG_H
#include <config.h>
#endif
-
+#include <linux/sockios.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdio.h>
--
2.23.0
@@ -0,0 +1,22 @@
diff -up linux-atm-2.5.1/src/arpd/arp.c.ftbfs linux-atm-2.5.1/src/arpd/arp.c
--- linux-atm-2.5.1/src/arpd/arp.c.ftbfs 2007-07-11 11:27:15.000000000 -0400
+++ linux-atm-2.5.1/src/arpd/arp.c 2019-05-02 20:15:45.497338836 -0400
@@ -15,7 +15,6 @@
#include <sys/types.h>
#include <sys/socket.h> /* for linux/if_arp.h */
#include <netinet/in.h> /* for ntohs, etc. */
-#define _LINUX_NETDEVICE_H /* very crude hack for glibc2 */
#include <linux/types.h>
#include <linux/if_arp.h>
#include <linux/if_ether.h>
diff -up linux-atm-2.5.1/src/arpd/itf.c.ftbfs linux-atm-2.5.1/src/arpd/itf.c
--- linux-atm-2.5.1/src/arpd/itf.c.ftbfs 2007-07-11 11:27:15.000000000 -0400
+++ linux-atm-2.5.1/src/arpd/itf.c 2019-05-02 20:19:08.046499027 -0400
@@ -12,7 +12,6 @@
#include <sys/types.h>
#include <linux/atmclip.h>
#include <sys/socket.h>
-#define _LINUX_NETDEVICE_H /* glibc2 */
#include <linux/types.h>
#include <linux/if_arp.h>
+2 -4
View File
@@ -19,10 +19,8 @@
</BuildDependencies>
<Patches>
<Patch level="1">man-pages.patch</Patch>
<!--<Patch level="1">linux-atm-2.5.0-open-macro.patch</Patch>
<Patch level="1">linux-atm-2.5.0-disable-ilmidiag.patch</Patch>
<Patch level="1">gcc43.patch</Patch>
<Patch level="1">netdevice.patch</Patch>-->
<Patch level="1">remove-define-hacks.patch</Patch>
<Patch level="1">0001-saaldump-atmdump-Include-linux-sockios.h-for-SIOCGST.patch</Patch>
</Patches>
</Source>