2006-01-23 20:46:56 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# lighttpd
|
|
|
|
#
|
|
|
|
#############################################################
|
2009-07-01 15:31:59 +02:00
|
|
|
|
2012-06-08 07:30:45 +02:00
|
|
|
LIGHTTPD_VERSION = 1.4.31
|
2009-12-01 21:00:59 +01:00
|
|
|
LIGHTTPD_SITE = http://download.lighttpd.net/lighttpd/releases-1.4.x
|
2012-08-11 22:12:41 +02:00
|
|
|
LIGHTTPD_LICENSE = BSD-3c
|
|
|
|
LIGHTTPD_LICENSE_FILES = COPYING
|
2011-03-03 14:53:30 +01:00
|
|
|
LIGHTTPD_DEPENDENCIES = host-pkg-config
|
2008-04-24 15:18:50 +02:00
|
|
|
LIGHTTPD_CONF_OPT = \
|
|
|
|
--libdir=/usr/lib/lighttpd \
|
|
|
|
--libexecdir=/usr/lib \
|
|
|
|
--localstatedir=/var \
|
2010-03-22 14:29:00 +01:00
|
|
|
$(if $(BR2_LARGEFILE),,--disable-lfs)
|
2006-01-23 20:46:56 +01:00
|
|
|
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_OPENSSL),y)
|
2008-04-24 15:18:50 +02:00
|
|
|
LIGHTTPD_DEPENDENCIES += openssl
|
|
|
|
LIGHTTPD_CONF_OPT += --with-openssl
|
2007-07-17 02:27:10 +02:00
|
|
|
else
|
2008-04-24 15:18:50 +02:00
|
|
|
LIGHTTPD_CONF_OPT += --without-openssl
|
2007-09-19 22:13:08 +02:00
|
|
|
endif
|
2006-01-23 20:46:56 +01:00
|
|
|
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_ZLIB),y)
|
2008-07-05 10:20:34 +02:00
|
|
|
LIGHTTPD_DEPENDENCIES += zlib
|
|
|
|
LIGHTTPD_CONF_OPT += --with-zlib
|
|
|
|
else
|
|
|
|
LIGHTTPD_CONF_OPT += --without-zlib
|
|
|
|
endif
|
|
|
|
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_BZIP2),y)
|
2008-07-05 10:20:34 +02:00
|
|
|
LIGHTTPD_DEPENDENCIES += bzip2
|
|
|
|
LIGHTTPD_CONF_OPT += --with-bzip2
|
|
|
|
else
|
|
|
|
LIGHTTPD_CONF_OPT += --without-bzip2
|
|
|
|
endif
|
|
|
|
|
2008-12-08 09:15:27 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_PCRE),y)
|
2010-07-22 09:08:34 +02:00
|
|
|
LIGHTTPD_CONF_ENV = PCRECONFIG=$(STAGING_DIR)/usr/bin/pcre-config
|
2008-04-24 15:18:50 +02:00
|
|
|
LIGHTTPD_DEPENDENCIES += pcre
|
|
|
|
LIGHTTPD_CONF_OPT += --with-pcre
|
2007-07-17 02:27:10 +02:00
|
|
|
else
|
2008-04-24 15:18:50 +02:00
|
|
|
LIGHTTPD_CONF_OPT += --without-pcre
|
2007-07-17 02:27:10 +02:00
|
|
|
endif
|
2006-01-23 20:46:56 +01:00
|
|
|
|
2011-03-03 14:53:30 +01:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_WEBDAV),y)
|
|
|
|
LIGHTTPD_DEPENDENCIES += libxml2 sqlite
|
|
|
|
LIGHTTPD_CONF_OPT += --with-webdav-props --with-webdav-locks
|
|
|
|
else
|
2011-04-02 10:24:59 +02:00
|
|
|
LIGHTTPD_CONF_OPT += --without-webdav-props --without-webdav-locks
|
2011-03-03 14:53:30 +01:00
|
|
|
endif
|
|
|
|
|
2011-10-28 15:09:23 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_LIGHTTPD_LUA),y)
|
|
|
|
LIGHTTPD_DEPENDENCIES += lua
|
|
|
|
LIGHTTPD_CONF_OPT += --with-lua
|
|
|
|
else
|
|
|
|
LIGHTTPD_CONF_OPT += --without-lua
|
|
|
|
endif
|
|
|
|
|
2012-04-20 06:04:20 +02:00
|
|
|
define LIGHTTPD_INSTALL_CONFIG
|
2012-07-21 20:47:51 +02:00
|
|
|
$(INSTALL) -d -m 0755 $(TARGET_DIR)/etc/lighttpd/conf.d
|
|
|
|
$(INSTALL) -d -m 0755 $(TARGET_DIR)/var/www
|
2012-04-20 06:04:20 +02:00
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/lighttpd.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/lighttpd.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/lighttpd.conf
|
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/modules.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/modules.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/modules.conf
|
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/access_log.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/access_log.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/conf.d/access_log.conf
|
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/debug.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/debug.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/conf.d/debug.conf
|
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/dirlisting.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/dirlisting.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/conf.d/dirlisting.conf
|
|
|
|
|
|
|
|
[ -f $(TARGET_DIR)/etc/lighttpd/conf.d/mime.conf ] || \
|
|
|
|
$(INSTALL) -D -m 755 $(@D)/doc/config/conf.d/mime.conf \
|
|
|
|
$(TARGET_DIR)/etc/lighttpd/conf.d/mime.conf
|
|
|
|
endef
|
|
|
|
|
|
|
|
LIGHTTPD_POST_INSTALL_TARGET_HOOKS += LIGHTTPD_INSTALL_CONFIG
|
|
|
|
|
2012-07-28 09:21:21 +02:00
|
|
|
define LIGHTTPD_INSTALL_INIT_SYSV
|
2012-07-22 19:17:48 +02:00
|
|
|
[ -f $(TARGET_DIR)/etc/init.d/S50lighttpd ] || \
|
|
|
|
$(INSTALL) -D -m 755 package/lighttpd/S50lighttpd \
|
|
|
|
$(TARGET_DIR)/etc/init.d/S50lighttpd
|
|
|
|
endef
|
|
|
|
|
2012-07-28 09:21:21 +02:00
|
|
|
define LIGHTTPD_INSTALL_INIT_SYSTEMD
|
|
|
|
[ -f $(TARGET_DIR)/etc/systemd/system/lighttpd.service ] || \
|
|
|
|
$(INSTALL) -D -m 755 package/lighttpd/lighttpd.service \
|
|
|
|
$(TARGET_DIR)/etc/systemd/system/lighttpd.service
|
|
|
|
|
|
|
|
mkdir -p $(TARGET_DIR)/etc/systemd/system/multi-user.target.wants
|
|
|
|
|
|
|
|
ln -fs ../lighttpd.service \
|
|
|
|
$(TARGET_DIR)/etc/systemd/system/multi-user.target.wants/lighttpd.service
|
|
|
|
endef
|
2012-07-22 19:17:48 +02:00
|
|
|
|
2010-09-01 23:24:17 +02:00
|
|
|
define LIGHTTPD_UNINSTALL_TARGET_CMDS
|
2012-07-21 20:47:51 +02:00
|
|
|
$(RM) $(TARGET_DIR)/usr/sbin/lighttpd
|
|
|
|
$(RM) $(TARGET_DIR)/usr/sbin/lighttpd-angel
|
|
|
|
$(RM) -r $(TARGET_DIR)/usr/lib/lighttpd
|
2010-09-01 23:24:17 +02:00
|
|
|
endef
|
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(autotools-package))
|