summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArno Töll <arno@debian.org>2012-11-21 23:03:59 +0100
committerArno Töll <arno@debian.org>2012-11-21 23:03:59 +0100
commit16cadaab87d25fc026ac777746eabbff3030f0cc (patch)
treeebd408dc2d6d5d821137994e93203e57ab8f25f6
parent985230456afb0b945234dfac919a6ece3df4a715 (diff)
downloadlighttpd-16cadaab87d25fc026ac777746eabbff3030f0cc.tar.gz
Imported Upstream version 1.4.28upstream/1.4.28
-rw-r--r--AUTHORS7
-rw-r--r--Makefile.in4
-rw-r--r--NEWS36
-rw-r--r--SConstruct4
-rw-r--r--aclocal.m462
-rw-r--r--config.h.in9
-rwxr-xr-xconfigure1469
-rw-r--r--configure.ac58
-rw-r--r--doc/Makefile.am6
-rw-r--r--doc/Makefile.in288
-rw-r--r--doc/config/Makefile.am2
-rw-r--r--doc/config/Makefile.in597
-rw-r--r--doc/config/conf.d/Makefile.am25
-rw-r--r--doc/config/conf.d/Makefile.in419
-rw-r--r--doc/config/conf.d/access_log.conf27
-rw-r--r--doc/config/conf.d/auth.conf27
-rw-r--r--doc/config/conf.d/cgi.conf33
-rw-r--r--doc/config/conf.d/cml.conf27
-rw-r--r--doc/config/conf.d/compress.conf31
-rw-r--r--doc/config/conf.d/debug.conf47
-rw-r--r--doc/config/conf.d/dirlisting.conf55
-rw-r--r--doc/config/conf.d/evhost.conf22
-rw-r--r--doc/config/conf.d/expire.conf22
-rw-r--r--doc/config/conf.d/fastcgi.conf135
-rw-r--r--doc/config/conf.d/geoip.conf26
-rw-r--r--doc/config/conf.d/magnet.conf22
-rw-r--r--doc/config/conf.d/mime.conf77
-rw-r--r--doc/config/conf.d/mod.template16
-rw-r--r--doc/config/conf.d/mysql_vhost.conf47
-rw-r--r--doc/config/conf.d/proxy.conf35
-rw-r--r--doc/config/conf.d/rrdtool.conf21
-rw-r--r--doc/config/conf.d/scgi.conf51
-rw-r--r--doc/config/conf.d/secdownload.conf35
-rw-r--r--doc/config/conf.d/simple_vhost.conf28
-rw-r--r--doc/config/conf.d/ssi.conf16
-rw-r--r--doc/config/conf.d/status.conf24
-rw-r--r--doc/config/conf.d/trigger_b4_dl.conf70
-rw-r--r--doc/config/conf.d/userdir.conf37
-rw-r--r--doc/config/conf.d/webdav.conf33
-rw-r--r--doc/config/lighttpd.conf426
-rw-r--r--doc/config/modules.conf172
-rw-r--r--doc/config/vhosts.d/Makefile.am1
-rw-r--r--doc/config/vhosts.d/Makefile.in394
-rw-r--r--doc/config/vhosts.d/vhosts.template33
-rw-r--r--doc/initscripts/Makefile.am1
-rw-r--r--doc/initscripts/Makefile.in394
-rwxr-xr-xdoc/initscripts/rc.lighttpd (renamed from doc/rc.lighttpd)0
-rwxr-xr-xdoc/initscripts/rc.lighttpd.redhat (renamed from doc/rc.lighttpd.redhat)0
-rw-r--r--doc/initscripts/sysconfig.lighttpd (renamed from doc/sysconfig.lighttpd)0
-rw-r--r--doc/lighttpd.conf322
-rw-r--r--doc/lighttpd.user1
-rw-r--r--doc/scripts/Makefile.am3
-rw-r--r--doc/scripts/Makefile.in397
-rwxr-xr-xdoc/scripts/rrdtool-graph.sh (renamed from doc/rrdtool-graph.sh)0
-rwxr-xr-xdoc/scripts/spawn-php.sh (renamed from doc/spawn-php.sh)0
-rw-r--r--src/Makefile.am12
-rw-r--r--src/Makefile.in51
-rw-r--r--src/SConscript2
-rw-r--r--src/array.c24
-rw-r--r--src/base.h2
-rw-r--r--src/buffer.h1
-rw-r--r--src/configfile.c54
-rw-r--r--src/connections.c40
-rw-r--r--src/data_string.c19
-rw-r--r--src/etag.c2
-rw-r--r--src/fdevent.c75
-rw-r--r--src/fdevent.h74
-rw-r--r--src/fdevent_freebsd_kqueue.c100
-rw-r--r--src/fdevent_libev.c168
-rw-r--r--src/fdevent_linux_rtsig.c258
-rw-r--r--src/fdevent_linux_sysepoll.c26
-rw-r--r--src/fdevent_poll.c39
-rw-r--r--src/fdevent_select.c19
-rw-r--r--src/fdevent_solaris_devpoll.c53
-rw-r--r--src/http_auth.c11
-rw-r--r--src/keyvalue.c6
-rw-r--r--src/keyvalue.h4
-rw-r--r--src/mod_accesslog.c85
-rw-r--r--src/mod_cgi.c55
-rw-r--r--src/mod_compress.c37
-rw-r--r--src/mod_dirlisting.c2
-rw-r--r--src/mod_extforward.c15
-rw-r--r--src/mod_fastcgi.c37
-rw-r--r--src/mod_proxy.c29
-rw-r--r--src/mod_redirect.c2
-rw-r--r--src/mod_scgi.c29
-rw-r--r--src/mod_staticfile.c3
-rw-r--r--src/mod_status.c15
-rw-r--r--src/network.c25
-rw-r--r--src/plugin.c9
-rw-r--r--src/response.c6
-rw-r--r--src/server.c17
-rw-r--r--src/stat_cache.c6
-rw-r--r--src/stat_cache.h2
-rw-r--r--tests/Makefile.in4
-rw-r--r--tests/docroot/123/Makefile.in4
-rw-r--r--tests/docroot/Makefile.in4
-rw-r--r--tests/docroot/www/Makefile.in4
-rw-r--r--tests/docroot/www/expire/Makefile.in4
-rw-r--r--tests/docroot/www/go/Makefile.in4
-rw-r--r--tests/docroot/www/indexfile/Makefile.in4
101 files changed, 5837 insertions, 1699 deletions
diff --git a/AUTHORS b/AUTHORS
index 80ea411..590be9d 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -1 +1,6 @@
-jan kneschke <jan@kneschke.de>
+Jan Kneschke <jan@kneschke.de>
+Elan Ruusamäe <glen@delfi.ee>
+Marcus Rückert <darix@opensu.se>
+mOo <moo.lighttpd@gmail.com>
+Robert Jakabosky <bobby@neoawareness.com>
+Stefan Bühler <stbuehler@web.de>
diff --git a/Makefile.in b/Makefile.in
index 8f67c32..f577e28 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -152,6 +152,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -183,6 +185,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/NEWS b/NEWS
index 493f0de..f2cd39c 100644
--- a/NEWS
+++ b/NEWS
@@ -3,7 +3,41 @@
NEWS
====
-- 1.4.26 -
+- 1.4.28 -
+ * Rename fdevent_event_add to _set to reflect what the function does. Fix some handlers. (fixes #2249)
+ * Fix buffer.h to include stdio.h as it is needer for SEGFAULT() (fixes #2250)
+
+- 1.4.27 - 2010-08-13
+ * Fix handling return value of SSL_CTX_set_options (fixes #2157, thx mlcreech)
+ * Fix mod_proxy HUP handling (send final chunk, fix usage counter)
+ * mod_proxy: close connection on write error (fixes #2114)
+ * Check uri instead of physical path for directory redirect
+ * Fix detecting git repository (fixes #2173, thx ncopa)
+ * [mod_compress] Fix segfault when etags are disabled (fixes #2169)
+ * Reset uri.authority before TLS servername handling, reset all "keep-alive" data in connection_del (fixes #2125)
+ * Print double quotes properly when dumping config file (fixes #1806)
+ * Include IP addresses on error log on password failures (fixes #2191)
+ * Fix stalls while reading from ssl sockets (fixes #2197)
+ * Fix etag formatting on boxes with 32-bit longs
+ * Fix two compiler warnings
+ * mod_accesslog: fix %p for ipv6 sockets (fixes #2228, thx jo.henke)
+ * mod_fastcgi: Send 502 "Bad Gateway" if we couldn't open the file for X-Sendfile (fixes #2226)
+ * mod_staticfile: add debug output if we ignore a file with static-file.exclude-extensions (fixes #2215)
+ * mod_cgi: fix race condition leaving response not forwarded to client (fixes #2217)
+ * mod_accesslog: Fix var declarations mixed in source (fixes #2233)
+ * mod_status: Add version to status page (fixes #2219)
+ * mod_accesslog: optimize accesslog_append_escaped (fixes #2236, thx crypt)
+ * openssl: silence annoying error messages for errno==0 (fixes #2213)
+ * array.c: improve array_get_unused_element to check data type; fix mem leak if unused_element didn't find a matching entry (fixes #2145)
+ * add check to stop loading plugins twice
+ * cleanup fdevent code, removed linux-rtsig handler, replaced some fprintf calls
+ * only require FDEVENT_IN bit to be set for listening connections (fixes #2227)
+ * add libev fdevent handler: server.event-handler = "libev"
+ * mod_proxy: return response as soon as it is available (fixes #2196)
+ * don't overwrite global server.force-lowercase-filenames setting (fixes #2042)
+ * bind to IPV6-only if ipv6 address was specified (http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config)
+
+- 1.4.26 - 2010-02-07
* Fix request parser to handle packets with splitted \r\n\r\n (fixes #2105)
* Remove dependency on automake >= 1.11 with m4_ifdef check
* mod_accesslog: support %e (fixes #2113, thx presbrey)
diff --git a/SConstruct b/SConstruct
index 3e03e38..0513f53 100644
--- a/SConstruct
+++ b/SConstruct
@@ -5,7 +5,7 @@ import string
from stat import *
package = 'lighttpd'
-version = '1.4.26'
+version = '1.4.28'
def checkCHeaders(autoconf, hdrs):
p = re.compile('[^A-Z0-9]')
@@ -157,7 +157,7 @@ if 1:
checkFuncs(autoconf, Split('fork stat lstat strftime dup2 getcwd inet_ntoa inet_ntop memset mmap munmap strchr \
strdup strerror strstr strtol sendfile getopt socket \
- gethostbyname poll sigtimedwait epoll_ctl getrlimit chroot \
+ gethostbyname poll epoll_ctl getrlimit chroot \
getuid select signal pathconf madvise prctl\
writev sigaction sendfile64 send_file kqueue port_create localtime_r posix_fadvise issetugid inet_pton'))
diff --git a/aclocal.m4 b/aclocal.m4
index 009e640..a2e838c 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -13,13 +13,14 @@
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.65],,
-[m4_warning([this file was generated for autoconf 2.65.
+m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.67],,
+[m4_warning([this file was generated for autoconf 2.67.
You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically `autoreconf'.])])
# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
+# serial 1 (pkg-config-0.24)
#
# Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
#
@@ -47,7 +48,10 @@ To do so, use the procedure documented by the package, typically `autoreconf'.])
AC_DEFUN([PKG_PROG_PKG_CONFIG],
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
-AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl
+AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])
+AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path])
+AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path])
+
if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
fi
@@ -60,7 +64,6 @@ if test -n "$PKG_CONFIG"; then
AC_MSG_RESULT([no])
PKG_CONFIG=""
fi
-
fi[]dnl
])# PKG_PROG_PKG_CONFIG
@@ -69,34 +72,31 @@ fi[]dnl
# Check to see whether a particular set of modules exists. Similar
# to PKG_CHECK_MODULES(), but does not set variables or print errors.
#
-#
-# Similar to PKG_CHECK_MODULES, make sure that the first instance of
-# this or PKG_CHECK_MODULES is called, or make sure to call
-# PKG_CHECK_EXISTS manually
+# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
+# only at the first occurence in configure.ac, so if the first place
+# it's called might be skipped (such as if it is within an "if", you
+# have to call PKG_CHECK_EXISTS manually
# --------------------------------------------------------------
AC_DEFUN([PKG_CHECK_EXISTS],
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
if test -n "$PKG_CONFIG" && \
AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
- m4_ifval([$2], [$2], [:])
+ m4_default([$2], [:])
m4_ifvaln([$3], [else
$3])dnl
fi])
-
# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
# ---------------------------------------------
m4_define([_PKG_CONFIG],
-[if test -n "$PKG_CONFIG"; then
- if test -n "$$1"; then
- pkg_cv_[]$1="$$1"
- else
- PKG_CHECK_EXISTS([$3],
- [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
- [pkg_failed=yes])
- fi
-else
- pkg_failed=untried
+[if test -n "$$1"; then
+ pkg_cv_[]$1="$$1"
+ elif test -n "$PKG_CONFIG"; then
+ PKG_CHECK_EXISTS([$3],
+ [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
+ [pkg_failed=yes])
+ else
+ pkg_failed=untried
fi[]dnl
])# _PKG_CONFIG
@@ -138,16 +138,17 @@ and $1[]_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.])
if test $pkg_failed = yes; then
+ AC_MSG_RESULT([no])
_PKG_SHORT_ERRORS_SUPPORTED
if test $_pkg_short_errors_supported = yes; then
- $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"`
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
else
- $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
- ifelse([$4], , [AC_MSG_ERROR(dnl
+ m4_default([$4], [AC_MSG_ERROR(
[Package requirements ($2) were not met:
$$1_PKG_ERRORS
@@ -155,25 +156,24 @@ $$1_PKG_ERRORS
Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.
-_PKG_TEXT
-])],
- [AC_MSG_RESULT([no])
- $4])
+_PKG_TEXT])dnl
+ ])
elif test $pkg_failed = untried; then
- ifelse([$4], , [AC_MSG_FAILURE(dnl
+ AC_MSG_RESULT([no])
+ m4_default([$4], [AC_MSG_FAILURE(
[The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
_PKG_TEXT
-To get pkg-config, see <http://pkg-config.freedesktop.org/>.])],
- [$4])
+To get pkg-config, see <http://pkg-config.freedesktop.org/>.])dnl
+ ])
else
$1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
$1[]_LIBS=$pkg_cv_[]$1[]_LIBS
AC_MSG_RESULT([yes])
- ifelse([$3], , :, [$3])
+ $3
fi[]dnl
])# PKG_CHECK_MODULES
diff --git a/config.h.in b/config.h.in
index 9a5d86d..703e2ac 100644
--- a/config.h.in
+++ b/config.h.in
@@ -27,6 +27,9 @@
/* Define to 1 if you have the <errmsg.h> header file. */
#undef HAVE_ERRMSG_H
+/* Define to 1 if you have the <ev.h> header file. */
+#undef HAVE_EV_H
+
/* Define to 1 if you have the `FAMNoExists' function. */
#undef HAVE_FAMNOEXISTS
@@ -108,6 +111,9 @@
/* libdl */
#undef HAVE_LIBDL
+/* libev support */
+#undef HAVE_LIBEV
+
/* libfam */
#undef HAVE_LIBFAM
@@ -225,9 +231,6 @@
/* Define to 1 if you have the `signal' function. */
#undef HAVE_SIGNAL
-/* Define to 1 if you have the `sigtimedwait' function. */
-#undef HAVE_SIGTIMEDWAIT
-
/* Define to 1 if you have the `socket' function. */
#undef HAVE_SOCKET
diff --git a/configure b/configure
index a84da8e..3320daa 100755
--- a/configure
+++ b/configure
@@ -1,13 +1,13 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.65 for lighttpd 1.4.26.
+# Generated by GNU Autoconf 2.67 for lighttpd 1.4.28.
#
# Report bugs to <contact@lighttpd.net>.
#
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
-# Inc.
+# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
+# Foundation, Inc.
#
#
# This configure script is free software; the Free Software Foundation
@@ -319,7 +319,7 @@ $as_echo X"$as_dir" |
test -d "$as_dir" && break
done
test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
} # as_fn_mkdir_p
@@ -359,19 +359,19 @@ else
fi # as_fn_arith
-# as_fn_error ERROR [LINENO LOG_FD]
-# ---------------------------------
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with status $?, using 1 if that was 0.
+# script with STATUS, using 1 if that was 0.
as_fn_error ()
{
- as_status=$?; test $as_status -eq 0 && as_status=1
- if test "$3"; then
- as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
+ as_status=$1; test $as_status -eq 0 && as_status=1
+ if test "$4"; then
+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
fi
- $as_echo "$as_me: error: $1" >&2
+ $as_echo "$as_me: error: $2" >&2
as_fn_exit $as_status
} # as_fn_error
@@ -682,7 +682,7 @@ test -n "$DJDIR" || exec 7<&0 </dev/null
exec 6>&1
# Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
+# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
@@ -701,8 +701,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='lighttpd'
PACKAGE_TARNAME='lighttpd'
-PACKAGE_VERSION='1.4.26'
-PACKAGE_STRING='lighttpd 1.4.26'
+PACKAGE_VERSION='1.4.28'
+PACKAGE_STRING='lighttpd 1.4.28'
PACKAGE_BUGREPORT='contact@lighttpd.net'
PACKAGE_URL=''
@@ -763,7 +763,6 @@ XML_LIBS
XML_CFLAGS
FAM_LIBS
FAM_CFLAGS
-PKG_CONFIG
BZ_LIB
Z_LIB
PCRE_LIB
@@ -776,6 +775,11 @@ LDAP_LIB
MYSQL_INCLUDE
MYSQL_LIBS
MYSQL_CONFIG
+LIBEV_LIBS
+LIBEV_CFLAGS
+PKG_CONFIG_LIBDIR
+PKG_CONFIG_PATH
+PKG_CONFIG
LIBOBJS
OTOOL64
OTOOL
@@ -903,6 +907,7 @@ enable_shared
with_pic
enable_fast_install
enable_libtool_lock
+with_libev
with_mysql
with_ldap
with_attr
@@ -934,6 +939,10 @@ LIBS
CPPFLAGS
CPP
PKG_CONFIG
+PKG_CONFIG_PATH
+PKG_CONFIG_LIBDIR
+LIBEV_CFLAGS
+LIBEV_LIBS
FAM_CFLAGS
FAM_LIBS
XML_CFLAGS
@@ -1004,8 +1013,9 @@ do
fi
case $ac_option in
- *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *) ac_optarg=yes ;;
+ *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
+ *=) ac_optarg= ;;
+ *) ac_optarg=yes ;;
esac
# Accept the important Cygnus configure options, so we can diagnose typos.
@@ -1050,7 +1060,7 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error "invalid feature name: $ac_useropt"
+ as_fn_error $? "invalid feature name: $ac_useropt"
ac_useropt_orig=$ac_useropt
ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1076,7 +1086,7 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error "invalid feature name: $ac_useropt"
+ as_fn_error $? "invalid feature name: $ac_useropt"
ac_useropt_orig=$ac_useropt
ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1280,7 +1290,7 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error "invalid package name: $ac_useropt"
+ as_fn_error $? "invalid package name: $ac_useropt"
ac_useropt_orig=$ac_useropt
ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1296,7 +1306,7 @@ do
ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error "invalid package name: $ac_useropt"
+ as_fn_error $? "invalid package name: $ac_useropt"
ac_useropt_orig=$ac_useropt
ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
case $ac_user_opts in
@@ -1326,8 +1336,8 @@ do
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
x_libraries=$ac_optarg ;;
- -*) as_fn_error "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information."
+ -*) as_fn_error $? "unrecognized option: \`$ac_option'
+Try \`$0 --help' for more information"
;;
*=*)
@@ -1335,7 +1345,7 @@ Try \`$0 --help' for more information."
# Reject names that are not valid shell variable names.
case $ac_envvar in #(
'' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error "invalid variable name: \`$ac_envvar'" ;;
+ as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
esac
eval $ac_envvar=\$ac_optarg
export $ac_envvar ;;
@@ -1353,13 +1363,13 @@ done
if test -n "$ac_prev"; then
ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error "missing argument to $ac_option"
+ as_fn_error $? "missing argument to $ac_option"
fi
if test -n "$ac_unrecognized_opts"; then
case $enable_option_checking in
no) ;;
- fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
+ fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
*) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
esac
fi
@@ -1382,7 +1392,7 @@ do
[\\/$]* | ?:[\\/]* ) continue;;
NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
esac
- as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
+ as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
done
# There might be people who depend on the old broken behavior: `$host'
@@ -1396,8 +1406,8 @@ target=$target_alias
if test "x$host_alias" != x; then
if test "x$build_alias" = x; then
cross_compiling=maybe
- $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
- If a cross compiler is detected then cross compile mode will be used." >&2
+ $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
+ If a cross compiler is detected then cross compile mode will be used" >&2
elif test "x$build_alias" != "x$host_alias"; then
cross_compiling=yes
fi
@@ -1412,9 +1422,9 @@ test "$silent" = yes && exec 6>/dev/null
ac_pwd=`pwd` && test -n "$ac_pwd" &&
ac_ls_di=`ls -di .` &&
ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error "working directory cannot be determined"
+ as_fn_error $? "working directory cannot be determined"
test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error "pwd does not report name of working directory"
+ as_fn_error $? "pwd does not report name of working directory"
# Find the source files, if location was not specified.
@@ -1453,11 +1463,11 @@ else
fi
if test ! -r "$srcdir/$ac_unique_file"; then
test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
+ as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
fi
ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
+ cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
pwd)`
# When building in place, set srcdir=.
if test "$ac_abs_confdir" = "$ac_pwd"; then
@@ -1483,7 +1493,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures lighttpd 1.4.26 to adapt to many kinds of systems.
+\`configure' configures lighttpd 1.4.28 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1497,7 +1507,7 @@ Configuration:
--help=short display options specific to this package
--help=recursive display the short help of all the included packages
-V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking...' messages
+ -q, --quiet, --silent do not print \`checking ...' messages
--cache-file=FILE cache test results in FILE [disabled]
-C, --config-cache alias for \`--cache-file=config.cache'
-n, --no-create do not create output files
@@ -1554,7 +1564,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of lighttpd 1.4.26:";;
+ short | recursive ) echo "Configuration of lighttpd 1.4.28:";;
esac
cat <<\_ACEOF
@@ -1581,6 +1591,8 @@ Optional Packages:
--with-gnu-ld assume the C compiler uses GNU ld [default=no]
--with-pic try to use only PIC/non-PIC objects [default=use
both]
+ --with-libev[=PATH] Include libev support for fdevent handlers in
+ PATH/include and PATH/lib
--with-mysql[=PATH] Include MySQL support. PATH is the path to
'mysql_config'
--with-ldap enable LDAP support
@@ -1611,6 +1623,13 @@ Some influential environment variables:
you have headers in a nonstandard directory <include dir>
CPP C preprocessor
PKG_CONFIG path to pkg-config utility
+ PKG_CONFIG_PATH
+ directories to add to pkg-config's search path
+ PKG_CONFIG_LIBDIR
+ path overriding pkg-config's built-in search path
+ LIBEV_CFLAGS
+ C compiler flags for LIBEV, overriding pkg-config
+ LIBEV_LIBS linker flags for LIBEV, overriding pkg-config
FAM_CFLAGS C compiler flags for FAM, overriding pkg-config
FAM_LIBS linker flags for FAM, overriding pkg-config
XML_CFLAGS C compiler flags for XML, overriding pkg-config
@@ -1687,10 +1706,10 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-lighttpd configure 1.4.26
-generated by GNU Autoconf 2.65
+lighttpd configure 1.4.28
+generated by GNU Autoconf 2.67
-Copyright (C) 2009 Free Software Foundation, Inc.
+Copyright (C) 2010 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
@@ -1760,7 +1779,7 @@ $as_echo "$ac_try_echo"; } >&5
mv -f conftest.er1 conftest.err
fi
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } >/dev/null && {
+ test $ac_status = 0; } > conftest.i && {
test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
test ! -s conftest.err
}; then :
@@ -1784,10 +1803,10 @@ fi
ac_fn_c_check_header_mongrel ()
{
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+ if eval "test \"\${$3+set}\"" = set; then :
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$3+set}\"" = set; then :
$as_echo_n "(cached) " >&6
fi
eval ac_res=\$$3
@@ -1823,7 +1842,7 @@ if ac_fn_c_try_cpp "$LINENO"; then :
else
ac_header_preproc=no
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }
@@ -1846,17 +1865,15 @@ $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
-( cat <<\_ASBOX
-## ----------------------------------- ##
+( $as_echo "## ----------------------------------- ##
## Report this to contact@lighttpd.net ##
-## ----------------------------------- ##
-_ASBOX
+## ----------------------------------- ##"
) | sed "s/^/$as_me: WARNING: /" >&2
;;
esac
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$3+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
eval "$3=\$ac_header_compiler"
@@ -1920,7 +1937,7 @@ ac_fn_c_check_header_compile ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$3+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -1996,7 +2013,7 @@ ac_fn_c_check_func ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$3+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2064,7 +2081,7 @@ ac_fn_c_check_type ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
$as_echo_n "checking for $2... " >&6; }
-if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$3+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
eval "$3=no"
@@ -2118,7 +2135,7 @@ ac_fn_c_check_member ()
as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
$as_echo_n "checking for $2.$3... " >&6; }
-if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${$4+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -2347,8 +2364,8 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by lighttpd $as_me 1.4.26, which was
-generated by GNU Autoconf 2.65. Invocation command line was
+It was created by lighttpd $as_me 1.4.28, which was
+generated by GNU Autoconf 2.67. Invocation command line was
$ $0 $@
@@ -2458,11 +2475,9 @@ trap 'exit_status=$?
{
echo
- cat <<\_ASBOX
-## ---------------- ##
+ $as_echo "## ---------------- ##
## Cache variables. ##
-## ---------------- ##
-_ASBOX
+## ---------------- ##"
echo
# The following way of writing the cache mishandles newlines in values,
(
@@ -2496,11 +2511,9 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
)
echo
- cat <<\_ASBOX
-## ----------------- ##
+ $as_echo "## ----------------- ##
## Output variables. ##
-## ----------------- ##
-_ASBOX
+## ----------------- ##"
echo
for ac_var in $ac_subst_vars
do
@@ -2513,11 +2526,9 @@ _ASBOX
echo
if test -n "$ac_subst_files"; then
- cat <<\_ASBOX
-## ------------------- ##
+ $as_echo "## ------------------- ##
## File substitutions. ##
-## ------------------- ##
-_ASBOX
+## ------------------- ##"
echo
for ac_var in $ac_subst_files
do
@@ -2531,11 +2542,9 @@ _ASBOX
fi
if test -s confdefs.h; then
- cat <<\_ASBOX
-## ----------- ##
+ $as_echo "## ----------- ##
## confdefs.h. ##
-## ----------- ##
-_ASBOX
+## ----------- ##"
echo
cat confdefs.h
echo
@@ -2590,7 +2599,12 @@ _ACEOF
ac_site_file1=NONE
ac_site_file2=NONE
if test -n "$CONFIG_SITE"; then
- ac_site_file1=$CONFIG_SITE
+ # We do not want a PATH search for config.site.
+ case $CONFIG_SITE in #((
+ -*) ac_site_file1=./$CONFIG_SITE;;
+ */*) ac_site_file1=$CONFIG_SITE;;
+ *) ac_site_file1=./$CONFIG_SITE;;
+ esac
elif test "x$prefix" != xNONE; then
ac_site_file1=$prefix/share/config.site
ac_site_file2=$prefix/etc/config.site
@@ -2605,7 +2619,11 @@ do
{ $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
$as_echo "$as_me: loading site script $ac_site_file" >&6;}
sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file"
+ . "$ac_site_file" \
+ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "failed to load site script $ac_site_file
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
done
@@ -2681,7 +2699,7 @@ if $ac_cache_corrupted; then
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
+ as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
fi
## -------------------- ##
## Main body of script. ##
@@ -2701,16 +2719,22 @@ ac_config_headers="$ac_config_headers config.h"
ac_aux_dir=
for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- for ac_t in install-sh install.sh shtool; do
- if test -f "$ac_dir/$ac_t"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/$ac_t -c"
- break 2
- fi
- done
+ if test -f "$ac_dir/install-sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f "$ac_dir/install.sh"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ elif test -f "$ac_dir/shtool"; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/shtool install -c"
+ break
+ fi
done
if test -z "$ac_aux_dir"; then
- as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
+ as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
fi
# These three variables are undocumented and unsupported,
@@ -2724,7 +2748,7 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
# Make sure we can run config.sub.
$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
+ as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
$as_echo_n "checking build system type... " >&6; }
@@ -2735,16 +2759,16 @@ else
test "x$ac_build_alias" = x &&
ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
test "x$ac_build_alias" = x &&
- as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
+ as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
+ as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
$as_echo "$ac_cv_build" >&6; }
case $ac_cv_build in
*-*-*) ;;
-*) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5 ;;
esac
build=$ac_cv_build
ac_save_IFS=$IFS; IFS='-'
@@ -2769,7 +2793,7 @@ else
ac_cv_host=$ac_cv_build
else
ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
+ as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
fi
fi
@@ -2777,7 +2801,7 @@ fi
$as_echo "$ac_cv_host" >&6; }
case $ac_cv_host in
*-*-*) ;;
-*) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5 ;;
esac
host=$ac_cv_host
ac_save_IFS=$IFS; IFS='-'
@@ -2802,7 +2826,7 @@ else
ac_cv_target=$ac_cv_host
else
ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
+ as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
fi
fi
@@ -2810,7 +2834,7 @@ fi
$as_echo "$ac_cv_target" >&6; }
case $ac_cv_target in
*-*-*) ;;
-*) as_fn_error "invalid value of canonical target" "$LINENO" 5;;
+*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5 ;;
esac
target=$ac_cv_target
ac_save_IFS=$IFS; IFS='-'
@@ -2939,11 +2963,11 @@ am_lf='
'
case `pwd` in
*[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
+ as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5 ;;
esac
case $srcdir in
*[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
+ as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5 ;;
esac
# Do `set' in a subshell so we don't clobber the current shell's
@@ -2965,7 +2989,7 @@ if (
# if, for instance, CONFIG_SHELL is bash and it inherits a
# broken ls alias from the environment. This has actually
# happened. Such a system could not be considered "sane".
- as_fn_error "ls -t appears to fail. Make sure there is not a broken
+ as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
alias in your environment" "$LINENO" 5
fi
@@ -2975,7 +2999,7 @@ then
# Ok.
:
else
- as_fn_error "newly created file is older than distributed files!
+ as_fn_error $? "newly created file is older than distributed files!
Check your system clock" "$LINENO" 5
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
@@ -3213,7 +3237,7 @@ done
$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
set x ${MAKE-make}
ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat >conftest.make <<\_ACEOF
@@ -3221,7 +3245,7 @@ SHELL = /bin/sh
all:
@echo '@@@%%%=$(MAKE)=@@@%%%'
_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
case `${MAKE-make} -f conftest.make 2>/dev/null` in
*@@@%%%=?*=@@@%%%*)
eval ac_cv_prog_make_${ac_make}_set=yes;;
@@ -3255,7 +3279,7 @@ if test "`cd $srcdir && pwd`" != "`pwd`"; then
am__isrc=' -I$(srcdir)'
# test to see if srcdir already configured
if test -f $srcdir/config.status; then
- as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
+ as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
fi
fi
@@ -3271,7 +3295,7 @@ fi
# Define the identity of the package.
PACKAGE='lighttpd'
- VERSION='1.4.26'
+ VERSION='1.4.28'
cat >>confdefs.h <<_ACEOF
@@ -3706,8 +3730,8 @@ fi
test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "no acceptable C compiler found in \$PATH
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "no acceptable C compiler found in \$PATH
+See \`config.log' for more details" "$LINENO" 5 ; }
# Provide some information about the compiler.
$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
@@ -3821,9 +3845,8 @@ sed 's/^/| /' conftest.$ac_ext >&5
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "C compiler cannot create executables
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "C compiler cannot create executables
+See \`config.log' for more details" "$LINENO" 5 ; }
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
$as_echo "yes" >&6; }
@@ -3865,8 +3888,8 @@ done
else
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot compute suffix of executables: cannot compile and link
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
rm -f conftest conftest$ac_cv_exeext
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
@@ -3923,9 +3946,9 @@ $as_echo "$ac_try_echo"; } >&5
else
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot run C compiled programs.
+as_fn_error $? "cannot run C compiled programs.
If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
fi
fi
@@ -3976,8 +3999,8 @@ sed 's/^/| /' conftest.$ac_ext >&5
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot compute suffix of object files: cannot compile
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
@@ -4395,7 +4418,7 @@ $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
fi
set dummy $CC; ac_cc=`$as_echo "$2" |
sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
-if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${ac_cv_prog_cc_${ac_cc}_c_o+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
@@ -4569,7 +4592,7 @@ esac
done
IFS=$as_save_IFS
if test -z "$ac_cv_path_SED"; then
- as_fn_error "no acceptable sed could be found in \$PATH" "$LINENO" 5
+ as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
fi
else
ac_cv_path_SED=$SED
@@ -4645,7 +4668,7 @@ esac
done
IFS=$as_save_IFS
if test -z "$ac_cv_path_GREP"; then
- as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
fi
else
ac_cv_path_GREP=$GREP
@@ -4711,7 +4734,7 @@ esac
done
IFS=$as_save_IFS
if test -z "$ac_cv_path_EGREP"; then
- as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
fi
else
ac_cv_path_EGREP=$EGREP
@@ -4778,7 +4801,7 @@ esac
done
IFS=$as_save_IFS
if test -z "$ac_cv_path_FGREP"; then
- as_fn_error "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
+ as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
fi
else
ac_cv_path_FGREP=$FGREP
@@ -4894,7 +4917,7 @@ else
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
$as_echo "no" >&6; }
fi
-test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5
+test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
if test "${lt_cv_prog_gnu_ld+set}" = set; then :
@@ -5007,7 +5030,7 @@ else
# Broken: fails on valid input.
continue
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
# OK, works on sane cases. Now check whether nonexistent headers
# can be detected and how.
@@ -5023,11 +5046,11 @@ else
ac_preproc_ok=:
break
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.i conftest.err conftest.$ac_ext
if $ac_preproc_ok; then :
break
fi
@@ -5066,7 +5089,7 @@ else
# Broken: fails on valid input.
continue
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
# OK, works on sane cases. Now check whether nonexistent headers
# can be detected and how.
@@ -5082,18 +5105,18 @@ else
ac_preproc_ok=:
break
fi
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.err conftest.i conftest.$ac_ext
done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.err conftest.$ac_ext
+rm -f conftest.i conftest.err conftest.$ac_ext
if $ac_preproc_ok; then :
else
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
+See \`config.log' for more details" "$LINENO" 5 ; }
fi
ac_ext=c
@@ -5117,7 +5140,7 @@ fi
$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
set x ${MAKE-make}
ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
+if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\"" = set; then :
$as_echo_n "(cached) " >&6
else
cat >conftest.make <<\_ACEOF
@@ -5125,7 +5148,7 @@ SHELL = /bin/sh
all:
@echo '@@@%%%=$(MAKE)=@@@%%%'
_ACEOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
+# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
case `${MAKE-make} -f conftest.make 2>/dev/null` in
*@@@%%%=?*=@@@%%%*)
eval ac_cv_prog_make_${ac_make}_set=yes;;
@@ -5266,8 +5289,7 @@ do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
"
-eval as_val=\$$as_ac_Header
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
@@ -5716,13 +5738,13 @@ if test "${lt_cv_nm_interface+set}" = set; then :
else
lt_cv_nm_interface="BSD nm"
echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:5719: $ac_compile\"" >&5)
+ (eval echo "\"\$as_me:5741: $ac_compile\"" >&5)
(eval "$ac_compile" 2>conftest.err)
cat conftest.err >&5
- (eval echo "\"\$as_me:5722: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
+ (eval echo "\"\$as_me:5744: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
cat conftest.err >&5
- (eval echo "\"\$as_me:5725: output\"" >&5)
+ (eval echo "\"\$as_me:5747: output\"" >&5)
cat conftest.out >&5
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
lt_cv_nm_interface="MS dumpbin"
@@ -6916,7 +6938,7 @@ ia64-*-hpux*)
;;
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 6919 "configure"' > conftest.$ac_ext
+ echo '#line 6941 "configure"' > conftest.$ac_ext
if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
(eval $ac_compile) 2>&5
ac_status=$?
@@ -8116,11 +8138,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8119: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8141: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:8123: \$? = $ac_status" >&5
+ echo "$as_me:8145: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -8455,11 +8477,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8458: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8480: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:8462: \$? = $ac_status" >&5
+ echo "$as_me:8484: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
@@ -8560,11 +8582,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8563: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8585: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:8567: \$? = $ac_status" >&5
+ echo "$as_me:8589: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -8615,11 +8637,11 @@ else
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:8618: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:8640: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:8622: \$? = $ac_status" >&5
+ echo "$as_me:8644: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
@@ -10999,7 +11021,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11002 "configure"
+#line 11024 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11095,7 +11117,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11098 "configure"
+#line 11120 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
@@ -11486,8 +11508,7 @@ sys/resource.h sys/un.h syslog.h sys/prctl.h uuid/uuid.h
do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-eval as_val=\$$as_ac_Header
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
@@ -11733,8 +11754,7 @@ for ac_func in fork vfork
do :
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-eval as_val=\$$as_ac_var
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF
@@ -12131,8 +12151,7 @@ for ac_func in issetugid inet_pton
do :
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-eval as_val=\$$as_ac_var
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF
@@ -12141,6 +12160,406 @@ fi
done
+if test -z "$PKG_CONFIG"; then
+ # Extract the first word of "pkg-config", so it can be a program name with args.
+set dummy pkg-config; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $PKG_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
+ ;;
+esac
+fi
+PKG_CONFIG=$ac_cv_path_PKG_CONFIG
+if test -n "$PKG_CONFIG"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
+$as_echo "$PKG_CONFIG" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libev support" >&5
+$as_echo_n "checking for libev support... " >&6; }
+
+# Check whether --with-libev was given.
+if test "${with_libev+set}" = set; then :
+ withval=$with_libev; WITH_LIBEV=$withval
+else
+ WITH_LIBEV=no
+fi
+
+
+LIBEV_CFLAGS=""
+LIBEV_LIBS=""
+
+if test "$WITH_LIBEV" != "no"; then
+
+
+
+
+
+
+if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
+set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $PKG_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ ;;
+esac
+fi
+PKG_CONFIG=$ac_cv_path_PKG_CONFIG
+if test -n "$PKG_CONFIG"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
+$as_echo "$PKG_CONFIG" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_path_PKG_CONFIG"; then
+ ac_pt_PKG_CONFIG=$PKG_CONFIG
+ # Extract the first word of "pkg-config", so it can be a program name with args.
+set dummy pkg-config; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ case $ac_pt_PKG_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+ ;;
+esac
+fi
+ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
+if test -n "$ac_pt_PKG_CONFIG"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
+$as_echo "$ac_pt_PKG_CONFIG" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+ if test "x$ac_pt_PKG_CONFIG" = x; then
+ PKG_CONFIG=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+ PKG_CONFIG=$ac_pt_PKG_CONFIG
+ fi
+else
+ PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
+fi
+
+fi
+if test -n "$PKG_CONFIG"; then
+ _pkg_min_version=0.9.0
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
+$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
+ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+ else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+ PKG_CONFIG=""
+ fi
+fi
+
+pkg_failed=no
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBEV" >&5
+$as_echo_n "checking for LIBEV... " >&6; }
+
+if test -n "$LIBEV_CFLAGS"; then
+ pkg_cv_LIBEV_CFLAGS="$LIBEV_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libev\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "libev") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBEV_CFLAGS=`$PKG_CONFIG --cflags "libev" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$LIBEV_LIBS"; then
+ pkg_cv_LIBEV_LIBS="$LIBEV_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libev\""; } >&5
+ ($PKG_CONFIG --exists --print-errors "libev") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+ test $ac_status = 0; }; then
+ pkg_cv_LIBEV_LIBS=`$PKG_CONFIG --libs "libev" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ LIBEV_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libev" 2>&1`
+ else
+ LIBEV_PKG_ERRORS=`$PKG_CONFIG --print-errors "libev" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$LIBEV_PKG_ERRORS" >&5
+
+
+
+ if test "$WITH_LIBEV" != "yes"; then
+ LIBEV_CFLAGS="-I$WITH_LIBEV/include"
+ LIBEV_LIBS="-L$WITH_LIBEV/lib -lev"
+ else
+ for ac_header in ev.h
+do :
+ ac_fn_c_check_header_mongrel "$LINENO" "ev.h" "ac_cv_header_ev_h" "$ac_includes_default"
+if test "x$ac_cv_header_ev_h" = x""yes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_EV_H 1
+_ACEOF
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ev_loop in -lev" >&5
+$as_echo_n "checking for ev_loop in -lev... " >&6; }
+if test "${ac_cv_lib_ev_ev_loop+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lev $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char ev_loop ();
+int
+main ()
+{
+return ev_loop ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_lib_ev_ev_loop=yes
+else
+ ac_cv_lib_ev_ev_loop=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ev_ev_loop" >&5
+$as_echo "$ac_cv_lib_ev_ev_loop" >&6; }
+if test "x$ac_cv_lib_ev_ev_loop" = x""yes; then :
+
+ LIBEV_CFLAGS=""
+ LIBEV_LIBS="-lev"
+
+else
+
+ as_fn_error $? "libev not found" "$LINENO" 5
+
+
+fi
+
+else
+
+ as_fn_error $? "libev not found" "$LINENO" 5
+
+
+fi
+
+done
+
+ fi
+
+elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+
+
+ if test "$WITH_LIBEV" != "yes"; then
+ LIBEV_CFLAGS="-I$WITH_LIBEV/include"
+ LIBEV_LIBS="-L$WITH_LIBEV/lib -lev"
+ else
+ for ac_header in ev.h
+do :
+ ac_fn_c_check_header_mongrel "$LINENO" "ev.h" "ac_cv_header_ev_h" "$ac_includes_default"
+if test "x$ac_cv_header_ev_h" = x""yes; then :
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_EV_H 1
+_ACEOF
+
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ev_loop in -lev" >&5
+$as_echo_n "checking for ev_loop in -lev... " >&6; }
+if test "${ac_cv_lib_ev_ev_loop+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lev $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char ev_loop ();
+int
+main ()
+{
+return ev_loop ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_lib_ev_ev_loop=yes
+else
+ ac_cv_lib_ev_ev_loop=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ev_ev_loop" >&5
+$as_echo "$ac_cv_lib_ev_ev_loop" >&6; }
+if test "x$ac_cv_lib_ev_ev_loop" = x""yes; then :
+
+ LIBEV_CFLAGS=""
+ LIBEV_LIBS="-lev"
+
+else
+
+ as_fn_error $? "libev not found" "$LINENO" 5
+
+
+fi
+
+else
+
+ as_fn_error $? "libev not found" "$LINENO" 5
+
+
+fi
+
+done
+
+ fi
+
+else
+ LIBEV_CFLAGS=$pkg_cv_LIBEV_CFLAGS
+ LIBEV_LIBS=$pkg_cv_LIBEV_LIBS
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+
+fi
+
+
+$as_echo "#define HAVE_LIBEV 1" >>confdefs.h
+
+fi
+
+
+
+
MYSQL_INCLUDE=""
MYSQL_LIBS=""
@@ -12204,11 +12623,10 @@ fi
fi
if test "$MYSQL_CONFIG" = ""; then
- as_fn_error "mysql_config is not found" "$LINENO" 5
+ as_fn_error $? "mysql_config is not found" "$LINENO" 5
fi
if test \! -x $MYSQL_CONFIG; then
- { as_fn_set_status use --with-mysql=path-to-mysql_config
-as_fn_error "mysql_config not exists or not executable" "$LINENO" 5; }
+ as_fn_error use --with-mysql=path-to-mysql_config "mysql_config not exists or not executable" "$LINENO" 5
fi
if $MYSQL_CONFIG | grep -- '--include' > /dev/null ; then
@@ -12233,8 +12651,7 @@ $as_echo "$MYSQL_LIBS" >&6; }
do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-eval as_val=\$$as_ac_Header
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
@@ -12971,7 +13388,7 @@ $as_echo "#define HAVE_LIBPCRE 1" >>confdefs.h
$as_echo "#define HAVE_PCRE_H 1" >>confdefs.h
else
- as_fn_error "pcre-config not found, install the pcre-devel package or build with --without-pcre" "$LINENO" 5
+ as_fn_error $? "pcre-config not found, install the pcre-devel package or build with --without-pcre" "$LINENO" 5
fi
fi
@@ -13052,7 +13469,7 @@ done
fi
if test x$Z_LIB = x; then
- as_fn_error "zlib-headers and/or libs where not found, install them or build with --without-zlib" "$LINENO" 5
+ as_fn_error $? "zlib-headers and/or libs where not found, install them or build with --without-zlib" "$LINENO" 5
fi
fi
@@ -13132,55 +13549,11 @@ done
fi
if test x$BZ_LIB = x; then
- as_fn_error "bzip2-headers and/or libs where not found, install them or build with --without-bzip2" "$LINENO" 5
- fi
-fi
-
-
-if test -z "$PKG_CONFIG"; then
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
+ as_fn_error $? "bzip2-headers and/or libs where not found, install them or build with --without-bzip2" "$LINENO" 5
fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
fi
-fi
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FAM" >&5
$as_echo_n "checking for FAM... " >&6; }
@@ -13258,131 +13631,14 @@ fi
if test "x$FAM_LIBS" = x; then
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-
-fi
-
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for FAM" >&5
$as_echo_n "checking for FAM... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$FAM_CFLAGS"; then
- pkg_cv_FAM_CFLAGS="$FAM_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$FAM_CFLAGS"; then
+ pkg_cv_FAM_CFLAGS="$FAM_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gamin >= 0.1.0\""; } >&5
($PKG_CONFIG --exists --print-errors "gamin >= 0.1.0") 2>&5
ac_status=$?
@@ -13392,15 +13648,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$FAM_LIBS"; then
- pkg_cv_FAM_LIBS="$FAM_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$FAM_LIBS"; then
+ pkg_cv_FAM_LIBS="$FAM_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gamin >= 0.1.0\""; } >&5
($PKG_CONFIG --exists --print-errors "gamin >= 0.1.0") 2>&5
ac_status=$?
@@ -13410,14 +13664,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -13425,14 +13680,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- FAM_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "gamin >= 0.1.0"`
+ FAM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "gamin >= 0.1.0" 2>&1`
else
- FAM_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gamin >= 0.1.0"`
+ FAM_PKG_ERRORS=`$PKG_CONFIG --print-errors "gamin >= 0.1.0" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$FAM_PKG_ERRORS" >&5
- as_fn_error "Package requirements (gamin >= 0.1.0) were not met:
+ as_fn_error $? "Package requirements (gamin >= 0.1.0) were not met:
$FAM_PKG_ERRORS
@@ -13441,12 +13696,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables FAM_CFLAGS
and FAM_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -13455,7 +13711,7 @@ and FAM_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
FAM_CFLAGS=$pkg_cv_FAM_CFLAGS
FAM_LIBS=$pkg_cv_FAM_LIBS
@@ -13487,7 +13743,7 @@ done
LIBS=$OLD_LIBS
if test x$FAM_LIBS = x; then
- as_fn_error "fam/gamin-headers and/or libs where not found, install them or build with --without-fam" "$LINENO" 5
+ as_fn_error $? "fam/gamin-headers and/or libs where not found, install them or build with --without-fam" "$LINENO" 5
fi
fi
@@ -13510,11 +13766,10 @@ pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML" >&5
$as_echo_n "checking for XML... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$XML_CFLAGS"; then
- pkg_cv_XML_CFLAGS="$XML_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$XML_CFLAGS"; then
+ pkg_cv_XML_CFLAGS="$XML_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0\""; } >&5
($PKG_CONFIG --exists --print-errors "libxml-2.0") 2>&5
ac_status=$?
@@ -13524,15 +13779,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$XML_LIBS"; then
- pkg_cv_XML_LIBS="$XML_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$XML_LIBS"; then
+ pkg_cv_XML_LIBS="$XML_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0\""; } >&5
($PKG_CONFIG --exists --print-errors "libxml-2.0") 2>&5
ac_status=$?
@@ -13542,14 +13795,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -13557,14 +13811,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- XML_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "libxml-2.0"`
+ XML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libxml-2.0" 2>&1`
else
- XML_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0"`
+ XML_PKG_ERRORS=`$PKG_CONFIG --print-errors "libxml-2.0" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$XML_PKG_ERRORS" >&5
- as_fn_error "Package requirements (libxml-2.0) were not met:
+ as_fn_error $? "Package requirements (libxml-2.0) were not met:
$XML_PKG_ERRORS
@@ -13573,12 +13827,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables XML_CFLAGS
and XML_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -13587,7 +13842,7 @@ and XML_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
XML_CFLAGS=$pkg_cv_XML_CFLAGS
XML_LIBS=$pkg_cv_XML_LIBS
@@ -13607,11 +13862,10 @@ pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for SQLITE" >&5
$as_echo_n "checking for SQLITE... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$SQLITE_CFLAGS"; then
- pkg_cv_SQLITE_CFLAGS="$SQLITE_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$SQLITE_CFLAGS"; then
+ pkg_cv_SQLITE_CFLAGS="$SQLITE_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3\""; } >&5
($PKG_CONFIG --exists --print-errors "sqlite3") 2>&5
ac_status=$?
@@ -13621,15 +13875,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$SQLITE_LIBS"; then
- pkg_cv_SQLITE_LIBS="$SQLITE_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$SQLITE_LIBS"; then
+ pkg_cv_SQLITE_LIBS="$SQLITE_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"sqlite3\""; } >&5
($PKG_CONFIG --exists --print-errors "sqlite3") 2>&5
ac_status=$?
@@ -13639,14 +13891,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -13654,14 +13907,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- SQLITE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "sqlite3"`
+ SQLITE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "sqlite3" 2>&1`
else
- SQLITE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "sqlite3"`
+ SQLITE_PKG_ERRORS=`$PKG_CONFIG --print-errors "sqlite3" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$SQLITE_PKG_ERRORS" >&5
- as_fn_error "Package requirements (sqlite3) were not met:
+ as_fn_error $? "Package requirements (sqlite3) were not met:
$SQLITE_PKG_ERRORS
@@ -13670,12 +13923,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables SQLITE_CFLAGS
and SQLITE_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -13684,7 +13938,7 @@ and SQLITE_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
SQLITE_CFLAGS=$pkg_cv_SQLITE_CFLAGS
SQLITE_LIBS=$pkg_cv_SQLITE_LIBS
@@ -13956,11 +14210,10 @@ pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\$WITH_LUA >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "$WITH_LUA >= 5.1") 2>&5
ac_status=$?
@@ -13970,15 +14223,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\$WITH_LUA >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "$WITH_LUA >= 5.1") 2>&5
ac_status=$?
@@ -13988,14 +14239,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14003,26 +14255,23 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$WITH_LUA >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$WITH_LUA >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$WITH_LUA >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "$WITH_LUA >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14032,15 +14281,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14050,14 +14297,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14065,26 +14313,23 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14094,15 +14339,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14112,14 +14355,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14127,14 +14371,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua-5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua-5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- as_fn_error "Package requirements (lua-5.1 >= 5.1) were not met:
+ as_fn_error $? "Package requirements (lua-5.1 >= 5.1) were not met:
$LUA_PKG_ERRORS
@@ -14143,12 +14387,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables LUA_CFLAGS
and LUA_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -14157,7 +14402,7 @@ and LUA_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
LUA_CFLAGS=$pkg_cv_LUA_CFLAGS
LUA_LIBS=$pkg_cv_LUA_LIBS
@@ -14174,17 +14419,18 @@ $as_echo "#define HAVE_LUA_H 1" >>confdefs.h
fi
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14194,15 +14440,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14212,14 +14456,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14227,14 +14472,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua-5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua-5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- as_fn_error "Package requirements (lua-5.1 >= 5.1) were not met:
+ as_fn_error $? "Package requirements (lua-5.1 >= 5.1) were not met:
$LUA_PKG_ERRORS
@@ -14243,12 +14488,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables LUA_CFLAGS
and LUA_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -14257,7 +14503,7 @@ and LUA_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
LUA_CFLAGS=$pkg_cv_LUA_CFLAGS
LUA_LIBS=$pkg_cv_LUA_LIBS
@@ -14289,17 +14535,18 @@ $as_echo "#define HAVE_LUA_H 1" >>confdefs.h
fi
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14309,15 +14556,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14327,14 +14572,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14342,26 +14588,23 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14371,15 +14614,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14389,14 +14630,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14404,14 +14646,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua-5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua-5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- as_fn_error "Package requirements (lua-5.1 >= 5.1) were not met:
+ as_fn_error $? "Package requirements (lua-5.1 >= 5.1) were not met:
$LUA_PKG_ERRORS
@@ -14420,12 +14662,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables LUA_CFLAGS
and LUA_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -14434,7 +14677,7 @@ and LUA_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
LUA_CFLAGS=$pkg_cv_LUA_CFLAGS
LUA_LIBS=$pkg_cv_LUA_LIBS
@@ -14451,17 +14694,18 @@ $as_echo "#define HAVE_LUA_H 1" >>confdefs.h
fi
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
pkg_failed=no
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for LUA" >&5
$as_echo_n "checking for LUA... " >&6; }
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_CFLAGS"; then
- pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_CFLAGS"; then
+ pkg_cv_LUA_CFLAGS="$LUA_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14471,15 +14715,13 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
-if test -n "$PKG_CONFIG"; then
- if test -n "$LUA_LIBS"; then
- pkg_cv_LUA_LIBS="$LUA_LIBS"
- else
- if test -n "$PKG_CONFIG" && \
+if test -n "$LUA_LIBS"; then
+ pkg_cv_LUA_LIBS="$LUA_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lua-5.1 >= 5.1\""; } >&5
($PKG_CONFIG --exists --print-errors "lua-5.1 >= 5.1") 2>&5
ac_status=$?
@@ -14489,14 +14731,15 @@ if test -n "$PKG_CONFIG"; then
else
pkg_failed=yes
fi
- fi
-else
- pkg_failed=untried
+ else
+ pkg_failed=untried
fi
if test $pkg_failed = yes; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
_pkg_short_errors_supported=yes
@@ -14504,14 +14747,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lua-5.1 >= 5.1" 2>&1`
else
- LUA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "lua-5.1 >= 5.1"`
+ LUA_PKG_ERRORS=`$PKG_CONFIG --print-errors "lua-5.1 >= 5.1" 2>&1`
fi
# Put the nasty error message in config.log where it belongs
echo "$LUA_PKG_ERRORS" >&5
- as_fn_error "Package requirements (lua-5.1 >= 5.1) were not met:
+ as_fn_error $? "Package requirements (lua-5.1 >= 5.1) were not met:
$LUA_PKG_ERRORS
@@ -14520,12 +14763,13 @@ installed software in a non-standard prefix.
Alternatively, you may set the environment variables LUA_CFLAGS
and LUA_LIBS to avoid the need to call pkg-config.
-See the pkg-config man page for more details.
-" "$LINENO" 5
+See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "The pkg-config script could not be found or is too old. Make sure it
+as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -14534,7 +14778,7 @@ and LUA_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
-See \`config.log' for more details." "$LINENO" 5; }
+See \`config.log' for more details" "$LINENO" 5 ; }
else
LUA_CFLAGS=$pkg_cv_LUA_CFLAGS
LUA_LIBS=$pkg_cv_LUA_LIBS
@@ -14741,14 +14985,13 @@ esac
for ac_func in dup2 getcwd inet_ntoa inet_ntop memset mmap munmap strchr \
strdup strerror strstr strtol sendfile getopt socket lstat \
- gethostbyname poll sigtimedwait epoll_ctl getrlimit chroot \
+ gethostbyname poll epoll_ctl getrlimit chroot \
getuid select signal pathconf madvise posix_fadvise posix_madvise \
writev sigaction sendfile64 send_file kqueue port_create localtime_r gmtime_r
do :
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-eval as_val=\$$as_ac_var
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF
@@ -14764,7 +15007,7 @@ if test "${enable_lfs+set}" = set; then :
enableval=$enable_lfs; case "${enableval}" in
yes) CPPFLAGS="${CPPFLAGS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES" ;;
no) ;;
- *) as_fn_error "bad value ${enableval} for --enable-lfs" "$LINENO" 5 ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-lfs" "$LINENO" 5 ;;
esac
else
CPPFLAGS="${CPPFLAGS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGE_FILES"
@@ -14789,9 +15032,8 @@ else
if test "$ac_cv_type_long" = yes; then
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (long)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (long)
+See \`config.log' for more details" "$LINENO" 5 ; }
else
ac_cv_sizeof_long=0
fi
@@ -14823,9 +15065,8 @@ else
if test "$ac_cv_type_off_t" = yes; then
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-{ as_fn_set_status 77
-as_fn_error "cannot compute sizeof (off_t)
-See \`config.log' for more details." "$LINENO" 5; }; }
+as_fn_error 77 "cannot compute sizeof (off_t)
+See \`config.log' for more details" "$LINENO" 5 ; }
else
ac_cv_sizeof_off_t=0
fi
@@ -14850,8 +15091,8 @@ $as_echo_n "checking if sendfile works... " >&6; }
if test "$cross_compiling" = yes; then :
{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error "cannot run test program while cross compiling
-See \`config.log' for more details." "$LINENO" 5; }
+as_fn_error $? "cannot run test program while cross compiling
+See \`config.log' for more details" "$LINENO" 5 ; }
else
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -14895,7 +15136,7 @@ if test "${enable_ipv6+set}" = set; then :
enableval=$enable_ipv6; case "${enableval}" in
yes) ipv6=true ;;
no) ipv6=false ;;
- *) as_fn_error "bad value ${enableval} for --enable-ipv6" "$LINENO" 5 ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-ipv6" "$LINENO" 5 ;;
esac
else
ipv6=true
@@ -14992,8 +15233,7 @@ if test "x$ac_cv_lib_fcgi_FCGI_Accept" = x""yes; then :
do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-eval as_val=\$$as_ac_Header
- if test "x$as_val" = x""yes; then :
+if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
@@ -15027,7 +15267,7 @@ if test "${enable_extra_warnings+set}" = set; then :
enableval=$enable_extra_warnings; case "${enableval}" in
yes) extrawarnings=true ;;
no) extrawarnings=false ;;
- *) as_fn_error "bad value ${enableval} for --enable-extra-warnings" "$LINENO" 5 ;;
+ *) as_fn_error $? "bad value ${enableval} for --enable-extra-warnings" "$LINENO" 5 ;;
esac
else
extrawarnings=false
@@ -15045,7 +15285,7 @@ cat >>confdefs.h <<_ACEOF
_ACEOF
-ac_config_files="$ac_config_files Makefile src/Makefile doc/Makefile tests/Makefile tests/docroot/Makefile tests/docroot/123/Makefile tests/docroot/www/Makefile tests/docroot/www/go/Makefile tests/docroot/www/indexfile/Makefile tests/docroot/www/expire/Makefile distribute.sh"
+ac_config_files="$ac_config_files Makefile src/Makefile doc/config/conf.d/Makefile doc/config/vhosts.d/Makefile doc/config/Makefile doc/scripts/Makefile doc/initscripts/Makefile doc/Makefile tests/Makefile tests/docroot/Makefile tests/docroot/123/Makefile tests/docroot/www/Makefile tests/docroot/www/go/Makefile tests/docroot/www/indexfile/Makefile tests/docroot/www/expire/Makefile distribute.sh"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@@ -15153,23 +15393,23 @@ else
fi
if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error "conditional \"AMDEP\" was never defined.
+ as_fn_error $? "conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error "conditional \"am__fastdepCC\" was never defined.
+ as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
if test -z "${NO_RDYNAMIC_TRUE}" && test -z "${NO_RDYNAMIC_FALSE}"; then
- as_fn_error "conditional \"NO_RDYNAMIC\" was never defined.
+ as_fn_error $? "conditional \"NO_RDYNAMIC\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
if test -z "${CROSS_COMPILING_TRUE}" && test -z "${CROSS_COMPILING_FALSE}"; then
- as_fn_error "conditional \"CROSS_COMPILING\" was never defined.
+ as_fn_error $? "conditional \"CROSS_COMPILING\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
if test -z "${CHECK_WITH_FASTCGI_TRUE}" && test -z "${CHECK_WITH_FASTCGI_FALSE}"; then
- as_fn_error "conditional \"CHECK_WITH_FASTCGI\" was never defined.
+ as_fn_error $? "conditional \"CHECK_WITH_FASTCGI\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
@@ -15319,19 +15559,19 @@ export LANGUAGE
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-# as_fn_error ERROR [LINENO LOG_FD]
-# ---------------------------------
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with status $?, using 1 if that was 0.
+# script with STATUS, using 1 if that was 0.
as_fn_error ()
{
- as_status=$?; test $as_status -eq 0 && as_status=1
- if test "$3"; then
- as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
+ as_status=$1; test $as_status -eq 0 && as_status=1
+ if test "$4"; then
+ as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+ $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
fi
- $as_echo "$as_me: error: $1" >&2
+ $as_echo "$as_me: error: $2" >&2
as_fn_exit $as_status
} # as_fn_error
@@ -15527,7 +15767,7 @@ $as_echo X"$as_dir" |
test -d "$as_dir" && break
done
test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
+ } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
} # as_fn_mkdir_p
@@ -15580,8 +15820,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by lighttpd $as_me 1.4.26, which was
-generated by GNU Autoconf 2.65. Invocation command line was
+This file was extended by lighttpd $as_me 1.4.28, which was
+generated by GNU Autoconf 2.67. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -15646,11 +15886,11 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-lighttpd config.status 1.4.26
-configured by $0, generated by GNU Autoconf 2.65,
+lighttpd config.status 1.4.28
+configured by $0, generated by GNU Autoconf 2.67,
with options \\"\$ac_cs_config\\"
-Copyright (C) 2009 Free Software Foundation, Inc.
+Copyright (C) 2010 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
@@ -15668,11 +15908,16 @@ ac_need_defaults=:
while test $# != 0
do
case $1 in
- --*=*)
+ --*=?*)
ac_option=`expr "X$1" : 'X\([^=]*\)='`
ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
ac_shift=:
;;
+ --*=)
+ ac_option=`expr "X$1" : 'X\([^=]*\)='`
+ ac_optarg=
+ ac_shift=:
+ ;;
*)
ac_option=$1
ac_optarg=$2
@@ -15694,6 +15939,7 @@ do
$ac_shift
case $ac_optarg in
*\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ '') as_fn_error $? "missing file argument" ;;
esac
as_fn_append CONFIG_FILES " '$ac_optarg'"
ac_need_defaults=false;;
@@ -15706,7 +15952,7 @@ do
ac_need_defaults=false;;
--he | --h)
# Conflict between --help and --header
- as_fn_error "ambiguous option: \`$1'
+ as_fn_error $? "ambiguous option: \`$1'
Try \`$0 --help' for more information.";;
--help | --hel | -h )
$as_echo "$ac_cs_usage"; exit ;;
@@ -15715,7 +15961,7 @@ Try \`$0 --help' for more information.";;
ac_cs_silent=: ;;
# This is an error.
- -*) as_fn_error "unrecognized option: \`$1'
+ -*) as_fn_error $? "unrecognized option: \`$1'
Try \`$0 --help' for more information." ;;
*) as_fn_append ac_config_targets " $1"
@@ -16029,6 +16275,11 @@ do
"libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
"src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
+ "doc/config/conf.d/Makefile") CONFIG_FILES="$CONFIG_FILES doc/config/conf.d/Makefile" ;;
+ "doc/config/vhosts.d/Makefile") CONFIG_FILES="$CONFIG_FILES doc/config/vhosts.d/Makefile" ;;
+ "doc/config/Makefile") CONFIG_FILES="$CONFIG_FILES doc/config/Makefile" ;;
+ "doc/scripts/Makefile") CONFIG_FILES="$CONFIG_FILES doc/scripts/Makefile" ;;
+ "doc/initscripts/Makefile") CONFIG_FILES="$CONFIG_FILES doc/initscripts/Makefile" ;;
"doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
"tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
"tests/docroot/Makefile") CONFIG_FILES="$CONFIG_FILES tests/docroot/Makefile" ;;
@@ -16039,7 +16290,7 @@ do
"tests/docroot/www/expire/Makefile") CONFIG_FILES="$CONFIG_FILES tests/docroot/www/expire/Makefile" ;;
"distribute.sh") CONFIG_FILES="$CONFIG_FILES distribute.sh" ;;
- *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
+ *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;;
esac
done
@@ -16077,7 +16328,7 @@ $debug ||
{
tmp=./conf$$-$RANDOM
(umask 077 && mkdir "$tmp")
-} || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
# Set up the scripts for CONFIG_FILES section.
# No need to generate them if there are no CONFIG_FILES.
@@ -16094,7 +16345,7 @@ if test "x$ac_cr" = x; then
fi
ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\r'
+ ac_cs_awk_cr='\\r'
else
ac_cs_awk_cr=$ac_cr
fi
@@ -16108,18 +16359,18 @@ _ACEOF
echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
echo "_ACEOF"
} >conf$$subs.sh ||
- as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
+ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
ac_delim='%!_!# '
for ac_last_try in false false false false false :; do
. ./conf$$subs.sh ||
- as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
if test $ac_delim_n = $ac_delim_num; then
break
elif $ac_last_try; then
- as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
+ as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
else
ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
fi
@@ -16208,20 +16459,28 @@ if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
else
cat
fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
- || as_fn_error "could not setup config files machinery" "$LINENO" 5
+ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
_ACEOF
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
+# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
+# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
# trailing colons and then remove the whole line if VPATH becomes empty
# (actually we leave an empty line to preserve line numbers).
if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=/{
-s/:*\$(srcdir):*/:/
-s/:*\${srcdir}:*/:/
-s/:*@srcdir@:*/:/
-s/^\([^=]*=[ ]*\):*/\1/
+ ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
+h
+s///
+s/^/:/
+s/[ ]*$/:/
+s/:\$(srcdir):/:/g
+s/:\${srcdir}:/:/g
+s/:@srcdir@:/:/g
+s/^:*//
s/:*$//
+x
+s/\(=[ ]*\).*/\1/
+G
+s/\n//
s/^[^=]*=[ ]*$//
}'
fi
@@ -16249,7 +16508,7 @@ for ac_last_try in false false :; do
if test -z "$ac_t"; then
break
elif $ac_last_try; then
- as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
+ as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
else
ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
fi
@@ -16334,7 +16593,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
_ACAWK
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error "could not setup config headers machinery" "$LINENO" 5
+ as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
fi # test -n "$CONFIG_HEADERS"
@@ -16347,7 +16606,7 @@ do
esac
case $ac_mode$ac_tag in
:[FHL]*:*);;
- :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
+ :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;;
:[FH]-) ac_tag=-:-;;
:[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
esac
@@ -16375,7 +16634,7 @@ do
[\\/$]*) false;;
*) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
esac ||
- as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
+ as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;;
esac
case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
as_fn_append ac_file_inputs " '$ac_f'"
@@ -16402,7 +16661,7 @@ $as_echo "$as_me: creating $ac_file" >&6;}
case $ac_tag in
*:-:* | *:-) cat >"$tmp/stdin" \
- || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
esac
;;
esac
@@ -16539,22 +16798,22 @@ s&@MKDIR_P@&$ac_MKDIR_P&;t t
$ac_datarootdir_hack
"
eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
- || as_fn_error "could not create $ac_file" "$LINENO" 5
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
{ ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
{ ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined." >&5
+which seems to be undefined. Please make sure it is defined" >&5
$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined." >&2;}
+which seems to be undefined. Please make sure it is defined" >&2;}
rm -f "$tmp/stdin"
case $ac_file in
-) cat "$tmp/out" && rm -f "$tmp/out";;
*) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
esac \
- || as_fn_error "could not create $ac_file" "$LINENO" 5
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5
;;
:H)
#
@@ -16565,19 +16824,19 @@ which seems to be undefined. Please make sure it is defined." >&2;}
$as_echo "/* $configure_input */" \
&& eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
} >"$tmp/config.h" \
- || as_fn_error "could not create $ac_file" "$LINENO" 5
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5
if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
$as_echo "$as_me: $ac_file is unchanged" >&6;}
else
rm -f "$ac_file"
mv "$tmp/config.h" "$ac_file" \
- || as_fn_error "could not create $ac_file" "$LINENO" 5
+ || as_fn_error $? "could not create $ac_file" "$LINENO" 5
fi
else
$as_echo "/* $configure_input */" \
&& eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error "could not create -" "$LINENO" 5
+ || as_fn_error $? "could not create -" "$LINENO" 5
fi
# Compute "$ac_file"'s index in $config_headers.
_am_arg="$ac_file"
@@ -17362,7 +17621,7 @@ _ACEOF
ac_clean_files=$ac_clean_files_save
test $ac_write_fail = 0 ||
- as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
+ as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
# configure is writing to config.log, and then calls config.status.
@@ -17383,7 +17642,7 @@ if test "$no_create" != yes; then
exec 5>>config.log
# Use ||, not &&, to avoid exiting from the if with $? = 1, which
# would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit $?
+ $ac_cs_success || as_fn_exit 1
fi
if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
diff --git a/configure.ac b/configure.ac
index 6f72eeb..6ef0df4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,7 +1,7 @@
dnl -*- Autoconf -*-
dnl Process this file with autoconf to produce a configure script.
AC_PREREQ(2.57)
-AC_INIT([lighttpd], [1.4.26], [contact@lighttpd.net])
+AC_INIT([lighttpd], [1.4.28], [contact@lighttpd.net])
AC_CONFIG_SRCDIR([src/server.c])
AC_CONFIG_HEADER([config.h])
AC_CONFIG_MACRO_DIR([m4])
@@ -83,6 +83,47 @@ AC_FUNC_STAT
AC_FUNC_STRFTIME
AC_CHECK_FUNCS([issetugid inet_pton])
+if test -z "$PKG_CONFIG"; then
+ AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
+fi
+
+dnl checking for libev
+AC_MSG_CHECKING(for libev support)
+AC_ARG_WITH(libev,
+ AC_HELP_STRING([--with-libev@<:@=PATH@:>@],[Include libev support for fdevent handlers in PATH/include and PATH/lib]),
+ [WITH_LIBEV=$withval],[WITH_LIBEV=no])
+
+LIBEV_CFLAGS=""
+LIBEV_LIBS=""
+
+if test "$WITH_LIBEV" != "no"; then
+ PKG_CHECK_MODULES(LIBEV, libev, [], [
+ dnl no pkg-config for libev, searching manually:
+
+ if test "$WITH_LIBEV" != "yes"; then
+ LIBEV_CFLAGS="-I$WITH_LIBEV/include"
+ LIBEV_LIBS="-L$WITH_LIBEV/lib -lev"
+ else
+ AC_CHECK_HEADERS([ev.h],[
+ AC_CHECK_LIB([ev], [ev_loop], [
+ LIBEV_CFLAGS=""
+ LIBEV_LIBS="-lev"
+ ],[
+ AC_MSG_ERROR([libev not found])
+ ]
+ )],[
+ AC_MSG_ERROR([libev not found])
+ ]
+ )
+ fi
+ ])
+
+ AC_DEFINE([HAVE_LIBEV], [1], [libev support])
+fi
+
+AC_SUBST(LIBEV_CFLAGS)
+AC_SUBST(LIBEV_LIBS)
+
dnl Checks for database.
MYSQL_INCLUDE=""
MYSQL_LIBS=""
@@ -307,10 +348,6 @@ if test "$WITH_BZIP2" != "no"; then
fi
AC_SUBST(BZ_LIB)
-if test -z "$PKG_CONFIG"; then
- AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
-fi
-
dnl Check for gamin
AC_MSG_CHECKING(for FAM)
AC_ARG_WITH(fam, AC_HELP_STRING([--with-fam],[fam/gamin for reducing number of stat() calls]),
@@ -469,7 +506,7 @@ esac
AC_CHECK_FUNCS([dup2 getcwd inet_ntoa inet_ntop memset mmap munmap strchr \
strdup strerror strstr strtol sendfile getopt socket lstat \
- gethostbyname poll sigtimedwait epoll_ctl getrlimit chroot \
+ gethostbyname poll epoll_ctl getrlimit chroot \
getuid select signal pathconf madvise posix_fadvise posix_madvise \
writev sigaction sendfile64 send_file kqueue port_create localtime_r gmtime_r])
@@ -567,7 +604,14 @@ dnl build version-id
LIGHTTPD_VERSION_ID=`echo $PACKAGE_VERSION | $AWK -F '.' '{print "(" $1 " << 16 | " $2 " << 8 | " $3 ")"}'`
AC_DEFINE_UNQUOTED([LIGHTTPD_VERSION_ID], [$LIGHTTPD_VERSION_ID], [lighttpd-version-id])
-AC_CONFIG_FILES([Makefile src/Makefile doc/Makefile tests/Makefile \
+AC_CONFIG_FILES([Makefile src/Makefile
+ doc/config/conf.d/Makefile \
+ doc/config/vhosts.d/Makefile \
+ doc/config/Makefile \
+ doc/scripts/Makefile \
+ doc/initscripts/Makefile \
+ doc/Makefile \
+ tests/Makefile \
tests/docroot/Makefile \
tests/docroot/123/Makefile \
tests/docroot/www/Makefile \
diff --git a/doc/Makefile.am b/doc/Makefile.am
index ebd1ee1..52c7980 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -1,3 +1,4 @@
+SUBDIRS=config scripts initscripts
dist_man8_MANS=lighttpd.8
DOCS=accesslog.txt \
@@ -76,11 +77,8 @@ HTMLDOCS=accesslog.html \
evhost.html \
magnet.html
-EXTRA_DIST=lighttpd.conf lighttpd.user \
- rc.lighttpd rc.lighttpd.redhat sysconfig.lighttpd \
- rrdtool-graph.sh \
+EXTRA_DIST= \
state.dot fastcgi-state.dot \
- spawn-php.sh \
newstyle.css \
oldstyle.css \
$(DOCS)
diff --git a/doc/Makefile.in b/doc/Makefile.in
index 9f0e303..7f89d07 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -56,6 +56,13 @@ am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
am__v_at_0 = @
SOURCES =
DIST_SOURCES =
+RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
+ html-recursive info-recursive install-data-recursive \
+ install-dvi-recursive install-exec-recursive \
+ install-html-recursive install-info-recursive \
+ install-pdf-recursive install-ps-recursive install-recursive \
+ installcheck-recursive installdirs-recursive pdf-recursive \
+ ps-recursive uninstall-recursive
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
@@ -81,7 +88,40 @@ man8dir = $(mandir)/man8
am__installdirs = "$(DESTDIR)$(man8dir)"
NROFF = nroff
MANS = $(dist_man8_MANS)
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+ $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+ distdir
+ETAGS = etags
+CTAGS = ctags
+DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+ dir0=`pwd`; \
+ sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+ sed_rest='s,^[^/]*/*,,'; \
+ sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+ sed_butlast='s,/*[^/]*$$,,'; \
+ while test -n "$$dir1"; do \
+ first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+ if test "$$first" != "."; then \
+ if test "$$first" = ".."; then \
+ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+ else \
+ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+ if test "$$first2" = "$$first"; then \
+ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+ else \
+ dir2="../$$dir2"; \
+ fi; \
+ dir0="$$dir0"/"$$first"; \
+ fi; \
+ fi; \
+ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+ done; \
+ reldir="$$dir2"
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
@@ -123,6 +163,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -154,6 +196,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
@@ -225,6 +269,7 @@ target_vendor = @target_vendor@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
+SUBDIRS = config scripts initscripts
dist_man8_MANS = lighttpd.8
DOCS = accesslog.txt \
authentication.txt \
@@ -302,16 +347,13 @@ HTMLDOCS = accesslog.html \
evhost.html \
magnet.html
-EXTRA_DIST = lighttpd.conf lighttpd.user \
- rc.lighttpd rc.lighttpd.redhat sysconfig.lighttpd \
- rrdtool-graph.sh \
+EXTRA_DIST = \
state.dot fastcgi-state.dot \
- spawn-php.sh \
newstyle.css \
oldstyle.css \
$(DOCS)
-all: all-am
+all: all-recursive
.SUFFIXES:
.SUFFIXES: .html .txt
@@ -385,12 +427,141 @@ uninstall-man8:
test -z "$$files" || { \
echo " ( cd '$(DESTDIR)$(man8dir)' && rm -f" $$files ")"; \
cd "$(DESTDIR)$(man8dir)" && rm -f $$files; }
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run `make' without going through this Makefile.
+# To change the values of `make' variables: instead of editing Makefiles,
+# (1) if the variable is set in `config.status', edit `config.status'
+# (which will cause the Makefiles to be regenerated when you run `make');
+# (2) otherwise, pass the desired values on the `make' command line.
+$(RECURSIVE_TARGETS):
+ @fail= failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+$(RECURSIVE_CLEAN_TARGETS):
+ @fail= failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ rev=''; for subdir in $$list; do \
+ if test "$$subdir" = "."; then :; else \
+ rev="$$subdir $$rev"; \
+ fi; \
+ done; \
+ rev="$$rev ."; \
+ target=`echo $@ | sed s/-recursive//`; \
+ for subdir in $$rev; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done && test -z "$$fail"
+tags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+ done
+ctags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+ done
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ mkid -fID $$unique
tags: TAGS
-TAGS:
+TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ set x; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ shift; \
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ if test $$# -gt 0; then \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ "$$@" $$unique; \
+ else \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$unique; \
+ fi; \
+ fi
ctags: CTAGS
-CTAGS:
-
+CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ test -z "$(CTAGS_ARGS)$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && $(am__cd) $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) "$$here"
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
@list='$(MANS)'; if test -n "$$list"; then \
@@ -435,22 +606,51 @@ distdir: $(DISTFILES)
|| exit 1; \
fi; \
done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test -d "$(distdir)/$$subdir" \
+ || $(MKDIR_P) "$(distdir)/$$subdir" \
+ || exit 1; \
+ fi; \
+ done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+ $(am__relativize); \
+ new_distdir=$$reldir; \
+ dir1=$$subdir; dir2="$(top_distdir)"; \
+ $(am__relativize); \
+ new_top_distdir=$$reldir; \
+ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+ ($(am__cd) $$subdir && \
+ $(MAKE) $(AM_MAKEFLAGS) \
+ top_distdir="$$new_top_distdir" \
+ distdir="$$new_distdir" \
+ am__remove_distdir=: \
+ am__skip_length_check=: \
+ am__skip_mode_fix=: \
+ distdir) \
+ || exit 1; \
+ fi; \
+ done
check-am: all-am
-check: check-am
+check: check-recursive
all-am: Makefile $(MANS)
-installdirs:
+installdirs: installdirs-recursive
+installdirs-am:
for dir in "$(DESTDIR)$(man8dir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
+install: install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-installcheck: installcheck-am
+installcheck: installcheck-recursive
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
@@ -467,67 +667,67 @@ distclean-generic:
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
-clean: clean-am
+clean: clean-recursive
clean-am: clean-generic clean-libtool clean-local mostlyclean-am
-distclean: distclean-am
+distclean: distclean-recursive
-rm -f Makefile
-distclean-am: clean-am distclean-generic
+distclean-am: clean-am distclean-generic distclean-tags
-dvi: dvi-am
+dvi: dvi-recursive
dvi-am:
-html: html-am
+html: html-recursive
html-am: html-local
-info: info-am
+info: info-recursive
info-am:
install-data-am: install-man
-install-dvi: install-dvi-am
+install-dvi: install-dvi-recursive
install-dvi-am:
install-exec-am:
-install-html: install-html-am
+install-html: install-html-recursive
install-html-am:
-install-info: install-info-am
+install-info: install-info-recursive
install-info-am:
install-man: install-man8
-install-pdf: install-pdf-am
+install-pdf: install-pdf-recursive
install-pdf-am:
-install-ps: install-ps-am
+install-ps: install-ps-recursive
install-ps-am:
installcheck-am:
-maintainer-clean: maintainer-clean-am
+maintainer-clean: maintainer-clean-recursive
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
-mostlyclean: mostlyclean-am
+mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
-pdf: pdf-am
+pdf: pdf-recursive
pdf-am:
-ps: ps-am
+ps: ps-recursive
ps-am:
@@ -535,19 +735,23 @@ uninstall-am: uninstall-man
uninstall-man: uninstall-man8
-.MAKE: install-am install-strip
-
-.PHONY: all all-am check check-am clean clean-generic clean-libtool \
- clean-local distclean distclean-generic distclean-libtool \
- distdir dvi dvi-am html html-am html-local info info-am \
- install install-am install-data install-data-am install-dvi \
- install-dvi-am install-exec install-exec-am install-html \
- install-html-am install-info install-info-am install-man \
- install-man8 install-pdf install-pdf-am install-ps \
- install-ps-am install-strip installcheck installcheck-am \
- installdirs maintainer-clean maintainer-clean-generic \
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+ install-am install-strip tags-recursive
+
+.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
+ all all-am check check-am clean clean-generic clean-libtool \
+ clean-local ctags ctags-recursive distclean distclean-generic \
+ distclean-libtool distclean-tags distdir dvi dvi-am html \
+ html-am html-local info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-man8 \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ installdirs-am maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
- ps ps-am uninstall uninstall-am uninstall-man uninstall-man8
+ ps ps-am tags tags-recursive uninstall uninstall-am \
+ uninstall-man uninstall-man8
.txt.html:
diff --git a/doc/config/Makefile.am b/doc/config/Makefile.am
new file mode 100644
index 0000000..57bf101
--- /dev/null
+++ b/doc/config/Makefile.am
@@ -0,0 +1,2 @@
+SUBDIRS=conf.d vhosts.d
+EXTRA_DIST=lighttpd.conf modules.conf
diff --git a/doc/config/Makefile.in b/doc/config/Makefile.in
new file mode 100644
index 0000000..1e5c437
--- /dev/null
+++ b/doc/config/Makefile.in
@@ -0,0 +1,597 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = doc/config
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo " GEN " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
+ html-recursive info-recursive install-data-recursive \
+ install-dvi-recursive install-exec-recursive \
+ install-html-recursive install-info-recursive \
+ install-pdf-recursive install-ps-recursive install-recursive \
+ installcheck-recursive installdirs-recursive pdf-recursive \
+ ps-recursive uninstall-recursive
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
+ $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+ distdir
+ETAGS = etags
+CTAGS = ctags
+DIST_SUBDIRS = $(SUBDIRS)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+ dir0=`pwd`; \
+ sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+ sed_rest='s,^[^/]*/*,,'; \
+ sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+ sed_butlast='s,/*[^/]*$$,,'; \
+ while test -n "$$dir1"; do \
+ first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+ if test "$$first" != "."; then \
+ if test "$$first" = ".."; then \
+ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+ else \
+ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+ if test "$$first2" = "$$first"; then \
+ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+ else \
+ dir2="../$$dir2"; \
+ fi; \
+ dir0="$$dir0"/"$$first"; \
+ fi; \
+ fi; \
+ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+ done; \
+ reldir="$$dir2"
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+ATTR_LIB = @ATTR_LIB@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BZ_LIB = @BZ_LIB@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRYPT_LIB = @CRYPT_LIB@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DL_LIB = @DL_LIB@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FAM_CFLAGS = @FAM_CFLAGS@
+FAM_LIBS = @FAM_LIBS@
+FGREP = @FGREP@
+GDBM_LIB = @GDBM_LIB@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LBER_LIB = @LBER_LIB@
+LD = @LD@
+LDAP_LIB = @LDAP_LIB@
+LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LUA_CFLAGS = @LUA_CFLAGS@
+LUA_LIBS = @LUA_LIBS@
+MAKEINFO = @MAKEINFO@
+MEMCACHE_LIB = @MEMCACHE_LIB@
+MKDIR_P = @MKDIR_P@
+MYSQL_CONFIG = @MYSQL_CONFIG@
+MYSQL_INCLUDE = @MYSQL_INCLUDE@
+MYSQL_LIBS = @MYSQL_LIBS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PCRECONFIG = @PCRECONFIG@
+PCRE_LIB = @PCRE_LIB@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SENDFILE_LIB = @SENDFILE_LIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SQLITE_CFLAGS = @SQLITE_CFLAGS@
+SQLITE_LIBS = @SQLITE_LIBS@
+SSL_LIB = @SSL_LIB@
+STRIP = @STRIP@
+U = @U@
+UUID_LIBS = @UUID_LIBS@
+VERSION = @VERSION@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+Z_LIB = @Z_LIB@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+SUBDIRS = conf.d vhosts.d
+EXTRA_DIST = lighttpd.conf modules.conf
+all: all-recursive
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/config/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/config/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run `make' without going through this Makefile.
+# To change the values of `make' variables: instead of editing Makefiles,
+# (1) if the variable is set in `config.status', edit `config.status'
+# (which will cause the Makefiles to be regenerated when you run `make');
+# (2) otherwise, pass the desired values on the `make' command line.
+$(RECURSIVE_TARGETS):
+ @fail= failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+$(RECURSIVE_CLEAN_TARGETS):
+ @fail= failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ rev=''; for subdir in $$list; do \
+ if test "$$subdir" = "."; then :; else \
+ rev="$$subdir $$rev"; \
+ fi; \
+ done; \
+ rev="$$rev ."; \
+ target=`echo $@ | sed s/-recursive//`; \
+ for subdir in $$rev; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done && test -z "$$fail"
+tags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+ done
+ctags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+ done
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ mkid -fID $$unique
+tags: TAGS
+
+TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ set x; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ shift; \
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ if test $$# -gt 0; then \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ "$$@" $$unique; \
+ else \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$unique; \
+ fi; \
+ fi
+ctags: CTAGS
+CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in files) print i; }; }'`; \
+ test -z "$(CTAGS_ARGS)$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && $(am__cd) $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) "$$here"
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test -d "$(distdir)/$$subdir" \
+ || $(MKDIR_P) "$(distdir)/$$subdir" \
+ || exit 1; \
+ fi; \
+ done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+ $(am__relativize); \
+ new_distdir=$$reldir; \
+ dir1=$$subdir; dir2="$(top_distdir)"; \
+ $(am__relativize); \
+ new_top_distdir=$$reldir; \
+ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+ ($(am__cd) $$subdir && \
+ $(MAKE) $(AM_MAKEFLAGS) \
+ top_distdir="$$new_top_distdir" \
+ distdir="$$new_distdir" \
+ am__remove_distdir=: \
+ am__skip_length_check=: \
+ am__skip_mode_fix=: \
+ distdir) \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-recursive
+all-am: Makefile
+installdirs: installdirs-recursive
+installdirs-am:
+install: install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-recursive
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-recursive
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-recursive
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic distclean-tags
+
+dvi: dvi-recursive
+
+dvi-am:
+
+html: html-recursive
+
+html-am:
+
+info: info-recursive
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-recursive
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-recursive
+
+install-html-am:
+
+install-info: install-info-recursive
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-recursive
+
+install-pdf-am:
+
+install-ps: install-ps-recursive
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-recursive
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-recursive
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-recursive
+
+pdf-am:
+
+ps: ps-recursive
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \
+ install-am install-strip tags-recursive
+
+.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
+ all all-am check check-am clean clean-generic clean-libtool \
+ ctags ctags-recursive distclean distclean-generic \
+ distclean-libtool distclean-tags distdir dvi dvi-am html \
+ html-am info info-am install install-am install-data \
+ install-data-am install-dvi install-dvi-am install-exec \
+ install-exec-am install-html install-html-am install-info \
+ install-info-am install-man install-pdf install-pdf-am \
+ install-ps install-ps-am install-strip installcheck \
+ installcheck-am installdirs installdirs-am maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
+ uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/doc/config/conf.d/Makefile.am b/doc/config/conf.d/Makefile.am
new file mode 100644
index 0000000..165c17e
--- /dev/null
+++ b/doc/config/conf.d/Makefile.am
@@ -0,0 +1,25 @@
+EXTRA_DIST=access_log.conf \
+ auth.conf \
+ cgi.conf \
+ cml.conf \
+ compress.conf \
+ debug.conf \
+ dirlisting.conf \
+ evhost.conf \
+ expire.conf \
+ fastcgi.conf \
+ geoip.conf \
+ magnet.conf \
+ mime.conf \
+ mod.template \
+ mysql_vhost.conf \
+ proxy.conf \
+ rrdtool.conf \
+ scgi.conf \
+ secdownload.conf \
+ simple_vhost.conf \
+ ssi.conf \
+ status.conf \
+ trigger_b4_dl.conf \
+ userdir.conf \
+ webdav.conf
diff --git a/doc/config/conf.d/Makefile.in b/doc/config/conf.d/Makefile.in
new file mode 100644
index 0000000..1d15454
--- /dev/null
+++ b/doc/config/conf.d/Makefile.in
@@ -0,0 +1,419 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = doc/config/conf.d
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo " GEN " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+ATTR_LIB = @ATTR_LIB@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BZ_LIB = @BZ_LIB@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRYPT_LIB = @CRYPT_LIB@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DL_LIB = @DL_LIB@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FAM_CFLAGS = @FAM_CFLAGS@
+FAM_LIBS = @FAM_LIBS@
+FGREP = @FGREP@
+GDBM_LIB = @GDBM_LIB@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LBER_LIB = @LBER_LIB@
+LD = @LD@
+LDAP_LIB = @LDAP_LIB@
+LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LUA_CFLAGS = @LUA_CFLAGS@
+LUA_LIBS = @LUA_LIBS@
+MAKEINFO = @MAKEINFO@
+MEMCACHE_LIB = @MEMCACHE_LIB@
+MKDIR_P = @MKDIR_P@
+MYSQL_CONFIG = @MYSQL_CONFIG@
+MYSQL_INCLUDE = @MYSQL_INCLUDE@
+MYSQL_LIBS = @MYSQL_LIBS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PCRECONFIG = @PCRECONFIG@
+PCRE_LIB = @PCRE_LIB@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SENDFILE_LIB = @SENDFILE_LIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SQLITE_CFLAGS = @SQLITE_CFLAGS@
+SQLITE_LIBS = @SQLITE_LIBS@
+SSL_LIB = @SSL_LIB@
+STRIP = @STRIP@
+U = @U@
+UUID_LIBS = @UUID_LIBS@
+VERSION = @VERSION@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+Z_LIB = @Z_LIB@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = access_log.conf \
+ auth.conf \
+ cgi.conf \
+ cml.conf \
+ compress.conf \
+ debug.conf \
+ dirlisting.conf \
+ evhost.conf \
+ expire.conf \
+ fastcgi.conf \
+ geoip.conf \
+ magnet.conf \
+ mime.conf \
+ mod.template \
+ mysql_vhost.conf \
+ proxy.conf \
+ rrdtool.conf \
+ scgi.conf \
+ secdownload.conf \
+ simple_vhost.conf \
+ ssi.conf \
+ status.conf \
+ trigger_b4_dl.conf \
+ userdir.conf \
+ webdav.conf
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/config/conf.d/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/config/conf.d/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ distclean distclean-generic distclean-libtool distdir dvi \
+ dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-pdf \
+ install-pdf-am install-ps install-ps-am install-strip \
+ installcheck installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/doc/config/conf.d/access_log.conf b/doc/config/conf.d/access_log.conf
new file mode 100644
index 0000000..6c1e7e3
--- /dev/null
+++ b/doc/config/conf.d/access_log.conf
@@ -0,0 +1,27 @@
+#######################################################################
+##
+## Corresponding documentation:
+##
+## http://www.lighttpd.net/documentation/access.html
+##
+server.modules += ( "mod_accesslog" )
+
+##
+## Default access log.
+##
+accesslog.filename = log_root + "/access.log"
+
+##
+## The default format produces CLF compatible output.
+## For available parameters see access.txt
+##
+#accesslog.format = "%h %l %u %t \"%r\" %b %>s \"%{User-Agent}i\" \"%{Referer}i\""
+
+##
+## If you want to log to syslog you have to unset the
+## accesslog.use-syslog setting and uncomment the next line.
+##
+#accesslog.use-syslog = "enable"
+
+#
+#######################################################################
diff --git a/doc/config/conf.d/auth.conf b/doc/config/conf.d/auth.conf
new file mode 100644
index 0000000..1d3d69c
--- /dev/null
+++ b/doc/config/conf.d/auth.conf
@@ -0,0 +1,27 @@
+#######################################################################
+##
+## Authentication Module
+## -----------------------
+##
+## See http://www.lighttpd.net/documentation/authentification.html
+## for more info.
+##
+
+#auth.backend = "plain"
+#auth.backend.plain.userfile = "/etc/lighttpd/lighttpd.user"
+#auth.backend.plain.groupfile = "/etc/lighttpd/lighttpd.group"
+
+#auth.backend.ldap.hostname = "localhost"
+#auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
+#auth.backend.ldap.filter = "(uid=$)"
+
+#auth.require = ( "/server-status" =>
+# (
+# "method" => "digest",
+# "realm" => "Server Status",
+# "require" => "valid-user"
+# ),
+# )
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/cgi.conf b/doc/config/conf.d/cgi.conf
new file mode 100644
index 0000000..ed27799
--- /dev/null
+++ b/doc/config/conf.d/cgi.conf
@@ -0,0 +1,33 @@
+#######################################################################
+##
+## CGI modules
+## ---------------
+##
+## http://www.lighttpd.net/documentation/cgi.html
+##
+server.modules += ( "mod_cgi" )
+
+##
+## Plain old CGI handling
+##
+## For PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini.
+##
+cgi.assign = ( ".pl" => "/usr/bin/perl",
+ ".cgi" => "/usr/bin/perl",
+ ".rb" => "/usr/bin/ruby",
+ ".erb" => "/usr/bin/eruby",
+ ".py" => "/usr/bin/python" )
+
+##
+## to get the old cgi-bin behavior of apache
+##
+## Note: make sure that mod_alias is loaded if you uncomment the
+## next line. (see modules.conf)
+##
+#alias.url += ( "/cgi-bin" => server_root + "/cgi-bin" )
+#$HTTP["url"] =~ "^/cgi-bin" {
+# cgi.assign = ( "" => "" )
+#}
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/cml.conf b/doc/config/conf.d/cml.conf
new file mode 100644
index 0000000..8054ea6
--- /dev/null
+++ b/doc/config/conf.d/cml.conf
@@ -0,0 +1,27 @@
+#######################################################################
+##
+## CML Module
+## ---------------
+##
+## see http://www.lighttpd.net/documentation/cml.html
+##
+server.modules += ( "mod_cml" )
+index-file.names += ( "index.cml" )
+
+##
+## The file extension that is bound to the cml-module.
+##
+cml.extension = ".cml"
+
+##
+## Memcached hosts used for memcache* functions.
+##
+#cml.memcache-hosts = ( "127.0.0.1:11211" )
+
+##
+## A cml file that is executed for each request.
+##
+#cml.power-magnet = server_root + "/htdocs/powermagnet.cml"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/compress.conf b/doc/config/conf.d/compress.conf
new file mode 100644
index 0000000..8ea4248
--- /dev/null
+++ b/doc/config/conf.d/compress.conf
@@ -0,0 +1,31 @@
+#######################################################################
+##
+## Output Compression
+## --------------------
+##
+## see http://www.lighttpd.net/documentation/compress.html
+##
+server.modules += ( "mod_compress" )
+
+##
+## where should the compressed files be cached?
+## see the base config for the declaration of the variable.
+##
+## This directory should be changed per vhost otherwise you can
+## run into trouble with overlapping filenames
+##
+compress.cache-dir = cache_dir + "/compress"
+
+##
+## FileTypes to compress.
+##
+compress.filetype = ("text/plain", "text/html")
+
+##
+## Maximum filesize that will be compressed.
+## Default is 0, which means unlimited file size.
+##
+#compress.max-filesize = 0
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/debug.conf b/doc/config/conf.d/debug.conf
new file mode 100644
index 0000000..80bbea0
--- /dev/null
+++ b/doc/config/conf.d/debug.conf
@@ -0,0 +1,47 @@
+#######################################################################
+##
+## Debug options
+## ---------------
+##
+## Enable those options for debugging the behavior
+##
+## The settings can be set per location/vhost.
+##
+
+##
+## log-request-handling allows you to track the request
+## handing inside lighttpd.
+##
+#debug.log-request-handling = "enable"
+
+##
+## log all request headers.
+##
+#debug.log-request-header = "enable"
+
+##
+## similar to log-request-header.
+## but only logs if we encountered an error.
+## (return codes 400 and 5xx)
+##
+#debug.log-request-header-on-error = "enable"
+
+##
+## log the header we send out to the client.
+##
+#debug.log-response-header = "enable"
+
+##
+## log if a file wasnt found in the error log.
+##
+#debug.log-file-not-found = "enable"
+
+##
+## debug conditionals handling
+##
+#debug.log-condition-handling = "enable"
+
+#
+#######################################################################
+
+
diff --git a/doc/config/conf.d/dirlisting.conf b/doc/config/conf.d/dirlisting.conf
new file mode 100644
index 0000000..53a18a2
--- /dev/null
+++ b/doc/config/conf.d/dirlisting.conf
@@ -0,0 +1,55 @@
+#######################################################################
+##
+## Dirlisting Module
+## -------------------
+##
+## See http://www.lighttpd.net/documentation/dirlisting.html
+##
+
+##
+## Enabled Directory listing
+##
+dir-listing.activate = "disable"
+
+##
+## Hide dot files from the listing?
+## By default they are listed.
+##
+dir-listing.hide-dotfiles = "disable"
+
+##
+## list of regular expressions. Files that match any of the specified
+## regular expressions will be excluded from directory listings.
+##
+dir-listing.exclude = ( "~$" )
+
+##
+## set a encoding for the generated directory listing
+##
+## If you file-system is not using ASCII you have to set the encoding of
+## the filenames as they are put into the HTML listing AS IS (with XML
+## encoding)
+##
+dir-listing.encoding = "UTF-8"
+
+##
+## Specify the url to an optional CSS file.
+##
+#dir-listing.external-css = "/dirindex.css"
+
+##
+## Include HEADER.txt files above the directory listing.
+## You can disable showing the HEADER.txt in the listing.
+##
+dir-listing.hide-header-file = "disable"
+dir-listing.show-header = "disable"
+
+##
+## Include README.txt files above the directory listing.
+## You can disable showing the README.txt in the listing.
+##
+dir-listing.hide-readme-file = "disable"
+dir-listing.show-readme = "disable"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/evhost.conf b/doc/config/conf.d/evhost.conf
new file mode 100644
index 0000000..6da89c1
--- /dev/null
+++ b/doc/config/conf.d/evhost.conf
@@ -0,0 +1,22 @@
+#######################################################################
+##
+## Enhanced virtual hosting
+## --------------------------
+##
+## See http://www.lighttpd.net/documentation/evhost.html
+##
+server.modules += ( "mod_evhost" )
+
+##
+## define a pattern for the host url finding
+## %% => % sign
+## %0 => domain name + tld
+## %1 => tld
+## %2 => domain name without tld
+## %3 => subdomain 1 name
+## %4 => subdomain 2 name
+##
+evhost.path-pattern = vhosts_dir + "/%3/htdocs/"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/expire.conf b/doc/config/conf.d/expire.conf
new file mode 100644
index 0000000..0ca0ab2
--- /dev/null
+++ b/doc/config/conf.d/expire.conf
@@ -0,0 +1,22 @@
+#######################################################################
+##
+## Expire Module
+## ---------------
+##
+## See http://www.lighttpd.net/documentation/expire.html
+##
+server.modules += ( "mod_expire" )
+
+##
+## assignes a expiration to all files below the specified path. The
+## specification of the time is made up of:
+##
+## <access|modification> <number> <years|months|days|hours|minutes|seconds>
+##
+#expire.url = (
+# "/buggy/" => "access 2 hours",
+# "/images/" => "access plus 1 seconds 2 minutes"
+#)
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/fastcgi.conf b/doc/config/conf.d/fastcgi.conf
new file mode 100644
index 0000000..49cff62
--- /dev/null
+++ b/doc/config/conf.d/fastcgi.conf
@@ -0,0 +1,135 @@
+#######################################################################
+##
+## FastCGI Module
+## ---------------
+##
+## http://www.lighttpd.net/documentation/fastcgi.html
+##
+server.modules += ( "mod_fastcgi" )
+
+##
+## PHP Example
+## For PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini.
+##
+## The number of php processes you will get can be easily calculated:
+##
+## num-procs = max-procs * ( 1 + PHP_FCGI_CHILDREN )
+##
+## for the php-num-procs example it means you will get 17*5 = 85 php
+## processes. you always should need this high number for your very
+## busy sites. And if you have a lot of RAM. :)
+##
+#fastcgi.server = ( ".php" =>
+# ( "php-local" =>
+# (
+# "socket" => socket_dir + "/php-fastcgi-1.socket",
+# "bin-path" => server_root + "/cgi-bin/php5",
+# "max-procs" => 1,
+# "broken-scriptfilename" => "enable",
+# )
+# ),
+# ( "php-tcp" =>
+# (
+# "host" => "127.0.0.1",
+# "port" => 9999,
+# "check-local" => "disable",
+# "broken-scriptfilename" => "enable",
+# )
+# ),
+#
+# ( "php-num-procs" =>
+# (
+# "socket" => socket_dir + "/php-fastcgi-2.socket",
+# "bin-path" => server_root + "/cgi-bin/php5",
+# "bin-environment" => (
+# "PHP_FCGI_CHILDREN" => "16",
+# "PHP_FCGI_MAX_REQUESTS" => "10000",
+# ),
+# "max-procs" => 5,
+# "broken-scriptfilename" => "enable",
+# )
+# ),
+# )
+
+##
+## Ruby on Rails Example
+##
+## Normally you only run one Rails application on one vhost.
+##
+#$HTTP["host"] == "rails1.example.com" {
+# server.document-root = server_root + "/rails/someapp/public"
+# server.error-handler-404 = "/dispatch.fcgi"
+# fastcgi.server = ( ".fcgi" =>
+# ("someapp" =>
+# ( "socket" => socket_dir + "/someapp-fcgi.socket",
+# "bin-path" => server_root + "/rails/someapp/public/dispatch.fcgi",
+# "bin-environment" => (
+# "RAILS_ENV" => "production",
+# "TMP" => home_dir + "/rails/someapp",
+# ),
+# )
+# )
+# )
+#}
+
+##
+## Another example with multiple rails applications on one vhost.
+##
+## http://blog.lighttpd.net/articles/2005/11/23/lighttpd-1-4-8-and-multiple-rails-apps
+##
+#$HTTP["host"] == "rails2.example.com" {
+# $HTTP["url"] =~ "^/someapp1" {
+# server.document-root = server_root + "/rails/someapp1/public"
+# server.error-handler-404 = "/dispatch.fcgi"
+# fastcgi.server = ( ".fcgi" =>
+# ("someapp1" =>
+# ( "socket" => socket_dir + "/someapp1-fcgi.socket",
+# "bin-path" => server_root + "/rails/someapp1/public/dispatch.fcgi",
+# "bin-environment" => (
+# "RAILS_ENV" => "production",
+# "TMP" => home_dir + "/rails/someapp1",
+# ),
+# "strip-request-uri" => "/someapp1/"
+# )
+# )
+# )
+# }
+#
+# $HTTP["url"] =~ "^/someapp2" {
+# server.document-root = server_root + "/rails/someapp2/public"
+# server.error-handler-404 = "/dispatch.fcgi"
+# fastcgi.server = ( ".fcgi" =>
+# ("someapp2" =>
+# ( "socket" => socket_dir + "/someapp2-fcgi.socket",
+# "bin-path" => server_root + "/rails/someapp2/public/dispatch.fcgi",
+# "bin-environment" => (
+# "RAILS_ENV" => "production",
+# "TMP" => home_dir + "/rails/someapp2",
+# ),
+# "strip-request-uri" => "/someapp2/"
+# )
+# )
+# )
+# }
+#}
+
+## chrooted webserver + external PHP
+##
+## $ spawn-fcgi -f /usr/bin/php-cgi -p 2000 -a 127.0.0.1 -C 8
+##
+## webserver chrooted to /srv/www/
+## php running outside the chroot
+#
+#fastcgi.server = (
+# ".php" => ((
+# "host" => "127.0.0.1",
+# "port" => "2000",
+# "docroot" => "/srv/www/servers/www.example.org/htdocs/"
+# )))
+#
+#server.chroot = "/srv/www"
+#server.document-root = "/servers/wwww.example.org/htdocs/"
+#
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/geoip.conf b/doc/config/conf.d/geoip.conf
new file mode 100644
index 0000000..5b5b28b
--- /dev/null
+++ b/doc/config/conf.d/geoip.conf
@@ -0,0 +1,26 @@
+#######################################################################
+##
+## GeoIP Module
+## ---------------
+##
+## mod_geoip is a module for fast ip/location lookups. It uses MaxMind
+## GeoIP / GeoCity databases. If the ip was found in the database the
+## module sets the appropriate environments variables to the request,
+## thus making other modules/fcgi be informed.
+##
+server.modules += ( "mod_geoip" )
+
+##
+## mod_geoip will determine the database type automatically so if you
+## enter GeoCity databse path it will load GeoCity Env.
+##
+#geoip.db-filename = "/path/to/GeoCityLite.dat"
+
+##
+## If enabled, mod_geoip will load the database binary file to memory
+## for very fast lookups. The only penalty is memory usage.
+##
+#geoip.memory-cache = "disable"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/magnet.conf b/doc/config/conf.d/magnet.conf
new file mode 100644
index 0000000..1ebf529
--- /dev/null
+++ b/doc/config/conf.d/magnet.conf
@@ -0,0 +1,22 @@
+#######################################################################
+##
+## Magnet Module
+## ---------------
+##
+## see http://trac.lighttpd.net/trac/wiki/Docs%3AModMagnet
+##
+server.modules += ( "mod_magnet" )
+
+##
+##
+##
+#magnet.attract-raw-url-to = ( )
+
+##
+## as an example for that see the mod_magnet docs and
+## http://pixel.global-banlist.de./
+##
+#magnet.attract-physical-path-to = ( conf_dir + "/cleanurl.lua" )
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/mime.conf b/doc/config/conf.d/mime.conf
new file mode 100644
index 0000000..a3c6f0c
--- /dev/null
+++ b/doc/config/conf.d/mime.conf
@@ -0,0 +1,77 @@
+#######################################################################
+##
+## MimeType handling
+## -------------------
+##
+## http://www.lighttpd.net/documentation/configuration.html#mimetypes
+##
+## Use the "Content-Type" extended attribute to obtain mime type if
+## possible
+##
+mimetype.use-xattr = "disable"
+
+##
+## mimetype mapping
+##
+mimetype.assign = (
+ ".pdf" => "application/pdf",
+ ".sig" => "application/pgp-signature",
+ ".spl" => "application/futuresplash",
+ ".class" => "application/octet-stream",
+ ".ps" => "application/postscript",
+ ".torrent" => "application/x-bittorrent",
+ ".dvi" => "application/x-dvi",
+ ".gz" => "application/x-gzip",
+ ".pac" => "application/x-ns-proxy-autoconfig",
+ ".swf" => "application/x-shockwave-flash",
+ ".tar.gz" => "application/x-tgz",
+ ".tgz" => "application/x-tgz",
+ ".tar" => "application/x-tar",
+ ".zip" => "application/zip",
+ ".mp3" => "audio/mpeg",
+ ".m3u" => "audio/x-mpegurl",
+ ".wma" => "audio/x-ms-wma",
+ ".wax" => "audio/x-ms-wax",
+ ".ogg" => "application/ogg",
+ ".wav" => "audio/x-wav",
+ ".gif" => "image/gif",
+ ".jpg" => "image/jpeg",
+ ".jpeg" => "image/jpeg",
+ ".png" => "image/png",
+ ".xbm" => "image/x-xbitmap",
+ ".xpm" => "image/x-xpixmap",
+ ".xwd" => "image/x-xwindowdump",
+ ".css" => "text/css",
+ ".html" => "text/html",
+ ".htm" => "text/html",
+ ".js" => "text/javascript",
+ ".asc" => "text/plain",
+ ".c" => "text/plain",
+ ".cpp" => "text/plain",
+ ".log" => "text/plain",
+ ".conf" => "text/plain",
+ ".text" => "text/plain",
+ ".txt" => "text/plain",
+ ".spec" => "text/plain",
+ ".dtd" => "text/xml",
+ ".xml" => "text/xml",
+ ".mpeg" => "video/mpeg",
+ ".mpg" => "video/mpeg",
+ ".mov" => "video/quicktime",
+ ".qt" => "video/quicktime",
+ ".avi" => "video/x-msvideo",
+ ".asf" => "video/x-ms-asf",
+ ".asx" => "video/x-ms-asf",
+ ".wmv" => "video/x-ms-wmv",
+ ".bz2" => "application/x-bzip",
+ ".tbz" => "application/x-bzip-compressed-tar",
+ ".tar.bz2" => "application/x-bzip-compressed-tar",
+ ".rpm" => "application/x-rpm",
+ # make the default mime type application/octet-stream.
+ "" => "application/octet-stream",
+ )
+
+
+#
+#######################################################################
+
diff --git a/doc/config/conf.d/mod.template b/doc/config/conf.d/mod.template
new file mode 100644
index 0000000..fcfdac4
--- /dev/null
+++ b/doc/config/conf.d/mod.template
@@ -0,0 +1,16 @@
+#######################################################################
+##
+## Foo Module
+## ---------------
+##
+## http://www.lighttpd.net/documentation/Foo.html
+##
+server.modules += ( "mod_Foo" )
+
+##
+## foo
+##
+#foo.bar = 1
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/mysql_vhost.conf b/doc/config/conf.d/mysql_vhost.conf
new file mode 100644
index 0000000..63550c4
--- /dev/null
+++ b/doc/config/conf.d/mysql_vhost.conf
@@ -0,0 +1,47 @@
+#######################################################################
+##
+## Virtual hosting with MySQL
+## ----------------------------
+##
+## http://www.lighttpd.net/documentation/mysqlvhost.html
+##
+server.modules += ( "mod_mysql_vhost" )
+
+##
+## Either set the the socket or host (and port)
+##
+## Local path to the mysql socket
+##
+#mysql-vhost.sock = "/var/lib/mysql/mysql.sock"
+
+##
+## Host of the MySQL server.
+##
+#mysql-vhost.hostname = "localhost"
+
+##
+## Optional: port to use.
+##
+#mysql-vhost.port = 3306
+
+##
+## Name of the database
+##
+mysql-vhost.db = "lighttpd"
+
+##
+## SQL User/Password for the connection
+##
+mysql-vhost.user = "lighttpd"
+mysql-vhost.pass = "secret"
+
+##
+## The query to get the needed informations from the database.
+##
+## It doesnt matter how you name the fields the first field is always used
+## as the document root.
+##
+mysql-vhost.sql = "SELECT docroot FROM domains WHERE domain='?'"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/proxy.conf b/doc/config/conf.d/proxy.conf
new file mode 100644
index 0000000..f0552c2
--- /dev/null
+++ b/doc/config/conf.d/proxy.conf
@@ -0,0 +1,35 @@
+#######################################################################
+##
+## Proxy Module
+## ---------------
+##
+## http://www.lighttpd.net/documentation/proxy.html
+##
+server.modules += ( "mod_proxy" )
+
+##
+## a value between 0 and 65535 to set the debug-level in the Proxy module.
+## Currently only 0 and 1 are used. Use 1 to enable some debug output, 0 to
+## disable it.
+##
+#proxy.debug = 1
+
+##
+## might be one of 'hash', 'round-robin' or 'fair' (default).
+##
+#proxy.balance = "fair"
+
+##
+## Handle all jsp requests via 192.168.0.101
+##
+#proxy.server = ( ".jsp" =>
+# ( "tomcat" =>
+# (
+# "host" => "192.168.0.101",
+# "port" => 80
+# )
+# )
+# )
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/rrdtool.conf b/doc/config/conf.d/rrdtool.conf
new file mode 100644
index 0000000..c29013b
--- /dev/null
+++ b/doc/config/conf.d/rrdtool.conf
@@ -0,0 +1,21 @@
+#######################################################################
+##
+## RRD Tool Module
+## -----------------
+##
+## see http://www.lighttpd.net/documentation/rrdtool.html
+##
+server.modules += ( "mod_rrdtool" )
+
+##
+## Path to the rrdtool binary.
+##
+rrdtool.binary = "/usr/bin/rrdtool"
+
+##
+## Path to the rrdtool database. You can override this in conditionals.
+##
+rrdtool.db-name = "/var/lib/lighttpd/lighttpd.rrd"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/scgi.conf b/doc/config/conf.d/scgi.conf
new file mode 100644
index 0000000..3fcf280
--- /dev/null
+++ b/doc/config/conf.d/scgi.conf
@@ -0,0 +1,51 @@
+#######################################################################
+##
+## FastCGI Module
+## ---------------
+##
+## http://www.lighttpd.net/documentation/scgi.html
+##
+server.modules += ( "mod_scgi" )
+
+##
+## Ruby on Rails Example
+##
+## Normally you only run one Rails application on one vhost.
+##
+#$HTTP["host"] == "rails1.example.com" {
+# server.document-root = server_root + "/rails/someapp/public"
+# server.error-handler-404 = "/dispatch.fcgi"
+# scgi.server = ( ".scgi" =>
+# ("scgi-someapp" =>
+# ( "socket" => socket_dir + "/someapp-scgi.socket",
+# "bin-path" => server_root + "/rails/someapp/public/dispatch.scgi",
+# "bin-environment" => (
+# "RAILS_ENV" => "production",
+# "TMP" => home_dir + "/rails/someapp",
+# ),
+# )
+# )
+# )
+#}
+
+##
+## 2nd Ruby on Rails Example
+##
+## This time we launch the rails application via scgi_rails externally.
+##
+#$HTTP["host"] == "rails2.example.com" {
+# server.document-root = server_root + "/rails/someapp/public"
+# server.error-handler-404 = "/dispatch.scgi"
+# scgi.server = ( ".scgi" =>
+# ( "scgi-tcp" =>
+# (
+# "host" => "127.0.0.1",
+# "port" => 9998,
+# "check-local" => "disable",
+# )
+# )
+# )
+#}
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/secdownload.conf b/doc/config/conf.d/secdownload.conf
new file mode 100644
index 0000000..2d4d11a
--- /dev/null
+++ b/doc/config/conf.d/secdownload.conf
@@ -0,0 +1,35 @@
+#######################################################################
+##
+## Secure Download Module
+## ------------------------
+##
+## see http://www.lighttpd.net/documentation/secdownload.html
+##
+server.modules += ( "mod_secdownload" )
+
+##
+## Document root for the download area.
+## The directory should not be below your normal
+## document root!
+##
+#secdownload.document-root = server_root + "/downloads"
+
+##
+## Secret string that will be used for the checksum calculation.
+##
+#secdownload.secret = ""
+
+##
+## How long is the secret valid?
+##
+## Default: 60 seconds
+##
+#secdownload.timeout = 60
+
+##
+## Prefix for the download area.
+##
+#secdownload.uri-prefix = "/download/"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/simple_vhost.conf b/doc/config/conf.d/simple_vhost.conf
new file mode 100644
index 0000000..220331e
--- /dev/null
+++ b/doc/config/conf.d/simple_vhost.conf
@@ -0,0 +1,28 @@
+#######################################################################
+##
+## Simple Virtual hosting
+## ------------------------
+##
+## http://www.lighttpd.net/documentation/simple-vhost.html
+##
+server.modules += ( "mod_simple_vhost" )
+
+## If you want name-based virtual hosting add the next three settings and load
+## mod_simple_vhost
+##
+## document-root =
+## virtual-server-root + virtual-server-default-host + virtual-server-docroot
+## or
+## virtual-server-root + http-host + virtual-server-docroot
+##
+simple-vhost.server-root = vhosts_dir + "/"
+simple-vhost.default-host = "default.example.com"
+simple-vhost.document-root = "/htdocs/"
+
+##
+## Print some errors for finding the document-root
+##
+#simple-vhost.debug = "enable"
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/ssi.conf b/doc/config/conf.d/ssi.conf
new file mode 100644
index 0000000..a82d1a5
--- /dev/null
+++ b/doc/config/conf.d/ssi.conf
@@ -0,0 +1,16 @@
+#######################################################################
+##
+## Server Side Includes
+## -----------------------
+##
+## see /usr/share/doc/packages/lighttpd/ssi.html
+##
+server.modules += ( "mod_ssi" )
+
+##
+## which extensions should be ran through mod_ssi.
+##
+ssi.extension = ( ".shtml" )
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/status.conf b/doc/config/conf.d/status.conf
new file mode 100644
index 0000000..946939f
--- /dev/null
+++ b/doc/config/conf.d/status.conf
@@ -0,0 +1,24 @@
+#######################################################################
+##
+## Status Module
+## ---------------
+##
+## see http://www.lighttpd.net/documentation/status.html
+##
+server.modules += ( "mod_status" )
+
+$HTTP["remoteip"] == "127.0.0.0/8" {
+##
+## configure urls for the various parts of the module.
+##
+ status.status-url = "/server-status"
+ status.config-url = "/server-config"
+ status.statistics-url = "/server-statistics"
+##
+## add JavaScript which allows client-side sorting for the connection
+## overview
+##
+ status.enable-sort = "enable"
+}
+##
+#######################################################################
diff --git a/doc/config/conf.d/trigger_b4_dl.conf b/doc/config/conf.d/trigger_b4_dl.conf
new file mode 100644
index 0000000..1efd3fd
--- /dev/null
+++ b/doc/config/conf.d/trigger_b4_dl.conf
@@ -0,0 +1,70 @@
+#######################################################################
+##
+## Trigger before download
+## ---------------
+##
+## - if user requests ''download-url'' directly, the request is denied
+## and he is redirected to ''deny-url'
+## - if user visits ''trigger-url'' before requesting ''download-url'',
+## access is granted
+## - if user visits ''download-url'' again after ''trigger-timeout'' has
+## elapsed, the request is denied and he is redirected to ''deny-url''
+##
+## http://www.lighttpd.net/documentation/trigger_b4_dl.html
+##
+server.modules += ( "mod_mod_trigger_b4_dl" )
+
+##
+## To store the trigger state you can either use a local GDBM
+## file or memcached(s).
+##
+
+##
+## Path to the local GDBM file.
+##
+trigger-before-download.gdbm-filename = home_dir + "/trigger.db"
+
+##
+## List of memcached servers.
+##
+#trigger-before-download.memcache-hosts = ( "127.0.0.1:11211" )
+
+##
+## URL prefix a visitor has to visit before downloading is allowed
+##
+trigger-before-download.trigger-url = "^/trigger/"
+
+##
+## URL Prefix of the proteced area.
+##
+trigger-before-download.download-url = "^/download/"
+
+##
+##
+## The deny url.
+##
+trigger-before-download.deny-url = "http://www.example.com/index.html"
+
+##
+## How long the "ticket" of the user will be valid.
+##
+## Value in seconds.
+##
+trigger-before-download.trigger-timeout = 10
+
+##
+## Normally the memcached key will be the remote ip of the request
+## If you store other data in the memcached aswell and want to avoid
+## key collisions you can configure a memcache-namespace.
+##
+## The key for the request will be memcache-namespace + remote_ip than.
+##
+#trigger-before-download.memcache-namespace = "t4bdl_"
+
+##
+## If set to 1, the module will log some debug informations.
+##
+#trigger-before-download.debug = 0
+
+##
+#######################################################################
diff --git a/doc/config/conf.d/userdir.conf b/doc/config/conf.d/userdir.conf
new file mode 100644
index 0000000..1e3691e
--- /dev/null
+++ b/doc/config/conf.d/userdir.conf
@@ -0,0 +1,37 @@
+#######################################################################
+##
+## Userdir Module
+## ----------------
+##
+## for all details see:
+## http://www.lighttpd.net/documentation/userdir.html
+##
+server.modules += ( "mod_userdir" )
+
+##
+## usually it should be set to "public_html" to take ~/public_html/ as
+## the document root
+## Default: empty (document root is the home directory)
+##
+userdir.path = "public_html"
+
+##
+## If set, don't check /etc/passwd for homedir
+## Default: empty
+#userdir.basepath = server_root + "/users/"
+
+##
+## list of usernames which may not use this feature
+## Default: empty (all users may use it)
+##
+#userdir.exclude-user = ( "root", "postmaster" )
+
+##
+## if set, only users from this list may use the feature
+## Default: empty (all users may use it)
+##
+#userdir.include-user = ("user1", "user2")
+
+##
+#######################################################################
+
diff --git a/doc/config/conf.d/webdav.conf b/doc/config/conf.d/webdav.conf
new file mode 100644
index 0000000..2c37335
--- /dev/null
+++ b/doc/config/conf.d/webdav.conf
@@ -0,0 +1,33 @@
+#######################################################################
+##
+## WebDAV Module
+## ---------------
+##
+## http://www.lighttpd.net/documentation/webdav.html
+##
+server.modules += ( "mod_webdav" )
+
+$HTTP["url"] =~ "^/dav($|/)" {
+ ##
+ ## enable webdav for this location
+ ##
+ webdav.activate = "enable"
+
+ ##
+ ## By default the webdav url is writable.
+ ## Uncomment the following line if you want to make it readonly.
+ ##
+ #webdav.is-readonly = "enable"
+
+ ##
+ ## Log the XML Request bodies for debugging
+ ##
+ #webdav.log-xml = "disable"
+
+ ##
+ ##
+ ##
+ webdav.sqlite-db-name = home_dir + "/webdav.db"
+}
+##
+#######################################################################
diff --git a/doc/config/lighttpd.conf b/doc/config/lighttpd.conf
new file mode 100644
index 0000000..efe96be
--- /dev/null
+++ b/doc/config/lighttpd.conf
@@ -0,0 +1,426 @@
+#######################################################################
+##
+## /etc/lighttpd/lighttpd.conf
+##
+## check /etc/lighttpd/conf.d/*.conf for the configuration of modules.
+##
+#######################################################################
+
+#######################################################################
+##
+## Some Variable definition which will make chrooting easier.
+##
+## if you add a variable here. Add the corresponding variable in the
+## chroot example aswell.
+##
+var.log_root = "/var/log/lighttpd"
+var.server_root = "/srv/www"
+var.state_dir = "/var/run"
+var.home_dir = "/var/lib/lighttpd"
+var.conf_dir = "/etc/lighttpd"
+
+##
+## run the server chrooted.
+##
+## This requires root permissions during startup.
+##
+## If you run Chrooted set the the variables to directories relative to
+## the chroot dir.
+##
+## example chroot configuration:
+##
+#var.log_root = "/logs"
+#var.server_root = "/"
+#var.state_dir = "/run"
+#var.home_dir = "/lib/lighttpd"
+#var.vhosts_dir = "/vhosts"
+#var.conf_dir = "/etc"
+#
+#server.chroot = "/srv/www"
+
+##
+## Some additional variables to make the configuration easier
+##
+
+##
+## Base directory for all virtual hosts
+##
+## used in:
+## conf.d/evhost.conf
+## conf.d/simple_vhost.conf
+## vhosts.d/vhosts.template
+##
+var.vhosts_dir = server_root + "/vhosts"
+
+##
+## Cache for mod_compress
+##
+## used in:
+## conf.d/compress.conf
+##
+var.cache_dir = "/var/cache/lighttpd"
+
+##
+## Base directory for sockets.
+##
+## used in:
+## conf.d/fastcgi.conf
+## conf.d/scgi.conf
+##
+var.socket_dir = home_dir + "/sockets"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Load the modules.
+include "modules.conf"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Basic Configuration
+## ---------------------
+##
+server.port = 80
+
+##
+## Use IPv6?
+##
+server.use-ipv6 = "enable"
+
+##
+## bind to a specific IP
+##
+#server.bind = "localhost"
+
+##
+## Run as a different username/groupname.
+## This requires root permissions during startup.
+##
+server.username = "lighttpd"
+server.groupname = "lighttpd"
+
+##
+## enable core files.
+##
+#server.core-files = "disable"
+
+##
+## Document root
+##
+server.document-root = server_root + "/htdocs"
+
+##
+## The value for the "Server:" response field.
+##
+## It would be nice to keep it at "lighttpd".
+##
+#server.tag = "lighttpd"
+
+##
+## store a pid file
+##
+server.pid-file = state_dir + "/lighttpd.pid"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Logging Options
+## ------------------
+##
+## all logging options can be overwritten per vhost.
+##
+## Path to the error log file
+##
+server.errorlog = log_root + "/error.log"
+
+##
+## If you want to log to syslog you have to unset the
+## server.errorlog setting and uncomment the next line.
+##
+#server.errorlog-use-syslog = "enable"
+
+##
+## Access log config
+##
+include "conf.d/access_log.conf"
+
+##
+## The debug options are moved into their own file.
+## see conf.d/debug.conf for various options for request debugging.
+##
+include "conf.d/debug.conf"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Tuning/Performance
+## --------------------
+##
+## corresponding documentation:
+## http://www.lighttpd.net/documentation/performance.html
+##
+## set the event-handler (read the performance section in the manual)
+##
+## possible options on linux are:
+##
+## select
+## poll
+## linux-sysepoll
+##
+## linux-sysepoll is recommended on kernel 2.6.
+##
+server.event-handler = "linux-sysepoll"
+
+##
+## The basic network interface for all platforms at the syscalls read()
+## and write(). Every modern OS provides its own syscall to help network
+## servers transfer files as fast as possible
+##
+## linux-sendfile - is recommended for small files.
+## writev - is recommended for sending many large files
+##
+server.network-backend = "linux-sendfile"
+
+##
+## As lighttpd is a single-threaded server, its main resource limit is
+## the number of file descriptors, which is set to 1024 by default (on
+## most systems).
+##
+## If you are running a high-traffic site you might want to increase this
+## limit by setting server.max-fds.
+##
+## Changing this setting requires root permissions on startup. see
+## server.username/server.groupname.
+##
+## By default lighttpd would not change the operation system default.
+## But setting it to 2048 is a better default for busy servers.
+##
+server.max-fds = 2048
+
+##
+## Stat() call caching.
+##
+## lighttpd can utilize FAM/Gamin to cache stat call.
+##
+## possible values are:
+## disable, simple or fam.
+##
+server.stat-cache-engine = "simple"
+
+##
+## Fine tuning for the request handling
+##
+## max-connections == max-fds/2 (maybe /3)
+## means the other file handles are used for fastcgi/files
+##
+server.max-connections = 1024
+
+##
+## How many seconds to keep a keep-alive connection open,
+## until we consider it idle.
+##
+## Default: 5
+##
+#server.max-keep-alive-idle = 5
+
+##
+## How many keep-alive requests until closing the connection.
+##
+## Default: 16
+##
+#server.max-keep-alive-requests = 16
+
+##
+## Maximum size of a request in kilobytes.
+## By default it is unlimited (0).
+##
+## Uploads to your server cant be larger than this value.
+##
+#server.max-request-size = 0
+
+##
+## Time to read from a socket before we consider it idle.
+##
+## Default: 60
+##
+#server.max-read-idle = 60
+
+##
+## Time to write to a socket before we consider it idle.
+##
+## Default: 360
+##
+#server.max-write-idle = 360
+
+##
+## Traffic Shaping
+## -----------------
+##
+## see /usr/share/doc/lighttpd/traffic-shaping.txt
+##
+## Values are in kilobyte per second.
+##
+## Keep in mind that a limit below 32kB/s might actually limit the
+## traffic to 32kB/s. This is caused by the size of the TCP send
+## buffer.
+##
+## per server:
+##
+#server.kbytes-per-second = 128
+
+##
+## per connection:
+##
+#connection.kbytes-per-second = 32
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Filename/File handling
+## ------------------------
+
+##
+## files to check for if .../ is requested
+## index-file.names = ( "index.php", "index.rb", "index.html",
+## "index.htm", "default.htm" )
+##
+index-file.names += (
+ "index.xhtml", "index.html", "index.htm", "default.htm", "index.php"
+)
+
+##
+## deny access the file-extensions
+##
+## ~ is for backupfiles from vi, emacs, joe, ...
+## .inc is often used for code includes which should in general not be part
+## of the document-root
+url.access-deny = ( "~", ".inc" )
+
+##
+## disable range requests for pdf files
+## workaround for a bug in the Acrobat Reader plugin.
+##
+$HTTP["url"] =~ "\.pdf$" {
+ server.range-requests = "disable"
+}
+
+##
+## url handling modules (rewrite, redirect)
+##
+#url.rewrite = ( "^/$" => "/server-status" )
+#url.redirect = ( "^/wishlist/(.+)" => "http://www.example.com/$1" )
+
+##
+## both rewrite/redirect support back reference to regex conditional using %n
+##
+#$HTTP["host"] =~ "^www\.(.*)" {
+# url.redirect = ( "^/(.*)" => "http://%1/$1" )
+#}
+
+##
+## which extensions should not be handle via static-file transfer
+##
+## .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
+##
+static-file.exclude-extensions = ( ".php", ".pl", ".fcgi", ".scgi" )
+
+##
+## error-handler for status 404
+##
+#server.error-handler-404 = "/error-handler.html"
+#server.error-handler-404 = "/error-handler.php"
+
+##
+## Format: <errorfile-prefix><status-code>.html
+## -> ..../status-404.html for 'File not found'
+##
+#server.errorfile-prefix = "/srv/www/htdocs/errors/status-"
+
+##
+## mimetype mapping
+##
+include "conf.d/mime.conf"
+
+##
+## directory listing configuration
+##
+include "conf.d/dirlisting.conf"
+
+##
+## Should lighttpd follow symlinks?
+##
+server.follow-symlink = "enable"
+
+##
+## force all filenames to be lowercase?
+##
+#server.force-lowercase-filenames = "disable"
+
+##
+## defaults to /var/tmp as we assume it is a local harddisk
+##
+server.upload-dirs = ( "/var/tmp" )
+
+##
+#######################################################################
+
+
+#######################################################################
+##
+## SSL Support
+## -------------
+##
+## To enable SSL for the whole server you have to provide a valid
+## certificate and have to enable the SSL engine.::
+##
+## ssl.engine = "enable"
+## ssl.pemfile = "/path/to/server.pem"
+##
+## The HTTPS protocol does not allow you to use name-based virtual
+## hosting with SSL. If you want to run multiple SSL servers with
+## one lighttpd instance you must use IP-based virtual hosting: ::
+##
+## $SERVER["socket"] == "10.0.0.1:443" {
+## ssl.engine = "enable"
+## ssl.pemfile = "/etc/ssl/private/www.example.com.pem"
+## server.name = "www.example.com"
+##
+## server.document-root = "/srv/www/vhosts/example.com/www/"
+## }
+##
+
+## If you have a .crt and a .key file, cat them together into a
+## single PEM file:
+## $ cat /etc/ssl/private/lighttpd.key /etc/ssl/certs/lighttpd.crt \
+## > /etc/ssl/private/lighttpd.pem
+##
+#ssl.pemfile = "/etc/ssl/private/lighttpd.pem"
+
+##
+## optionally pass the CA certificate here.
+##
+##
+#ssl.ca-file = ""
+
+##
+#######################################################################
+
+#######################################################################
+##
+## custom includes like vhosts.
+##
+#include "conf.d/config.conf"
+#include_shell "cat /etc/lighttpd/vhosts.d/*.conf"
+##
+#######################################################################
diff --git a/doc/config/modules.conf b/doc/config/modules.conf
new file mode 100644
index 0000000..99a3c3f
--- /dev/null
+++ b/doc/config/modules.conf
@@ -0,0 +1,172 @@
+#######################################################################
+##
+## Modules to load
+## -----------------
+##
+## at least mod_access and mod_accesslog should be loaded
+## all other module should only be loaded if really neccesary
+##
+## - saves some time
+## - saves memory
+##
+## the default module set contains:
+##
+## "mod_indexfile", "mod_dirlisting", "mod_staticfile"
+##
+## you dont have to include those modules in your list
+##
+## Modules, which are pulled in via conf.d/*.conf
+##
+## NOTE: the order of modules is important.
+##
+## - mod_accesslog -> conf.d/access_log.conf
+## - mod_compress -> conf.d/compress.conf
+## - mod_status -> conf.d/status.conf
+## - mod_webdav -> conf.d/webdav.conf
+## - mod_cml -> conf.d/cml.conf
+## - mod_evhost -> conf.d/evhost.conf
+## - mod_simple_vhost -> conf.d/simple_vhost.conf
+## - mod_mysql_vhost -> conf.d/mysql_vhost.conf
+## - mod_trigger_b4_dl -> conf.d/trigger_b4_dl.conf
+## - mod_userdir -> conf.d/userdir.conf
+## - mod_rrdtool -> conf.d/rrdtool.conf
+## - mod_ssi -> conf.d/ssi.conf
+## - mod_cgi -> conf.d/cgi.conf
+## - mod_scgi -> conf.d/scgi.conf
+## - mod_fastcgi -> conf.d/fastcgi.conf
+## - mod_proxy -> conf.d/proxy.conf
+## - mod_secdownload -> conf.d/secdownload.conf
+## - mod_expire -> conf.d/expire.conf
+##
+
+server.modules = (
+ "mod_access",
+# "mod_alias",
+# "mod_auth",
+# "mod_evasive",
+# "mod_redirect",
+# "mod_rewrite",
+# "mod_setenv",
+# "mod_usertrack",
+)
+
+##
+#######################################################################
+
+#######################################################################
+##
+## Config for various Modules
+##
+
+##
+## mod_ssi
+##
+#include "conf.d/ssi.conf"
+
+##
+## mod_status
+##
+#include "conf.d/status.conf"
+
+##
+## mod_webdav
+##
+#include "conf.d/webdav.conf"
+
+##
+## mod_compress
+##
+#include "conf.d/compress.conf"
+
+##
+## mod_userdir
+##
+#include "conf.d/userdir.conf"
+
+##
+## mod_magnet
+##
+#include "conf.d/magnet.conf"
+
+##
+## mod_cml
+##
+#include "conf.d/cml.conf"
+
+##
+## mod_rrdtool
+##
+#include "conf.d/rrdtool.conf"
+
+##
+## mod_proxy
+##
+#include "conf.d/proxy.conf"
+
+##
+## mod_expire
+##
+#include "conf.d/expire.conf"
+
+##
+## mod_secdownload
+##
+#include "conf.d/secdownload.conf"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## CGI modules
+##
+
+##
+## SCGI (mod_scgi)
+##
+#include "conf.d/scgi.conf"
+
+##
+## FastCGI (mod_fastcgi)
+##
+#include "conf.d/fastcgi.conf"
+
+##
+## plain old CGI (mod_cgi)
+##
+#include "conf.d/cgi.conf"
+
+##
+#######################################################################
+
+#######################################################################
+##
+## VHost Modules
+##
+## Only load ONE of them!
+## ========================
+##
+
+##
+## You can use conditionals for vhosts aswell.
+##
+## see http://www.lighttpd.net/documentation/configuration.html
+##
+
+##
+## mod_evhost
+##
+#include "conf.d/evhost.conf"
+
+##
+## mod_simple_vhost
+##
+#include "conf.d/simple_vhost.conf"
+
+##
+## mod_mysql_vhost
+##
+#include "conf.d/mysql_vhost.conf"
+
+##
+#######################################################################
diff --git a/doc/config/vhosts.d/Makefile.am b/doc/config/vhosts.d/Makefile.am
new file mode 100644
index 0000000..51d9376
--- /dev/null
+++ b/doc/config/vhosts.d/Makefile.am
@@ -0,0 +1 @@
+EXTRA_DIST=vhosts.template
diff --git a/doc/config/vhosts.d/Makefile.in b/doc/config/vhosts.d/Makefile.in
new file mode 100644
index 0000000..6fe8d8a
--- /dev/null
+++ b/doc/config/vhosts.d/Makefile.in
@@ -0,0 +1,394 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = doc/config/vhosts.d
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo " GEN " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+ATTR_LIB = @ATTR_LIB@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BZ_LIB = @BZ_LIB@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRYPT_LIB = @CRYPT_LIB@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DL_LIB = @DL_LIB@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FAM_CFLAGS = @FAM_CFLAGS@
+FAM_LIBS = @FAM_LIBS@
+FGREP = @FGREP@
+GDBM_LIB = @GDBM_LIB@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LBER_LIB = @LBER_LIB@
+LD = @LD@
+LDAP_LIB = @LDAP_LIB@
+LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LUA_CFLAGS = @LUA_CFLAGS@
+LUA_LIBS = @LUA_LIBS@
+MAKEINFO = @MAKEINFO@
+MEMCACHE_LIB = @MEMCACHE_LIB@
+MKDIR_P = @MKDIR_P@
+MYSQL_CONFIG = @MYSQL_CONFIG@
+MYSQL_INCLUDE = @MYSQL_INCLUDE@
+MYSQL_LIBS = @MYSQL_LIBS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PCRECONFIG = @PCRECONFIG@
+PCRE_LIB = @PCRE_LIB@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SENDFILE_LIB = @SENDFILE_LIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SQLITE_CFLAGS = @SQLITE_CFLAGS@
+SQLITE_LIBS = @SQLITE_LIBS@
+SSL_LIB = @SSL_LIB@
+STRIP = @STRIP@
+U = @U@
+UUID_LIBS = @UUID_LIBS@
+VERSION = @VERSION@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+Z_LIB = @Z_LIB@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = vhosts.template
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/config/vhosts.d/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/config/vhosts.d/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ distclean distclean-generic distclean-libtool distdir dvi \
+ dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-pdf \
+ install-pdf-am install-ps install-ps-am install-strip \
+ installcheck installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/doc/config/vhosts.d/vhosts.template b/doc/config/vhosts.d/vhosts.template
new file mode 100644
index 0000000..2c443aa
--- /dev/null
+++ b/doc/config/vhosts.d/vhosts.template
@@ -0,0 +1,33 @@
+#######################################################################
+##
+## For more examples check:
+##
+## http://www.lighttpd.net/documentation/configuration.html#conditional-configuration
+##
+$HTTP["host"] == "download.example.com" {
+ var.server_name = "download.example.com"
+
+ server.name = server_name
+ ##
+ ## use trigger before download
+ ##
+ include "conf.d/trigger_b4_dl.conf"
+
+ server.document-root = vhosts_dir + "/example.com/download/htdocs"
+ ##
+ ## use a seperate access log file
+ ## At the moment you cant have different error log files.
+ ##
+ accesslog.filename = log_root + "/" + server_name "/access.log"
+}
+
+$SERVER["socket"] == "127.0.0.1:443" {
+ server.name = "localhost"
+ ssl.pemfile = "/etc/ssl/private/lighttpd-localhost.pem"
+ ssl.engine = "enable"
+
+ server.document-root = vhosts_dir + "/ssl-localhost/pages/"
+}
+
+##
+#######################################################################
diff --git a/doc/initscripts/Makefile.am b/doc/initscripts/Makefile.am
new file mode 100644
index 0000000..dfed858
--- /dev/null
+++ b/doc/initscripts/Makefile.am
@@ -0,0 +1 @@
+EXTRA_DIST=rc.lighttpd rc.lighttpd.redhat sysconfig.lighttpd
diff --git a/doc/initscripts/Makefile.in b/doc/initscripts/Makefile.in
new file mode 100644
index 0000000..5bda324
--- /dev/null
+++ b/doc/initscripts/Makefile.in
@@ -0,0 +1,394 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = doc/initscripts
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo " GEN " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+ATTR_LIB = @ATTR_LIB@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BZ_LIB = @BZ_LIB@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRYPT_LIB = @CRYPT_LIB@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DL_LIB = @DL_LIB@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FAM_CFLAGS = @FAM_CFLAGS@
+FAM_LIBS = @FAM_LIBS@
+FGREP = @FGREP@
+GDBM_LIB = @GDBM_LIB@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LBER_LIB = @LBER_LIB@
+LD = @LD@
+LDAP_LIB = @LDAP_LIB@
+LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LUA_CFLAGS = @LUA_CFLAGS@
+LUA_LIBS = @LUA_LIBS@
+MAKEINFO = @MAKEINFO@
+MEMCACHE_LIB = @MEMCACHE_LIB@
+MKDIR_P = @MKDIR_P@
+MYSQL_CONFIG = @MYSQL_CONFIG@
+MYSQL_INCLUDE = @MYSQL_INCLUDE@
+MYSQL_LIBS = @MYSQL_LIBS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PCRECONFIG = @PCRECONFIG@
+PCRE_LIB = @PCRE_LIB@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SENDFILE_LIB = @SENDFILE_LIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SQLITE_CFLAGS = @SQLITE_CFLAGS@
+SQLITE_LIBS = @SQLITE_LIBS@
+SSL_LIB = @SSL_LIB@
+STRIP = @STRIP@
+U = @U@
+UUID_LIBS = @UUID_LIBS@
+VERSION = @VERSION@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+Z_LIB = @Z_LIB@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = rc.lighttpd rc.lighttpd.redhat sysconfig.lighttpd
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/initscripts/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/initscripts/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ distclean distclean-generic distclean-libtool distdir dvi \
+ dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-pdf \
+ install-pdf-am install-ps install-ps-am install-strip \
+ installcheck installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/doc/rc.lighttpd b/doc/initscripts/rc.lighttpd
index da0d244..da0d244 100755
--- a/doc/rc.lighttpd
+++ b/doc/initscripts/rc.lighttpd
diff --git a/doc/rc.lighttpd.redhat b/doc/initscripts/rc.lighttpd.redhat
index e22d551..e22d551 100755
--- a/doc/rc.lighttpd.redhat
+++ b/doc/initscripts/rc.lighttpd.redhat
diff --git a/doc/sysconfig.lighttpd b/doc/initscripts/sysconfig.lighttpd
index c8154c9..c8154c9 100644
--- a/doc/sysconfig.lighttpd
+++ b/doc/initscripts/sysconfig.lighttpd
diff --git a/doc/lighttpd.conf b/doc/lighttpd.conf
deleted file mode 100644
index a3a641f..0000000
--- a/doc/lighttpd.conf
+++ /dev/null
@@ -1,322 +0,0 @@
-# lighttpd configuration file
-#
-# use it as a base for lighttpd 1.0.0 and above
-#
-# $Id: lighttpd.conf,v 1.7 2004/11/03 22:26:05 weigon Exp $
-
-############ Options you really have to take care of ####################
-
-## modules to load
-# at least mod_access and mod_accesslog should be loaded
-# all other module should only be loaded if really neccesary
-# - saves some time
-# - saves memory
-server.modules = (
-# "mod_rewrite",
-# "mod_redirect",
-# "mod_alias",
- "mod_access",
-# "mod_trigger_b4_dl",
-# "mod_auth",
-# "mod_status",
-# "mod_setenv",
-# "mod_fastcgi",
-# "mod_proxy",
-# "mod_simple_vhost",
-# "mod_evhost",
-# "mod_userdir",
-# "mod_cgi",
-# "mod_compress",
-# "mod_ssi",
-# "mod_usertrack",
-# "mod_expire",
-# "mod_secdownload",
-# "mod_rrdtool",
- "mod_accesslog" )
-
-## A static document-root. For virtual hosting take a look at the
-## mod_simple_vhost module.
-server.document-root = "/srv/www/htdocs/"
-
-## where to send error-messages to
-server.errorlog = "/var/log/lighttpd/error.log"
-
-# files to check for if .../ is requested
-index-file.names = ( "index.php", "index.html",
- "index.htm", "default.htm" )
-
-## set the event-handler (read the performance section in the manual)
-# server.event-handler = "freebsd-kqueue" # needed on OS X
-
-# mimetype mapping
-mimetype.assign = (
- ".pdf" => "application/pdf",
- ".sig" => "application/pgp-signature",
- ".spl" => "application/futuresplash",
- ".class" => "application/octet-stream",
- ".ps" => "application/postscript",
- ".torrent" => "application/x-bittorrent",
- ".dvi" => "application/x-dvi",
- ".gz" => "application/x-gzip",
- ".pac" => "application/x-ns-proxy-autoconfig",
- ".swf" => "application/x-shockwave-flash",
- ".tar.gz" => "application/x-tgz",
- ".tgz" => "application/x-tgz",
- ".tar" => "application/x-tar",
- ".zip" => "application/zip",
- ".mp3" => "audio/mpeg",
- ".m3u" => "audio/x-mpegurl",
- ".wma" => "audio/x-ms-wma",
- ".wax" => "audio/x-ms-wax",
- ".ogg" => "application/ogg",
- ".wav" => "audio/x-wav",
- ".gif" => "image/gif",
- ".jar" => "application/x-java-archive",
- ".jpg" => "image/jpeg",
- ".jpeg" => "image/jpeg",
- ".png" => "image/png",
- ".xbm" => "image/x-xbitmap",
- ".xpm" => "image/x-xpixmap",
- ".xwd" => "image/x-xwindowdump",
- ".css" => "text/css",
- ".html" => "text/html",
- ".htm" => "text/html",
- ".js" => "text/javascript",
- ".asc" => "text/plain",
- ".c" => "text/plain",
- ".cpp" => "text/plain",
- ".log" => "text/plain",
- ".conf" => "text/plain",
- ".text" => "text/plain",
- ".txt" => "text/plain",
- ".dtd" => "text/xml",
- ".xml" => "text/xml",
- ".mpeg" => "video/mpeg",
- ".mpg" => "video/mpeg",
- ".mov" => "video/quicktime",
- ".qt" => "video/quicktime",
- ".avi" => "video/x-msvideo",
- ".asf" => "video/x-ms-asf",
- ".asx" => "video/x-ms-asf",
- ".wmv" => "video/x-ms-wmv",
- ".bz2" => "application/x-bzip",
- ".tbz" => "application/x-bzip-compressed-tar",
- ".tar.bz2" => "application/x-bzip-compressed-tar",
- # default mime type
- "" => "application/octet-stream",
- )
-
-# Use the "Content-Type" extended attribute to obtain mime type if possible
-#mimetype.use-xattr = "enable"
-
-
-## send a different Server: header
-## be nice and keep it at lighttpd
-# server.tag = "lighttpd"
-
-#### accesslog module
-accesslog.filename = "/var/log/lighttpd/access.log"
-
-## deny access the file-extensions
-#
-# ~ is for backupfiles from vi, emacs, joe, ...
-# .inc is often used for code includes which should in general not be part
-# of the document-root
-url.access-deny = ( "~", ".inc" )
-
-$HTTP["url"] =~ "\.pdf$" {
- server.range-requests = "disable"
-}
-
-##
-# which extensions should not be handle via static-file transfer
-#
-# .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
-static-file.exclude-extensions = ( ".php", ".pl", ".fcgi" )
-
-######### Options that are good to be but not neccesary to be changed #######
-
-## bind to port (default: 80)
-#server.port = 81
-
-## bind to localhost (default: all interfaces)
-#server.bind = "127.0.0.1"
-
-## error-handler for status 404
-#server.error-handler-404 = "/error-handler.html"
-#server.error-handler-404 = "/error-handler.php"
-
-## to help the rc.scripts
-#server.pid-file = "/var/run/lighttpd.pid"
-
-
-###### virtual hosts
-##
-## If you want name-based virtual hosting add the next three settings and load
-## mod_simple_vhost
-##
-## document-root =
-## virtual-server-root + virtual-server-default-host + virtual-server-docroot
-## or
-## virtual-server-root + http-host + virtual-server-docroot
-##
-#simple-vhost.server-root = "/srv/www/vhosts/"
-#simple-vhost.default-host = "www.example.org"
-#simple-vhost.document-root = "/htdocs/"
-
-
-##
-## Format: <errorfile-prefix><status-code>.html
-## -> ..../status-404.html for 'File not found'
-#server.errorfile-prefix = "/usr/share/lighttpd/errors/status-"
-#server.errorfile-prefix = "/srv/www/errors/status-"
-
-## virtual directory listings
-#dir-listing.activate = "enable"
-## select encoding for directory listings
-#dir-listing.encoding = "utf-8"
-
-## enable debugging
-#debug.log-request-header = "enable"
-#debug.log-response-header = "enable"
-#debug.log-request-handling = "enable"
-#debug.log-file-not-found = "enable"
-
-### only root can use these options
-#
-# chroot() to directory (default: no chroot() )
-#server.chroot = "/"
-
-## change uid to <uid> (default: don't care)
-#server.username = "wwwrun"
-
-## change uid to <uid> (default: don't care)
-#server.groupname = "wwwrun"
-
-#### compress module
-#compress.cache-dir = "/var/cache/lighttpd/compress/"
-#compress.filetype = ("text/plain", "text/html")
-
-#### proxy module
-## read proxy.txt for more info
-#proxy.server = ( ".php" =>
-# ( "localhost" =>
-# (
-# "host" => "192.168.0.101",
-# "port" => 80
-# )
-# )
-# )
-
-#### fastcgi module
-## read fastcgi.txt for more info
-## for PHP don't forget to set cgi.fix_pathinfo = 1 in the php.ini
-#fastcgi.server = ( ".php" =>
-# ( "localhost" =>
-# (
-# "socket" => "/var/run/lighttpd/php-fastcgi.socket",
-# "bin-path" => "/usr/local/bin/php-cgi"
-# )
-# )
-# )
-
-#### CGI module
-#cgi.assign = ( ".pl" => "/usr/bin/perl",
-# ".cgi" => "/usr/bin/perl" )
-#
-
-#### SSL engine
-#ssl.engine = "enable"
-#ssl.pemfile = "/etc/ssl/private/lighttpd.pem"
-
-#### status module
-#status.status-url = "/server-status"
-#status.config-url = "/server-config"
-
-#### auth module
-## read authentication.txt for more info
-#auth.backend = "plain"
-#auth.backend.plain.userfile = "lighttpd.user"
-#auth.backend.plain.groupfile = "lighttpd.group"
-
-#auth.backend.ldap.hostname = "localhost"
-#auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
-#auth.backend.ldap.filter = "(uid=$)"
-
-#auth.require = ( "/server-status" =>
-# (
-# "method" => "digest",
-# "realm" => "download archiv",
-# "require" => "user=jan"
-# ),
-# "/server-config" =>
-# (
-# "method" => "digest",
-# "realm" => "download archiv",
-# "require" => "valid-user"
-# )
-# )
-
-#### url handling modules (rewrite, redirect, access)
-#url.rewrite = ( "^/$" => "/server-status" )
-#url.redirect = ( "^/wishlist/(.+)" => "http://www.123.org/$1" )
-#### both rewrite/redirect support back reference to regex conditional using %n
-#$HTTP["host"] =~ "^www\.(.*)" {
-# url.redirect = ( "^/(.*)" => "http://%1/$1" )
-#}
-
-#
-# define a pattern for the host url finding
-# %% => % sign
-# %0 => domain name + tld
-# %1 => tld
-# %2 => domain name without tld
-# %3 => subdomain 1 name
-# %4 => subdomain 2 name
-#
-#evhost.path-pattern = "/srv/www/vhosts/%3/htdocs/"
-
-#### expire module
-#expire.url = ( "/buggy/" => "access 2 hours", "/asdhas/" => "access plus 1 seconds 2 minutes")
-
-#### ssi
-#ssi.extension = ( ".shtml" )
-
-#### rrdtool
-#rrdtool.binary = "/usr/bin/rrdtool"
-#rrdtool.db-name = "/var/lib/lighttpd/lighttpd.rrd"
-
-#### setenv
-#setenv.add-request-header = ( "TRAV_ENV" => "mysql://user@host/db" )
-#setenv.add-response-header = ( "X-Secret-Message" => "42" )
-
-## for mod_trigger_b4_dl
-# trigger-before-download.gdbm-filename = "/var/lib/lighttpd/trigger.db"
-# trigger-before-download.memcache-hosts = ( "127.0.0.1:11211" )
-# trigger-before-download.trigger-url = "^/trigger/"
-# trigger-before-download.download-url = "^/download/"
-# trigger-before-download.deny-url = "http://127.0.0.1/index.html"
-# trigger-before-download.trigger-timeout = 10
-
-#### variable usage:
-## variable name without "." is auto prefixed by "var." and becomes "var.bar"
-#bar = 1
-#var.mystring = "foo"
-
-## integer add
-#bar += 1
-## string concat, with integer cast as string, result: "www.foo1.com"
-#server.name = "www." + mystring + var.bar + ".com"
-## array merge
-#index-file.names = (foo + ".php") + index-file.names
-#index-file.names += (foo + ".php")
-
-#### include
-#include /etc/lighttpd/lighttpd-inc.conf
-## same as above if you run: "lighttpd -f /etc/lighttpd/lighttpd.conf"
-#include "lighttpd-inc.conf"
-
-#### include_shell
-#include_shell "echo var.a=1"
-## the above is same as:
-#var.a=1
diff --git a/doc/lighttpd.user b/doc/lighttpd.user
deleted file mode 100644
index 727e9c3..0000000
--- a/doc/lighttpd.user
+++ /dev/null
@@ -1 +0,0 @@
-dummy:test123
diff --git a/doc/scripts/Makefile.am b/doc/scripts/Makefile.am
new file mode 100644
index 0000000..08aaa25
--- /dev/null
+++ b/doc/scripts/Makefile.am
@@ -0,0 +1,3 @@
+EXTRA_DIST= \
+ rrdtool-graph.sh \
+ spawn-php.sh
diff --git a/doc/scripts/Makefile.in b/doc/scripts/Makefile.in
new file mode 100644
index 0000000..f3da67d
--- /dev/null
+++ b/doc/scripts/Makefile.in
@@ -0,0 +1,397 @@
+# Makefile.in generated by automake 1.11.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
+# Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+subdir = doc/scripts
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_GEN = $(am__v_GEN_$(V))
+am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY))
+am__v_GEN_0 = @echo " GEN " $@;
+AM_V_at = $(am__v_at_$(V))
+am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY))
+am__v_at_0 = @
+SOURCES =
+DIST_SOURCES =
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+ATTR_LIB = @ATTR_LIB@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+BZ_LIB = @BZ_LIB@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CRYPT_LIB = @CRYPT_LIB@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DL_LIB = @DL_LIB@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FAM_CFLAGS = @FAM_CFLAGS@
+FAM_LIBS = @FAM_LIBS@
+FGREP = @FGREP@
+GDBM_LIB = @GDBM_LIB@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LBER_LIB = @LBER_LIB@
+LD = @LD@
+LDAP_LIB = @LDAP_LIB@
+LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LUA_CFLAGS = @LUA_CFLAGS@
+LUA_LIBS = @LUA_LIBS@
+MAKEINFO = @MAKEINFO@
+MEMCACHE_LIB = @MEMCACHE_LIB@
+MKDIR_P = @MKDIR_P@
+MYSQL_CONFIG = @MYSQL_CONFIG@
+MYSQL_INCLUDE = @MYSQL_INCLUDE@
+MYSQL_LIBS = @MYSQL_LIBS@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PCRECONFIG = @PCRECONFIG@
+PCRE_LIB = @PCRE_LIB@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SENDFILE_LIB = @SENDFILE_LIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+SQLITE_CFLAGS = @SQLITE_CFLAGS@
+SQLITE_LIBS = @SQLITE_LIBS@
+SSL_LIB = @SSL_LIB@
+STRIP = @STRIP@
+U = @U@
+UUID_LIBS = @UUID_LIBS@
+VERSION = @VERSION@
+XML_CFLAGS = @XML_CFLAGS@
+XML_LIBS = @XML_LIBS@
+Z_LIB = @Z_LIB@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_ECHO = @lt_ECHO@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_os = @target_os@
+target_vendor = @target_vendor@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ rrdtool-graph.sh \
+ spawn-php.sh
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/scripts/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/scripts/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags: TAGS
+TAGS:
+
+ctags: CTAGS
+CTAGS:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ distclean distclean-generic distclean-libtool distdir dvi \
+ dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-pdf \
+ install-pdf-am install-ps install-ps-am install-strip \
+ installcheck installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/doc/rrdtool-graph.sh b/doc/scripts/rrdtool-graph.sh
index 1157a28..1157a28 100755
--- a/doc/rrdtool-graph.sh
+++ b/doc/scripts/rrdtool-graph.sh
diff --git a/doc/spawn-php.sh b/doc/scripts/spawn-php.sh
index 181eae2..181eae2 100755
--- a/doc/spawn-php.sh
+++ b/doc/scripts/spawn-php.sh
diff --git a/src/Makefile.am b/src/Makefile.am
index 328931b..e675dc0 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -19,7 +19,7 @@ versionstamp:
REVISION=""; \
fi; \
fi; \
- if test -z "$$REVISION" -a -x "`which git`"; then \
+ if test -z "$$REVISION" -a -d "$(top_srcdir)/.git" -a -x "`which git`"; then \
REVISION="$$(cd "$(top_srcdir)"; LANG= LC_ALL=C git describe --always 2>/dev/null || echo)"; \
fi; \
if test -n "$$REVISION"; then \
@@ -62,7 +62,7 @@ common_src=buffer.c log.c \
stat_cache.c plugin.c joblist.c etag.c array.c \
data_string.c data_count.c data_array.c \
data_integer.c md5.c data_fastcgi.c \
- fdevent_select.c fdevent_linux_rtsig.c \
+ fdevent_select.c fdevent_libev.c \
fdevent_poll.c fdevent_linux_sysepoll.c \
fdevent_solaris_devpoll.c fdevent_freebsd_kqueue.c \
data_config.c bitset.c \
@@ -86,9 +86,9 @@ if NO_RDYNAMIC
# everything
lib_LTLIBRARIES += liblightcomp.la
liblightcomp_la_SOURCES=$(common_src)
-liblightcomp_la_CFLAGS=$(AM_CFLAGS)
+liblightcomp_la_CFLAGS=$(AM_CFLAGS) $(LIBEV_CFLAGS)
liblightcomp_la_LDFLAGS = -avoid-version -no-undefined
-liblightcomp_la_LIBADD = $(PCRE_LIB) $(SSL_LIB) $(FAM_LIBS)
+liblightcomp_la_LIBADD = $(PCRE_LIB) $(SSL_LIB) $(FAM_LIBS) $(LIBEV_LIBS)
common_libadd = liblightcomp.la
else
src += $(common_src)
@@ -283,9 +283,9 @@ hdr = server.h buffer.h network.h log.h keyvalue.h \
DEFS= @DEFS@ -DHAVE_VERSION_H -DLIBRARY_DIR="\"$(libdir)\"" -DSBIN_DIR="\"$(sbindir)\""
lighttpd_SOURCES = $(src)
-lighttpd_LDADD = $(PCRE_LIB) $(DL_LIB) $(SENDFILE_LIB) $(ATTR_LIB) $(common_libadd) $(SSL_LIB) $(FAM_LIBS)
+lighttpd_LDADD = $(PCRE_LIB) $(DL_LIB) $(SENDFILE_LIB) $(ATTR_LIB) $(common_libadd) $(SSL_LIB) $(FAM_LIBS) $(LIBEV_LIBS)
lighttpd_LDFLAGS = -export-dynamic
-lighttpd_CCPFLAGS = $(FAM_CFLAGS)
+lighttpd_CCPFLAGS = $(FAM_CFLAGS) $(LIBEV_CFLAGS)
proc_open_SOURCES = proc_open.c buffer.c
proc_open_CPPFLAGS= -DDEBUG_PROC_OPEN
diff --git a/src/Makefile.in b/src/Makefile.in
index 1af1f5f..5b7cb63 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -85,12 +85,12 @@ LTLIBRARIES = $(lib_LTLIBRARIES)
am__DEPENDENCIES_1 =
@NO_RDYNAMIC_TRUE@liblightcomp_la_DEPENDENCIES = \
@NO_RDYNAMIC_TRUE@ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
-@NO_RDYNAMIC_TRUE@ $(am__DEPENDENCIES_1)
+@NO_RDYNAMIC_TRUE@ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
am__liblightcomp_la_SOURCES_DIST = buffer.c log.c keyvalue.c chunk.c \
http_chunk.c stream.c fdevent.c stat_cache.c plugin.c \
joblist.c etag.c array.c data_string.c data_count.c \
data_array.c data_integer.c md5.c data_fastcgi.c \
- fdevent_select.c fdevent_linux_rtsig.c fdevent_poll.c \
+ fdevent_select.c fdevent_libev.c fdevent_poll.c \
fdevent_linux_sysepoll.c fdevent_solaris_devpoll.c \
fdevent_freebsd_kqueue.c data_config.c bitset.c \
inet_ntop_cache.c crc32.c connections-glue.c configfile-glue.c \
@@ -108,7 +108,7 @@ am__objects_1 = liblightcomp_la-buffer.lo liblightcomp_la-log.lo \
liblightcomp_la-data_array.lo liblightcomp_la-data_integer.lo \
liblightcomp_la-md5.lo liblightcomp_la-data_fastcgi.lo \
liblightcomp_la-fdevent_select.lo \
- liblightcomp_la-fdevent_linux_rtsig.lo \
+ liblightcomp_la-fdevent_libev.lo \
liblightcomp_la-fdevent_poll.lo \
liblightcomp_la-fdevent_linux_sysepoll.lo \
liblightcomp_la-fdevent_solaris_devpoll.lo \
@@ -370,12 +370,11 @@ am__lighttpd_SOURCES_DIST = server.c response.c connections.c \
buffer.c log.c keyvalue.c chunk.c http_chunk.c stream.c \
fdevent.c stat_cache.c plugin.c joblist.c etag.c array.c \
data_string.c data_count.c data_array.c data_integer.c md5.c \
- data_fastcgi.c fdevent_select.c fdevent_linux_rtsig.c \
- fdevent_poll.c fdevent_linux_sysepoll.c \
- fdevent_solaris_devpoll.c fdevent_freebsd_kqueue.c \
- data_config.c bitset.c inet_ntop_cache.c crc32.c \
- connections-glue.c configfile-glue.c http-header-glue.c \
- network_write.c network_linux_sendfile.c \
+ data_fastcgi.c fdevent_select.c fdevent_libev.c fdevent_poll.c \
+ fdevent_linux_sysepoll.c fdevent_solaris_devpoll.c \
+ fdevent_freebsd_kqueue.c data_config.c bitset.c \
+ inet_ntop_cache.c crc32.c connections-glue.c configfile-glue.c \
+ http-header-glue.c network_write.c network_linux_sendfile.c \
network_freebsd_sendfile.c network_writev.c \
network_solaris_sendfilev.c network_openssl.c splaytree.c \
status_counter.c
@@ -386,7 +385,7 @@ am__objects_2 = buffer.$(OBJEXT) log.$(OBJEXT) keyvalue.$(OBJEXT) \
data_string.$(OBJEXT) data_count.$(OBJEXT) \
data_array.$(OBJEXT) data_integer.$(OBJEXT) md5.$(OBJEXT) \
data_fastcgi.$(OBJEXT) fdevent_select.$(OBJEXT) \
- fdevent_linux_rtsig.$(OBJEXT) fdevent_poll.$(OBJEXT) \
+ fdevent_libev.$(OBJEXT) fdevent_poll.$(OBJEXT) \
fdevent_linux_sysepoll.$(OBJEXT) \
fdevent_solaris_devpoll.$(OBJEXT) \
fdevent_freebsd_kqueue.$(OBJEXT) data_config.$(OBJEXT) \
@@ -407,7 +406,7 @@ lighttpd_OBJECTS = $(am_lighttpd_OBJECTS)
lighttpd_DEPENDENCIES = $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
$(am__DEPENDENCIES_2) $(am__DEPENDENCIES_1) \
- $(am__DEPENDENCIES_1)
+ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
lighttpd_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
$(lighttpd_LDFLAGS) $(LDFLAGS) -o $@
@@ -526,6 +525,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -557,6 +558,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
@@ -641,7 +644,7 @@ common_src = buffer.c log.c \
stat_cache.c plugin.c joblist.c etag.c array.c \
data_string.c data_count.c data_array.c \
data_integer.c md5.c data_fastcgi.c \
- fdevent_select.c fdevent_linux_rtsig.c \
+ fdevent_select.c fdevent_libev.c \
fdevent_poll.c fdevent_linux_sysepoll.c \
fdevent_solaris_devpoll.c fdevent_freebsd_kqueue.c \
data_config.c bitset.c \
@@ -671,9 +674,9 @@ lib_LTLIBRARIES = $(am__append_1) mod_flv_streaming.la mod_evasive.la \
mod_access.la mod_compress.la mod_auth.la mod_rewrite.la \
mod_redirect.la mod_status.la mod_accesslog.la
@NO_RDYNAMIC_TRUE@liblightcomp_la_SOURCES = $(common_src)
-@NO_RDYNAMIC_TRUE@liblightcomp_la_CFLAGS = $(AM_CFLAGS)
+@NO_RDYNAMIC_TRUE@liblightcomp_la_CFLAGS = $(AM_CFLAGS) $(LIBEV_CFLAGS)
@NO_RDYNAMIC_TRUE@liblightcomp_la_LDFLAGS = -avoid-version -no-undefined
-@NO_RDYNAMIC_TRUE@liblightcomp_la_LIBADD = $(PCRE_LIB) $(SSL_LIB) $(FAM_LIBS)
+@NO_RDYNAMIC_TRUE@liblightcomp_la_LIBADD = $(PCRE_LIB) $(SSL_LIB) $(FAM_LIBS) $(LIBEV_LIBS)
@NO_RDYNAMIC_FALSE@common_libadd =
@NO_RDYNAMIC_TRUE@common_libadd = liblightcomp.la
mod_flv_streaming_la_SOURCES = mod_flv_streaming.c
@@ -792,9 +795,9 @@ hdr = server.h buffer.h network.h log.h keyvalue.h \
version.h
lighttpd_SOURCES = $(src)
-lighttpd_LDADD = $(PCRE_LIB) $(DL_LIB) $(SENDFILE_LIB) $(ATTR_LIB) $(common_libadd) $(SSL_LIB) $(FAM_LIBS)
+lighttpd_LDADD = $(PCRE_LIB) $(DL_LIB) $(SENDFILE_LIB) $(ATTR_LIB) $(common_libadd) $(SSL_LIB) $(FAM_LIBS) $(LIBEV_LIBS)
lighttpd_LDFLAGS = -export-dynamic
-lighttpd_CCPFLAGS = $(FAM_CFLAGS)
+lighttpd_CCPFLAGS = $(FAM_CFLAGS) $(LIBEV_CFLAGS)
proc_open_SOURCES = proc_open.c buffer.c
proc_open_CPPFLAGS = -DDEBUG_PROC_OPEN
@@ -1034,7 +1037,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/etag.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_freebsd_kqueue.Po@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_linux_rtsig.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_libev.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_linux_sysepoll.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_poll.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/fdevent_select.Po@am__quote@
@@ -1063,7 +1066,7 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-etag.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_freebsd_kqueue.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_linux_rtsig.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_libev.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_linux_sysepoll.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_poll.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liblightcomp_la-fdevent_select.Plo@am__quote@
@@ -1321,13 +1324,13 @@ liblightcomp_la-fdevent_select.lo: fdevent_select.c
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -c -o liblightcomp_la-fdevent_select.lo `test -f 'fdevent_select.c' || echo '$(srcdir)/'`fdevent_select.c
-liblightcomp_la-fdevent_linux_rtsig.lo: fdevent_linux_rtsig.c
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -MT liblightcomp_la-fdevent_linux_rtsig.lo -MD -MP -MF $(DEPDIR)/liblightcomp_la-fdevent_linux_rtsig.Tpo -c -o liblightcomp_la-fdevent_linux_rtsig.lo `test -f 'fdevent_linux_rtsig.c' || echo '$(srcdir)/'`fdevent_linux_rtsig.c
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/liblightcomp_la-fdevent_linux_rtsig.Tpo $(DEPDIR)/liblightcomp_la-fdevent_linux_rtsig.Plo
+liblightcomp_la-fdevent_libev.lo: fdevent_libev.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -MT liblightcomp_la-fdevent_libev.lo -MD -MP -MF $(DEPDIR)/liblightcomp_la-fdevent_libev.Tpo -c -o liblightcomp_la-fdevent_libev.lo `test -f 'fdevent_libev.c' || echo '$(srcdir)/'`fdevent_libev.c
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/liblightcomp_la-fdevent_libev.Tpo $(DEPDIR)/liblightcomp_la-fdevent_libev.Plo
@am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='fdevent_linux_rtsig.c' object='liblightcomp_la-fdevent_linux_rtsig.lo' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='fdevent_libev.c' object='liblightcomp_la-fdevent_libev.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -c -o liblightcomp_la-fdevent_linux_rtsig.lo `test -f 'fdevent_linux_rtsig.c' || echo '$(srcdir)/'`fdevent_linux_rtsig.c
+@am__fastdepCC_FALSE@ $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -c -o liblightcomp_la-fdevent_libev.lo `test -f 'fdevent_libev.c' || echo '$(srcdir)/'`fdevent_libev.c
liblightcomp_la-fdevent_poll.lo: fdevent_poll.c
@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liblightcomp_la_CFLAGS) $(CFLAGS) -MT liblightcomp_la-fdevent_poll.lo -MD -MP -MF $(DEPDIR)/liblightcomp_la-fdevent_poll.Tpo -c -o liblightcomp_la-fdevent_poll.lo `test -f 'fdevent_poll.c' || echo '$(srcdir)/'`fdevent_poll.c
@@ -1795,7 +1798,7 @@ versionstamp:
REVISION=""; \
fi; \
fi; \
- if test -z "$$REVISION" -a -x "`which git`"; then \
+ if test -z "$$REVISION" -a -d "$(top_srcdir)/.git" -a -x "`which git`"; then \
REVISION="$$(cd "$(top_srcdir)"; LANG= LC_ALL=C git describe --always 2>/dev/null || echo)"; \
fi; \
if test -n "$$REVISION"; then \
diff --git a/src/SConscript b/src/SConscript
index 40bdb7c..1d1592e 100644
--- a/src/SConscript
+++ b/src/SConscript
@@ -10,7 +10,7 @@ common_src = Split("buffer.c log.c \
stat_cache.c plugin.c joblist.c etag.c array.c \
data_string.c data_count.c data_array.c \
data_integer.c md5.c data_fastcgi.c \
- fdevent_select.c fdevent_linux_rtsig.c \
+ fdevent_select.c fdevent_libev.c \
fdevent_poll.c fdevent_linux_sysepoll.c \
fdevent_solaris_devpoll.c fdevent_freebsd_kqueue.c \
data_config.c bitset.c \
diff --git a/src/array.c b/src/array.c
index e93906b..05568b3 100644
--- a/src/array.c
+++ b/src/array.c
@@ -130,20 +130,21 @@ data_unset *array_get_element(array *a, const char *key) {
data_unset *array_get_unused_element(array *a, data_type_t t) {
data_unset *ds = NULL;
+ unsigned int i;
- UNUSED(t);
+ for (i = a->used; i < a->size; i++) {
+ if (a->data[i] && a->data[i]->type == t) {
+ ds = a->data[i];
- if (a->size == 0) return NULL;
+ /* make empty slot at a->used for next insert */
+ a->data[i] = a->data[a->used];
+ a->data[a->used] = NULL;
- if (a->used == a->size) return NULL;
-
- if (a->data[a->used]) {
- ds = a->data[a->used];
-
- a->data[a->used] = NULL;
+ return ds;
+ }
}
- return ds;
+ return NULL;
}
void array_set_key_value(array *hdrs, const char *key, size_t key_len, const char *value, size_t val_len) {
@@ -194,7 +195,7 @@ int array_insert_unique(array *a, data_unset *str) {
if (a->data[ndx]->type == str->type) {
str->insert_dup(a->data[ndx], str);
} else {
- fprintf(stderr, "a\n");
+ SEGFAULT();
}
return 0;
}
@@ -224,6 +225,9 @@ int array_insert_unique(array *a, data_unset *str) {
ndx = (int) a->used;
+ /* make sure there is nothing here */
+ if (a->data[ndx]) a->data[ndx]->free(a->data[ndx]);
+
a->data[a->used++] = str;
if (pos != ndx &&
diff --git a/src/base.h b/src/base.h
index 4243bd2..8278c7e 100644
--- a/src/base.h
+++ b/src/base.h
@@ -282,7 +282,7 @@ typedef struct {
buffer *ssl_verifyclient_username;
unsigned short ssl_verifyclient_export_cert;
- unsigned short use_ipv6;
+ unsigned short use_ipv6, set_v6only; /* set_v6only is only a temporary option */
unsigned short defer_accept;
unsigned short is_ssl;
unsigned short allow_http11;
diff --git a/src/buffer.h b/src/buffer.h
index 67a47ab..bda0424 100644
--- a/src/buffer.h
+++ b/src/buffer.h
@@ -9,6 +9,7 @@
#include <stdlib.h>
#include <sys/types.h>
+#include <stdio.h>
typedef struct {
char *ptr;
diff --git a/src/configfile.c b/src/configfile.c
index 3037185..0ee96b6 100644
--- a/src/configfile.c
+++ b/src/configfile.c
@@ -100,6 +100,9 @@ static int config_insert(server *srv) {
{ "ssl.verifyclient.depth", NULL, T_CONFIG_SHORT, T_CONFIG_SCOPE_SERVER }, /* 58 */
{ "ssl.verifyclient.username", NULL, T_CONFIG_STRING, T_CONFIG_SCOPE_SERVER }, /* 59 */
{ "ssl.verifyclient.exportcert", NULL, T_CONFIG_BOOLEAN, T_CONFIG_SCOPE_SERVER }, /* 60 */
+
+ { "server.set-v6only", NULL, T_CONFIG_BOOLEAN, T_CONFIG_SCOPE_CONNECTION }, /* 61 */
+
{ "server.host", "use server.bind instead", T_CONFIG_DEPRECATED, T_CONFIG_SCOPE_UNSET },
{ "server.docroot", "use server.document-root instead", T_CONFIG_DEPRECATED, T_CONFIG_SCOPE_UNSET },
{ "server.virtual-root", "load mod_simple_vhost and use simple-vhost.server-root instead", T_CONFIG_DEPRECATED, T_CONFIG_SCOPE_UNSET },
@@ -170,6 +173,7 @@ static int config_insert(server *srv) {
s->is_ssl = 0;
s->ssl_use_sslv2 = 0;
s->use_ipv6 = 0;
+ s->set_v6only = 1;
s->defer_accept = 0;
#ifdef HAVE_LSTAT
s->follow_symlink = 1;
@@ -180,7 +184,7 @@ static int config_insert(server *srv) {
s->etag_use_mtime = 1;
s->etag_use_size = 1;
s->range_requests = 1;
- s->force_lowercase_filenames = 0;
+ s->force_lowercase_filenames = (i == 0) ? 2 : 0; /* we wan't to detect later if user changed this for global section */
s->global_kbytes_per_second = 0;
s->global_bytes_per_second_cnt = 0;
s->global_bytes_per_second_cnt_ptr = &s->global_bytes_per_second_cnt;
@@ -194,6 +198,7 @@ static int config_insert(server *srv) {
cv[7].destination = s->server_tag;
cv[8].destination = &(s->use_ipv6);
+ cv[61].destination = &(s->set_v6only);
cv[54].destination = &(s->defer_accept);
@@ -1171,9 +1176,8 @@ int config_set_defaults(server *srv) {
struct ev_map { fdevent_handler_t et; const char *name; } event_handlers[] =
{
- /* - poll is most reliable
+ /* - epoll is most reliable
* - select works everywhere
- * - linux-* are experimental
*/
#ifdef USE_LINUX_EPOLL
{ FDEVENT_HANDLER_LINUX_SYSEPOLL, "linux-sysepoll" },
@@ -1184,8 +1188,8 @@ int config_set_defaults(server *srv) {
#ifdef USE_SELECT
{ FDEVENT_HANDLER_SELECT, "select" },
#endif
-#ifdef USE_LINUX_SIGIO
- { FDEVENT_HANDLER_LINUX_RTSIG, "linux-rtsig" },
+#ifdef USE_LIBEV
+ { FDEVENT_HANDLER_LIBEV, "libev" },
#endif
#ifdef USE_SOLARIS_DEVPOLL
{ FDEVENT_HANDLER_SOLARIS_DEVPOLL,"solaris-devpoll" },
@@ -1230,35 +1234,39 @@ int config_set_defaults(server *srv) {
buffer_to_lower(srv->tmp_buf);
- if (0 == stat(srv->tmp_buf->ptr, &st1)) {
- int is_lower = 0;
+ if (2 == s->force_lowercase_filenames) { /* user didn't configure it in global section? */
+ s->force_lowercase_filenames = 0; /* default to 0 */
- is_lower = buffer_is_equal(srv->tmp_buf, s->document_root);
+ if (0 == stat(srv->tmp_buf->ptr, &st1)) {
+ int is_lower = 0;
- /* lower-case existed, check upper-case */
- buffer_copy_string_buffer(srv->tmp_buf, s->document_root);
+ is_lower = buffer_is_equal(srv->tmp_buf, s->document_root);
- buffer_to_upper(srv->tmp_buf);
+ /* lower-case existed, check upper-case */
+ buffer_copy_string_buffer(srv->tmp_buf, s->document_root);
- /* we have to handle the special case that upper and lower-casing results in the same filename
- * as in server.document-root = "/" or "/12345/" */
+ buffer_to_upper(srv->tmp_buf);
- if (is_lower && buffer_is_equal(srv->tmp_buf, s->document_root)) {
- /* lower-casing and upper-casing didn't result in
- * an other filename, no need to stat(),
- * just assume it is case-sensitive. */
+ /* we have to handle the special case that upper and lower-casing results in the same filename
+ * as in server.document-root = "/" or "/12345/" */
- s->force_lowercase_filenames = 0;
- } else if (0 == stat(srv->tmp_buf->ptr, &st2)) {
+ if (is_lower && buffer_is_equal(srv->tmp_buf, s->document_root)) {
+ /* lower-casing and upper-casing didn't result in
+ * an other filename, no need to stat(),
+ * just assume it is case-sensitive. */
- /* upper case exists too, doesn't the FS handle this ? */
+ s->force_lowercase_filenames = 0;
+ } else if (0 == stat(srv->tmp_buf->ptr, &st2)) {
- /* upper and lower have the same inode -> case-insensitve FS */
+ /* upper case exists too, doesn't the FS handle this ? */
- if (st1.st_ino == st2.st_ino) {
/* upper and lower have the same inode -> case-insensitve FS */
- s->force_lowercase_filenames = 1;
+ if (st1.st_ino == st2.st_ino) {
+ /* upper and lower have the same inode -> case-insensitve FS */
+
+ s->force_lowercase_filenames = 1;
+ }
}
}
}
diff --git a/src/connections.c b/src/connections.c
index 27e9a98..95c1cda 100644
--- a/src/connections.c
+++ b/src/connections.c
@@ -82,6 +82,11 @@ static int connection_del(server *srv, connection *con) {
if (-1 == con->ndx) return -1;
+ buffer_reset(con->uri.authority);
+ buffer_reset(con->uri.path);
+ buffer_reset(con->uri.query);
+ buffer_reset(con->request.orig_uri);
+
i = con->ndx;
/* not last element */
@@ -305,6 +310,8 @@ static int connection_handle_read_ssl(server *srv, connection *con) {
/* the other end close the connection -> KEEP-ALIVE */
return -2;
+ } else {
+ joblist_append(srv, con);
}
return 0;
@@ -315,6 +322,7 @@ static int connection_handle_read_ssl(server *srv, connection *con) {
#endif
}
+/* 0: everything ok, -1: error, -2: con closed */
static int connection_handle_read(server *srv, connection *con) {
int len;
buffer *b;
@@ -1169,21 +1177,25 @@ found_header_end:
return 0;
}
-static handler_t connection_handle_fdevent(void *s, void *context, int revents) {
- server *srv = (server *)s;
+static handler_t connection_handle_fdevent(server *srv, void *context, int revents) {
connection *con = context;
joblist_append(srv, con);
- if (revents & FDEVENT_IN) {
- con->is_readable = 1;
-#if 0
- log_error_write(srv, __FILE__, __LINE__, "sd", "read-wait - done", con->fd);
-#endif
- }
- if (revents & FDEVENT_OUT) {
- con->is_writable = 1;
- /* we don't need the event twice */
+ if (con->conf.is_ssl) {
+ /* ssl may read and write for both reads and writes */
+ if (revents & (FDEVENT_IN | FDEVENT_OUT)) {
+ con->is_readable = 1;
+ con->is_writable = 1;
+ }
+ } else {
+ if (revents & FDEVENT_IN) {
+ con->is_readable = 1;
+ }
+ if (revents & FDEVENT_OUT) {
+ con->is_writable = 1;
+ /* we don't need the event twice */
+ }
}
@@ -1694,7 +1706,7 @@ int connection_state_machine(server *srv, connection *con) {
ssl_r, ret,
ERR_error_string(err, NULL));
} while((err = ERR_get_error()));
- } else {
+ } else if (errno != 0) { /* ssl bug (see lighttpd ticket #2213): sometimes errno == 0 */
log_error_write(srv, __FILE__, __LINE__, "sddds", "SSL (error):",
ssl_r, ret, errno,
strerror(errno));
@@ -1780,7 +1792,7 @@ int connection_state_machine(server *srv, connection *con) {
case CON_STATE_READ_POST:
case CON_STATE_READ:
case CON_STATE_CLOSE:
- fdevent_event_add(srv->ev, &(con->fde_ndx), con->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(con->fde_ndx), con->fd, FDEVENT_IN);
break;
case CON_STATE_WRITE:
/* request write-fdevent only if we really need it
@@ -1790,7 +1802,7 @@ int connection_state_machine(server *srv, connection *con) {
if (!chunkqueue_is_empty(con->write_queue) &&
(con->is_writable == 0) &&
(con->traffic_limit_reached == 0)) {
- fdevent_event_add(srv->ev, &(con->fde_ndx), con->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(con->fde_ndx), con->fd, FDEVENT_OUT);
} else {
fdevent_event_del(srv->ev, &(con->fde_ndx), con->fd);
}
diff --git a/src/data_string.c b/src/data_string.c
index 919550b..7648946 100644
--- a/src/data_string.c
+++ b/src/data_string.c
@@ -69,9 +69,26 @@ static int data_response_insert_dup(data_unset *dst, data_unset *src) {
static void data_string_print(const data_unset *d, int depth) {
data_string *ds = (data_string *)d;
+ unsigned int i;
UNUSED(depth);
- fprintf(stdout, "\"%s\"", ds->value->used ? ds->value->ptr : "");
+ /* empty and uninitialized strings */
+ if (ds->value->used < 1) {
+ fputs("\"\"", stdout);
+ return;
+ }
+
+ /* print out the string as is, except prepend " with backslash */
+ putc('"', stdout);
+ for (i = 0; i < ds->value->used - 1; i++) {
+ unsigned char c = ds->value->ptr[i];
+ if (c == '"') {
+ fputs("\\\"", stdout);
+ } else {
+ putc(c, stdout);
+ }
+ }
+ putc('"', stdout);
}
diff --git a/src/etag.c b/src/etag.c
index 9ff585f..e7e9e3f 100644
--- a/src/etag.c
+++ b/src/etag.c
@@ -44,7 +44,7 @@ int etag_mutate(buffer *mut, buffer *etag) {
buffer_reset(mut);
buffer_copy_string_len(mut, CONST_STR_LEN("\""));
- buffer_append_long(mut, h);
+ buffer_append_off_t(mut, h);
buffer_append_string_len(mut, CONST_STR_LEN("\""));
return 0;
diff --git a/src/fdevent.c b/src/fdevent.c
index de9ee91..5f24b16 100644
--- a/src/fdevent.c
+++ b/src/fdevent.c
@@ -1,5 +1,5 @@
-#include "fdevent.h"
-#include "buffer.h"
+#include "base.h"
+#include "log.h"
#include <sys/types.h>
@@ -9,66 +9,68 @@
#include <errno.h>
#include <stdio.h>
#include <fcntl.h>
+#include <assert.h>
-fdevents *fdevent_init(size_t maxfds, fdevent_handler_t type) {
+fdevents *fdevent_init(server *srv, size_t maxfds, fdevent_handler_t type) {
fdevents *ev;
ev = calloc(1, sizeof(*ev));
+ ev->srv = srv;
ev->fdarray = calloc(maxfds, sizeof(*ev->fdarray));
ev->maxfds = maxfds;
switch(type) {
case FDEVENT_HANDLER_POLL:
if (0 != fdevent_poll_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler poll failed\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler poll failed");
return NULL;
}
- break;
+ return ev;
case FDEVENT_HANDLER_SELECT:
if (0 != fdevent_select_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler select failed\n",
- __FILE__, __LINE__);
- return NULL;
- }
- break;
- case FDEVENT_HANDLER_LINUX_RTSIG:
- if (0 != fdevent_linux_rtsig_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler linux-rtsig failed, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler select failed");
return NULL;
}
- break;
+ return ev;
case FDEVENT_HANDLER_LINUX_SYSEPOLL:
if (0 != fdevent_linux_sysepoll_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler linux-sysepoll failed, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler linux-sysepoll failed, try to set server.event-handler = \"poll\" or \"select\"");
return NULL;
}
- break;
+ return ev;
case FDEVENT_HANDLER_SOLARIS_DEVPOLL:
if (0 != fdevent_solaris_devpoll_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler solaris-devpoll failed, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler solaris-devpoll failed, try to set server.event-handler = \"poll\" or \"select\"");
return NULL;
}
- break;
+ return ev;
case FDEVENT_HANDLER_FREEBSD_KQUEUE:
if (0 != fdevent_freebsd_kqueue_init(ev)) {
- fprintf(stderr, "%s.%d: event-handler freebsd-kqueue failed, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler freebsd-kqueue failed, try to set server.event-handler = \"poll\" or \"select\"");
+ return NULL;
+ }
+ return ev;
+ case FDEVENT_HANDLER_LIBEV:
+ if (0 != fdevent_libev_init(ev)) {
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler libev failed, try to set server.event-handler = \"poll\" or \"select\"");
return NULL;
}
+ return ev;
+ case FDEVENT_HANDLER_UNSET:
break;
- default:
- fprintf(stderr, "%s.%d: event-handler is unknown, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
- return NULL;
}
- return ev;
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "event-handler is unknown, try to set server.event-handler = \"poll\" or \"select\"");
+ return NULL;
}
void fdevent_free(fdevents *ev) {
@@ -110,6 +112,8 @@ int fdevent_register(fdevents *ev, int fd, fdevent_handler handler, void *ctx) {
fdn->handler = handler;
fdn->fd = fd;
fdn->ctx = ctx;
+ fdn->handler_ctx = NULL;
+ fdn->events = 0;
ev->fdarray[fd] = fdn;
@@ -118,9 +122,12 @@ int fdevent_register(fdevents *ev, int fd, fdevent_handler handler, void *ctx) {
int fdevent_unregister(fdevents *ev, int fd) {
fdnode *fdn;
- if (!ev) return 0;
+
+ if (!ev) return 0;
fdn = ev->fdarray[fd];
+ assert(fdn->events == 0);
+
fdnode_free(fdn);
ev->fdarray[fd] = NULL;
@@ -131,17 +138,21 @@ int fdevent_unregister(fdevents *ev, int fd) {
int fdevent_event_del(fdevents *ev, int *fde_ndx, int fd) {
int fde = fde_ndx ? *fde_ndx : -1;
+ if (NULL == ev->fdarray[fd]) return 0;
+
if (ev->event_del) fde = ev->event_del(ev, fde, fd);
+ ev->fdarray[fd]->events = 0;
if (fde_ndx) *fde_ndx = fde;
return 0;
}
-int fdevent_event_add(fdevents *ev, int *fde_ndx, int fd, int events) {
+int fdevent_event_set(fdevents *ev, int *fde_ndx, int fd, int events) {
int fde = fde_ndx ? *fde_ndx : -1;
- if (ev->event_add) fde = ev->event_add(ev, fde, fd, events);
+ if (ev->event_set) fde = ev->event_set(ev, fde, fd, events);
+ ev->fdarray[fd]->events = events;
if (fde_ndx) *fde_ndx = fde;
diff --git a/src/fdevent.h b/src/fdevent.h
index 601acf1..5f813d6 100644
--- a/src/fdevent.h
+++ b/src/fdevent.h
@@ -32,10 +32,6 @@
# else
# include <sys/poll.h>
# endif
-# if defined HAVE_SIGTIMEDWAIT && defined(__linux__)
-# define USE_LINUX_SIGIO
-# include <signal.h>
-# endif
#endif
#if defined HAVE_SELECT
@@ -63,8 +59,17 @@
# include <sys/port.h>
#endif
+#if defined HAVE_LIBEV
+# define USE_LIBEV
+# include <ev.h>
+#endif
+
+struct server;
+
+typedef handler_t (*fdevent_handler)(struct server *srv, void *ctx, int revents);
-typedef handler_t (*fdevent_handler)(void *srv, void *ctx, int revents);
+/* these are the POLL* values from <bits/poll.h> (linux poll)
+ */
#define FDEVENT_IN BV(0)
#define FDEVENT_PRI BV(1)
@@ -83,45 +88,26 @@ typedef enum { FD_EVENT_TYPE_UNSET = -1,
typedef enum { FDEVENT_HANDLER_UNSET,
FDEVENT_HANDLER_SELECT,
FDEVENT_HANDLER_POLL,
- FDEVENT_HANDLER_LINUX_RTSIG,
FDEVENT_HANDLER_LINUX_SYSEPOLL,
FDEVENT_HANDLER_SOLARIS_DEVPOLL,
FDEVENT_HANDLER_FREEBSD_KQUEUE,
- FDEVENT_HANDLER_SOLARIS_PORT
+ FDEVENT_HANDLER_LIBEV
} fdevent_handler_t;
-/**
- * a mapping from fd to connection structure
- *
- */
-typedef struct {
- int fd; /**< the fd */
- void *conn; /**< a reference the corresponding data-structure */
- fd_event_t fd_type; /**< type of the fd */
- int events; /**< registered events */
- int revents;
-} fd_conn;
-
-typedef struct {
- fd_conn *ptr;
-
- size_t size;
- size_t used;
-} fd_conn_buffer;
-
-/**
- * array of unused fd's
- *
- */
typedef struct _fdnode {
fdevent_handler handler;
void *ctx;
+ void *handler_ctx;
int fd;
-
- struct _fdnode *prev, *next;
+ int events;
} fdnode;
+/**
+ * array of unused fd's
+ *
+ */
+
typedef struct {
int *ptr;
@@ -134,18 +120,12 @@ typedef struct {
*
*/
typedef struct fdevents {
+ struct server *srv;
fdevent_handler_t type;
fdnode **fdarray;
size_t maxfds;
-#ifdef USE_LINUX_SIGIO
- int in_sigio;
- int signum;
- sigset_t sigset;
- siginfo_t siginfo;
- bitset *sigbset;
-#endif
#ifdef USE_LINUX_EPOLL
int epoll_fd;
struct epoll_event *epoll_events;
@@ -176,15 +156,17 @@ typedef struct fdevents {
#ifdef USE_FREEBSD_KQUEUE
int kq_fd;
struct kevent *kq_results;
- bitset *kq_bevents;
#endif
#ifdef USE_SOLARIS_PORT
int port_fd;
#endif
+#ifdef USE_LIBEV
+ struct ev_loop *libev_loop;
+#endif
int (*reset)(struct fdevents *ev);
void (*free)(struct fdevents *ev);
- int (*event_add)(struct fdevents *ev, int fde_ndx, int fd, int events);
+ int (*event_set)(struct fdevents *ev, int fde_ndx, int fd, int events);
int (*event_del)(struct fdevents *ev, int fde_ndx, int fd);
int (*event_get_revent)(struct fdevents *ev, size_t ndx);
int (*event_get_fd)(struct fdevents *ev, size_t ndx);
@@ -196,11 +178,11 @@ typedef struct fdevents {
int (*fcntl_set)(struct fdevents *ev, int fd);
} fdevents;
-fdevents *fdevent_init(size_t maxfds, fdevent_handler_t type);
-int fdevent_reset(fdevents *ev);
+fdevents *fdevent_init(struct server *srv, size_t maxfds, fdevent_handler_t type);
+int fdevent_reset(fdevents *ev); /* "init" after fork() */
void fdevent_free(fdevents *ev);
-int fdevent_event_add(fdevents *ev, int *fde_ndx, int fd, int events);
+int fdevent_event_set(fdevents *ev, int *fde_ndx, int fd, int events); /* events can be FDEVENT_IN, FDEVENT_OUT or FDEVENT_IN | FDEVENT_OUT */
int fdevent_event_del(fdevents *ev, int *fde_ndx, int fd);
int fdevent_event_get_revent(fdevents *ev, size_t ndx);
int fdevent_event_get_fd(fdevents *ev, size_t ndx);
@@ -218,11 +200,9 @@ int fdevent_fcntl_set(fdevents *ev, int fd);
int fdevent_select_init(fdevents *ev);
int fdevent_poll_init(fdevents *ev);
-int fdevent_linux_rtsig_init(fdevents *ev);
int fdevent_linux_sysepoll_init(fdevents *ev);
int fdevent_solaris_devpoll_init(fdevents *ev);
int fdevent_freebsd_kqueue_init(fdevents *ev);
+int fdevent_libev_init(fdevents *ev);
#endif
-
-
diff --git a/src/fdevent_freebsd_kqueue.c b/src/fdevent_freebsd_kqueue.c
index 948d52c..0f53a2a 100644
--- a/src/fdevent_freebsd_kqueue.c
+++ b/src/fdevent_freebsd_kqueue.c
@@ -1,6 +1,6 @@
#include "fdevent.h"
#include "buffer.h"
-#include "server.h"
+#include "log.h"
#include <sys/types.h>
@@ -19,31 +19,40 @@
static void fdevent_freebsd_kqueue_free(fdevents *ev) {
close(ev->kq_fd);
free(ev->kq_results);
- bitset_free(ev->kq_bevents);
}
static int fdevent_freebsd_kqueue_event_del(fdevents *ev, int fde_ndx, int fd) {
- int filter, ret;
- struct kevent kev;
+ int ret, n = 0;
+ struct kevent kev[2];
struct timespec ts;
+ int oevents;
if (fde_ndx < 0) return -1;
- filter = bitset_test_bit(ev->kq_bevents, fd) ? EVFILT_READ : EVFILT_WRITE;
+ oevents = ev->fdarray[fd]->events;
- EV_SET(&kev, fd, filter, EV_DELETE, 0, 0, NULL);
+ if (oevents & FDEVENT_IN) {
+ EV_SET(&kev[n], fd, EVFILT_READ, EV_DELETE, 0, 0, NULL);
+ n++;
+ }
+ if (oevents & FDEVENT_OUT) {
+ EV_SET(&kev[n], fd, EVFILT_WRITE, EV_DELETE, 0, 0, NULL);
+ n++;
+ }
+
+ if (0 == n) return -1;
ts.tv_sec = 0;
ts.tv_nsec = 0;
ret = kevent(ev->kq_fd,
- &kev, 1,
- NULL, 0,
- &ts);
+ &kev, n,
+ NULL, 0,
+ &ts);
if (ret == -1) {
- fprintf(stderr, "%s.%d: kqueue failed polling: %s\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SS",
+ "kqueue event delete failed: ", strerror(errno));
return -1;
}
@@ -51,38 +60,50 @@ static int fdevent_freebsd_kqueue_event_del(fdevents *ev, int fde_ndx, int fd) {
return -1;
}
-static int fdevent_freebsd_kqueue_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
- int filter, ret;
- struct kevent kev;
+static int fdevent_freebsd_kqueue_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
+ int ret, n = 0;
+ struct kevent kev[2];
struct timespec ts;
+ int oevents = ev->fdarray[fd]->events;
+ int addevents = events & ~oevents;
+ int delevents = ~events & oevents;
UNUSED(fde_ndx);
- filter = (events & FDEVENT_IN) ? EVFILT_READ : EVFILT_WRITE;
+ if (events == oevents) return fd;
+
+ if (addevents & FDEVENT_IN) {
+ EV_SET(&kev[n], fd, EVFILT_READ, EV_ADD|EV_CLEAR, 0, 0, NULL);
+ n++;
+ } else if (delevents & FDEVENT_IN) {
+ EV_SET(&kev[n], fd, EVFILT_READ, EV_DELETE, 0, 0, NULL);
+ n++;
+ }
+ if (addevents & FDEVENT_OUT) {
+ EV_SET(&kev[n], fd, EVFILT_WRITE, EV_ADD|EV_CLEAR, 0, 0, NULL);
+ n++;
+ } else if (delevents & FDEVENT_OUT) {
+ EV_SET(&kev[n], fd, EVFILT_WRITE, EV_DELETE, 0, 0, NULL);
+ n++;
+ }
- EV_SET(&kev, fd, filter, EV_ADD|EV_CLEAR, 0, 0, NULL);
+ if (0 == n) return fd;
ts.tv_sec = 0;
ts.tv_nsec = 0;
ret = kevent(ev->kq_fd,
- &kev, 1,
- NULL, 0,
- &ts);
+ kev, n,
+ NULL, 0,
+ &ts);
if (ret == -1) {
- fprintf(stderr, "%s.%d: kqueue failed polling: %s\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SS",
+ "kqueue event set failed: ", strerror(errno));
return -1;
}
- if (filter == EVFILT_READ) {
- bitset_set_bit(ev->kq_bevents, fd);
- } else {
- bitset_clear_bit(ev->kq_bevents, fd);
- }
-
return fd;
}
@@ -94,9 +115,9 @@ static int fdevent_freebsd_kqueue_poll(fdevents *ev, int timeout_ms) {
ts.tv_nsec = (timeout_ms % 1000) * 1000000;
ret = kevent(ev->kq_fd,
- NULL, 0,
- ev->kq_results, ev->maxfds,
- &ts);
+ NULL, 0,
+ ev->kq_results, ev->maxfds,
+ &ts);
if (ret == -1) {
switch(errno) {
@@ -104,8 +125,8 @@ static int fdevent_freebsd_kqueue_poll(fdevents *ev, int timeout_ms) {
/* we got interrupted, perhaps just a SIGCHLD of a CGI script */
return 0;
default:
- fprintf(stderr, "%s.%d: kqueue failed polling: %s\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SS",
+ "kqueue failed polling: ", strerror(errno));
break;
}
}
@@ -149,8 +170,8 @@ static int fdevent_freebsd_kqueue_event_next_fdndx(fdevents *ev, int ndx) {
static int fdevent_freebsd_kqueue_reset(fdevents *ev) {
if (-1 == (ev->kq_fd = kqueue())) {
- fprintf(stderr, "%s.%d: kqueue failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "kqueue failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
@@ -169,7 +190,7 @@ int fdevent_freebsd_kqueue_init(fdevents *ev) {
SET(reset);
SET(event_del);
- SET(event_add);
+ SET(event_set);
SET(event_next_fdndx);
SET(event_get_fd);
@@ -178,13 +199,12 @@ int fdevent_freebsd_kqueue_init(fdevents *ev) {
ev->kq_fd = -1;
ev->kq_results = calloc(ev->maxfds, sizeof(*ev->kq_results));
- ev->kq_bevents = bitset_init(ev->maxfds);
/* check that kqueue works */
if (-1 == (ev->kq_fd = kqueue())) {
- fprintf(stderr, "%s.%d: kqueue failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "kqueue failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
@@ -198,8 +218,8 @@ int fdevent_freebsd_kqueue_init(fdevents *ev) {
int fdevent_freebsd_kqueue_init(fdevents *ev) {
UNUSED(ev);
- fprintf(stderr, "%s.%d: kqueue not available, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "kqueue not available, try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
diff --git a/src/fdevent_libev.c b/src/fdevent_libev.c
new file mode 100644
index 0000000..543127a
--- /dev/null
+++ b/src/fdevent_libev.c
@@ -0,0 +1,168 @@
+#include "fdevent.h"
+#include "buffer.h"
+#include "log.h"
+
+#include <assert.h>
+
+#ifdef USE_LIBEV
+static void io_watcher_cb(struct ev_loop *loop, ev_io *w, int revents) {
+ fdevents *ev = w->data;
+ fdnode *fdn = ev->fdarray[w->fd];
+ int r = 0;
+ UNUSED(loop);
+
+ if (revents & EV_READ) r |= FDEVENT_IN;
+ if (revents & EV_WRITE) r |= FDEVENT_OUT;
+ if (revents & EV_ERROR) r |= FDEVENT_ERR;
+
+ switch (r = (*fdn->handler)(ev->srv, fdn->ctx, r)) {
+ case HANDLER_FINISHED:
+ case HANDLER_GO_ON:
+ case HANDLER_WAIT_FOR_EVENT:
+ case HANDLER_WAIT_FOR_FD:
+ break;
+ case HANDLER_ERROR:
+ /* should never happen */
+ SEGFAULT();
+ break;
+ default:
+ log_error_write(ev->srv, __FILE__, __LINE__, "d", r);
+ break;
+ }
+}
+
+static void fdevent_libev_free(fdevents *ev) {
+ UNUSED(ev);
+}
+
+static int fdevent_libev_event_del(fdevents *ev, int fde_ndx, int fd) {
+ fdnode *fdn;
+ ev_io *watcher;
+
+ if (-1 == fde_ndx) return -1;
+
+ fdn = ev->fdarray[fd];
+ watcher = fdn->handler_ctx;
+
+ if (!watcher) return -1;
+
+ ev_io_stop(ev->libev_loop, watcher);
+ free(watcher);
+ fdn->handler_ctx = NULL;
+
+ return -1;
+}
+
+static int fdevent_libev_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
+ fdnode *fdn = ev->fdarray[fd];
+ ev_io *watcher = fdn->handler_ctx;
+ int ev_events = 0;
+ UNUSED(fde_ndx);
+
+ if (events & FDEVENT_IN) ev_events |= EV_READ;
+ if (events & FDEVENT_OUT) ev_events |= EV_WRITE;
+
+ if (!watcher) {
+ fdn->handler_ctx = watcher = calloc(1, sizeof(ev_io));
+ assert(watcher);
+
+ ev_io_init(watcher, io_watcher_cb, fd, ev_events);
+ watcher->data = ev;
+ ev_io_start(ev->libev_loop, watcher);
+ } else {
+ if ((watcher->events & (EV_READ | EV_WRITE)) != ev_events) {
+ ev_io_stop(ev->libev_loop, watcher);
+ ev_io_set(watcher, watcher->fd, ev_events);
+ ev_io_start(ev->libev_loop, watcher);
+ }
+ }
+
+ return fd;
+}
+
+static void timeout_watcher_cb(struct ev_loop *loop, ev_timer *w, int revents) {
+ UNUSED(loop);
+ UNUSED(w);
+ UNUSED(revents);
+}
+
+
+static int fdevent_libev_poll(fdevents *ev, int timeout_ms) {
+ ev_timer timeout_watcher;
+
+ ev_init(&timeout_watcher, timeout_watcher_cb);
+ ev_timer_set(&timeout_watcher, ((ev_tstamp) timeout_ms)/1000.0, 0.0);
+ ev_timer_start(ev->libev_loop, &timeout_watcher);
+
+ ev_loop(ev->libev_loop, EVLOOP_ONESHOT);
+
+ ev_timer_stop(ev->libev_loop, &timeout_watcher);
+
+ return 0;
+}
+
+static int fdevent_libev_event_get_revent(fdevents *ev, size_t ndx) {
+ UNUSED(ev);
+ UNUSED(ndx);
+
+ return 0;
+}
+
+static int fdevent_libev_event_get_fd(fdevents *ev, size_t ndx) {
+ UNUSED(ev);
+ UNUSED(ndx);
+
+ return -1;
+}
+
+static int fdevent_libev_event_next_fdndx(fdevents *ev, int ndx) {
+ UNUSED(ev);
+ UNUSED(ndx);
+
+ return -1;
+}
+
+static int fdevent_libev_reset(fdevents *ev) {
+ UNUSED(ev);
+
+ ev_default_fork();
+
+ return 0;
+}
+
+int fdevent_libev_init(fdevents *ev) {
+ ev->type = FDEVENT_HANDLER_LIBEV;
+#define SET(x) \
+ ev->x = fdevent_libev_##x;
+
+ SET(free);
+ SET(poll);
+ SET(reset);
+
+ SET(event_del);
+ SET(event_set);
+
+ SET(event_next_fdndx);
+ SET(event_get_fd);
+ SET(event_get_revent);
+
+ if (NULL == (ev->libev_loop = ev_default_loop(0))) {
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "ev_default_loop failed , try to set server.event-handler = \"poll\" or \"select\"");
+
+ return -1;
+ }
+
+ return 0;
+}
+
+#else
+int fdevent_libev_init(fdevents *ev) {
+ UNUSED(ev);
+
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "libev not supported, try to set server.event-handler = \"poll\" or \"select\"");
+
+ return -1;
+}
+#endif
diff --git a/src/fdevent_linux_rtsig.c b/src/fdevent_linux_rtsig.c
deleted file mode 100644
index 624c980..0000000
--- a/src/fdevent_linux_rtsig.c
+++ /dev/null
@@ -1,258 +0,0 @@
-#include "fdevent.h"
-#include "buffer.h"
-
-#include <sys/types.h>
-
-#include <unistd.h>
-#include <stdlib.h>
-#include <stdio.h>
-#include <string.h>
-#include <errno.h>
-#include <signal.h>
-#include <limits.h>
-
-#include <fcntl.h>
-
-#ifdef USE_LINUX_SIGIO
-static void fdevent_linux_rtsig_free(fdevents *ev) {
- free(ev->pollfds);
- if (ev->unused.ptr) free(ev->unused.ptr);
-
- bitset_free(ev->sigbset);
-}
-
-
-static int fdevent_linux_rtsig_event_del(fdevents *ev, int fde_ndx, int fd) {
- if (fde_ndx < 0) return -1;
-
- if ((size_t)fde_ndx >= ev->used) {
- fprintf(stderr, "%s.%d: del! out of range %d %zu\n", __FILE__, __LINE__, fde_ndx, ev->used);
- SEGFAULT();
- }
-
- if (ev->pollfds[fde_ndx].fd == fd) {
- size_t k = fde_ndx;
-
- ev->pollfds[k].fd = -1;
-
- bitset_clear_bit(ev->sigbset, fd);
-
- if (ev->unused.size == 0) {
- ev->unused.size = 16;
- ev->unused.ptr = malloc(sizeof(*(ev->unused.ptr)) * ev->unused.size);
- } else if (ev->unused.size == ev->unused.used) {
- ev->unused.size += 16;
- ev->unused.ptr = realloc(ev->unused.ptr, sizeof(*(ev->unused.ptr)) * ev->unused.size);
- }
-
- ev->unused.ptr[ev->unused.used++] = k;
- } else {
- fprintf(stderr, "%s.%d: del! %d %d\n", __FILE__, __LINE__, ev->pollfds[fde_ndx].fd, fd);
-
- SEGFAULT();
- }
-
- return -1;
-}
-
-#if 0
-static int fdevent_linux_rtsig_event_compress(fdevents *ev) {
- size_t j;
-
- if (ev->used == 0) return 0;
- if (ev->unused.used != 0) return 0;
-
- for (j = ev->used - 1; j + 1 > 0; j--) {
- if (ev->pollfds[j].fd == -1) ev->used--;
- }
-
-
- return 0;
-}
-#endif
-
-static int fdevent_linux_rtsig_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
- /* known index */
- if (fde_ndx != -1) {
- if (ev->pollfds[fde_ndx].fd == fd) {
- ev->pollfds[fde_ndx].events = events;
-
- return fde_ndx;
- }
- fprintf(stderr, "%s.%d: add: (%d, %d)\n", __FILE__, __LINE__, fde_ndx, ev->pollfds[fde_ndx].fd);
- SEGFAULT();
- }
-
- if (ev->unused.used > 0) {
- int k = ev->unused.ptr[--ev->unused.used];
-
- ev->pollfds[k].fd = fd;
- ev->pollfds[k].events = events;
-
- bitset_set_bit(ev->sigbset, fd);
-
- return k;
- } else {
- if (ev->size == 0) {
- ev->size = 16;
- ev->pollfds = malloc(sizeof(*ev->pollfds) * ev->size);
- } else if (ev->size == ev->used) {
- ev->size += 16;
- ev->pollfds = realloc(ev->pollfds, sizeof(*ev->pollfds) * ev->size);
- }
-
- ev->pollfds[ev->used].fd = fd;
- ev->pollfds[ev->used].events = events;
-
- bitset_set_bit(ev->sigbset, fd);
-
- return ev->used++;
- }
-}
-
-static int fdevent_linux_rtsig_poll(fdevents *ev, int timeout_ms) {
- struct timespec ts;
- int r;
-
-#if 0
- fdevent_linux_rtsig_event_compress(ev);
-#endif
-
- ev->in_sigio = 1;
-
- ts.tv_sec = timeout_ms / 1000;
- ts.tv_nsec = (timeout_ms % 1000) * 1000000;
- r = sigtimedwait(&(ev->sigset), &(ev->siginfo), &(ts));
-
- if (r == -1) {
- if (errno == EAGAIN) return 0;
- return r;
- } else if (r == SIGIO) {
- struct sigaction act;
-
- /* flush the signal queue */
- memset(&act, 0, sizeof(act));
- act.sa_handler = SIG_IGN;
- sigaction(ev->signum, &act, NULL);
-
- /* re-enable the signal queue */
- act.sa_handler = SIG_DFL;
- sigaction(ev->signum, &act, NULL);
-
- ev->in_sigio = 0;
- r = poll(ev->pollfds, ev->used, timeout_ms);
-
- return r;
- } else if (r == ev->signum) {
-# if 0
- fprintf(stderr, "event: %d %02lx\n", ev->siginfo.si_fd, ev->siginfo.si_band);
-# endif
- return bitset_test_bit(ev->sigbset, ev->siginfo.si_fd);
- } else {
- /* ? */
- return -1;
- }
-}
-
-static int fdevent_linux_rtsig_event_get_revent(fdevents *ev, size_t ndx) {
- if (ev->in_sigio == 1) {
-# if 0
- if (ev->siginfo.si_band == POLLERR) {
- fprintf(stderr, "event: %d %02lx %02x %s\n", ev->siginfo.si_fd, ev->siginfo.si_band, errno, strerror(errno));
- }
-# endif
- if (ndx != 0) {
- fprintf(stderr, "+\n");
- return 0;
- }
-
- return ev->siginfo.si_band & 0x3f;
- } else {
- if (ndx >= ev->used) {
- fprintf(stderr, "%s.%d: event: %zu %zu\n", __FILE__, __LINE__, ndx, ev->used);
- return 0;
- }
- return ev->pollfds[ndx].revents;
- }
-}
-
-static int fdevent_linux_rtsig_event_get_fd(fdevents *ev, size_t ndx) {
- if (ev->in_sigio == 1) {
- return ev->siginfo.si_fd;
- } else {
- return ev->pollfds[ndx].fd;
- }
-}
-
-static int fdevent_linux_rtsig_fcntl_set(fdevents *ev, int fd) {
- static pid_t pid = 0;
-
- if (pid == 0) pid = getpid();
-
- if (-1 == fcntl(fd, F_SETSIG, ev->signum)) return -1;
-
- if (-1 == fcntl(fd, F_SETOWN, (int) pid)) return -1;
-
- return fcntl(fd, F_SETFL, O_ASYNC | O_NONBLOCK | O_RDWR);
-}
-
-
-static int fdevent_linux_rtsig_event_next_fdndx(fdevents *ev, int ndx) {
- if (ev->in_sigio == 1) {
- if (ndx < 0) return 0;
- return -1;
- } else {
- size_t i;
-
- i = (ndx < 0) ? 0 : ndx + 1;
- for (; i < ev->used; i++) {
- if (ev->pollfds[i].revents) break;
- }
-
- return i;
- }
-}
-
-int fdevent_linux_rtsig_init(fdevents *ev) {
- ev->type = FDEVENT_HANDLER_LINUX_RTSIG;
-#define SET(x) \
- ev->x = fdevent_linux_rtsig_##x;
-
- SET(free);
- SET(poll);
-
- SET(event_del);
- SET(event_add);
-
- SET(event_next_fdndx);
- SET(fcntl_set);
- SET(event_get_fd);
- SET(event_get_revent);
-
- ev->signum = SIGRTMIN + 1;
-
- sigemptyset(&(ev->sigset));
- sigaddset(&(ev->sigset), ev->signum);
- sigaddset(&(ev->sigset), SIGIO);
- if (-1 == sigprocmask(SIG_BLOCK, &(ev->sigset), NULL)) {
- fprintf(stderr, "%s.%d: sigprocmask failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
-
- return -1;
- }
-
- ev->in_sigio = 1;
-
- ev->sigbset = bitset_init(ev->maxfds);
-
- return 0;
-}
-#else
-int fdevent_linux_rtsig_init(fdevents *ev) {
- UNUSED(ev);
-
- fprintf(stderr, "%s.%d: linux-rtsig not supported, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
- return -1;
-}
-#endif
diff --git a/src/fdevent_linux_sysepoll.c b/src/fdevent_linux_sysepoll.c
index a00fdd3..b311f45 100644
--- a/src/fdevent_linux_sysepoll.c
+++ b/src/fdevent_linux_sysepoll.c
@@ -1,5 +1,6 @@
#include "fdevent.h"
#include "buffer.h"
+#include "log.h"
#include <sys/types.h>
@@ -28,7 +29,8 @@ static int fdevent_linux_sysepoll_event_del(fdevents *ev, int fde_ndx, int fd) {
ep.data.ptr = NULL;
if (0 != epoll_ctl(ev->epoll_fd, EPOLL_CTL_DEL, fd, &ep)) {
- fprintf(stderr, "%s.%d: epoll_ctl failed: %s, dying\n", __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "epoll_ctl failed: ", strerror(errno), ", dying");
SEGFAULT();
@@ -39,7 +41,7 @@ static int fdevent_linux_sysepoll_event_del(fdevents *ev, int fde_ndx, int fd) {
return -1;
}
-static int fdevent_linux_sysepoll_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
+static int fdevent_linux_sysepoll_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
struct epoll_event ep;
int add = 0;
@@ -66,7 +68,8 @@ static int fdevent_linux_sysepoll_event_add(fdevents *ev, int fde_ndx, int fd, i
ep.data.fd = fd;
if (0 != epoll_ctl(ev->epoll_fd, add ? EPOLL_CTL_ADD : EPOLL_CTL_MOD, fd, &ep)) {
- fprintf(stderr, "%s.%d: epoll_ctl failed: %s, dying\n", __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "epoll_ctl failed: ", strerror(errno), ", dying");
SEGFAULT();
@@ -95,7 +98,8 @@ static int fdevent_linux_sysepoll_event_get_revent(fdevents *ev, size_t ndx) {
static int fdevent_linux_sysepoll_event_get_fd(fdevents *ev, size_t ndx) {
# if 0
- fprintf(stderr, "%s.%d: %d, %d\n", __FILE__, __LINE__, ndx, ev->epoll_events[ndx].data.fd);
+ log_error_write(ev->srv, __FILE__, __LINE__, "SD, D",
+ "fdevent_linux_sysepoll_event_get_fd: ", (int) ndx, ev->epoll_events[ndx].data.fd);
# endif
return ev->epoll_events[ndx].data.fd;
@@ -120,22 +124,22 @@ int fdevent_linux_sysepoll_init(fdevents *ev) {
SET(poll);
SET(event_del);
- SET(event_add);
+ SET(event_set);
SET(event_next_fdndx);
SET(event_get_fd);
SET(event_get_revent);
if (-1 == (ev->epoll_fd = epoll_create(ev->maxfds))) {
- fprintf(stderr, "%s.%d: epoll_create failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "epoll_create failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
if (-1 == fcntl(ev->epoll_fd, F_SETFD, FD_CLOEXEC)) {
- fprintf(stderr, "%s.%d: epoll_create failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "fcntl on epoll-fd failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
close(ev->epoll_fd);
@@ -151,8 +155,8 @@ int fdevent_linux_sysepoll_init(fdevents *ev) {
int fdevent_linux_sysepoll_init(fdevents *ev) {
UNUSED(ev);
- fprintf(stderr, "%s.%d: linux-sysepoll not supported, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "linux-sysepoll not supported, try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
diff --git a/src/fdevent_poll.c b/src/fdevent_poll.c
index 6e63bd0..6d102e6 100644
--- a/src/fdevent_poll.c
+++ b/src/fdevent_poll.c
@@ -1,5 +1,6 @@
#include "fdevent.h"
#include "buffer.h"
+#include "log.h"
#include <sys/types.h>
@@ -21,7 +22,8 @@ static int fdevent_poll_event_del(fdevents *ev, int fde_ndx, int fd) {
if (fde_ndx < 0) return -1;
if ((size_t)fde_ndx >= ev->used) {
- fprintf(stderr, "%s.%d: del! out of range %d %zd\n", __FILE__, __LINE__, fde_ndx, ev->used);
+ log_error_write(ev->srv, __FILE__, __LINE__, "SdD",
+ "del! out of range ", fde_ndx, (int) ev->used);
SEGFAULT();
}
@@ -42,6 +44,9 @@ static int fdevent_poll_event_del(fdevents *ev, int fde_ndx, int fd) {
ev->unused.ptr[ev->unused.used++] = k;
} else {
+ log_error_write(ev->srv, __FILE__, __LINE__, "SdD",
+ "del! ", ev->pollfds[fde_ndx].fd, fd);
+
SEGFAULT();
}
@@ -61,16 +66,21 @@ static int fdevent_poll_event_compress(fdevents *ev) {
}
#endif
-static int fdevent_poll_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
+static int fdevent_poll_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
+ int pevents = 0;
+ if (events & FDEVENT_IN) pevents |= POLLIN;
+ if (events & FDEVENT_OUT) pevents |= POLLOUT;
+
/* known index */
if (fde_ndx != -1) {
if (ev->pollfds[fde_ndx].fd == fd) {
- ev->pollfds[fde_ndx].events = events;
+ ev->pollfds[fde_ndx].events = pevents;
return fde_ndx;
}
- fprintf(stderr, "%s.%d: add: (%d, %d)\n", __FILE__, __LINE__, fde_ndx, ev->pollfds[fde_ndx].fd);
+ log_error_write(ev->srv, __FILE__, __LINE__, "SdD",
+ "set: ", fde_ndx, ev->pollfds[fde_ndx].fd);
SEGFAULT();
}
@@ -78,7 +88,7 @@ static int fdevent_poll_event_add(fdevents *ev, int fde_ndx, int fd, int events)
int k = ev->unused.ptr[--ev->unused.used];
ev->pollfds[k].fd = fd;
- ev->pollfds[k].events = events;
+ ev->pollfds[k].events = pevents;
return k;
} else {
@@ -91,7 +101,7 @@ static int fdevent_poll_event_add(fdevents *ev, int fde_ndx, int fd, int events)
}
ev->pollfds[ev->used].fd = fd;
- ev->pollfds[ev->used].events = events;
+ ev->pollfds[ev->used].events = pevents;
return ev->used++;
}
@@ -106,8 +116,10 @@ static int fdevent_poll_poll(fdevents *ev, int timeout_ms) {
static int fdevent_poll_event_get_revent(fdevents *ev, size_t ndx) {
int r, poll_r;
+
if (ndx >= ev->used) {
- fprintf(stderr, "%s.%d: dying because: event: %zd >= %zd\n", __FILE__, __LINE__, ndx, ev->used);
+ log_error_write(ev->srv, __FILE__, __LINE__, "sii",
+ "dying because: event: ", (int) ndx, (int) ev->used);
SEGFAULT();
@@ -122,7 +134,7 @@ static int fdevent_poll_event_get_revent(fdevents *ev, size_t ndx) {
r = 0;
poll_r = ev->pollfds[ndx].revents;
- /* map POLL* to FDEVEN_* */
+ /* map POLL* to FDEVEN_*; they are probably the same, but still. */
if (poll_r & POLLIN) r |= FDEVENT_IN;
if (poll_r & POLLOUT) r |= FDEVENT_OUT;
@@ -143,10 +155,10 @@ static int fdevent_poll_event_next_fdndx(fdevents *ev, int ndx) {
i = (ndx < 0) ? 0 : ndx + 1;
for (; i < ev->used; i++) {
- if (ev->pollfds[i].revents) break;
+ if (ev->pollfds[i].revents) return i;
}
- return i;
+ return -1;
}
int fdevent_poll_init(fdevents *ev) {
@@ -158,7 +170,7 @@ int fdevent_poll_init(fdevents *ev) {
SET(poll);
SET(event_del);
- SET(event_add);
+ SET(event_set);
SET(event_next_fdndx);
SET(event_get_fd);
@@ -174,8 +186,9 @@ int fdevent_poll_init(fdevents *ev) {
int fdevent_poll_init(fdevents *ev) {
UNUSED(ev);
- fprintf(stderr, "%s.%d: poll is not supported, try to set server.event-handler = \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(srv, __FILE__, __LINE__,
+ "s", "poll is not supported, try to set server.event-handler = \"select\"");
+
return -1;
}
#endif
diff --git a/src/fdevent_select.c b/src/fdevent_select.c
index 4a32420..2e23dce 100644
--- a/src/fdevent_select.c
+++ b/src/fdevent_select.c
@@ -1,5 +1,6 @@
#include "fdevent.h"
#include "buffer.h"
+#include "log.h"
#include <sys/time.h>
#include <sys/types.h>
@@ -33,7 +34,7 @@ static int fdevent_select_event_del(fdevents *ev, int fde_ndx, int fd) {
return -1;
}
-static int fdevent_select_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
+static int fdevent_select_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
UNUSED(fde_ndx);
/* we should be protected by max-fds, but you never know */
@@ -41,11 +42,13 @@ static int fdevent_select_event_add(fdevents *ev, int fde_ndx, int fd, int event
if (events & FDEVENT_IN) {
FD_SET(fd, &(ev->select_set_read));
- FD_CLR(fd, &(ev->select_set_write));
+ } else {
+ FD_CLR(fd, &(ev->select_set_read));
}
if (events & FDEVENT_OUT) {
- FD_CLR(fd, &(ev->select_set_read));
FD_SET(fd, &(ev->select_set_write));
+ } else {
+ FD_CLR(fd, &(ev->select_set_write));
}
FD_SET(fd, &(ev->select_set_error));
@@ -95,12 +98,12 @@ static int fdevent_select_event_next_fdndx(fdevents *ev, int ndx) {
i = (ndx < 0) ? 0 : ndx + 1;
for (; i < ev->select_max_fd + 1; i++) {
- if (FD_ISSET(i, &(ev->select_read))) break;
- if (FD_ISSET(i, &(ev->select_write))) break;
- if (FD_ISSET(i, &(ev->select_error))) break;
+ if (FD_ISSET(i, &(ev->select_read))) return i;
+ if (FD_ISSET(i, &(ev->select_write))) return i;
+ if (FD_ISSET(i, &(ev->select_error))) return i;
}
- return i;
+ return -1;
}
int fdevent_select_init(fdevents *ev) {
@@ -112,7 +115,7 @@ int fdevent_select_init(fdevents *ev) {
SET(poll);
SET(event_del);
- SET(event_add);
+ SET(event_set);
SET(event_next_fdndx);
SET(event_get_fd);
diff --git a/src/fdevent_solaris_devpoll.c b/src/fdevent_solaris_devpoll.c
index c099b12..cfbc510 100644
--- a/src/fdevent_solaris_devpoll.c
+++ b/src/fdevent_solaris_devpoll.c
@@ -1,5 +1,6 @@
#include "fdevent.h"
#include "buffer.h"
+#include "log.h"
#include <sys/types.h>
@@ -30,9 +31,8 @@ static int fdevent_solaris_devpoll_event_del(fdevents *ev, int fde_ndx, int fd)
pfd.revents = 0;
if (-1 == write(ev->devpoll_fd, &pfd, sizeof(pfd))) {
- fprintf(stderr, "%s.%d: (del) write failed: (%d, %s)\n",
- __FILE__, __LINE__,
- fd, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "S(D, S)",
+ "(del) write failed: ", fd, strerror(errno));
return -1;
}
@@ -40,20 +40,23 @@ static int fdevent_solaris_devpoll_event_del(fdevents *ev, int fde_ndx, int fd)
return -1;
}
-static int fdevent_solaris_devpoll_event_add(fdevents *ev, int fde_ndx, int fd, int events) {
+static int fdevent_solaris_devpoll_event_set(fdevents *ev, int fde_ndx, int fd, int events) {
struct pollfd pfd;
int add = 0;
+ int pevents = 0;
+ if (events & FDEVENT_IN) pevents |= POLLIN;
+ if (events & FDEVENT_OUT) pevents |= POLLOUT;
+
if (fde_ndx == -1) add = 1;
pfd.fd = fd;
- pfd.events = events;
+ pfd.events = pevents;
pfd.revents = 0;
if (-1 == write(ev->devpoll_fd, &pfd, sizeof(pfd))) {
- fprintf(stderr, "%s.%d: (del) write failed: (%d, %s)\n",
- __FILE__, __LINE__,
- fd, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "S(D, S)",
+ "(set) write failed: ", fd, strerror(errno));
return -1;
}
@@ -75,7 +78,21 @@ static int fdevent_solaris_devpoll_poll(fdevents *ev, int timeout_ms) {
}
static int fdevent_solaris_devpoll_event_get_revent(fdevents *ev, size_t ndx) {
- return ev->devpollfds[ndx].revents;
+ int r, poll_r;
+
+ r = 0;
+ poll_r = ev->devpollfds[ndx].revents;
+
+ /* map POLL* to FDEVEN_*; they are probably the same, but still. */
+
+ if (poll_r & POLLIN) r |= FDEVENT_IN;
+ if (poll_r & POLLOUT) r |= FDEVENT_OUT;
+ if (poll_r & POLLERR) r |= FDEVENT_ERR;
+ if (poll_r & POLLHUP) r |= FDEVENT_HUP;
+ if (poll_r & POLLNVAL) r |= FDEVENT_NVAL;
+ if (poll_r & POLLPRI) r |= FDEVENT_PRI;
+
+ return r;
}
static int fdevent_solaris_devpoll_event_get_fd(fdevents *ev, size_t ndx) {
@@ -96,15 +113,15 @@ int fdevent_solaris_devpoll_reset(fdevents *ev) {
/* a forked process does only inherit the filedescriptor,
* but every operation on the device will lead to a EACCES */
if ((ev->devpoll_fd = open("/dev/poll", O_RDWR)) < 0) {
- fprintf(stderr, "%s.%d: opening /dev/poll failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "opening /dev/poll failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
if (fcntl(ev->devpoll_fd, F_SETFD, FD_CLOEXEC) < 0) {
- fprintf(stderr, "%s.%d: opening /dev/poll failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "fcntl /dev/poll fd failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
close(ev->devpoll_fd);
@@ -122,7 +139,7 @@ int fdevent_solaris_devpoll_init(fdevents *ev) {
SET(reset);
SET(event_del);
- SET(event_add);
+ SET(event_set);
SET(event_next_fdndx);
SET(event_get_fd);
@@ -131,8 +148,8 @@ int fdevent_solaris_devpoll_init(fdevents *ev) {
ev->devpollfds = malloc(sizeof(*ev->devpollfds) * ev->maxfds);
if ((ev->devpoll_fd = open("/dev/poll", O_RDWR)) < 0) {
- fprintf(stderr, "%s.%d: opening /dev/poll failed (%s), try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__, strerror(errno));
+ log_error_write(ev->srv, __FILE__, __LINE__, "SSS",
+ "opening /dev/poll failed (", strerror(errno), "), try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
@@ -149,8 +166,8 @@ int fdevent_solaris_devpoll_init(fdevents *ev) {
int fdevent_solaris_devpoll_init(fdevents *ev) {
UNUSED(ev);
- fprintf(stderr, "%s.%d: solaris-devpoll not supported, try to set server.event-handler = \"poll\" or \"select\"\n",
- __FILE__, __LINE__);
+ log_error_write(ev->srv, __FILE__, __LINE__, "S",
+ "solaris-devpoll not supported, try to set server.event-handler = \"poll\" or \"select\"");
return -1;
}
diff --git a/src/http_auth.c b/src/http_auth.c
index 0c0c4a5..f7f0aaf 100644
--- a/src/http_auth.c
+++ b/src/http_auth.c
@@ -653,7 +653,6 @@ static int http_auth_basic_password_compare(server *srv, mod_auth_plugin_data *p
*/
if (password->used < 13 + 1) {
- fprintf(stderr, "%s.%d\n", __FILE__, __LINE__);
return -1;
}
@@ -664,7 +663,6 @@ static int http_auth_basic_password_compare(server *srv, mod_auth_plugin_data *p
char *dollar = NULL;
if (NULL == (dollar = strchr(password->ptr + 3, '$'))) {
- fprintf(stderr, "%s.%d\n", __FILE__, __LINE__);
return -1;
}
@@ -672,7 +670,6 @@ static int http_auth_basic_password_compare(server *srv, mod_auth_plugin_data *p
}
if (salt_len > sizeof(salt) - 1) {
- fprintf(stderr, "%s.%d\n", __FILE__, __LINE__);
return -1;
}
@@ -684,8 +681,6 @@ static int http_auth_basic_password_compare(server *srv, mod_auth_plugin_data *p
if (0 == strcmp(password->ptr, crypted)) {
return 0;
- } else {
- fprintf(stderr, "%s.%d\n", __FILE__, __LINE__);
}
#endif
@@ -869,7 +864,7 @@ int http_auth_basic_check(server *srv, connection *con, mod_auth_plugin_data *p,
if (AUTH_BACKEND_UNSET == p->conf.auth_backend) {
log_error_write(srv, __FILE__, __LINE__, "s", "auth.backend is not set");
} else {
- log_error_write(srv, __FILE__, __LINE__, "s", "get_password failed");
+ log_error_write(srv, __FILE__, __LINE__, "ss", "get_password failed, IP:", inet_ntop_cache_get_ip(srv, &(con->dst_addr)));
}
return 0;
@@ -877,7 +872,7 @@ int http_auth_basic_check(server *srv, connection *con, mod_auth_plugin_data *p,
/* password doesn't match */
if (http_auth_basic_password_compare(srv, p, req, username, realm->value, password, pw)) {
- log_error_write(srv, __FILE__, __LINE__, "sbbss", "password doesn't match for ", con->uri.path, username, ", IP:", inet_ntop_cache_get_ip(srv, &(con->dst_addr)));
+ log_error_write(srv, __FILE__, __LINE__, "sbsBss", "password doesn't match for", con->uri.path, "username:", username, ", IP:", inet_ntop_cache_get_ip(srv, &(con->dst_addr)));
buffer_free(username);
buffer_free(password);
@@ -1138,7 +1133,7 @@ int http_auth_digest_check(server *srv, connection *con, mod_auth_plugin_data *p
"digest: digest mismatch", a2, respons);
}
- log_error_write(srv, __FILE__, __LINE__, "sss",
+ log_error_write(srv, __FILE__, __LINE__, "ssss",
"digest: auth failed for ", username, ": wrong password, IP:", inet_ntop_cache_get_ip(srv, &(con->dst_addr)));
buffer_free(b);
diff --git a/src/keyvalue.c b/src/keyvalue.c
index 00f6ef6..8ca739b 100644
--- a/src/keyvalue.c
+++ b/src/keyvalue.c
@@ -1,5 +1,6 @@
#include "server.h"
#include "keyvalue.h"
+#include "log.h"
#include <stdlib.h>
#include <string.h>
@@ -312,7 +313,7 @@ pcre_keyvalue_buffer *pcre_keyvalue_buffer_init(void) {
return kvb;
}
-int pcre_keyvalue_buffer_append(pcre_keyvalue_buffer *kvb, const char *key, const char *value) {
+int pcre_keyvalue_buffer_append(server *srv, pcre_keyvalue_buffer *kvb, const char *key, const char *value) {
#ifdef HAVE_PCRE_H
size_t i;
const char *errptr;
@@ -346,7 +347,8 @@ int pcre_keyvalue_buffer_append(pcre_keyvalue_buffer *kvb, const char *key, cons
if (NULL == (kv->key = pcre_compile(key,
0, &errptr, &erroff, NULL))) {
- fprintf(stderr, "%s.%d: rexexp compilation error at %s\n", __FILE__, __LINE__, errptr);
+ log_error_write(srv, __FILE__, __LINE__, "SS",
+ "rexexp compilation error at ", errptr);
return -1;
}
diff --git a/src/keyvalue.h b/src/keyvalue.h
index b2b178a..209b2cf 100644
--- a/src/keyvalue.h
+++ b/src/keyvalue.h
@@ -9,6 +9,8 @@
# include <pcre.h>
#endif
+struct server;
+
typedef enum {
HTTP_METHOD_UNSET = -1,
HTTP_METHOD_GET,
@@ -102,7 +104,7 @@ int httpauth_keyvalue_buffer_append(httpauth_keyvalue_buffer *kvb, const char *k
void httpauth_keyvalue_buffer_free(httpauth_keyvalue_buffer *kvb);
pcre_keyvalue_buffer *pcre_keyvalue_buffer_init(void);
-int pcre_keyvalue_buffer_append(pcre_keyvalue_buffer *kvb, const char *key, const char *value);
+int pcre_keyvalue_buffer_append(struct server *srv, pcre_keyvalue_buffer *kvb, const char *key, const char *value);
void pcre_keyvalue_buffer_free(pcre_keyvalue_buffer *kvb);
#endif
diff --git a/src/mod_accesslog.c b/src/mod_accesslog.c
index 07cb82e..420037e 100644
--- a/src/mod_accesslog.c
+++ b/src/mod_accesslog.c
@@ -157,49 +157,62 @@ INIT_FUNC(mod_accesslog_init) {
}
static void accesslog_append_escaped(buffer *dest, buffer *str) {
+ char *ptr, *start, *end;
+
/* replaces non-printable chars with \xHH where HH is the hex representation of the byte */
/* exceptions: " => \", \ => \\, whitespace chars => \n \t etc. */
if (str->used == 0) return;
buffer_prepare_append(dest, str->used - 1);
- for (unsigned int i = 0; i < str->used - 1; i++) {
- if (str->ptr[i] >= ' ' && str->ptr[i] <= '~') {
- /* printable chars */
- buffer_append_string_len(dest, &str->ptr[i], 1);
- } else switch (str->ptr[i]) {
- case '"':
- BUFFER_APPEND_STRING_CONST(dest, "\\\"");
- break;
- case '\\':
- BUFFER_APPEND_STRING_CONST(dest, "\\\\");
- break;
- case '\b':
- BUFFER_APPEND_STRING_CONST(dest, "\\b");
- break;
- case '\n':
- BUFFER_APPEND_STRING_CONST(dest, "\\n");
- break;
- case '\r':
- BUFFER_APPEND_STRING_CONST(dest, "\\r");
- break;
- case '\t':
- BUFFER_APPEND_STRING_CONST(dest, "\\t");
- break;
- case '\v':
- BUFFER_APPEND_STRING_CONST(dest, "\\v");
- break;
- default: {
- /* non printable char => \xHH */
- char hh[5] = {'\\','x',0,0,0};
- char h = str->ptr[i] / 16;
- hh[2] = (h > 9) ? (h - 10 + 'A') : (h + '0');
- h = str->ptr[i] % 16;
- hh[3] = (h > 9) ? (h - 10 + 'A') : (h + '0');
- buffer_append_string_len(dest, &hh[0], 4);
+ for (ptr = start = str->ptr, end = str->ptr + str->used - 1; ptr < end; ptr++) {
+ if (*ptr >= ' ' && *ptr <= '~') {
+ /* nothing to change, add later as one block */
+ } else {
+ /* copy previous part */
+ if (start < ptr) {
+ buffer_append_string_len(dest, start, ptr - start);
+ }
+ start = ptr + 1;
+
+ switch (*ptr) {
+ case '"':
+ BUFFER_APPEND_STRING_CONST(dest, "\\\"");
+ break;
+ case '\\':
+ BUFFER_APPEND_STRING_CONST(dest, "\\\\");
+ break;
+ case '\b':
+ BUFFER_APPEND_STRING_CONST(dest, "\\b");
+ break;
+ case '\n':
+ BUFFER_APPEND_STRING_CONST(dest, "\\n");
+ break;
+ case '\r':
+ BUFFER_APPEND_STRING_CONST(dest, "\\r");
+ break;
+ case '\t':
+ BUFFER_APPEND_STRING_CONST(dest, "\\t");
+ break;
+ case '\v':
+ BUFFER_APPEND_STRING_CONST(dest, "\\v");
+ break;
+ default: {
+ /* non printable char => \xHH */
+ char hh[5] = {'\\','x',0,0,0};
+ char h = *ptr / 16;
+ hh[2] = (h > 9) ? (h - 10 + 'A') : (h + '0');
+ h = *ptr % 16;
+ hh[3] = (h > 9) ? (h - 10 + 'A') : (h + '0');
+ buffer_append_string_len(dest, &hh[0], 4);
+ }
+ break;
}
- break;
}
}
+
+ if (start < end) {
+ buffer_append_string_len(dest, start, end - start);
+ }
}
static int accesslog_parse_format(server *srv, format_fields *fields, buffer *format) {
@@ -845,7 +858,7 @@ REQUESTDONE_FUNC(log_access_write) {
break;
case FORMAT_SERVER_PORT:
{
- char *colon = strchr(((server_socket*)(con->srv_socket))->srv_token->ptr, ':');
+ char *colon = strrchr(((server_socket*)(con->srv_socket))->srv_token->ptr, ':');
if (colon) {
buffer_append_string(b, colon+1);
} else {
diff --git a/src/mod_cgi.c b/src/mod_cgi.c
index dd2b9bc..1608f02 100644
--- a/src/mod_cgi.c
+++ b/src/mod_cgi.c
@@ -577,6 +577,8 @@ static handler_t cgi_connection_close(server *srv, handler_ctx *hctx) {
connection_set_state(srv, con, CON_STATE_HANDLE_REQUEST);
con->http_status = 500;
con->mode = DIRECT;
+ } else {
+ con->file_finished = 1;
}
if (WIFEXITED(status)) {
@@ -607,8 +609,7 @@ static handler_t cgi_connection_close_callback(server *srv, connection *con, voi
}
-static handler_t cgi_handle_fdevent(void *s, void *ctx, int revents) {
- server *srv = (server *)s;
+static handler_t cgi_handle_fdevent(server *srv, void *ctx, int revents) {
handler_ctx *hctx = ctx;
connection *con = hctx->remote_conn;
@@ -635,9 +636,14 @@ static handler_t cgi_handle_fdevent(void *s, void *ctx, int revents) {
/* if we get a IN|HUP and have read everything don't exec the close twice */
return HANDLER_FINISHED;
case FDEVENT_HANDLED_ERROR:
- connection_set_state(srv, con, CON_STATE_HANDLE_REQUEST);
- con->http_status = 500;
- con->mode = DIRECT;
+ /* Send an error if we haven't sent any data yet */
+ if (0 == con->file_started) {
+ connection_set_state(srv, con, CON_STATE_HANDLE_REQUEST);
+ con->http_status = 500;
+ con->mode = DIRECT;
+ } else {
+ con->file_finished = 1;
+ }
log_error_write(srv, __FILE__, __LINE__, "s", "demuxer failed: ");
break;
@@ -1151,7 +1157,7 @@ static int cgi_create_env(server *srv, connection *con, plugin_data *p, buffer *
con->plugin_ctx[p->id] = hctx;
fdevent_register(srv->ev, hctx->fd, cgi_handle_fdevent, hctx);
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
if (-1 == fdevent_fcntl_set(srv->ev, hctx->fd)) {
log_error_write(srv, __FILE__, __LINE__, "ss", "fcntl failed: ", strerror(errno));
@@ -1302,6 +1308,11 @@ TRIGGER_FUNC(cgi_trigger) {
return HANDLER_GO_ON;
}
+/*
+ * - HANDLER_GO_ON : not our job
+ * - HANDLER_FINISHED: got response header
+ * - HANDLER_WAIT_FOR_EVENT: waiting for response header
+ */
SUBREQUEST_FUNC(mod_cgi_handle_subrequest) {
int status;
plugin_data *p = p_d;
@@ -1313,7 +1324,13 @@ SUBREQUEST_FUNC(mod_cgi_handle_subrequest) {
#if 0
log_error_write(srv, __FILE__, __LINE__, "sdd", "subrequest, pid =", hctx, hctx->pid);
#endif
- if (hctx->pid == 0) return HANDLER_FINISHED;
+
+ if (hctx->pid == 0) {
+ /* cgi already dead */
+ if (!con->file_started) return HANDLER_WAIT_FOR_EVENT;
+ return HANDLER_FINISHED;
+ }
+
#ifndef __WIN32
switch(waitpid(hctx->pid, &status, WNOHANG)) {
case 0:
@@ -1351,24 +1368,24 @@ SUBREQUEST_FUNC(mod_cgi_handle_subrequest) {
return HANDLER_FINISHED;
default:
- /* cgi process exited cleanly
- *
- * check if we already got the response
+ /* cgi process exited
*/
- if (!con->file_started) return HANDLER_WAIT_FOR_EVENT;
-
- if (WIFEXITED(status)) {
- /* nothing */
- } else {
- log_error_write(srv, __FILE__, __LINE__, "s", "cgi died ?");
+ hctx->pid = 0;
- con->mode = DIRECT;
- con->http_status = 500;
+ /* we already have response headers? just continue */
+ if (con->file_started) return HANDLER_FINISHED;
+ if (WIFEXITED(status)) {
+ /* clean exit - just continue */
+ return HANDLER_WAIT_FOR_EVENT;
}
- hctx->pid = 0;
+ /* cgi proc died, and we didn't get any data yet - send error message and close cgi con */
+ log_error_write(srv, __FILE__, __LINE__, "s", "cgi died ?");
+
+ con->http_status = 500;
+ con->mode = DIRECT;
fdevent_event_del(srv->ev, &(hctx->fde_ndx), hctx->fd);
fdevent_unregister(srv->ev, hctx->fd);
diff --git a/src/mod_compress.c b/src/mod_compress.c
index 1293950..748fc65 100644
--- a/src/mod_compress.c
+++ b/src/mod_compress.c
@@ -744,6 +744,7 @@ PHYSICALPATH_FUNC(mod_compress_physical) {
int accept_encoding = 0;
char *value = ds->value->ptr;
int matched_encodings = 0;
+ int use_etag = sce->etag != NULL && sce->etag->ptr != NULL;
/* get client side support encodings */
#ifdef USE_ZLIB
@@ -770,12 +771,14 @@ PHYSICALPATH_FUNC(mod_compress_physical) {
mtime = strftime_cache_get(srv, sce->st.st_mtime);
/* try matching original etag of uncompressed version */
- etag_mutate(con->physical.etag, sce->etag);
- if (HANDLER_FINISHED == http_response_handle_cachable(srv, con, mtime)) {
- response_header_overwrite(srv, con, CONST_STR_LEN("Content-Type"), CONST_BUF_LEN(sce->content_type));
- response_header_overwrite(srv, con, CONST_STR_LEN("Last-Modified"), CONST_BUF_LEN(mtime));
- response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
- return HANDLER_FINISHED;
+ if (use_etag) {
+ etag_mutate(con->physical.etag, sce->etag);
+ if (HANDLER_FINISHED == http_response_handle_cachable(srv, con, mtime)) {
+ response_header_overwrite(srv, con, CONST_STR_LEN("Content-Type"), CONST_BUF_LEN(sce->content_type));
+ response_header_overwrite(srv, con, CONST_STR_LEN("Last-Modified"), CONST_BUF_LEN(mtime));
+ response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
+ return HANDLER_FINISHED;
+ }
}
/* select best matching encoding */
@@ -790,22 +793,26 @@ PHYSICALPATH_FUNC(mod_compress_physical) {
compression_name = dflt_deflate;
}
- /* try matching etag of compressed version */
- buffer_copy_string_buffer(srv->tmp_buf, sce->etag);
- buffer_append_string_len(srv->tmp_buf, CONST_STR_LEN("-"));
- buffer_append_string(srv->tmp_buf, compression_name);
- etag_mutate(con->physical.etag, srv->tmp_buf);
+ if (use_etag) {
+ /* try matching etag of compressed version */
+ buffer_copy_string_buffer(srv->tmp_buf, sce->etag);
+ buffer_append_string_len(srv->tmp_buf, CONST_STR_LEN("-"));
+ buffer_append_string(srv->tmp_buf, compression_name);
+ etag_mutate(con->physical.etag, srv->tmp_buf);
+ }
if (HANDLER_FINISHED == http_response_handle_cachable(srv, con, mtime)) {
response_header_overwrite(srv, con, CONST_STR_LEN("Content-Encoding"), compression_name, strlen(compression_name));
response_header_overwrite(srv, con, CONST_STR_LEN("Content-Type"), CONST_BUF_LEN(sce->content_type));
response_header_overwrite(srv, con, CONST_STR_LEN("Last-Modified"), CONST_BUF_LEN(mtime));
- response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
+ if (use_etag) {
+ response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
+ }
return HANDLER_FINISHED;
}
/* deflate it */
- if (p->conf.compress_cache_dir->used) {
+ if (use_etag && p->conf.compress_cache_dir->used) {
if (0 != deflate_file_to_file(srv, con, p, con->physical.path, sce, compression_type))
return HANDLER_GO_ON;
} else {
@@ -814,7 +821,9 @@ PHYSICALPATH_FUNC(mod_compress_physical) {
}
response_header_overwrite(srv, con, CONST_STR_LEN("Content-Encoding"), compression_name, strlen(compression_name));
response_header_overwrite(srv, con, CONST_STR_LEN("Last-Modified"), CONST_BUF_LEN(mtime));
- response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
+ if (use_etag) {
+ response_header_overwrite(srv, con, CONST_STR_LEN("ETag"), CONST_BUF_LEN(con->physical.etag));
+ }
response_header_overwrite(srv, con, CONST_STR_LEN("Content-Type"), CONST_BUF_LEN(sce->content_type));
/* let mod_staticfile handle the cached compressed files, physical path was modified */
return p->conf.compress_cache_dir->used ? HANDLER_GO_ON : HANDLER_FINISHED;
diff --git a/src/mod_dirlisting.c b/src/mod_dirlisting.c
index 4adc879..bef8923 100644
--- a/src/mod_dirlisting.c
+++ b/src/mod_dirlisting.c
@@ -924,7 +924,7 @@ URIHANDLER_FUNC(mod_dirlisting_subrequest) {
}
if (HANDLER_ERROR == stat_cache_get_entry(srv, con, con->physical.path, &sce)) {
- fprintf(stderr, "%s.%d: %s\n", __FILE__, __LINE__, con->physical.path->ptr);
+ log_error_write(srv, __FILE__, __LINE__, "SB", "stat_cache_get_entry failed: ", con->physical.path);
SEGFAULT();
}
diff --git a/src/mod_extforward.c b/src/mod_extforward.c
index afcc559..a196db1 100644
--- a/src/mod_extforward.c
+++ b/src/mod_extforward.c
@@ -16,6 +16,7 @@
#include <string.h>
#include <stdio.h>
#include <netinet/in.h>
+#include <errno.h>
/**
* mod_extforward.c for lighttpd, by comman.kang <at> gmail <dot> com
@@ -302,7 +303,7 @@ static const char *last_not_in_array(array *a, plugin_data *p)
return NULL;
}
-static struct addrinfo *ipstr_to_sockaddr(const char *host) {
+static struct addrinfo *ipstr_to_sockaddr(server *srv, const char *host) {
struct addrinfo hints, *res0;
int result;
@@ -319,17 +320,17 @@ static struct addrinfo *ipstr_to_sockaddr(const char *host) {
#endif
hints.ai_flags = AI_NUMERICHOST | AI_NUMERICSERV;
+ errno = 0;
result = getaddrinfo(host, NULL, &hints, &res0);
if (result != 0) {
- fprintf(stderr, "could not resolve hostname %s because %s\n", host, gai_strerror(result));
-
- if (result == EAI_SYSTEM)
- perror("The system error is ");
+ log_error_write(srv, __FILE__, __LINE__, "SSSs(S)",
+ "could not resolve hostname ", host, " because ", gai_strerror(result), strerror(errno));
return NULL;
} else if (res0 == 0) {
- fprintf(stderr, "Problem in resolving hostname %s: succeeded, but no information returned\n", host);
+ log_error_write(srv, __FILE__, __LINE__, "SSS",
+ "Problem in resolving hostname ", host, ": succeeded, but no information returned");
}
return res0;
@@ -424,7 +425,7 @@ URIHANDLER_FUNC(mod_extforward_uri_handler) {
log_error_write(srv, __FILE__, __LINE__, "ss", "using address:", real_remote_addr);
}
#ifdef HAVE_IPV6
- addrlist = ipstr_to_sockaddr(real_remote_addr);
+ addrlist = ipstr_to_sockaddr(srv, real_remote_addr);
sock.plain.sa_family = AF_UNSPEC;
for (addrs_left = addrlist; addrs_left != NULL; addrs_left = addrs_left -> ai_next) {
sock.plain.sa_family = addrs_left->ai_family;
diff --git a/src/mod_fastcgi.c b/src/mod_fastcgi.c
index dfc605e..ae39d89 100644
--- a/src/mod_fastcgi.c
+++ b/src/mod_fastcgi.c
@@ -302,7 +302,7 @@ typedef struct {
array *ext_mapping;
- int debug;
+ unsigned int debug;
} plugin_config;
typedef struct {
@@ -370,7 +370,7 @@ typedef struct {
/* ok, we need a prototype */
-static handler_t fcgi_handle_fdevent(void *s, void *ctx, int revents);
+static handler_t fcgi_handle_fdevent(server *srv, void *ctx, int revents);
static void reset_signals(void) {
#ifdef SIGTTOU
@@ -1166,7 +1166,7 @@ SETDEFAULTS_FUNC(mod_fastcgi_set_defaults) {
config_values_t cv[] = {
{ "fastcgi.server", NULL, T_CONFIG_LOCAL, T_CONFIG_SCOPE_CONNECTION }, /* 0 */
- { "fastcgi.debug", NULL, T_CONFIG_SHORT, T_CONFIG_SCOPE_CONNECTION }, /* 1 */
+ { "fastcgi.debug", NULL, T_CONFIG_INT , T_CONFIG_SCOPE_CONNECTION }, /* 1 */
{ "fastcgi.map-extensions", NULL, T_CONFIG_ARRAY, T_CONFIG_SCOPE_CONNECTION }, /* 2 */
{ NULL, NULL, T_CONFIG_UNSET, T_CONFIG_SCOPE_UNSET }
};
@@ -2195,20 +2195,6 @@ static int fcgi_create_env(server *srv, handler_ctx *hctx, size_t request_id) {
hctx->wb->bytes_in += sizeof(header);
-#if 0
- for (i = 0; i < hctx->write_buffer->used; i++) {
- fprintf(stderr, "%02x ", hctx->write_buffer->ptr[i]);
- if ((i+1) % 16 == 0) {
- size_t j;
- for (j = i-15; j <= i; j++) {
- fprintf(stderr, "%c",
- isprint((unsigned char)hctx->write_buffer->ptr[j]) ? hctx->write_buffer->ptr[j] : '.');
- }
- fprintf(stderr, "\n");
- }
- }
-#endif
-
return 0;
}
@@ -2680,6 +2666,10 @@ static int fcgi_demux_response(server *srv, handler_ctx *hctx) {
log_error_write(srv, __FILE__, __LINE__, "sb",
"send-file error: couldn't get stat_cache entry for:",
ds->value);
+ con->http_status = 502;
+ hctx->send_content_body = 0;
+ con->file_started = 1;
+ break;
}
}
@@ -2999,7 +2989,7 @@ static handler_t fcgi_write_request(server *srv, handler_ctx *hctx) {
case CONNECTION_DELAYED:
/* connection is in progress, wait for an event and call getsockopt() below */
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
fcgi_set_state(srv, hctx, FCGI_STATE_CONNECT_DELAYED);
return HANDLER_WAIT_FOR_EVENT;
@@ -3118,10 +3108,10 @@ static handler_t fcgi_write_request(server *srv, handler_ctx *hctx) {
if (hctx->wb->bytes_out == hctx->wb->bytes_in) {
/* we don't need the out event anymore */
fdevent_event_del(srv->ev, &(hctx->fde_ndx), hctx->fd);
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
fcgi_set_state(srv, hctx, FCGI_STATE_READ);
} else {
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
return HANDLER_WAIT_FOR_EVENT;
}
@@ -3261,8 +3251,7 @@ SUBREQUEST_FUNC(mod_fastcgi_handle_subrequest) {
}
}
-static handler_t fcgi_handle_fdevent(void *s, void *ctx, int revents) {
- server *srv = (server *)s;
+static handler_t fcgi_handle_fdevent(server *srv, void *ctx, int revents) {
handler_ctx *hctx = ctx;
connection *con = hctx->remote_conn;
plugin_data *p = hctx->plugin_data;
@@ -3737,12 +3726,12 @@ JOBLIST_FUNC(mod_fastcgi_handle_joblist) {
if (hctx->fd != -1) {
switch (hctx->state) {
case FCGI_STATE_READ:
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
break;
case FCGI_STATE_CONNECT_DELAYED:
case FCGI_STATE_WRITE:
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
break;
case FCGI_STATE_INIT:
diff --git a/src/mod_proxy.c b/src/mod_proxy.c
index 6a8b8b1..b54d243 100644
--- a/src/mod_proxy.c
+++ b/src/mod_proxy.c
@@ -112,7 +112,7 @@ typedef struct {
/* ok, we need a prototype */
-static handler_t proxy_handle_fdevent(void *s, void *ctx, int revents);
+static handler_t proxy_handle_fdevent(server *srv, void *ctx, int revents);
static handler_ctx * handler_ctx_init() {
handler_ctx * hctx;
@@ -349,6 +349,10 @@ static void proxy_connection_close(server *srv, handler_ctx *hctx) {
srv->cur_fds--;
}
+ if (hctx->host) {
+ hctx->host->usage--;
+ }
+
handler_ctx_free(hctx);
con->plugin_ctx[p->id] = NULL;
}
@@ -794,7 +798,7 @@ static handler_t proxy_write_request(server *srv, handler_ctx *hctx) {
/* connection is in progress, wait for an event and call getsockopt() below */
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
return HANDLER_WAIT_FOR_EVENT;
case -1:
@@ -848,20 +852,20 @@ static handler_t proxy_write_request(server *srv, handler_ctx *hctx) {
if (-1 == ret) { /* error on our side */
log_error_write(srv, __FILE__, __LINE__, "ssd", "write failed:", strerror(errno), errno);
- return HANDLER_WAIT_FOR_EVENT;
+ return HANDLER_ERROR;
} else if (-2 == ret) { /* remote close */
log_error_write(srv, __FILE__, __LINE__, "ssd", "write failed, remote connection close:", strerror(errno), errno);
- return HANDLER_WAIT_FOR_EVENT;
+ return HANDLER_ERROR;
}
if (hctx->wb->bytes_out == hctx->wb->bytes_in) {
proxy_set_state(srv, hctx, PROXY_STATE_READ);
fdevent_event_del(srv->ev, &(hctx->fde_ndx), hctx->fd);
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
} else {
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
return HANDLER_WAIT_FOR_EVENT;
}
@@ -956,7 +960,7 @@ SUBREQUEST_FUNC(mod_proxy_handle_subrequest) {
return HANDLER_WAIT_FOR_FD;
case HANDLER_WAIT_FOR_EVENT:
- return HANDLER_WAIT_FOR_EVENT;
+ break;
case HANDLER_WAIT_FOR_FD:
return HANDLER_WAIT_FOR_FD;
default:
@@ -970,8 +974,7 @@ SUBREQUEST_FUNC(mod_proxy_handle_subrequest) {
}
}
-static handler_t proxy_handle_fdevent(void *s, void *ctx, int revents) {
- server *srv = (server *)s;
+static handler_t proxy_handle_fdevent(server *srv, void *ctx, int revents) {
handler_ctx *hctx = ctx;
connection *con = hctx->remote_conn;
plugin_data *p = hctx->plugin_data;
@@ -989,8 +992,6 @@ static handler_t proxy_handle_fdevent(void *s, void *ctx, int revents) {
case 0:
break;
case 1:
- hctx->host->usage--;
-
/* we are done */
proxy_connection_close(srv, hctx);
@@ -1077,8 +1078,11 @@ static handler_t proxy_handle_fdevent(void *s, void *ctx, int revents) {
return HANDLER_FINISHED;
}
- con->file_finished = 1;
+ if (!con->file_finished) {
+ http_chunk_append_mem(srv, con, NULL, 0);
+ }
+ con->file_finished = 1;
proxy_connection_close(srv, hctx);
joblist_append(srv, con);
} else if (revents & FDEVENT_ERR) {
@@ -1086,6 +1090,7 @@ static handler_t proxy_handle_fdevent(void *s, void *ctx, int revents) {
log_error_write(srv, __FILE__, __LINE__, "sd", "proxy-FDEVENT_ERR, but no HUP", revents);
+ con->file_finished = 1;
joblist_append(srv, con);
proxy_connection_close(srv, hctx);
}
diff --git a/src/mod_redirect.c b/src/mod_redirect.c
index 976d845..f9147cb 100644
--- a/src/mod_redirect.c
+++ b/src/mod_redirect.c
@@ -118,7 +118,7 @@ SETDEFAULTS_FUNC(mod_redirect_set_defaults) {
return HANDLER_ERROR;
}
- if (0 != pcre_keyvalue_buffer_append(s->redirect,
+ if (0 != pcre_keyvalue_buffer_append(srv, s->redirect,
((data_string *)(da->value->data[j]))->key->ptr,
((data_string *)(da->value->data[j]))->value->ptr)) {
diff --git a/src/mod_scgi.c b/src/mod_scgi.c
index 3702bd2..0455fbf 100644
--- a/src/mod_scgi.c
+++ b/src/mod_scgi.c
@@ -328,7 +328,7 @@ typedef struct {
/* ok, we need a prototype */
-static handler_t scgi_handle_fdevent(void *s, void *ctx, int revents);
+static handler_t scgi_handle_fdevent(server *srv, void *ctx, int revents);
int scgi_proclist_sort_down(server *srv, scgi_extension_host *host, scgi_proc *proc);
@@ -1676,20 +1676,6 @@ static int scgi_create_env(server *srv, handler_ctx *hctx) {
}
}
-#if 0
- for (i = 0; i < hctx->write_buffer->used; i++) {
- fprintf(stderr, "%02x ", hctx->write_buffer->ptr[i]);
- if ((i+1) % 16 == 0) {
- size_t j;
- for (j = i-15; j <= i; j++) {
- fprintf(stderr, "%c",
- isprint((unsigned char)hctx->write_buffer->ptr[j]) ? hctx->write_buffer->ptr[j] : '.');
- }
- fprintf(stderr, "\n");
- }
- }
-#endif
-
return 0;
}
@@ -2244,7 +2230,7 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
/* connection is in progress, wait for an event and call getsockopt() below */
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
return HANDLER_WAIT_FOR_EVENT;
case -1:
@@ -2357,10 +2343,10 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
if (hctx->wb->bytes_out == hctx->wb->bytes_in) {
/* we don't need the out event anymore */
fdevent_event_del(srv->ev, &(hctx->fde_ndx), hctx->fd);
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
scgi_set_state(srv, hctx, FCGI_STATE_READ);
} else {
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
return HANDLER_WAIT_FOR_EVENT;
}
@@ -2494,8 +2480,7 @@ static handler_t scgi_connection_close(server *srv, handler_ctx *hctx) {
}
-static handler_t scgi_handle_fdevent(void *s, void *ctx, int revents) {
- server *srv = (server *)s;
+static handler_t scgi_handle_fdevent(server *srv, void *ctx, int revents) {
handler_ctx *hctx = ctx;
connection *con = hctx->remote_conn;
plugin_data *p = hctx->plugin_data;
@@ -2906,12 +2891,12 @@ JOBLIST_FUNC(mod_scgi_handle_joblist) {
if (hctx->fd != -1) {
switch (hctx->state) {
case FCGI_STATE_READ:
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_IN);
break;
case FCGI_STATE_CONNECT:
case FCGI_STATE_WRITE:
- fdevent_event_add(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
+ fdevent_event_set(srv->ev, &(hctx->fde_ndx), hctx->fd, FDEVENT_OUT);
break;
case FCGI_STATE_INIT:
diff --git a/src/mod_staticfile.c b/src/mod_staticfile.c
index 41dc6a2..9b937ce 100644
--- a/src/mod_staticfile.c
+++ b/src/mod_staticfile.c
@@ -385,6 +385,9 @@ URIHANDLER_FUNC(mod_staticfile_subrequest) {
if (ds->value->used == 0) continue;
if (buffer_is_equal_right_len(con->physical.path, ds->value, ds->value->used - 1)) {
+ if (con->conf.log_request_handling) {
+ log_error_write(srv, __FILE__, __LINE__, "s", "-- NOT handling file as static file, extension forbidden");
+ }
return HANDLER_GO_ON;
}
}
diff --git a/src/mod_status.c b/src/mod_status.c
index df5bdb8..e1a11a0 100644
--- a/src/mod_status.c
+++ b/src/mod_status.c
@@ -299,7 +299,7 @@ static handler_t mod_status_handle_server_status_html(server *srv, connection *c
/* connection listing */
- buffer_append_string_len(b, CONST_STR_LEN("<h1>Server-Status</h1>"));
+ buffer_append_string_len(b, CONST_STR_LEN("<h1>Server-Status (" PACKAGE_NAME " " PACKAGE_VERSION ")</h1>"));
buffer_append_string_len(b, CONST_STR_LEN("<table summary=\"status\" class=\"status\">"));
buffer_append_string_len(b, CONST_STR_LEN("<tr><td>Hostname</td><td class=\"string\">"));
@@ -676,21 +676,20 @@ static handler_t mod_status_handle_server_config(server *srv, connection *con, v
struct ev_map { fdevent_handler_t et; const char *name; } event_handlers[] =
{
- /* - poll is most reliable
+ /* - epoll is most reliable
* - select works everywhere
- * - linux-* are experimental
*/
+#ifdef USE_LINUX_EPOLL
+ { FDEVENT_HANDLER_LINUX_SYSEPOLL, "linux-sysepoll" },
+#endif
#ifdef USE_POLL
{ FDEVENT_HANDLER_POLL, "poll" },
#endif
#ifdef USE_SELECT
{ FDEVENT_HANDLER_SELECT, "select" },
#endif
-#ifdef USE_LINUX_EPOLL
- { FDEVENT_HANDLER_LINUX_SYSEPOLL, "linux-sysepoll" },
-#endif
-#ifdef USE_LINUX_SIGIO
- { FDEVENT_HANDLER_LINUX_RTSIG, "linux-rtsig" },
+#ifdef USE_LIBEV
+ { FDEVENT_HANDLER_LIBEV, "libev" },
#endif
#ifdef USE_SOLARIS_DEVPOLL
{ FDEVENT_HANDLER_SOLARIS_DEVPOLL,"solaris-devpoll" },
diff --git a/src/network.c b/src/network.c
index 4b07618..a98b4b8 100644
--- a/src/network.c
+++ b/src/network.c
@@ -27,15 +27,14 @@
# include <openssl/rand.h>
#endif
-static handler_t network_server_handle_fdevent(void *s, void *context, int revents) {
- server *srv = (server *)s;
+static handler_t network_server_handle_fdevent(server *srv, void *context, int revents) {
server_socket *srv_socket = (server_socket *)context;
connection *con;
int loops = 0;
UNUSED(context);
- if (revents != FDEVENT_IN) {
+ if (0 == (revents & FDEVENT_IN)) {
log_error_write(srv, __FILE__, __LINE__, "sdd",
"strange event for server socket",
srv_socket->fd,
@@ -82,6 +81,9 @@ static int network_ssl_servername_callback(SSL *ssl, int *al, server *srv) {
buffer_copy_string(con->tlsext_server_name, servername);
buffer_to_lower(con->tlsext_server_name);
+ /* Sometimes this is still set, confusing COMP_HTTP_HOST */
+ buffer_reset(con->uri.authority);
+
config_cond_cache_reset(srv, con);
config_setup_connection(srv, con);
@@ -223,7 +225,7 @@ static int network_server_init(server *srv, buffer *host_token, specific_config
val = 1;
if (setsockopt(srv_socket->fd, SOL_SOCKET, SO_REUSEADDR, &val, sizeof(val)) < 0) {
- log_error_write(srv, __FILE__, __LINE__, "ss", "socketsockopt failed:", strerror(errno));
+ log_error_write(srv, __FILE__, __LINE__, "ss", "socketsockopt(SO_REUSEADDR) failed:", strerror(errno));
goto error_free_socket;
}
@@ -234,10 +236,21 @@ static int network_server_init(server *srv, buffer *host_token, specific_config
srv_socket->addr.ipv6.sin6_family = AF_INET6;
if (host == NULL) {
srv_socket->addr.ipv6.sin6_addr = in6addr_any;
+ log_error_write(srv, __FILE__, __LINE__, "s", "warning: please use server.use-ipv6 only for hostnames, not without server.bind / empty address; your config will break if the kernel default for IPV6_V6ONLY changes");
} else {
struct addrinfo hints, *res;
int r;
+ if (s->set_v6only) {
+ val = 1;
+ if (-1 == setsockopt(srv_socket->fd, IPPROTO_IPV6, IPV6_V6ONLY, &val, sizeof(val))) {
+ log_error_write(srv, __FILE__, __LINE__, "ss", "socketsockopt(IPV6_V6ONLY) failed:", strerror(errno));
+ goto error_free_socket;
+ }
+ } else {
+ log_error_write(srv, __FILE__, __LINE__, "s", "warning: server.set-v6only will be removed soon, update your config to have different sockets for ipv4 and ipv6");
+ }
+
memset(&hints, 0, sizeof(hints));
hints.ai_family = AF_INET6;
@@ -525,7 +538,7 @@ int network_init(server *srv) {
if (!s->ssl_use_sslv2) {
/* disable SSLv2 */
- if (SSL_OP_NO_SSLv2 != SSL_CTX_set_options(s->ssl_ctx, SSL_OP_NO_SSLv2)) {
+ if (!(SSL_OP_NO_SSLv2 & SSL_CTX_set_options(s->ssl_ctx, SSL_OP_NO_SSLv2))) {
log_error_write(srv, __FILE__, __LINE__, "ss", "SSL:",
ERR_error_string(ERR_get_error(), NULL));
return -1;
@@ -711,7 +724,7 @@ int network_register_fdevents(server *srv) {
server_socket *srv_socket = srv->srv_sockets.ptr[i];
fdevent_register(srv->ev, srv_socket->fd, network_server_handle_fdevent, srv_socket);
- fdevent_event_add(srv->ev, &(srv_socket->fde_ndx), srv_socket->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(srv_socket->fde_ndx), srv_socket->fd, FDEVENT_IN);
}
return 0;
}
diff --git a/src/plugin.c b/src/plugin.c
index 0690629..55f8b03 100644
--- a/src/plugin.c
+++ b/src/plugin.c
@@ -120,12 +120,19 @@ int plugins_load(server *srv) {
plugin *p;
int (*init)(plugin *pl);
const char *error;
- size_t i;
+ size_t i, j;
for (i = 0; i < srv->srvconf.modules->used; i++) {
data_string *d = (data_string *)srv->srvconf.modules->data[i];
char *modules = d->value->ptr;
+ for (j = 0; j < i; j++) {
+ if (buffer_is_equal(d->value, ((data_string *) srv->srvconf.modules->data[j])->value)) {
+ log_error_write(srv, __FILE__, __LINE__, "sbs", "Cannot load plugin", d->value, "more than once, please fix your config (we may not accept such configs in future releases");
+ continue;
+ }
+ }
+
buffer_copy_string_buffer(srv->tmp_buf, srv->srvconf.modules_dir);
buffer_append_string_len(srv->tmp_buf, CONST_STR_LEN("/"));
diff --git a/src/response.c b/src/response.c
index 7ba5281..e829cfd 100644
--- a/src/response.c
+++ b/src/response.c
@@ -136,6 +136,8 @@ static void https_add_ssl_entries(connection *con) {
X509 *xs;
X509_NAME *xn;
X509_NAME_ENTRY *xe;
+ int i, nentries;
+
if (
SSL_get_verify_result(con->ssl) != X509_V_OK
|| !(xs = SSL_get_peer_certificate(con->ssl))
@@ -144,7 +146,7 @@ static void https_add_ssl_entries(connection *con) {
}
xn = X509_get_subject_name(xs);
- for (int i = 0, nentries = X509_NAME_entry_count(xn); i < nentries; ++i) {
+ for (i = 0, nentries = X509_NAME_entry_count(xn); i < nentries; ++i) {
int xobjnid;
const char * xobjsn;
data_string *envds;
@@ -581,7 +583,7 @@ handler_t http_response_prepare(server *srv, connection *con) {
};
#endif
if (S_ISDIR(sce->st.st_mode)) {
- if (con->physical.path->ptr[con->physical.path->used - 2] != '/') {
+ if (con->uri.path->ptr[con->uri.path->used - 2] != '/') {
/* redirect to .../ */
http_response_redirect_to_directory(srv, con);
diff --git a/src/server.c b/src/server.c
index 1bedd00..0b92239 100644
--- a/src/server.c
+++ b/src/server.c
@@ -213,7 +213,9 @@ static server *server_init(void) {
if ((NULL != (frandom = fopen("/dev/urandom", "rb")) || NULL != (frandom = fopen("/dev/random", "rb")))
&& 1 == fread(srv->entropy, sizeof(srv->entropy), 1, frandom)) {
- srand(*(unsigned int*)srv->entropy);
+ unsigned int e;
+ memcpy(&e, srv->entropy, sizeof(e) < sizeof(srv->entropy) ? sizeof(e) : sizeof(srv->entropy));
+ srand(e);
srv->is_real_entropy = 1;
} else {
unsigned int j;
@@ -394,6 +396,11 @@ static void show_features (void) {
#else
"\t- kqueue (FreeBSD)\n"
#endif
+#ifdef USE_LIBEV
+ "\t+ libev (generic)\n"
+#else
+ "\t- libev (generic)\n"
+#endif
"\nNetwork handler:\n\n"
#if defined(USE_LINUX_SENDFILE) || defined(USE_FREEBSD_SENDFILE) || defined(USE_SOLARIS_SENDFILEV) || defined(USE_AIX_SENDFILE)
"\t+ sendfile\n"
@@ -1101,7 +1108,7 @@ int main (int argc, char **argv) {
}
#endif
- if (NULL == (srv->ev = fdevent_init(srv->max_fds + 1, srv->event_handler))) {
+ if (NULL == (srv->ev = fdevent_init(srv, srv->max_fds + 1, srv->event_handler))) {
log_error_write(srv, __FILE__, __LINE__,
"s", "fdevent_init failed");
return -1;
@@ -1140,7 +1147,7 @@ int main (int argc, char **argv) {
srv->stat_cache->fam_fcce_ndx = -1;
fdevent_register(srv->ev, FAMCONNECTION_GETFD(srv->stat_cache->fam), stat_cache_handle_fdevent, NULL);
- fdevent_event_add(srv->ev, &(srv->stat_cache->fam_fcce_ndx), FAMCONNECTION_GETFD(srv->stat_cache->fam), FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(srv->stat_cache->fam_fcce_ndx), FAMCONNECTION_GETFD(srv->stat_cache->fam), FDEVENT_IN);
}
#endif
@@ -1339,7 +1346,7 @@ int main (int argc, char **argv) {
(0 == graceful_shutdown)) {
for (i = 0; i < srv->srv_sockets.used; i++) {
server_socket *srv_socket = srv->srv_sockets.ptr[i];
- fdevent_event_add(srv->ev, &(srv_socket->fde_ndx), srv_socket->fd, FDEVENT_IN);
+ fdevent_event_set(srv->ev, &(srv_socket->fde_ndx), srv_socket->fd, FDEVENT_IN);
}
log_error_write(srv, __FILE__, __LINE__, "s", "[note] sockets enabled again");
@@ -1433,6 +1440,8 @@ int main (int argc, char **argv) {
handler_t r;
fd_ndx = fdevent_event_next_fdndx (srv->ev, fd_ndx);
+ if (-1 == fd_ndx) break; /* not all fdevent handlers know how many fds got an event */
+
revents = fdevent_event_get_revent (srv->ev, fd_ndx);
fd = fdevent_event_get_fd (srv->ev, fd_ndx);
handler = fdevent_get_handler(srv->ev, fd);
diff --git a/src/stat_cache.c b/src/stat_cache.c
index c1afade..3edaeeb 100644
--- a/src/stat_cache.c
+++ b/src/stat_cache.c
@@ -238,9 +238,8 @@ static uint32_t hashme(buffer *str) {
}
#ifdef HAVE_FAM_H
-handler_t stat_cache_handle_fdevent(void *_srv, void *_fce, int revent) {
+handler_t stat_cache_handle_fdevent(server *srv, void *_fce, int revent) {
size_t i;
- server *srv = _srv;
stat_cache *sc = srv->stat_cache;
size_t events;
@@ -433,7 +432,8 @@ handler_t stat_cache_get_entry(server *srv, connection *con, buffer *name, stat_
} else {
#ifdef DEBUG_STAT_CACHE
if (i != ctrl.used) {
- fprintf(stderr, "%s.%d: %08x was already inserted but not found in cache, %s\n", __FILE__, __LINE__, file_ndx, name->ptr);
+ log_error_write(srv, __FILE__, __LINE__, "xSB",
+ file_ndx, "was already inserted but not found in cache, ", name);
}
assert(i == ctrl.used);
#endif
diff --git a/src/stat_cache.h b/src/stat_cache.h
index e6f7796..7b80cce 100644
--- a/src/stat_cache.h
+++ b/src/stat_cache.h
@@ -7,7 +7,7 @@ stat_cache *stat_cache_init(void);
void stat_cache_free(stat_cache *fc);
handler_t stat_cache_get_entry(server *srv, connection *con, buffer *name, stat_cache_entry **fce);
-handler_t stat_cache_handle_fdevent(void *_srv, void *_fce, int revent);
+handler_t stat_cache_handle_fdevent(server *srv, void *_fce, int revent);
int stat_cache_trigger_cleanup(server *srv);
#endif
diff --git a/tests/Makefile.in b/tests/Makefile.in
index 2a15119..d32671c 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -174,6 +174,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -205,6 +207,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/123/Makefile.in b/tests/docroot/123/Makefile.in
index 51ef0f2..2f0f874 100644
--- a/tests/docroot/123/Makefile.in
+++ b/tests/docroot/123/Makefile.in
@@ -97,6 +97,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -128,6 +130,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/Makefile.in b/tests/docroot/Makefile.in
index 7782a33..b004d80 100644
--- a/tests/docroot/Makefile.in
+++ b/tests/docroot/Makefile.in
@@ -137,6 +137,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -168,6 +170,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/www/Makefile.in b/tests/docroot/www/Makefile.in
index b670fdb..ba3d7c0 100644
--- a/tests/docroot/www/Makefile.in
+++ b/tests/docroot/www/Makefile.in
@@ -137,6 +137,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -168,6 +170,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/www/expire/Makefile.in b/tests/docroot/www/expire/Makefile.in
index f36fc1b..aa3179b 100644
--- a/tests/docroot/www/expire/Makefile.in
+++ b/tests/docroot/www/expire/Makefile.in
@@ -97,6 +97,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -128,6 +130,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/www/go/Makefile.in b/tests/docroot/www/go/Makefile.in
index cba6259..523a476 100644
--- a/tests/docroot/www/go/Makefile.in
+++ b/tests/docroot/www/go/Makefile.in
@@ -97,6 +97,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -128,6 +130,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@
diff --git a/tests/docroot/www/indexfile/Makefile.in b/tests/docroot/www/indexfile/Makefile.in
index a255bad..b44c67c 100644
--- a/tests/docroot/www/indexfile/Makefile.in
+++ b/tests/docroot/www/indexfile/Makefile.in
@@ -97,6 +97,8 @@ LBER_LIB = @LBER_LIB@
LD = @LD@
LDAP_LIB = @LDAP_LIB@
LDFLAGS = @LDFLAGS@
+LIBEV_CFLAGS = @LIBEV_CFLAGS@
+LIBEV_LIBS = @LIBEV_LIBS@
LIBOBJS = @LIBOBJS@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
@@ -128,6 +130,8 @@ PATH_SEPARATOR = @PATH_SEPARATOR@
PCRECONFIG = @PCRECONFIG@
PCRE_LIB = @PCRE_LIB@
PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
RANLIB = @RANLIB@
SED = @SED@
SENDFILE_LIB = @SENDFILE_LIB@