summaryrefslogtreecommitdiffstats
path: root/recipes/nonworking/maemo/sapwood/sockets.patch
blob: 1568206e2a6046239e30556ce16c58c8fd4bf63b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
--- configure.in.old	2005-06-10 17:04:52.000000000 +0200
+++ configure.in	2005-06-10 17:20:47.000000000 +0200
@@ -13,61 +13,61 @@
 AC_PROG_MAKE_SET
 
 dnl abstract sockets namespace checks, from dbus
-AC_ARG_ENABLE(abstract-sockets,
-	      [AC_HELP_STRING([--enable-abstract-sockets],
-			      [use abstract socket namespace (linux only)])],
-	      [enable_abstract_sockets=$enableval],
-	      [enable_abstract_sockets=auto])
-
-AC_MSG_CHECKING(abstract socket namespace)
-AC_RUN_IFELSE([AC_LANG_PROGRAM(
-[[
+#AC_ARG_ENABLE(abstract-sockets,
+#	      [AC_HELP_STRING([--enable-abstract-sockets],
+#			      [use abstract socket namespace (linux only)])],
+#	      [enable_abstract_sockets=$enableval],
+#	      [enable_abstract_sockets=no])
+#
+#AC_MSG_CHECKING(abstract socket namespace)
+#AC_RUN_IFELSE([AC_LANG_PROGRAM(
+#[[
 #include <sys/types.h>
 #include <stdlib.h>
 #include <stdio.h>
 #include <sys/socket.h>
 #include <sys/un.h>
 #include <errno.h>
-]],
-[[
-  int listen_fd;
-  struct sockaddr_un addr;
-
-  listen_fd = socket (PF_UNIX, SOCK_STREAM, 0);
-
-  if (listen_fd < 0)
-    {
-      fprintf (stderr, "socket() failed: %s\n", strerror (errno));
-      exit (1);
-    }
-
-  memset (&addr, '\0', sizeof (addr));
-  addr.sun_family = AF_UNIX;
-  strcpy (addr.sun_path, "X/tmp/sapwood-fake-socket-path-used-in-configure-test");
-  addr.sun_path[0] = '\0'; /* this is what makes it abstract */
-
-  if (bind (listen_fd, (struct sockaddr*) &addr, SUN_LEN (&addr)) < 0)
-    {
-      fprintf (stderr, "Abstract socket namespace bind() failed: %s\n",
-               strerror (errno));
-      exit (1);
-    }
-  else
-    exit (0);
-]])],
-  [have_abstract_sockets=yes],
-  [have_abstract_sockets=no])
-AC_MSG_RESULT($have_abstract_sockets)
-
-if test x$enable_abstract_sockets = xyes; then
-  if test x$have_abstract_sockets = xno; then
-    AC_MSG_ERROR([Abstract sockets explicitly required, and support not detected.])
-  fi
-fi
-
-if test x$enable_abstract_sockets = xno; then
-  have_abstract_sockets=no
-fi
+#]],
+#[[
+#  int listen_fd;
+#  struct sockaddr_un addr;
+#
+#  listen_fd = socket (PF_UNIX, SOCK_STREAM, 0);
+
+#  if (listen_fd < 0)
+#    {
+#      fprintf (stderr, "socket() failed: %s\n", strerror (errno));
+#      exit (1);
+#   }
+#
+#  memset (&addr, '\0', sizeof (addr));
+#  addr.sun_family = AF_UNIX;
+#  strcpy (addr.sun_path, "X/tmp/sapwood-fake-socket-path-used-in-configure-test");
+#  addr.sun_path[0] = '\0'; /* this is what makes it abstract */
+#
+#  if (bind (listen_fd, (struct sockaddr*) &addr, SUN_LEN (&addr)) < 0)
+#    {
+#      fprintf (stderr, "Abstract socket namespace bind() failed: %s\n",
+#               strerror (errno));
+#      exit (1);
+#    }
+#  else
+#    exit (0);
+#]])],
+#  [have_abstract_sockets=no],
+#  [have_abstract_sockets=no])
+#AC_MSG_RESULT($have_abstract_sockets)
+
+#if test x$enable_abstract_sockets = xyes; then
+#  if test x$have_abstract_sockets = xno; then
+#    AC_MSG_ERROR([Abstract sockets explicitly required, and support not detected.])
+#  fi
+#fi
+
+#if test x$enable_abstract_sockets = xno; then
+have_abstract_sockets=no
+#fi
 
 if test x$have_abstract_sockets = xyes; then
   AC_DEFINE(HAVE_ABSTRACT_SOCKETS,1,[Have abstract socket namespace])