X-Git-Url: http://www.dolda2000.com/gitweb/?a=blobdiff_plain;f=configure.in;h=c8b97d6791017b79eae32c7579d88c64b3f77a9e;hb=695e99c86c52bfec896feff3a38da1fdec49fb3a;hp=1242e84cac8c6c61d62931515725a29379cf0ace;hpb=945d02f51b66c1ca7b8ae959cd06b4f9ebbd0954;p=ashd.git diff --git a/configure.in b/configure.in index 1242e84..c8b97d6 100644 --- a/configure.in +++ b/configure.in @@ -22,22 +22,28 @@ if test "$HAS_MAGIC" = no; then fi AH_TEMPLATE(HAVE_GLIBC_STDIO, [define to indicate system support for glibc cookie streams]) +AH_TEMPLATE(HAVE_BSD_STDIO, [define to indicate system support for BSD-style funopen streams]) HAS_FOPENCOOKIE=yes AC_CHECK_FUNC(fopencookie, [], [HAS_FOPENCOOKIE=no]) AC_CHECK_MEMBER([cookie_io_functions_t.read], [], [HAS_FOPENCOOKIE=no]) +HAS_FUNOPEN=yes +AC_CHECK_FUNC(funopen, [], [HAS_FUNOPEN=no]) + if test "$HAS_FOPENCOOKIE" = yes; then - AC_DEFINE(HAVE_GLIBC_STDIO) + AC_DEFINE(HAVE_GLIBC_STDIO) +elif test "$HAS_FUNOPEN" = yes; then + AC_DEFINE(HAVE_BSD_STDIO) else - AC_MSG_ERROR([*** libc support for custom stdio streams is required]) + AC_MSG_ERROR([*** libc support for custom stdio streams is required]) fi AH_TEMPLATE(HAVE_VALGRIND, [define to include debugging support for Valgrind]) AC_CHECK_HEADER(valgrind/memcheck.h, [AC_DEFINE(HAVE_VALGRIND)], []) AH_TEMPLATE(HAVE_EPOLL, [define to enable epoll support]) -AC_ARG_WITH(epoll, [ --with-epoll Enable epoll(2) support]) +AC_ARG_WITH(epoll, AS_HELP_STRING([--with-epoll], [enable epoll(2) support])) HAS_EPOLL="" if test "$with_epoll" = no; then HAS_EPOLL=no; fi if test -z "$HAS_EPOLL"; then @@ -56,7 +62,7 @@ fi AM_CONDITIONAL(USE_EPOLL, [test "$HAS_EPOLL" = yes ]) AH_TEMPLATE(HAVE_XATTR, [define to compile support for filesystem extended attributes]) -AC_ARG_WITH(xattr, [ --with-xattr Enable XATTR support]) +AC_ARG_WITH(xattr, AS_HELP_STRING([--with-xattr], [enable XATTR support])) HAS_XATTR="" if test "$with_xattr" = no; then HAS_XATTR=no; fi if test -z "$HAS_XATTR"; then @@ -76,7 +82,7 @@ fi AC_SUBST(XATTR_LIBS) AH_TEMPLATE(HAVE_GNUTLS, [define to use the GnuTLS library for SSL support]) -AC_ARG_WITH(gnutls, [ --with-gnutls Enable SSL support with the GnuTLS library]) +AC_ARG_WITH(gnutls, AS_HELP_STRING([--with-gnutls], [enable SSL support with the GnuTLS library])) HAS_GNUTLS="" if test "$with_gnutls" = no; then HAS_GNUTLS=no; fi if test -z "$HAS_GNUTLS"; then