aboutsummaryrefslogtreecommitdiffstats
path: root/meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch')
-rw-r--r--meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch130
1 files changed, 130 insertions, 0 deletions
diff --git a/meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch b/meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch
new file mode 100644
index 0000000..48e8f5c
--- /dev/null
+++ b/meta-ivi/recipes-core-ivi/eglibc/eglibc/eglibc_2.18_add_af_bus_support.patch
@@ -0,0 +1,130 @@
+Index: libc/Makefile
+===================================================================
+--- libc.orig/Makefile
++++ libc/Makefile
+@@ -317,7 +317,7 @@ installed-headers = argp/argp.h assert/a
+ resource/sys/vtimes.h resource/ulimit.h rt/aio.h \
+ rt/mqueue.h setjmp/setjmp.h shadow/shadow.h \
+ signal/signal.h signal/sys/signal.h socket/sys/socket.h \
+- socket/sys/un.h stdio-common/printf.h \
++ socket/sys/un.h socket/sys/bus.h stdio-common/printf.h \
+ stdio-common/stdio_ext.h stdlib/stdlib.h stdlib/alloca.h \
+ stdlib/monetary.h stdlib/fmtmsg.h stdlib/ucontext.h \
+ sysdeps/generic/inttypes.h sysdeps/generic/stdint.h \
+Index: libc/include/sys/bus.h
+===================================================================
+--- /dev/null
++++ libc/include/sys/bus.h
+@@ -0,0 +1 @@
++#include <socket/sys/bus.h>
+Index: libc/socket/Makefile
+===================================================================
+--- libc.orig/socket/Makefile
++++ libc/socket/Makefile
+@@ -21,7 +21,7 @@
+ #
+ subdir := socket
+
+-headers := sys/socket.h sys/un.h bits/sockaddr.h bits/socket.h \
++headers := sys/socket.h sys/bus.h sys/un.h bits/sockaddr.h bits/socket.h \
+ bits/socket2.h sys/socketvar.h net/if.h
+
+ routines := accept bind connect getpeername getsockname getsockopt \
+Index: libc/socket/sys/bus.h
+===================================================================
+--- /dev/null
++++ libc/socket/sys/bus.h
+@@ -0,0 +1,57 @@
++/* Copyright (C) 1991, 1995, 1996, 2001 Free Software Foundation, Inc.
++ This file is part of the GNU C Library.
++
++ The GNU C Library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Lesser General Public
++ License as published by the Free Software Foundation; either
++ version 2.1 of the License, or (at your option) any later version.
++
++ The GNU C Library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Lesser General Public License for more details.
++
++ You should have received a copy of the GNU Lesser General Public
++ License along with the GNU C Library; if not, see
++ <http://www.gnu.org/licenses/>. */
++
++#ifndef _SYS_BUS_H
++#define _SYS_BUS_H 1
++
++#include <sys/cdefs.h>
++
++/* Get the definition of the macro to define the common sockaddr members. */
++#include <bits/sockaddr.h>
++
++__BEGIN_DECLS
++
++/* 'protocol' to use in socket(AF_BUS, SOCK_SEQPACKET, protocol) */
++#define BUS_PROTO_NONE 0
++#define BUS_PROTO_DBUS 1
++#define BUS_PROTO_MAX 1
++
++/* setsockopt() operations */
++#define SOL_BUS 280
++#define BUS_ADD_ADDR 1
++#define BUS_JOIN_BUS 2
++#define BUS_DEL_ADDR 3
++#define BUS_SET_EAVESDROP 4
++#define BUS_UNSET_EAVESDROP 5
++
++/* Bus address */
++struct bus_addr
++ {
++ __uint64_t s_addr; /* 16-bit prefix + 48-bit client address */
++ };
++
++/* Structure describing an AF_BUS socket address. */
++struct sockaddr_bus
++ {
++ __SOCKADDR_COMMON (sbus_); /* AF_BUS */
++ struct bus_addr sbus_addr; /* bus address */
++ char sbus_path[108]; /* pathname */
++ };
++
++__END_DECLS
++
++#endif /* sys/bus.h */
+Index: libc/socket/sys/socket.h
+===================================================================
+--- libc.orig/socket/sys/socket.h
++++ libc/socket/sys/socket.h
+@@ -86,7 +86,8 @@ enum
+ __SOCKADDR_ONETYPE (sockaddr_iso) \
+ __SOCKADDR_ONETYPE (sockaddr_ns) \
+ __SOCKADDR_ONETYPE (sockaddr_un) \
+- __SOCKADDR_ONETYPE (sockaddr_x25)
++ __SOCKADDR_ONETYPE (sockaddr_x25) \
++ __SOCKADDR_ONETYPE (sockaddr_bus)
+
+ # define __SOCKADDR_ONETYPE(type) struct type *__restrict __##type##__;
+ typedef union { __SOCKADDR_ALLTYPES
+Index: libc/sysdeps/unix/sysv/linux/bits/socket.h
+===================================================================
+--- libc.orig/sysdeps/unix/sysv/linux/bits/socket.h
++++ libc/sysdeps/unix/sysv/linux/bits/socket.h
+@@ -80,7 +80,8 @@
+ #define PF_ALG 38 /* Algorithm sockets. */
+ #define PF_NFC 39 /* NFC sockets. */
+ #define PF_VSOCK 40 /* vSockets. */
+-#define PF_MAX 41 /* For now.. */
++#define PF_BUS 41 /* AF_BUS sockets */
++#define PF_MAX 42 /* For now.. */
+
+ /* Address families. */
+ #define AF_UNSPEC PF_UNSPEC
+@@ -125,6 +126,7 @@
+ #define AF_ALG PF_ALG
+ #define AF_NFC PF_NFC
+ #define AF_VSOCK PF_VSOCK
++#define AF_BUS PF_BUS
+ #define AF_MAX PF_MAX
+
+ /* Socket level values. Others are defined in the appropriate headers.