optional_depends zlib \
                 '' '' \
                 'for zlib support' &&
optional_depends pcre \
                 '--with-pcre' '--without-pcre' \
                 'for PCRE support' &&
optional_depends bzip2 \
                 '--with-bzip2' '--without-bzip2' \
                 'for bzip2 support' &&
optional_depends openldap \
                 '--with-ldap' '--without-ldap' \
                 'for OpenLDAP support' &&
optional_depends SSL \
                 '--with-openssl' '--without-openssl' \
                 'for OpenSSL support' &&
optional_depends MYSQL \
                 '--with-mysql' '--without-mysql' \
                 'for MySQL support' &&
optional_depends gdbm \
                 '--with-gdbm' '--without-gdbm' \
                 'gdbm storage for mod_trigger_b4_dl' &&
optional_depends FAM \
                 '--with-fam' '--without-fam' \
                 'to reduce number of stat() calls' &&
optional_depends LUA \
                 '--with-lua' '--without-lua' \
                 'lua engine for mod_cml'  &&
optional_depends libmemcache \
                 '--with-memcache' '--without-memcache' \
                 'memcache storage for mod_trigger_b4_dl'  &&

optional_depends libev \
                 "--with-libev" \
                 "--without-libev" \
                 "for fdevent handlers support" &&

if list_find "$LIGHTTPD_OPTS" "--with-webdav-props"; then
  depends libxml2
fi &&

if list_find "$LIGHTTPD_OPTS" "--with-webdav-locks"; then
  depends sqlite
fi
