Browse Source

[multiple] remove long-deprecated modules

x-ref:
  https://wiki.lighttpd.net/Docs_ConfigurationOptions#Deprecated
master
Glenn Strauss 6 months ago
parent
commit
86c2d30936
  1. 16
      INSTALL
  2. 31
      SConstruct
  3. 117
      configure.ac
  4. 4
      doc/config/conf.d/Makefile.am
  5. 27
      doc/config/conf.d/cml.conf
  6. 28
      doc/config/conf.d/geoip.conf
  7. 47
      doc/config/conf.d/mysql_vhost.conf
  8. 70
      doc/config/conf.d/trigger_b4_dl.conf
  9. 18
      doc/config/modules.conf
  10. 6
      doc/outdated/Makefile.am
  11. 261
      doc/outdated/cml.txt
  12. 148
      doc/outdated/geoip.txt
  13. 58
      doc/outdated/mysqlvhost.txt
  14. 57
      doc/outdated/trigger_b4_dl.txt
  15. 2
      meson.build
  16. 15
      meson_options.txt
  17. 10
      scripts/ci-build.sh
  18. 59
      src/CMakeLists.txt
  19. 64
      src/Makefile.am
  20. 13
      src/SConscript
  21. 7
      src/config.h.cmake
  22. 10
      src/configfile.c
  23. 48
      src/meson.build
  24. 501
      src/mod_authn_mysql.c
  25. 323
      src/mod_cml.c
  26. 37
      src/mod_cml.h
  27. 260
      src/mod_cml_funcs.c
  28. 16
      src/mod_cml_funcs.h
  29. 320
      src/mod_cml_lua.c
  30. 161
      src/mod_flv_streaming.c
  31. 291
      src/mod_geoip.c
  32. 385
      src/mod_mysql_vhost.c
  33. 619
      src/mod_trigger_b4_dl.c
  34. 10
      src/server.c

16
INSTALL

@ -60,10 +60,6 @@ optional packages for optional features ::
bzip2-libs
cyrus-sasl # SASL ./configure --with-sasl
cyrus-sasl-devel
gdbm # GDBM ./configure --with-gdbm
gdbm-devel
GeoIP-devel # GeoIP ./configure --with-geoip
GeoIP
gnutls # GnuTLS ./configure --with-gnutls
gnutls-devel
krb5-devel # Kerberos5 ./configure --with-krb5
@ -77,11 +73,9 @@ optional packages for optional features ::
libdbi-dbd-sqlite
libmaxminddb # MaxMindDB ./configure --with-maxminddb
libmaxminddb-devel
libmemcached-devel # Memcached ./configure --with-memcache
libmemcached-libs
libpq # Postgresql ./configure --with-pgsql
libpq-devel
libunwind # libunwind ./configure --with-libunwind
libunwind-devel # libunwind ./configure --with-libunwind
libuuid # libuuid ./configure --with-webdav-locks
libuuid-devel
libxml2 # libxml2 ./configure --with-webdav-props
@ -103,9 +97,9 @@ optional packages for optional features ::
openssl-libs
pam # PAM ./configure --with-pam
pam-devel
pcre # PCRE ./configure --with-pcre # (default)
pcre # PCRE ./configure --with-pcre
pcre-devel
pcre2 # PCRE ./configure --with-pcre2
pcre2 # PCRE ./configure --with-pcre2 # (default)
pcre2-devel
sqlite # SQLite ./configure --with-webdav-props
sqlite-devel
@ -113,9 +107,9 @@ optional packages for optional features ::
valgrind-devel
wolfssl # wolfSSL ./configure --with-wolfssl
wolfssl-devel
zlib # zlib ./configure --with-zlib
zlib # zlib ./configure --with-zlib # (default)
zlib-devel
zstd # zstd ./configure --with-zstd
libzstd # zstd ./configure --with-zstd
libzstd-devel
more options: ./configure --help

31
SConstruct

@ -244,15 +244,12 @@ vars.AddVariables(
BoolVariable('with_brotli', 'enable brotli compression', 'no'),
PackageVariable('with_dbi', 'enable dbi support', 'no'),
BoolVariable('with_fam', 'enable FAM/gamin support', 'no'),
BoolVariable('with_gdbm', 'enable gdbm support', 'no'),
BoolVariable('with_geoip', 'enable GeoIP support', 'no'),
BoolVariable('with_maxminddb', 'enable MaxMind GeoIP2 support', 'no'),
BoolVariable('with_krb5', 'enable krb5 auth support', 'no'),
BoolVariable('with_ldap', 'enable ldap auth support', 'no'),
# with_libev not supported
# with_libunwind not supported
BoolVariable('with_lua', 'enable lua support for mod_cml', 'no'),
BoolVariable('with_memcached', 'enable memcached support', 'no'),
BoolVariable('with_lua', 'enable lua support', 'no'),
PackageVariable('with_mysql', 'enable mysql support', 'no'),
BoolVariable('with_openssl', 'enable openssl support', 'no'),
PackageVariable('with_gnutls', 'enable GnuTLS support', 'no'),
@ -336,7 +333,6 @@ if 1:
LIBCRYPTO = '',
LIBDBI = '',
LIBDL = '',
LIBGDBM = '',
LIBGNUTLS = '',
LIBGSSAPI_KRB5 = '',
LIBKRB5 = '',
@ -346,7 +342,6 @@ if 1:
LIBMBEDTLS = '',
LIBMBEDX509 = '',
LIBMBEDCRYPTO = '',
LIBMEMCACHED = '',
LIBMYSQL = '',
LIBNSS = '',
LIBPAM = '',
@ -544,22 +539,6 @@ if 1:
)
autoconf.haveFunc('FAMNoExists')
if env['with_gdbm']:
if not autoconf.CheckLibWithHeader('gdbm', 'gdbm.h', 'C'):
fail("Couldn't find gdbm")
autoconf.env.Append(
CPPFLAGS = [ '-DHAVE_GDBM_H', '-DHAVE_GDBM' ],
LIBGDBM = 'gdbm',
)
if env['with_geoip']:
if not autoconf.CheckLibWithHeader('GeoIP', 'GeoIP.h', 'C'):
fail("Couldn't find geoip")
autoconf.env.Append(
CPPFLAGS = [ '-DHAVE_GEOIP' ],
LIBGEOIP = 'GeoIP',
)
if env['with_maxminddb']:
if not autoconf.CheckLibWithHeader('maxminddb', 'maxminddb.h', 'C'):
fail("Couldn't find maxminddb")
@ -604,14 +583,6 @@ if 1:
if not found_lua:
fail("Couldn't find any lua implementation")
if env['with_memcached']:
if not autoconf.CheckLibWithHeader('memcached', 'libmemcached/memcached.h', 'C'):
fail("Couldn't find memcached")
autoconf.env.Append(
CPPFLAGS = [ '-DUSE_MEMCACHED' ],
LIBMEMCACHED = 'memcached',
)
if env['with_mysql']:
mysql_config = autoconf.checkProgram('mysql', 'mysql_config')
if not autoconf.CheckParseConfigForLib('LIBMYSQL', mysql_config + ' --cflags --libs'):

117
configure.ac

@ -1296,66 +1296,6 @@ if test "$WITH_XXHASH" != no; then
AC_SUBST([XXHASH_LIBS])
fi
dnl Check for gdbm
AC_MSG_NOTICE([----------------------------------------])
AC_MSG_CHECKING([for gdbm])
AC_ARG_WITH([gdbm],
[AS_HELP_STRING([--with-gdbm], [gdbm storage for mod_trigger_b4_dl])],
[WITH_GDBM=$withval],
[WITH_GDBM=no]
)
AC_MSG_RESULT([$WITH_GDBM])
if test "$WITH_GDBM" != no; then
if test "$WITH_GDBM" != yes; then
GDBM_LIB="-L$WITH_GDBM -lgdbm"
CPPFLAGS="$CPPFLAGS -I$WITH_GDBM"
else
AC_CHECK_LIB([gdbm], [gdbm_open],
[GDBM_LIB=-lgdbm],
[AC_MSG_ERROR([gdbm lib not found, install it or build without --with-gdbm])]
)
AC_CHECK_HEADERS([gdbm.h], [],
[AC_MSG_ERROR([gdbm headers not found, install them or build without --with-gdbm])]
)
fi
AC_DEFINE([HAVE_GDBM], [1], [libgdbm])
AC_DEFINE([HAVE_GDBM_H], [1])
AC_SUBST([GDBM_LIB])
fi
AM_CONDITIONAL([BUILD_WITH_GDBM], [test "$WITH_GDBM" != no])
dnl Check for GeoIP
AC_MSG_NOTICE([----------------------------------------])
AC_MSG_CHECKING([for GeoIP])
AC_ARG_WITH([geoip],
[AS_HELP_STRING([--with-geoip], [IP-based geolocation lookup])],
[WITH_GEOIP=$withval],
[WITH_GEOIP=no]
)
AC_MSG_RESULT([$WITH_GEOIP])
if test "$WITH_GEOIP" != no; then
if test "$WITH_GEOIP" != yes; then
GEOIP_LIB="-L$WITH_GEOIP -lGeoIP"
CPPFLAGS="$CPPFLAGS -I$WITH_GEOIP"
else
AC_CHECK_LIB([GeoIP], [GeoIP_country_name_by_addr],
[GEOIP_LIB=-lGeoIP],
[AC_MSG_ERROR([GeoIP lib not found, install it or build without --with-geoip])]
)
AC_CHECK_HEADERS([GeoIP.h], [],
[AC_MSG_ERROR([GeoIP headers not found, install them or build without --with-geoip])]
)
fi
AC_DEFINE([HAVE_GEOIP], [1], [libGeoIP])
AC_DEFINE([HAVE_GEOIP_H], [1])
AC_SUBST([GEOIP_LIB])
fi
AM_CONDITIONAL([BUILD_WITH_GEOIP], [test "$WITH_GEOIP" != no])
dnl Check for maxminddb
AC_MSG_NOTICE([----------------------------------------])
AC_MSG_CHECKING([for maxminddb])
@ -1386,49 +1326,11 @@ if test "$WITH_MAXMINDDB" != no; then
fi
AM_CONDITIONAL([BUILD_WITH_MAXMINDDB], [test "$WITH_MAXMINDDB" != no])
dnl Check for memcached
AC_MSG_NOTICE([----------------------------------------])
AC_MSG_CHECKING([for memcached])
AC_ARG_WITH([memcached],
[AS_HELP_STRING([--with-memcached],
[memcached storage for mod_trigger_b4_dl/mod_cml]
)],
[WITH_MEMCACHED=$withval],
[WITH_MEMCACHED=no]
)
AC_MSG_RESULT([$WITH_MEMCACHED])
if test "$WITH_MEMCACHED" != no; then
if test "$WITH_MEMCACHED" != yes; then
MEMCACHED_LIB="-L$WITH_MEMCACHED -lMEMCACHED"
CPPFLAGS="$CPPFLAGS -I$WITH_MEMCACHED"
else
AC_CHECK_LIB([memcached], [memcached],
[ MEMCACHED_LIB=-lmemcached ],
[AC_MSG_ERROR([memcached lib not found, install it or build without --with-memcached])]
)
AC_CHECK_HEADERS([libmemcached/memcached.h], [],
[AC_MSG_ERROR([memcached headers not found, install them or build without --with-memcached])]
)
fi
AC_DEFINE([USE_MEMCACHED], [1], [libmemcached])
AC_SUBST([MEMCACHED_LIB])
fi
AM_CONDITIONAL([BUILD_WITH_MEMCACHED], [test "$WITH_MEMCACHED" != no])
BUILD_MOD_TRIGGER_B4_DL=no
if test "$WITH_MEMCACHED" != no || test "$WITH_GDBM" != no ; then
BUILD_MOD_TRIGGER_B4_DL=yes
fi
AM_CONDITIONAL([BUILD_MOD_TRIGGER_B4_DL], [test "$BUILD_MOD_TRIGGER_B4_DL" != no])
dnl Check for lua
AC_MSG_NOTICE([----------------------------------------])
AC_MSG_CHECKING([if lua-support is requested])
AC_ARG_WITH([lua],
[AS_HELP_STRING([--with-lua], [lua engine for mod_magnet/mod_cml])],
[AS_HELP_STRING([--with-lua], [lua engine for mod_magnet])],
[WITH_LUA=$withval],
[WITH_LUA=no]
)
@ -1765,7 +1667,6 @@ do_build="\
mod_expire \
mod_extforward \
mod_fastcgi \
mod_flv_streaming \
mod_indexfile \
mod_proxy \
mod_redirect \
@ -1799,16 +1700,7 @@ lighty_track_feature() {
lighty_track_feature "regex-conditionals" "" \
'test "$WITH_PCRE" != no'
lighty_track_feature "storage-gdbm" "" \
'test "$WITH_GDBM" != no'
lighty_track_feature "storage-memcached" "" \
'test "$WITH_MEMCACHED" != no'
lighty_track_feature "" "mod_trigger_b4_dl" \
'test "$BUILD_MOD_TRIGGER_B4_DL" != no'
lighty_track_feature "mysql" "mod_authn_mysql mod_mysql_vhost mod_vhostdb_mysql" \
lighty_track_feature "mysql" "mod_vhostdb_mysql" \
'test "$WITH_MYSQL" != no'
lighty_track_feature "postgresql" "mod_vhostdb_pgsql" \
@ -1817,12 +1709,9 @@ lighty_track_feature "postgresql" "mod_vhostdb_pgsql" \
lighty_track_feature "dbi" "mod_authn_dbi mod_vhostdb_dbi" \
'test "$WITH_DBI" != no'
lighty_track_feature "lua" "mod_cml mod_magnet" \
lighty_track_feature "lua" "mod_magnet" \
'test "$WITH_LUA" != no'
lighty_track_feature "geoip" "mod_geoip" \
'test "$WITH_GEOIP" != no'
lighty_track_feature "maxminddb" "mod_maxminddb" \
'test "$WITH_MAXMINDDB" != no'

4
doc/config/conf.d/Makefile.am

@ -1,18 +1,15 @@
EXTRA_DIST=access_log.conf \
auth.conf \
cgi.conf \
cml.conf \
debug.conf \
deflate.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 \
@ -20,6 +17,5 @@ EXTRA_DIST=access_log.conf \
simple_vhost.conf \
ssi.conf \
status.conf \
trigger_b4_dl.conf \
userdir.conf \
webdav.conf

27
doc/config/conf.d/cml.conf

@ -1,27 +0,0 @@
#######################################################################
##
## CML Module
## ---------------
##
## See https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModCML
##
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"
##
#######################################################################

28
doc/config/conf.d/geoip.conf

@ -1,28 +0,0 @@
#######################################################################
##
## GeoIP Module
## ---------------
##
## See https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModGeoip
##
## 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/GeoLiteCity.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"
##
#######################################################################

47
doc/config/conf.d/mysql_vhost.conf

@ -1,47 +0,0 @@
#######################################################################
##
## Virtual hosting with MySQL
## ----------------------------
##
## See https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModMySQLVhost
##
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='?'"
##
#######################################################################

70
doc/config/conf.d/trigger_b4_dl.conf

@ -1,70 +0,0 @@
#######################################################################
##
## 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''
##
## See https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModTriggerBeforeDownload
##
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
##
#######################################################################

18
doc/config/modules.conf

@ -21,11 +21,8 @@
## - mod_deflate -> conf.d/deflate.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
@ -82,11 +79,6 @@ server.modules = (
##
#include conf_dir + "/conf.d/magnet.conf"
##
## mod_geoip
##
#include conf_dir + "/conf.d/geoip.conf"
##
## mod_ssi
##
@ -107,11 +99,6 @@ server.modules = (
##
#include conf_dir + "/conf.d/userdir.conf"
##
## mod_cml
##
#include conf_dir + "/conf.d/cml.conf"
##
## mod_rrdtool
##
@ -177,10 +164,5 @@ server.modules = (
##
#include conf_dir + "/conf.d/simple_vhost.conf"
##
## mod_mysql_vhost
##
#include conf_dir + "/conf.d/mysql_vhost.conf"
##
#######################################################################

6
doc/outdated/Makefile.am

@ -22,14 +22,11 @@ state.txt \
rrdtool.txt \
alias.txt \
userdir.txt \
mysqlvhost.txt \
access.txt \
traffic-shaping.txt \
setenv.txt \
status.txt \
scgi.txt \
cml.txt \
trigger_b4_dl.txt \
webdav.txt \
expire.txt \
dirlisting.txt \
@ -60,14 +57,11 @@ HTMLDOCS=accesslog.html \
rrdtool.html \
alias.html \
userdir.html \
mysqlvhost.html \
access.html \
traffic-shaping.html \
setenv.html \
status.html \
scgi.html \
cml.html \
trigger_b4_dl.html \
webdav.html \
expire.html \
dirlisting.html \

261
doc/outdated/cml.txt

@ -1,261 +0,0 @@
=========================
CML (Cache Meta Language)
=========================
---------------
Module: mod_cml
---------------
:Author: Jan Kneschke
:Date: $Date: 2004/11/03 22:26:05 $
:Revision: $Revision: 1.2 $
:abstract:
CML is a Meta language to describe the dependencies of a page at one side and building a page from its fragments on the other side using LUA.
.. meta::
:keywords: lighttpd, cml, lua
.. contents:: Table of Contents
Description
===========
CML (Cache Meta Language) wants to solves several problems:
* dynamic content needs caching to perform
* checking if the content is dirty inside of the application is usually more expensive than sending out the cached data
* a dynamic page is usually fragmented and the fragments have different livetimes
* the different fragments can be cached independently
Cache Decision
--------------
A simple example should show how to a content caching the very simple way in PHP.
jan.kneschke.de has a very simple design:
* the layout is taken from a template in templates/jk.tmpl
* the menu is generated from a menu.csv file
* the content is coming from files on the local directory named content-1, content-2 and so on
The page content is static as long non of the those tree items changes. A change in the layout
is affecting all pages, a change of menu.csv too, a change of content-x file only affects the
cached page itself.
If we model this in PHP we get: ::
<?php
## ... fetch all content-* files into $content
$cachefile = "/cache/dir/to/cached-content";
function is_cachable($content, $cachefile) {
if (!file_exists($cachefile)) {
return 0;
} else {
$cachemtime = filemtime($cachefile);
}
foreach($content as $k => $v) {
if (isset($v["file"]) &&
filemtime($v["file"]) > $cachemtime) {
return 0;
}
}
if (filemtime("/menu/menu.csv") > $cachemtime) {
return 0;
}
if (filemtime("/templates/jk.tmpl") > $cachemtime) {
return 0;
}
}
if (is_cachable(...), $cachefile) {
readfile($cachefile);
exit();
} else {
# generate content and write it to $cachefile
}
?>
Quite simple. No magic involved. If the one of the files is new than the cached
content, the content is dirty and has to be regenerated.
Now let take a look at the numbers:
* 150 req/s for a Cache-Hit
* 100 req/s for a Cache-Miss
As you can see the increase is not as good as it could be. The main reason as the overhead
of the PHP interpreter to start up (a byte-code cache has been used here).
Moving these decisions out of the PHP script into a server module will remove the need
to start PHP for a cache-hit.
To transform this example into a CML you need 'index.cml' in the list of indexfiles
and the following index.cml file: ::
output_contenttype = "text/html"
b = request["DOCUMENT_ROOT"]
cwd = request["CWD"]
output_include = { b .. "_cache.html" }
trigger_handler = "index.php"
if file_mtime(b .. "../lib/php/menu.csv") > file_mtime(cwd .. "_cache.html") or
file_mtime(b .. "templates/jk.tmpl") > file_mtime(cwd .. "_cache.html") or
file_mtime(b .. "content.html") > file_mtime(cwd .. "_cache.html") then
return CACHE_MISS
else
return CACHE_HIT
end
Numbers again:
* 4900 req/s for Cache-Hit
* 100 req/s for Cache-Miss
Content Assembling
------------------
Sometimes the different fragment are already generated externally. You have to cat them together: ::
<?php
readfile("head.html");
readfile("menu.html");
readfile("spacer.html");
readfile("db-content.html");
readfile("spacer2.html");
readfile("news.html");
readfile("footer.html");
?>
We we can do the same several times faster directly in the webserver.
Don't forget: Webserver are built to send out static content, that is what they can do best.
The index.cml for this looks like: ::
output_contenttype = "text/html"
cwd = request["CWD"]
output_include = { cwd .. "head.html",
cwd .. "menu.html",
cwd .. "spacer.html",
cwd .. "db-content.html",
cwd .. "spacer2.html",
cwd .. "news.html",
cwd .. "footer.html" }
return CACHE_HIT
Now we get about 10000 req/s instead of 600 req/s.
Power Magnet
------------
Next to all the features about Cache Decisions CML can do more. Starting
with lighttpd 1.4.9 a power-magnet was added which attracts each request
and allows you to manipulate the request for your needs.
We want to display a maintenance page by putting a file in a specified
place:
We enable the power magnet: ::
cml.power-magnet = "/home/www/power-magnet.cml"
and create /home/www/power-magnet.cml with: ::
dr = request["DOCUMENT_ROOT"]
if file_isreg(dr .. 'maintenance.html') then
output_include = { 'maintenance.html' }
return CACHE_HIT
end
return CACHE_MISS
For each requested file the /home/www/power-magnet.cml is executed which
checks if maintenance.html exists in the docroot and displays it
instead of handling the usual request.
Another example, create thumbnail for requested image and serve it instead
of sending the big image: ::
## image-url is /album/baltic_winter_2005.jpg
## no params -> 640x480 is served
## /album/baltic_winter_2005.jpg/orig for full size
## /album/baltic_winter_2005.jpg/thumb for thumbnail
dr = request["DOCUMENT_ROOT"]
sn = request["SCRIPT_NAME"]
## to be continued :) ...
trigger_handler = '/gen_image.php'
return CACHE_MISS
Installation
============
You need `lua <http://www.lua.org/>`_ and should install `memcached <http://www.memcached.org>`_ and have to configure lighttpd with: ::
./configure ... --with-lua --with-memcached
To use the plugin you have to load it: ::
server.modules = ( ..., "mod_cml", ... )
Options
=======
:cml.extension:
the file extension that is bound to the cml-module
:cml.memcache-hosts:
hosts for the memcache.* functions
:cml.memcache-namespace:
(not used yet)
:cml.power-magnet:
a cml file that is executed for each request
Language
========
The language used for CML is provided by `LUA <http://www.lua.org/>`_.
Additionally to the functions provided by lua mod_cml provides: ::
tables:
request
- REQUEST_URI
- SCRIPT_NAME
- SCRIPT_FILENAME
- DOCUMENT_ROOT
- PATH_INFO
- CWD
- BASEURI
get
- parameters from the query-string
functions:
string md5(string)
number file_mtime(string)
string memcache_get_string(string)
number memcache_get_long(string)
boolean memcache_exists(string)
What ever your script does, it has to return either CACHE_HIT or CACHE_MISS.
It case a error occurs check the error-log, the user will get a error 500. If you don't like
the standard error-page use ``server.errorfile-prefix``.

148
doc/outdated/geoip.txt

@ -1,148 +0,0 @@
{{{
#!rst
==============================
ip based geographic lookups...
==============================
-----------------
Module: mod_geoip
-----------------
.. contents:: Table of Contents
Requirements
============
:Packages: GeoIP C API & Library (http://www.maxmind.com/download/geoip/api/c/)
Overview
========
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.
.. note::
Currently only country/city databases are supported because they have a free
version that i can test.
Configuration Options
========================
mod_geoip uses two configuration options.
1) geoip.db-filename = <path to the geoip or geocity database>
2) geoip.memory-cache = <enable|disable> : default disabled
if enabled, mod_geoip will load the database binary file to
memory for very fast lookups. the only penalty is memory usage.
.. note::
mod_geoip will determine the database type automatically so if you enter
GeoCity database path it will load GeoCity Env.
Environment
===========
Every database sets it's own ENV:
GeoIP (Country):
----------------
::
GEOIP_COUNTRY_CODE
GEOIP_COUNTRY_CODE3
GEOIP_COUNTRY_NAME
GeoCity:
--------
::
GEOIP_COUNTRY_CODE
GEOIP_COUNTRY_CODE3
GEOIP_COUNTRY_NAME
GEOIP_CITY_NAME
GEOIP_CITY_POSTAL_CODE
GEOIP_CITY_LATITUDE
GEOIP_CITY_LONG_LATITUDE
GEOIP_CITY_DMA_CODE
GEOIP_CITY_AREA_CODE
Examples
========
mod_geoip + php
---------------
when using fastcgi (not only php) you can access mod_geoip env and do as you
please. this example just prints all mod_geoip envs to the client, html.
Config-file ::
geoip.db-filename = "/your-geoip-db-path/GeoCityLite.dat"
geoip.memory-cache = "enable"
index.php ::
<?php
$country_code = $_SERVER['GEOIP_COUNTRY_CODE'];
$country_code3 = $_SERVER['GEOIP_COUNTRY_CODE3'];
$country_name = $_SERVER['GEOIP_COUNTRY_NAME'];
$city_region = $_SERVER['GEOIP_CITY_REGION'];
$city_name = $_SERVER['GEOIP_CITY_NAME'];
$city_postal_code = $_SERVER['GEOIP_CITY_POSTAL_CODE'];
$city_latitude = $_SERVER['GEOIP_CITY_LATITUDE'];
$city_long_latitude = $_SERVER['GEOIP_CITY_LONG_LATITUDE'];
$city_dma_code = $_SERVER['GEOIP_CITY_DMA_CODE'];
$city_area_code = $_SERVER['GEOIP_CITY_AREA_CODE'];
echo "<html>\n<body>\n\t<br>\n";
echo 'Country Code: ' . $country_code . '<br>';
echo 'Country Code 3: ' . $country_code3 . '<br>';
echo 'Country Name: ' . $country_name . '<br>';
echo '<br>';
echo 'City Region: ' . $city_region . '<br>';
echo 'City Name: ' . $city_name . '<br>';
echo 'City Postal Code: ' . $city_postal_code . '<br>';
echo 'City Latitude: ' . $city_latitude . '<br>';
echo 'City Long Latitude: ' . $city_long_latitude . '<br>';
echo 'City DMA Code: ' . $city_dma_code . '<br>';
echo 'City Area Code: ' . $city_area_code . '<br>';
echo "</html>\n</body>";
?>
country based redirect
----------------------
Config-file ::
$HTTP["host"] =~ "www.domain.com" {
url.rewrite = ( "" => "/redirect.php")
}
redirect.php ::
<?php
$country_code = $_SERVER['GEOIP_COUNTRY_CODE'];
header ('Location: http://' . $country_code . '.domain.com/');
?>
.. note::
Currently it is not possible to redirect based on mod_geoip directly in
lighttpd config file. But i believe with the release of lighttpd mod_magnet
it would be. (mod_magnet will be available in lighttpd 1.4.12+)
Downloads
=========
mod_geoip.c (http://trac.lighttpd.net/trac/attachment/wiki/Docs/ModGeoip/mod_geoip.c)
}}}

58
doc/outdated/mysqlvhost.txt

@ -1,58 +0,0 @@
====================
MySQL-based vhosting
====================
-----------------------
Module: mod_mysql_vhost
-----------------------
:Author: ada@riksnet.se
:Date: $Date: 2004/08/29 09:43:49 $
:Revision: $Revision: 1.1 $
:abstract:
This module provides virtual hosts (vhosts) based on a MySQL table
.. meta::
:keywords: lighttpd, mysql, vhost
.. contents:: Table of Contents
Description
===========
With MySQL-based vhosting you can store the path to a given host's
document root in a MySQL database.
.. note:: Keep in mind that only one vhost module should be active at a time.
Don't mix mod_simple_vhost with mod_mysql_vhost.
Options
=======
Example: ::
mysql-vhost.db = "lighttpd"
mysql-vhost.user = "lighttpd"
mysql-vhost.pass = "secret"
mysql-vhost.sock = "/var/mysql.lighttpd.sock"
mysql-vhost.sql = "SELECT docroot FROM domains WHERE domain='?'"
MySQL setup: ::
GRANT SELECT ON lighttpd.* TO lighttpd@localhost IDENTIFIED BY 'secret';
CREATE DATABASE lighttpd;
USE lighttpd;
CREATE TABLE domains (
domain varchar(64) not null primary key,
docroot varchar(128) not null
);
INSERT INTO domains VALUES ('host.dom.ain','/http/host.dom.ain/');

57
doc/outdated/trigger_b4_dl.txt

@ -1,57 +0,0 @@
=======================
Trigger before Download
=======================
-------------------------
Module: mod_trigger_b4_dl
-------------------------
:Author: Jan Kneschke
:Date: $Date: 2004/11/03 22:26:05 $
:Revision: $Revision: 1.2 $
:abstract:
another anti-hot-linking module
.. meta::
:keywords: lighttpd, hot-linking, deep-linking
.. contents:: Table of Contents
Description
===========
Anti Hotlinking:
* 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''
The trigger information is either stored locally in a gdbm file or remotely in memcached.
Requirements
------------
* libpcre
* libgdbm or libmemcached
Options
=======
::
trigger-before-download.gdbm-filename = "/home/weigon/testbase/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://192.168.1.5:1025/index.html"
trigger-before-download.trigger-timeout = 10
If both trigger-before-download.gdbm-filename and
trigger-before-download.memcache-hosts is set gdbm will take precedence.
Installation
============
memcached should be started with the option -M as we don't want to remove entry if the memory is full.

2
meson.build

@ -10,7 +10,7 @@ subdir('tests')
# $ ninja
# full build:
# $ meson configure -D build_extra_warnings=true -D with_bzip=true -D with_dbi=true -D with_fam=true -D with_gdbm=true -D with_geoip=true -D with_krb5=true -D with_ldap=true -D with_libev=true -D with_libunwind=true -D with_lua=true -D with_memcached=true -D with_mysql=true -D with_openssl=true -D with_pcre=true -D with_pgsql=true -D with_sasl=true -D with_webdav_locks=true -D with_webdav_props=true -D with_xattr=true -D with_zlib=true
# $ meson configure -D build_extra_warnings=true -D with_bzip=true -D with_dbi=true -D with_fam=true -D with_krb5=true -D with_ldap=true -D with_libev=true -D with_libunwind=true -D with_lua=true -D with_mysql=true -D with_openssl=true -D with_pcre2=true -D with_pgsql=true -D with_sasl=true -D with_webdav_locks=true -D with_webdav_props=true -D with_xattr=true -D with_zlib=true
# optimized build:
# $ meson configure -D b_lto=true -D buildtype=debugoptimized

15
meson_options.txt

@ -18,16 +18,6 @@ option('with_fam',
value: false,
description: 'fam/gamin for reducing number of stat() calls [default: off]',
)
option('with_gdbm',
type: 'boolean',
value: false,
description: 'gdbm storage for mod_trigger_b4_dl [default: off]',
)
option('with_geoip',
type: 'boolean',
value: false,
description: 'with GeoIP-support mod_geoip [default: off]',
)
option('with_gnutls',
type: 'boolean',
value: 'false',
@ -68,11 +58,6 @@ option('with_mbedtls',
value: 'false',
description: 'with mbedTLS-support [default: off]',
)
option('with_memcached',
type: 'boolean',
value: false,
description: 'memcached storage for mod_trigger_b4_dl [default: off]',
)
option('with_mysql',
type: 'boolean',
value: false,

10
scripts/ci-build.sh

@ -19,8 +19,8 @@ case "${build}" in
--with-dbi --with-mysql --with-pgsql \
--with-ldap --with-pcre2 \
--with-zlib --with-zstd --with-brotli --with-bzip2 \
--with-webdav-props --with-webdav-locks --with-gdbm \
--with-memcached --with-lua --with-libev --with-libunwind \
--with-webdav-props --with-webdav-locks \
--with-lua --with-libev --with-libunwind \
--with-krb5 \
--with-nettle \
--with-gnutls \
@ -40,8 +40,8 @@ case "${build}" in
--with-dbi --with-mysql --with-pgsql \
--with-ldap --with-pcre2 \
--with-zlib --with-zstd --with-brotli --with-bzip2 \
--with-webdav-props --with-webdav-locks --with-gdbm \
--with-memcached --with-lua --with-libev --with-libunwind \
--with-webdav-props --with-webdav-locks \
--with-lua --with-libev --with-libunwind \
--with-krb5 --with-sasl \
--with-nettle \
--with-gnutls \
@ -59,12 +59,10 @@ case "${build}" in
-DWITH_ZSTD=ON \
-DWITH_BROTLI=ON \
-DWITH_BZIP=ON \
-DWITH_GDBM=ON \
-DWITH_LDAP=ON \
-DWITH_LIBEV=ON \
-DWITH_LIBUNWIND=ON \
-DWITH_LUA=ON \
-DWITH_MEMCACHED=ON \
-DWITH_DBI=ON \
-DWITH_MYSQL=ON \
-DWITH_PGSQL=ON \

59
src/CMakeLists.txt

@ -40,11 +40,8 @@ option(WITH_PAM "with PAM-support for mod_auth [default: off]")
option(WITH_LUA "with lua 5.1 for mod_magnet [default: off]")
# option(WITH_VALGRIND "with internal support for valgrind [default: off]")
option(WITH_FAM "fam/gamin for reducing number of stat() calls [default: off]")
option(WITH_GDBM "gdbm storage for mod_trigger_b4_dl [default: off]")
option(WITH_MEMCACHED "memcached storage for mod_trigger_b4_dl [default: off]")
option(WITH_LIBEV "libev support for fdevent handlers [default: off]")
option(WITH_LIBUNWIND "with libunwind to print backtraces in asserts [default: off]")
option(WITH_GEOIP "with GeoIP-support mod_geoip [default: off]")
option(WITH_MAXMINDDB "with MaxMind GeoIP2-support mod_maxminddb [default: off]")
option(WITH_SASL "with SASL-support for mod_authn_sasl [default: off]")
option(WITH_XXHASH "with system-provided xxhash [default: off]")
@ -742,28 +739,6 @@ else()
unset(HAVE_FAMNOEXISTS)
endif()
if(WITH_GDBM)
check_include_files(gdbm.h HAVE_GDBM_H)
check_library_exists(gdbm gdbm_open "" HAVE_GDBM)
else()
unset(HAVE_GDBM_H)
unset(HAVE_GDBM)
endif()
if(WITH_MEMCACHED)
check_include_files(libmemcached/memcached.h HAVE_LIBMEMCACHED_MEMCACHED_H)
check_library_exists(memcached memcached "" HAVE_LIBMEMCACHED)
if(HAVE_LIBMEMCACHED_MEMCACHED_H AND HAVE_LIBMEMCACHED)
set(USE_MEMCACHED 1)
else()
message(FATAL_ERROR "didn't find libmemcached")
endif()
endif()
if(WITH_GEOIP)
check_library_exists(geoip GeoIP_country_name_by_addr "" HAVE_GEOIP)
endif()
if(WITH_MAXMINDDB)
check_library_exists(maxminddb MMDB_open "" HAVE_MAXMINDDB)
endif()
@ -877,7 +852,6 @@ add_and_install_library(mod_evhost mod_evhost.c)
add_and_install_library(mod_expire mod_expire.c)
add_and_install_library(mod_extforward mod_extforward.c)
add_and_install_library(mod_fastcgi mod_fastcgi.c)
add_and_install_library(mod_flv_streaming mod_flv_streaming.c)
add_and_install_library(mod_indexfile mod_indexfile.c)
add_and_install_library(mod_proxy mod_proxy.c)
add_and_install_library(mod_redirect mod_redirect.c)
@ -956,26 +930,10 @@ if(HAVE_PCRE)
add_target_properties(test_mod COMPILE_FLAGS ${PCRE_CFLAGS})
endif()
if(HAVE_PCRE AND (WITH_MEMCACHED OR WITH_GDBM))
add_and_install_library(mod_trigger_b4_dl mod_trigger_b4_dl.c)
endif()
if(WITH_LUA)
add_and_install_library(mod_magnet "mod_magnet.c;mod_magnet_cache.c;algo_hmac.c")
target_link_libraries(mod_magnet ${LUA_LDFLAGS} ${CRYPTO_LIBRARY})
add_target_properties(mod_magnet COMPILE_FLAGS ${LUA_CFLAGS})
add_and_install_library(mod_cml "mod_cml.c;mod_cml_lua.c;mod_cml_funcs.c")
target_link_libraries(mod_cml ${LUA_LDFLAGS} ${CRYPTO_LIBRARY})
add_target_properties(mod_cml COMPILE_FLAGS ${LUA_CFLAGS})
if(WITH_MEMCACHED)
target_link_libraries(mod_cml memcached)
endif()
endif()
if(WITH_GEOIP)
add_and_install_library(mod_geoip mod_geoip.c)
target_link_libraries(mod_geoip GeoIP)
endif()
if(WITH_MAXMINDDB)
@ -984,18 +942,9 @@ if(WITH_MAXMINDDB)
endif()
if(HAVE_MYSQL_H AND HAVE_MYSQL)
add_and_install_library(mod_mysql_vhost "mod_mysql_vhost.c")
target_link_libraries(mod_mysql_vhost mysqlclient)
add_and_install_library(mod_vhostdb_mysql "mod_vhostdb_mysql.c")
target_link_libraries(mod_vhostdb_mysql mysqlclient)
include_directories(/usr/include/mysql)
add_and_install_library(mod_authn_mysql "mod_authn_mysql.c")
set(L_MOD_AUTHN_MYSQL ${CRYPTO_LIBRARY})
if(HAVE_LIBCRYPT)
set(L_MOD_AUTHN_MYSQL ${L_MOD_AUTHN_MYSQL} crypt)
endif()
target_link_libraries(mod_authn_mysql ${L_MOD_AUTHN_MYSQL} mysqlclient)
endif()
if(HAVE_PGSQL_H AND HAVE_PGSQL)
@ -1084,14 +1033,6 @@ if(HAVE_LIBFAM)
target_link_libraries(test_mod fam)
endif()
if(HAVE_GDBM_H)
target_link_libraries(mod_trigger_b4_dl gdbm)
endif()
if(WITH_MEMCACHED)
target_link_libraries(mod_trigger_b4_dl memcached)
endif()
if(HAVE_XATTR)
target_link_libraries(lighttpd attr)
target_link_libraries(test_mod attr)

64
src/Makefile.am

@ -99,18 +99,6 @@ common_libadd =
endif
common_module_ldflags = -module -export-dynamic $(common_ldflags)
lib_LTLIBRARIES += mod_flv_streaming.la
mod_flv_streaming_la_SOURCES = mod_flv_streaming.c
mod_flv_streaming_la_LDFLAGS = $(common_module_ldflags)
mod_flv_streaming_la_LIBADD = $(common_libadd)
if BUILD_WITH_GEOIP
lib_LTLIBRARIES += mod_geoip.la
mod_geoip_la_SOURCES = mod_geoip.c
mod_geoip_la_LDFLAGS = $(common_module_ldflags)
mod_geoip_la_LIBADD = $(common_libadd) $(GEOIP_LIB)
endif
if BUILD_WITH_MAXMINDDB
lib_LTLIBRARIES += mod_maxminddb.la
mod_maxminddb_la_SOURCES = mod_maxminddb.c
@ -137,21 +125,6 @@ mod_magnet_la_LDFLAGS = $(common_module_ldflags)
mod_magnet_la_LIBADD = $(common_libadd) $(LUA_LIBS) $(CRYPTO_LIB) -lm
endif
if BUILD_WITH_LUA
lib_LTLIBRARIES += mod_cml.la
mod_cml_la_SOURCES = mod_cml.c mod_cml_lua.c mod_cml_funcs.c
mod_cml_la_CFLAGS = $(AM_CFLAGS) $(LUA_CFLAGS)
mod_cml_la_LDFLAGS = $(common_module_ldflags)
mod_cml_la_LIBADD = $(MEMCACHED_LIB) $(common_libadd) $(LUA_LIBS) $(CRYPTO_LIB) -lm
endif
if BUILD_MOD_TRIGGER_B4_DL
lib_LTLIBRARIES += mod_trigger_b4_dl.la
mod_trigger_b4_dl_la_SOURCES = mod_trigger_b4_dl.c
mod_trigger_b4_dl_la_LDFLAGS = $(common_module_ldflags)
mod_trigger_b4_dl_la_LIBADD = $(GDBM_LIB) $(MEMCACHED_LIB) $(common_libadd)
endif
lib_LTLIBRARIES += mod_vhostdb.la
mod_vhostdb_la_SOURCES = mod_vhostdb.c
if !NO_RDYNAMIC
@ -167,14 +140,6 @@ mod_vhostdb_ldap_la_LDFLAGS = $(common_module_ldflags)
mod_vhostdb_ldap_la_LIBADD = $(LDAP_LIB) $(LBER_LIB) $(common_libadd)
endif
if BUILD_WITH_MYSQL
lib_LTLIBRARIES += mod_mysql_vhost.la
mod_mysql_vhost_la_SOURCES = mod_mysql_vhost.c
mod_mysql_vhost_la_LDFLAGS = $(common_module_ldflags)
mod_mysql_vhost_la_LIBADD = $(MYSQL_LIBS) $(common_libadd)
mod_mysql_vhost_la_CPPFLAGS = $(MYSQL_CFLAGS)
endif
if BUILD_WITH_MYSQL
lib_LTLIBRARIES += mod_vhostdb_mysql.la
mod_vhostdb_mysql_la_SOURCES = mod_vhostdb_mysql.c
@ -356,14 +321,6 @@ mod_authn_pam_la_LDFLAGS = $(common_module_ldflags)
mod_authn_pam_la_LIBADD = $(PAM_LIB) $(common_libadd)
endif
if BUILD_WITH_MYSQL
lib_LTLIBRARIES += mod_authn_mysql.la
mod_authn_mysql_la_SOURCES = mod_authn_mysql.c
mod_authn_mysql_la_LDFLAGS = $(common_module_ldflags)
mod_authn_mysql_la_LIBADD = $(CRYPT_LIB) $(MYSQL_LIBS) $(CRYPTO_LIB) $(common_libadd)
mod_authn_mysql_la_CPPFLAGS = $(MYSQL_CFLAGS)
endif
if BUILD_WITH_SASL
lib_LTLIBRARIES += mod_authn_sasl.la
mod_authn_sasl_la_SOURCES = mod_authn_sasl.c
@ -461,7 +418,6 @@ hdr = base64.h buffer.h burl.h network.h log.h http_kv.h keyvalue.h \
rand.h \
sys-crypto.h sys-crypto-md.h \
sys-endian.h sys-mmap.h sys-socket.h sys-strings.h sys-time.h \
mod_cml.h mod_cml_funcs.h \
sock_addr.h status_counter.h \
mod_auth_api.h \
mod_magnet_cache.h \
@ -495,7 +451,6 @@ lighttpd_SOURCES = \
mod_expire.c \
mod_extforward.c \
mod_fastcgi.c \
mod_flv_streaming.c \
mod_indexfile.c \
mod_proxy.c \
mod_redirect.c \
@ -527,17 +482,12 @@ lighttpd_LDADD = \
$(FAM_LIBS) $(LIBEV_LIBS) $(LIBUNWIND_LIBS)
lighttpd_LDFLAGS = -export-dynamic
if BUILD_WITH_GEOIP
lighttpd_SOURCES += mod_geoip.c
lighttpd_LDADD += $(GEOIP_LIB)
endif
if BUILD_WITH_MAXMINDDB
lighttpd_SOURCES += mod_maxminddb.c
lighttpd_LDADD += $(MAXMINDDB_LIB)
endif
if BUILD_WITH_LUA
lighttpd_SOURCES += mod_cml.c mod_cml_lua.c mod_cml_funcs.c \
mod_magnet.c mod_magnet_cache.c
lighttpd_SOURCES += mod_magnet.c mod_magnet_cache.c
#algo_hmac.c
lighttpd_CPPFLAGS += $(LUA_CFLAGS)
lighttpd_LDADD += $(LUA_LIBS) -lm
@ -555,7 +505,7 @@ lighttpd_SOURCES += mod_authn_pam.c
lighttpd_LDADD += $(PAM_LIB)
endif
if BUILD_WITH_MYSQL
lighttpd_SOURCES += mod_authn_mysql.c mod_mysql_vhost.c mod_vhostdb_mysql.c
lighttpd_SOURCES += mod_vhostdb_mysql.c
lighttpd_CPPFLAGS += $(MYSQL_CFLAGS)
lighttpd_LDADD += $(MYSQL_LIBS)
endif
@ -593,16 +543,6 @@ lighttpd_SOURCES += mod_wolfssl.c
lighttpd_CPPFLAGS += $(WOLFSSL_CFLAGS)
lighttpd_LDADD += $(WOLFSSL_LIBS)
endif
if BUILD_WITH_MEMCACHED
lighttpd_CPPFLAGS += $(MEMCACHED_CFLAGS)
lighttpd_LDADD += $(MEMCACHED_LIB)
endif
if BUILD_WITH_GDBM
lighttpd_LDADD += $(GDBM_LIB)
endif
if BUILD_MOD_TRIGGER_B4_DL
lighttpd_SOURCES += mod_trigger_b4_dl.c
endif
else

13
src/SConscript

@ -108,7 +108,6 @@ modules = {
'mod_expire' : { 'src' : [ 'mod_expire.c' ] },
'mod_extforward' : { 'src' : [ 'mod_extforward.c' ] },
'mod_fastcgi' : { 'src' : [ 'mod_fastcgi.c' ] },
'mod_flv_streaming' : { 'src' : [ 'mod_flv_streaming.c' ] },
'mod_indexfile' : { 'src' : [ 'mod_indexfile.c' ] },
'mod_proxy' : { 'src' : [ 'mod_proxy.c' ] },
'mod_redirect' : { 'src' : [ 'mod_redirect.c' ] },
@ -130,9 +129,6 @@ modules = {