mirror of
https://github.com/php/php-src.git
synced 2024-12-01 22:03:36 +08:00
226e1ed246
because it does not include <sys/socket.h> which is necessary for the definition of struct msghdr. This include file is not part of ac_includes_default. Regardless, AC_CHECK_MEMBER is a autoconf-2.5x macro and thus we expand it here for 2.13 compatibility.
22 lines
547 B
Plaintext
22 lines
547 B
Plaintext
dnl
|
|
dnl $Id$
|
|
dnl
|
|
|
|
PHP_ARG_ENABLE(sockets, whether to enable sockets support,
|
|
[ --enable-sockets Enable sockets support])
|
|
|
|
if test "$PHP_SOCKETS" != "no"; then
|
|
|
|
AC_CHECK_FUNCS([hstrerror])
|
|
AC_CHECK_HEADERS([netdb.h netinet/tcp.h sys/un.h errno.h])
|
|
AC_TRY_COMPILE([
|
|
#include <sys/types.h>
|
|
#include <sys/socket.h>
|
|
], [static struct msghdr tp; int n = (int) tp.msg_flags; return n],
|
|
[AC_DEFINE(MISSING_MSGHDR_MSGFLAGS, 1, [ ])]
|
|
)
|
|
AC_DEFINE([HAVE_SOCKETS], 1, [ ])
|
|
|
|
PHP_NEW_EXTENSION([sockets], [sockets.c], [$ext_shared])
|
|
fi
|