Revision 1.6 |
Revision 1.12 |
Line 2 |
Line 2 |
# Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) 
|
# Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) 
|
AC_INIT(CoW Webserver, 0.4.1, roper@cs.ucdavis.edu, cow)
AM_INIT_AUTOMAKE(cow, 0.4.1)
|
AC_INIT(CoW Webserver, 0.4.2, roper@cs.ucdavis.edu, cow)
AM_INIT_AUTOMAKE(cow, 0.4.2)
|
AC_CONFIG_SRCDIR([cow.c]) AM_CONFIG_HEADER(config.h) # Checks for programs. AC_PROG_CC AM_PROG_LEX
|
AC_CONFIG_SRCDIR([cow.c]) AM_CONFIG_HEADER(config.h) # Checks for programs. AC_PROG_CC AM_PROG_LEX
|
# Check for Pth library
AC_CHECK_PTH(1.3.0, subdir:pth, --disable-shared --disable-tests)
AC_CONFIG_SUBDIRS(pth)
|
|
# Checks for header files. AC_HEADER_DIRENT
|
# Checks for header files. AC_HEADER_DIRENT
|
Line 34 |
Line 30 |
AC_FUNC_STRFTIME AC_CHECK_FUNCS([bzero dup2 getcwd inet_ntoa memset munmap socket strchr strdup strrchr])
|
AC_FUNC_STRFTIME AC_CHECK_FUNCS([bzero dup2 getcwd inet_ntoa memset munmap socket strchr strdup strrchr])
|
|
# Check for TCP_CORK
#AC_MSG_CHECKING(availability of TCP_CORK)
#AC_EGREP_CPP(SUCCESS,
# [
# #include <netinet/tcp.h>
# #ifdef TCP_CORK
# SUCCESS
# #endif
# ],[
# AC_MSG_RESULT(present)
# AC_DEFINE([HAVE_TCPCORK], [], [TCP_CORK option is available])
#
# AC_MSG_CHECKING(whether to use TCP_CORK)
# AC_ARG_ENABLE(tcpcork,
# AC_HELP_STRING([--disable-tcpcork],
# [disable use of TCP_CORK buffering on Linux]),
# [
# if test "$enableval" = "no"; then
# AC_MSG_RESULT(no)
# else
# AC_MSG_RESULT(yes)
# AC_DEFINE([USE_TCPCORK], [],
# [Use TCP_CORK buffering on Linux])
# fi
# ],
# [
# AC_MSG_RESULT(yes)
# AC_DEFINE([USE_TCPCORK], [],
# [Use TCP_CORK buffering on Linux])
# ])
# ],[
# AC_MSG_RESULT(not present)
# ])
## Use sendfile() support?
#AC_MSG_CHECKING(whether to use sendfile)
#AC_ARG_ENABLE(sendfile,
# AC_HELP_STRING([--disable-sendfile],
# [disable sendfile() support, use writev() instead]),
#[
# if test "$enableval" = "no"; then
# AC_MSG_RESULT(no)
# else
# AC_MSG_RESULT(yes)
# AC_DEFINE([USE_SENDFILE], [], [Send responses with sendfile()])
# fi
#],
#[
# AC_MSG_RESULT(yes)
# AC_DEFINE([USE_SENDFILE], [], [Send responses with sendfile()])
#])
# Enable HTTP PUT requests?
AC_MSG_CHECKING(whether to enable PUT requests)
AC_ARG_ENABLE(put,
AC_HELP_STRING([--enable-put],
[Enable HTTP PUT requests]),
[
if test "$enableval" = "no"; then
AC_MSG_RESULT(no)
else
AC_MSG_RESULT(yes)
AC_DEFINE([ENABLE_PUT], [], [Enable PUT requests])
fi
],
[
AC_MSG_RESULT(no)
])
# Enable 503 (too busy) HTTP responses?
AC_MSG_CHECKING(whether to send 503 responses when overloaded)
AC_ARG_ENABLE(put,
AC_HELP_STRING([--enable-503],
[Enable HTTP 503 responses when overloaded]),
[
if test "$enableval" = "no"; then
AC_MSG_RESULT(no)
else
AC_MSG_RESULT(yes)
AC_DEFINE([ENABLE_503], [], [Enable 503 HTTP responses])
fi
],
[
AC_MSG_RESULT(no)
])
# Disable Keep-alive support?
AC_MSG_CHECKING(whether to enable keep-alive connections)
AC_ARG_ENABLE(keepalive,
AC_HELP_STRING([--disable-keepalive],
[disable keep-alive connections]),
[
if test "$enableval" = "no"; then
AC_MSG_RESULT(no)
AC_DEFINE([DISABLE_KEEPALIVE], [],
[Disable persistent connections])
else
AC_MSG_RESULT(yes)
fi
],
[
AC_MSG_RESULT(yes)
])
# Enable epoll-based pth code (highly experimental)
AC_MSG_CHECKING(whether to build Pth on top of epoll (very experimental))
AC_ARG_WITH(epoll,
AC_HELP_STRING([--with-epoll],
[build Pth on top of epoll (very experimental)]),
[
if test "$withval" = "yes"; then
AC_MSG_RESULT(yes)
EPOLL_FLAG="--enable-epoll"
else
AC_MSG_RESULT(no)
EPOLL_FLAG=""
fi
],
[
AC_MSG_RESULT(no)
EPOLL_FLAG=""
])
|
# Enable dmalloc? AC_MSG_CHECKING(whether to link with the Dmalloc memory debugger/profiler) AC_ARG_WITH(dmalloc,
|
# Enable dmalloc? AC_MSG_CHECKING(whether to link with the Dmalloc memory debugger/profiler) AC_ARG_WITH(dmalloc,
|
[ --with-dmalloc link with the Dmalloc memory debugger/profiler],
|
AC_HELP_STRING([--with-dmalloc],
|
|
[link with the Dmalloc memory debugger/profiler]),
|
[ if test "$withval" = "yes"; then AC_MSG_RESULT(trying)
|
[ if test "$withval" = "yes"; then AC_MSG_RESULT(trying)
|
Line 53 |
Line 177 |
# Enable logging? AC_MSG_CHECKING(whether to enable logging) AC_ARG_ENABLE(logging,
|
# Enable logging? AC_MSG_CHECKING(whether to enable logging) AC_ARG_ENABLE(logging,
|
[ --enable-logging Enable logging support (incomplete)],
|
AC_HELP_STRING([--enable-logging],
|
|
[Enable logging support (incomplete)]),
|
[ if test "$enableval" = "yes" ; then CFLAGS="$CFLAGS -DLOGGING"
|
[ if test "$enableval" = "yes" ; then CFLAGS="$CFLAGS -DLOGGING"
|
Line 66 |
Line 191 |
AC_MSG_RESULT(no) ])
|
AC_MSG_RESULT(no) ])
|
|
# Check for Pth library
AC_CHECK_PTH(1.3.0, subdir:pth $EPOLL_FLAG, --disable-shared --disable-tests)
AC_CONFIG_SUBDIRS(pth)
|
AC_CONFIG_FILES([Makefile]) AC_OUTPUT
|
AC_CONFIG_FILES([Makefile]) AC_OUTPUT
|