]> git.pld-linux.org Git - packages/perl-FCGI.git/blob - perl-FCGI-acinclude.m4
- rel 5
[packages/perl-FCGI.git] / perl-FCGI-acinclude.m4
1 AC_DEFUN(FCGI_COMMON_CHECKS, [
2     AC_CHECK_TYPE([ssize_t], [int]) 
3
4     AC_MSG_CHECKING([for sun_len in sys/un.h])
5     AC_EGREP_HEADER([sun_len], [sys/un.h],
6         [AC_MSG_RESULT([yes])
7          AC_DEFINE([HAVE_SOCKADDR_UN_SUN_LEN], [1],
8            [Define if sockaddr_un in sys/un.h contains a sun_len component])],
9         AC_MSG_RESULT([no]))
10
11     AC_MSG_CHECKING([for fpos_t in stdio.h])
12     AC_EGREP_HEADER([fpos_t], [stdio.h],
13         [AC_MSG_RESULT([yes])
14          AC_DEFINE([HAVE_FPOS], [1], 
15             [Define if the fpos_t typedef is in stdio.h])],
16         AC_MSG_RESULT([no]))
17
18     AC_CHECK_HEADERS([sys/socket.h netdb.h netinet/in.h arpa/inet.h])
19     AC_CHECK_HEADERS([sys/time.h limits.h sys/param.h unistd.h])
20
21     AC_MSG_CHECKING([for a fileno() prototype in stdio.h])
22     AC_EGREP_HEADER([fileno], [stdio.h], 
23             [AC_MSG_RESULT([yes]) 
24              AC_DEFINE([HAVE_FILENO_PROTO], [1], 
25                    [Define if there's a fileno() prototype in stdio.h])],
26             AC_MSG_RESULT([no]))
27
28     if test "$HAVE_SYS_SOCKET_H"; then
29         AC_MSG_CHECKING([for socklen_t in sys/socket.h])
30         AC_EGREP_HEADER([socklen_t], [sys/socket.h],
31             [AC_MSG_RESULT([yes])
32              AC_DEFINE([HAVE_SOCKLEN], [1],
33                                [Define if the socklen_t typedef is in sys/socket.h])],
34            AC_MSG_RESULT([no]))
35     fi
36
37     #--------------------------------------------------------------------
38     #  Do we need cross-process locking on this platform?
39     #--------------------------------------------------------------------
40     AC_MSG_CHECKING([whether cross-process locking is required by accept()])
41     case "`uname -sr`" in
42         IRIX\ 5.* | SunOS\ 5.* | UNIX_System_V\ 4.0)    
43                     AC_MSG_RESULT([yes])
44                     AC_DEFINE([USE_LOCKING], [1], 
45                       [Define if cross-process locking is required by accept()])
46             ;;
47         *)
48                     AC_MSG_RESULT([no])
49                 ;;
50     esac
51
52     #--------------------------------------------------------------------
53     #  Does va_arg(arg, long double) crash the compiler?
54     #  hpux 9.04 compiler does and so does Stratus FTX (uses HP's compiler)
55     #--------------------------------------------------------------------
56     AC_MSG_CHECKING([whether va_arg(arg, long double) crashes the compiler])
57     AC_TRY_COMPILE([#include <stdarg.h>],
58        [long double lDblArg; va_list arg; lDblArg = va_arg(arg, long double);],
59        AC_MSG_RESULT([no]),
60        [AC_MSG_RESULT([yes])
61         AC_DEFINE([HAVE_VA_ARG_LONG_DOUBLE_BUG], [1],
62               [Define if va_arg(arg, long double) crashes the compiler])])
63
64     AC_C_CONST 
65 ])
This page took 0.10334 seconds and 3 git commands to generate.