From 12b2b49fbe889d8dcd10d682fa2e7595c52b7072 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Thu, 3 Nov 2011 12:39:48 +0000 Subject: [PATCH 08/14] Remove check for abstract sockets, not relevant to dbus-glib (v2: also remove from Android.mk) --- Android.mk | 1 - configure.ac | 67 ---------------------------------------------------------- 2 files changed, 0 insertions(+), 68 deletions(-) diff --git a/Android.mk b/Android.mk index 8ba5609..7d30b96 100644 --- a/Android.mk +++ b/Android.mk @@ -16,7 +16,6 @@ dbus-glib-configure-real: CPPFLAGS="$(CONFIGURE_CPPFLAGS)" \ PKG_CONFIG_LIBDIR="$(CONFIGURE_PKG_CONFIG_LIBDIR)" \ PKG_CONFIG_TOP_BUILD_DIR=$(PKG_CONFIG_TOP_BUILD_DIR) \ - ac_cv_have_abstract_sockets=no \ ac_cv_lib_expat_XML_ParserCreate_MM=yes \ $(DBUS_GLIB_TOP)/$(CONFIGURE) --host=arm-linux-androideabi \ --disable-nls --disable-gtk-doc && \ diff --git a/configure.ac b/configure.ac index 21c1f1e..1d4d641 100644 --- a/configure.ac +++ b/configure.ac @@ -242,73 +242,6 @@ if test "x$dbus_have_socklen_t" = "xyes"; then AC_DEFINE(HAVE_SOCKLEN_T,1,[Have socklen_t type]) fi -#### Abstract sockets - -AC_LANG_PUSH(C) -AC_CACHE_CHECK([abstract socket namespace], - ac_cv_have_abstract_sockets, - [AC_RUN_IFELSE([AC_LANG_PROGRAM( -[[ -#include -#include -#include -#include -#include -#include -#include -]], -[[ - 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/dbus-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); -]])], - [ac_cv_have_abstract_sockets=yes], - [ac_cv_have_abstract_sockets=no] -)]) -AC_LANG_POP(C) - -if test x$enable_abstract_sockets = xyes; then - if test x$ac_cv_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 - ac_cv_have_abstract_sockets=no; -fi - -if test x$ac_cv_have_abstract_sockets = xyes ; then - DBUS_PATH_OR_ABSTRACT=abstract - AC_DEFINE(HAVE_ABSTRACT_SOCKETS,1,[Have abstract socket namespace]) -else - DBUS_PATH_OR_ABSTRACT=path -fi - -# this is used in addresses to prefer abstract, e.g. -# unix:path=/foo or unix:abstract=/foo -AC_SUBST(DBUS_PATH_OR_ABSTRACT) - #### Sort out XML library # see what we have -- 1.7.7.1