[klibc] [PATCH] include: [sys/ioctl.h] needs linux/sockios.h

maximilian attems max at stro.at
Mon Aug 8 11:24:57 PDT 2011


The defines of SIOCGIFCONF and SIOCSIFFLAGS are well
hidden in linux-2.6 under #ifdef __KERNEL__ sections
for example in linux/socket.h.

Fixes these in kexec-tools against klibc:
| kexec/ifdown.c:46:16: error: 'SIOCGIFCONF' undeclared (first use in
this function)
| kexec/ifdown.c:46:16: note: each undeclared identifier is reported
only once for each function it appears in
| kexec/ifdown.c:65:18: error: 'SIOCSIFFLAGS' undeclared (first use in
this function)

Reported-by: Andrea Adami <andrea.adami at gmail.com>
Suggested-by: KUMAAN <9maaan at gmail.com>
Cc: Ben Hutchings <ben at decadent.org.uk>
Signed-off-by: maximilian attems <max at stro.at>
---
 usr/include/sys/ioctl.h |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/usr/include/sys/ioctl.h b/usr/include/sys/ioctl.h
index 559f111..81ae756 100644
--- a/usr/include/sys/ioctl.h
+++ b/usr/include/sys/ioctl.h
@@ -9,6 +9,9 @@
 #include <linux/ioctl.h>
 #include <asm/ioctls.h>
 
+/* the SIOCxxx I/O are hidden */
+#include <linux/sockios.h>
+
 __extern int ioctl(int, int, void *);
 
 #endif				/* _SYS_IOCTL_H */
-- 
1.7.5.4



More information about the klibc mailing list