[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Vinson Lee <vlee@xxxxxxxxxxx>

This patch fixes these build errors with glibc before 2.9.

syscalls/socket.c: In function ‘gen_socket_args’:
syscalls/socket.c:82: error: ‘SOCK_CLOEXEC’ undeclared (first use in this function)
syscalls/socket.c:82: error: (Each undeclared identifier is reported only once
syscalls/socket.c:82: error: for each function it appears in.)
syscalls/socket.c:84: error: ‘SOCK_NONBLOCK’ undeclared (first use in this function)

Signed-off-by: Vinson Lee <vlee@xxxxxxxxxxx>
---
 include/compat.h |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/include/compat.h b/include/compat.h
index fe5d0c7..ae57fcb 100644
--- a/include/compat.h
+++ b/include/compat.h
@@ -93,6 +93,14 @@ enum {
 
 
 /* bits/socket.h */
+#ifndef SOCK_CLOEXEC
+#define SOCK_CLOEXEC	02000000
+#endif
+
+#ifndef SOCK_NONBLOCK
+#define SOCK_NONBLOCK	04000
+#endif
+
 #ifndef PF_RDS
 #define PF_RDS		21
 #endif
-- 
1.7.4.1

--
To unsubscribe from this list: send the line "unsubscribe trinity" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux SCSI]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux