From 7f0ccc917c7abe6223784c703d86cd14755691fb Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 3 Jul 2021 22:39:47 +0100 Subject: gentoo resync : 03.07.2021 --- www-servers/lighttpd/Manifest | 9 +- .../files/lighttpd-1.4.59-nspr-header.patch | 16 ++ www-servers/lighttpd/lighttpd-1.4.55-r100.ebuild | 244 ------------------- www-servers/lighttpd/lighttpd-1.4.55-r101.ebuild | 245 +++++++++++++++++++ www-servers/lighttpd/lighttpd-1.4.58-r1.ebuild | 266 +++++++++++++++++++++ www-servers/lighttpd/lighttpd-1.4.58.ebuild | 265 -------------------- www-servers/lighttpd/lighttpd-1.4.59.ebuild | 239 ++++++++++++++++++ www-servers/lighttpd/metadata.xml | 1 + 8 files changed, 773 insertions(+), 512 deletions(-) create mode 100644 www-servers/lighttpd/files/lighttpd-1.4.59-nspr-header.patch delete mode 100644 www-servers/lighttpd/lighttpd-1.4.55-r100.ebuild create mode 100644 www-servers/lighttpd/lighttpd-1.4.55-r101.ebuild create mode 100644 www-servers/lighttpd/lighttpd-1.4.58-r1.ebuild delete mode 100644 www-servers/lighttpd/lighttpd-1.4.58.ebuild create mode 100644 www-servers/lighttpd/lighttpd-1.4.59.ebuild (limited to 'www-servers/lighttpd') diff --git a/www-servers/lighttpd/Manifest b/www-servers/lighttpd/Manifest index 44976f46f1b0..3afbeebe568d 100644 --- a/www-servers/lighttpd/Manifest +++ b/www-servers/lighttpd/Manifest @@ -2,6 +2,7 @@ AUX conf/lighttpd.conf 8257 BLAKE2B 82090a8c467e3738d1e7bb3a55310040145ab6a0ee7d AUX conf/mime-types.conf 8035 BLAKE2B 4f47860376d6bed610ecacf2c79c3ccbd6ed7a05bce6fe57c93e4dfacc5f85fd4957730470765644c4ee233f9e4c853b5092362cbdcd4ad06d6e641ff53439b3 SHA512 230d86331c39e8819c14583309669e49c0a0dcf52144f9ddc24bcdd8a742364f6efee720c964ffaddb1f88bc64b04a32c5ac13b0d512806f98282e20e2682b6e AUX conf/mod_cgi.conf 749 BLAKE2B dd565d6052d74aea3489f3a011a5913fcbd331b57ca02e71496eecff7c303cd56e8e43cd5a9b33c27463304a2f2218fc7451cb5754200c9ef48eb4104b820547 SHA512 e611b3ed232af4fb8e9b8821a29fbc32acb0a3431c701e5a64afc192abc288cf90582fbbf79085de9426be23d8d42d90da66e6993ab7cf89943ae23d59d681a1 AUX conf/mod_fastcgi.conf 549 BLAKE2B 7bd525db1ace97a826bc4fcc11fc230f16839005da8988b21f54e5d43763a7df82b0d3b2cd5f410074cd87b2c8dbaab91042563bb7878ca0bedc076eafdc5906 SHA512 a9245394cbde327f997932546e2c6ee755da9365ce3a3d4662d2042971a9ec0a5fc36f9cdd7c032d35a6c0c3d02471b4b9b394b2cd349291c4a9827ca06cea4f +AUX lighttpd-1.4.59-nspr-header.patch 546 BLAKE2B c5354d75a0543a7ccb7e1f2c9aabc09dadd1703cc7199438b1b894c566314f189e2115db5f41d70c8df10101e05c31f7f5644634c0e4f9fca7919ced92457793 SHA512 e0ea1b0d3948ff487ffc050bbe692e488b98f4cacdfc122837458527168cf5c40125cd98e69a1f95095ecd28b309b19e209e07be75dae2bcdd48ea1692f1056b AUX lighttpd.confd 240 BLAKE2B 8383c102f9e3a373909f26cda9f73d1edf81ef9dae42a48593f6d6f61c1b1060cc324bb773d402307d54c6cca520ddada8016dc5b3f0922ddf75d24934bfc7c4 SHA512 dd722c15230df734d7151bcb9cfc66d6d54aac5dcdca5f50eb33979d3a2443ba3a9ef3d7cb35e6dbd3d39fce09da15ab0029b1399bf1b1e4f4ef20d40f70a416 AUX lighttpd.initd 1957 BLAKE2B df5ba8a820d9a75657e6bb3225f86b961d15f11f4b05278c44ffb1840386be5e8dd2c74e4c053ab4c5f10e5987ebac2e9b8e1489436e5ab337a2f96ca403610c SHA512 d5fc03ded923d2aeea19fefdf658ed793114867dd0b50be6836d767108c98fb7de56011f00ea63220c4b198cff45d98fdc8a649efae90673536e03f786219485 AUX lighttpd.logrotate-r1 385 BLAKE2B c41e4b7892d3cb8cd7306eb7fa93b4a03452786acc7a3078464cf2cb7eec982f626201cc0d0aea7dd7de81cacf603f6d064c8ec6f8dcff09f78dfd48b656aa93 SHA512 8cae2d3acb2f4d9a9043e492c4b15024f85f92d93616d5e92e08d51e2295fde6160c750be08244703f999208c4b43ecfb9a2fcb8e223e52992551a0668302ffe @@ -9,6 +10,8 @@ AUX lighttpd.service 257 BLAKE2B 7e60ad2f87ece8547cd3e39fc2121ea4664d9015722469a AUX lighttpd.tmpfiles.conf 41 BLAKE2B a159ae17094377d927bcf51078d40c322e5213d62064a271a7a0cf5b32423b349ac13d2ebc38a8de5c6478823ac022e46eef60a830e6ae9598e848b8c220bc2f SHA512 3fda360423a7a406a2981de647dac6b4419fe60c649bf3cc21fad566e8513293f6e81d4f5b777eaf06a056beedbf44360a39894ca3a2d05d3fc3a2d26c339efe DIST lighttpd-1.4.55.tar.xz 765660 BLAKE2B 7b972de86e7d1a51438718e4d5bd49188c107b0f2e656ead597085ae84f3d41cdb662a7774c6655155d390c26f3e4f0b0dc4243c85cb0255a91d8ca57742f402 SHA512 023d5a54079e710a89a59e259c0b5798103ef6fce4544c36110dc4c5281ef429ef99369923d74123fcf8be37afe622d44cd7149078d21971ff26f3f4ee37c439 DIST lighttpd-1.4.58.tar.xz 956828 BLAKE2B b8b0a111db64a8af429dd9922503991e55276808b58143ffce3268bc8b20a39cfec9d8c1e2917b34326ac5502801a6ca3b9bae26874f86b6749c363a09225ca3 SHA512 b7f18223e46bf78f866eb22f44a7702df07424271e085da9f0d03e626198c30e87a3959536d02e3588aa47ba4bc7db7c432307175fb3b25a2984f9cf692c0ca4 -EBUILD lighttpd-1.4.55-r100.ebuild 6908 BLAKE2B dd074fc1613f34eed2dbfcc4d7ab21a16b001f85d1abc24e08fa16468580e54e9773ef214242bb66b37280a754196701f514f43cc79bd7ff452524fcb0fed23c SHA512 c7e4ca53154f45139aad707815cfc207d0cce1fe9e7f838b675d4aa0f3e976c6d7e437656805b56adb744d3df96313dc1ce19f02edc6da41541e6d3bd1f5158a -EBUILD lighttpd-1.4.58.ebuild 7525 BLAKE2B 0db0ce65e51ce0d51ab7288a5e6d5331156b7c168da6bf3c5729b14aedece35366526c48094c0713d8d130d661d0126bfc84f3ebf7066a85aa92c377771240cc SHA512 2eba45931fd8262191c4ceb264beb27bd3a34146f32ca9392cd24697f478a23e1f203395fd605e3bbfda1c8c50990f10383e320ec62d96f6ccaba9d90dff6502 -MISC metadata.xml 1718 BLAKE2B 40b67e4fc9a9fad8cb7008b32e24a1d57149ecc78514ec3dbcb9d3df4cd865283c8a6685acf6037bfeb04b0f3b189a32fee0e0cf98955d99525bb4a5b417fb0d SHA512 442d7ee6fc749d065c01f2e6f798465ab001a504d1104726322d5fd539114301cef2562b4721df9d40305f547b81d28fdaa8d3abeb327c045065e1a7a3820616 +DIST lighttpd-1.4.59.tar.xz 968352 BLAKE2B 8997386be24d9d84fa8012aedd8ac97b3ad4fd19bb756163d3e9b8c6984c740475c6db2810817db9d1a246320bcd81f7ab35847707316454523c614a4485299f SHA512 94d312f6ac65c32057018b749c4865220b43b3e4b7fe9396848aa403ea7fdc2ccbf3f4f91daf281b754cf272a52a8bcdc689502773ea33cae36eead2785daa0f +EBUILD lighttpd-1.4.55-r101.ebuild 6930 BLAKE2B 4c4fa416b1c16180aa963cb27142b204359720984ffda46e97b72f271f33492a2e312124f65297ebd713f416b46eae14738befacb76db774660a977d0ea20cf8 SHA512 825d5eda1bea989b061daf2deaed0a7fb4677b07c5a813b28d46a7b1232ead07013eae16d428471e812d9b614f5c5a504a9d23f1ccef6fb0dc10da951a5857e8 +EBUILD lighttpd-1.4.58-r1.ebuild 7553 BLAKE2B 86e08f4bec91ec5609c202d0f9966b4aa680307dbd58f521b153ac5d31b273ea749ea51f92d5d5e05efb688a18b2fd5b072199fa62376d2f0b4837dc3d696dc4 SHA512 5e39ddbe0fc1e71ec6394e002aab4924812636768650ae79b43f38d87a4c381646ddc531ffce9b1e8cc15497f185a4073491e0df4ea63a4246f551223c1f7d33 +EBUILD lighttpd-1.4.59.ebuild 6610 BLAKE2B 4fc787aa2f3180ab55178cfb3c1be5fffcc223e738f91a562151044b19c46565f5d1df56e680e551a13ee310f7f6b11f5b8a06217177215f0b5e49083bce249e SHA512 e76181a8c1fa790f7883c5187d4c171512a67a35e2b48bb6146db5572c4fbb237ed3a5e7b416f2d04ace2448ac3c6d7117e9e18a9c73e42f6cc488621ec62129 +MISC metadata.xml 1795 BLAKE2B 40fb9d80ed77f9513c3d0c6b2ac4ee919fc496411bd003fad6f505d82eeebb4847e19def7d412939d6936d859eab088d1c345f30be4e6c4f5ca03d8a1dad7039 SHA512 b2c25885ae42fa963aad249a7f183a2093df7a612bbc7f8f33ea173f8c6ff3ebcdaa052e722a4e467ffc56815a4bf40dbb95782bb17b616be93c55a4ef5160fd diff --git a/www-servers/lighttpd/files/lighttpd-1.4.59-nspr-header.patch b/www-servers/lighttpd/files/lighttpd-1.4.59-nspr-header.patch new file mode 100644 index 000000000000..497ea36a1675 --- /dev/null +++ b/www-servers/lighttpd/files/lighttpd-1.4.59-nspr-header.patch @@ -0,0 +1,16 @@ +diff --git a/configure.ac b/configure.ac +index 325a1b4b..3f32daa9 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -887,7 +887,10 @@ if test "x$use_nss" = "xyes"; then + NSS_LIBS="-L$WITH_NSS/lib -lnss3" + else + PKG_CHECK_MODULES([NSS],[nss]) +- CPPFLAGS="$CPPFLAGS -I/usr/include/nspr4" ++ if test "x$CRYPTO_LIB" = "x"; then ++ PKG_CHECK_MODULES([NSPR],[nspr]) ++ CPPFLAGS="$CPPFLAGS $NSPR_CFLAGS" ++ fi + fi + AC_DEFINE([HAVE_NSS_NSS_H], [1], [nss/nss.h]) + AC_DEFINE([HAVE_NSS3_NSS_H], [1], [nss3/nss.h]) diff --git a/www-servers/lighttpd/lighttpd-1.4.55-r100.ebuild b/www-servers/lighttpd/lighttpd-1.4.55-r100.ebuild deleted file mode 100644 index a5923f383e75..000000000000 --- a/www-servers/lighttpd/lighttpd-1.4.55-r100.ebuild +++ /dev/null @@ -1,244 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -LUA_COMPAT=( lua5-{1..3} ) - -inherit autotools flag-o-matic lua-single readme.gentoo-r1 systemd toolchain-funcs tmpfiles - -DESCRIPTION="Lightweight high-performance web server" -HOMEPAGE="https://www.lighttpd.net https://github.com/lighttpd" -SRC_URI="https://download.lighttpd.net/lighttpd/releases-1.4.x/${P}.tar.xz" - -LICENSE="BSD GPL-2" -SLOT="0" -KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 sparc x86" -IUSE="bzip2 dbi doc fam gdbm geoip ipv6 kerberos ldap libev lua minimal mmap memcached mysql pcre php postgres rrdtool sasl selinux ssl sqlite test webdav xattr zlib" -RESTRICT="!test? ( test )" - -REQUIRED_USE="kerberos? ( ssl ) - lua? ( ${LUA_REQUIRED_USE} ) - webdav? ( sqlite )" - -BDEPEND="dev-libs/libgamin - virtual/pkgconfig" - -COMMON_DEPEND=" - bzip2? ( app-arch/bzip2 ) - dbi? ( dev-db/libdbi ) - fam? ( virtual/fam ) - gdbm? ( sys-libs/gdbm:= ) - geoip? ( dev-libs/geoip ) - ldap? ( >=net-nds/openldap-2.1.26 ) - libev? ( >=dev-libs/libev-4.01 ) - lua? ( ${LUA_DEPS} ) - memcached? ( dev-libs/libmemcached ) - mysql? ( dev-db/mysql-connector-c:= ) - pcre? ( >=dev-libs/libpcre-3.1 ) - php? ( dev-lang/php:*[cgi] ) - postgres? ( dev-db/postgresql:* ) - rrdtool? ( net-analyzer/rrdtool ) - sasl? ( dev-libs/cyrus-sasl ) - ssl? ( - >=dev-libs/openssl-0.9.7:0= - ) - sqlite? ( dev-db/sqlite:3 ) - webdav? ( - dev-libs/libxml2 - sys-fs/e2fsprogs - ) - xattr? ( kernel_linux? ( sys-apps/attr ) ) - zlib? ( >=sys-libs/zlib-1.1 ) - acct-group/lighttpd - acct-user/lighttpd" - -DEPEND="${COMMON_DEPEND} - doc? ( dev-python/docutils ) - test? ( - virtual/perl-Test-Harness - dev-libs/fcgi - )" - -RDEPEND="${COMMON_DEPEND} - selinux? ( sec-policy/selinux-apache ) -" - -# update certain parts of lighttpd.conf based on conditionals -update_config() { - local config="${D}/etc/lighttpd/lighttpd.conf" - - # enable php/mod_fastcgi settings - use php && { sed -i -e 's|#.*\(include.*fastcgi.*$\)|\1|' ${config} || die; } - - # enable stat() caching - use fam && { sed -i -e 's|#\(.*stat-cache.*$\)|\1|' ${config} || die; } - - # automatically listen on IPv6 if built with USE=ipv6. Bug #234987 - use ipv6 && { sed -i -e 's|# server.use-ipv6|server.use-ipv6|' ${config} || die; } -} - -# remove non-essential stuff (for USE=minimal) -remove_non_essential() { - local libdir="${D}/usr/$(get_libdir)/${PN}" - - # text docs - use doc || rm -fr "${D}"/usr/share/doc/${PF}/txt - - # non-essential modules - rm -f \ - ${libdir}/mod_{compress,evhost,expire,proxy,scgi,secdownload,simple_vhost,status,setenv,trigger*,usertrack}.* || die - - # allow users to keep some based on USE flags - use pcre || rm -f ${libdir}/mod_{ssi,re{direct,write}}.* - use webdav || rm -f ${libdir}/mod_webdav.* - use mysql || rm -f ${libdir}/mod_mysql_vhost.* - use lua || rm -f ${libdir}/mod_{cml,magnet}.* - use rrdtool || rm -f ${libdir}/mod_rrdtool.* - use zlib || rm -f ${libdir}/mod_compress.* -} - -pkg_setup() { - if use lua; then - lua-single_pkg_setup - fi - - if ! use pcre ; then - ewarn "It is highly recommended that you build ${PN}" - ewarn "with perl regular expressions support via USE=pcre." - ewarn "Otherwise you lose support for some core options such" - ewarn "as conditionals and modules such as mod_re{write,direct}" - ewarn "and mod_ssi." - fi - - DOC_CONTENTS="IPv6 migration guide:\n - http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config" -} - -src_prepare() { - default - use memcached && append-ldflags -pthread - #dev-python/docutils installs rst2html.py not rst2html - sed -i -e 's|\(rst2html\)|\1.py|g' doc/outdated/Makefile.am || \ - die "sed doc/Makefile.am failed" - eautoreconf -} - -src_configure() { - # The lua bit requires a bit of explanation. The lighttpd autoconf script - # handles the value passed to --with-lua as follows: - # - "no" - do nothing - # - "yes" - query pkgconfig for VERSIONED lua packages, starting with 5.3 - # and going down; only if lua5.1 cannot be found plain "lua" is tried - # - any other value is passed to pkgconfig as the exact package name to use. - # We want a specific implementation to be used even if a newer one is present - # in the system so we use the latter mode. - econf \ - CC_FOR_BUILD=$(tc-getBUILD_CC) \ - --libdir=/usr/$(get_libdir)/${PN} \ - --enable-lfs \ - $(use_enable ipv6) \ - $(use_enable mmap) \ - $(use_with bzip2) \ - $(use_with dbi) \ - $(use_with fam) \ - $(use_with gdbm) \ - $(use_with geoip ) \ - $(use_with kerberos krb5) \ - $(use_with ldap) \ - $(use_with libev) \ - $(use_with lua lua ${ELUA}) \ - $(use_with memcached) \ - $(use_with mysql) \ - $(use_with pcre) \ - $(use_with postgres pgsql) \ - $(use_with sasl) \ - $(use_with ssl openssl) \ - $(use_with sqlite) \ - $(use_with webdav webdav-props) \ - $(use_with webdav webdav-locks) \ - $(use_with xattr attr) \ - $(use_with zlib) -} - -src_compile() { - emake - - if use doc ; then - einfo "Building HTML documentation" - cd doc || die - emake html - fi -} - -src_test() { - if [[ ${EUID} -eq 0 ]]; then - default_src_test - else - ewarn "test skipped, please re-run as root if you wish to test ${PN}" - fi -} - -src_install() { - default - - find "${D}" -name '*.la' -delete || die - - # init script stuff - newinitd "${FILESDIR}"/lighttpd.initd lighttpd - newconfd "${FILESDIR}"/lighttpd.confd lighttpd - use fam && has_version app-admin/fam && \ - { sed -i 's/after famd/need famd/g' "${D}"/etc/init.d/lighttpd || die; } - - # configs - insinto /etc/lighttpd - doins "${FILESDIR}"/conf/lighttpd.conf - doins "${FILESDIR}"/conf/mime-types.conf - doins "${FILESDIR}"/conf/mod_cgi.conf - doins "${FILESDIR}"/conf/mod_fastcgi.conf - - # update lighttpd.conf directives based on conditionals - update_config - - # docs - dodoc AUTHORS README NEWS doc/scripts/*.sh - newdoc doc/config//lighttpd.conf lighttpd.conf.distrib - use ipv6 && readme.gentoo_create_doc - - use doc && dodoc -r doc - - docinto txt - dodoc doc/outdated/*.txt - - # logrotate - insinto /etc/logrotate.d - newins "${FILESDIR}"/lighttpd.logrotate-r1 lighttpd - - keepdir /var/l{ib,og}/lighttpd /var/www/localhost/htdocs - fowners lighttpd:lighttpd /var/l{ib,og}/lighttpd - fperms 0750 /var/l{ib,og}/lighttpd - - #spawn-fcgi may optionally be installed via www-servers/spawn-fcgi - rm -f "${D}"/usr/bin/spawn-fcgi "${D}"/usr/share/man/man1/spawn-fcgi.* || die - - use minimal && remove_non_essential - - systemd_dounit "${FILESDIR}/${PN}.service" - dotmpfiles "${FILESDIR}/${PN}.tmpfiles.conf" -} - -pkg_postinst() { - use ipv6 && readme.gentoo_print_elog - - if [[ -f ${ROOT}/etc/conf.d/spawn-fcgi.conf ]] ; then - einfo "spawn-fcgi is now provided by www-servers/spawn-fcgi." - einfo "spawn-fcgi's init script configuration is now located" - einfo "at /etc/conf.d/spawn-fcgi." - fi - - if [[ -f ${ROOT}/etc/lighttpd.conf ]] ; then - elog "Gentoo has a customized configuration," - elog "which is now located in /etc/lighttpd. Please migrate your" - elog "existing configuration." - fi -} diff --git a/www-servers/lighttpd/lighttpd-1.4.55-r101.ebuild b/www-servers/lighttpd/lighttpd-1.4.55-r101.ebuild new file mode 100644 index 000000000000..2da970b100e4 --- /dev/null +++ b/www-servers/lighttpd/lighttpd-1.4.55-r101.ebuild @@ -0,0 +1,245 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +LUA_COMPAT=( lua5-{1..3} ) + +inherit autotools flag-o-matic lua-single readme.gentoo-r1 systemd toolchain-funcs tmpfiles + +DESCRIPTION="Lightweight high-performance web server" +HOMEPAGE="https://www.lighttpd.net https://github.com/lighttpd" +SRC_URI="https://download.lighttpd.net/lighttpd/releases-1.4.x/${P}.tar.xz" + +LICENSE="BSD GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 sparc x86" +IUSE="bzip2 dbi doc fam gdbm geoip ipv6 kerberos ldap libev lua minimal mmap memcached mysql pcre php postgres rrdtool sasl selinux ssl sqlite test webdav xattr zlib" +RESTRICT="!test? ( test )" + +REQUIRED_USE="kerberos? ( ssl ) + lua? ( ${LUA_REQUIRED_USE} ) + webdav? ( sqlite )" + +BDEPEND="dev-libs/libgamin + virtual/pkgconfig" + +COMMON_DEPEND=" + virtual/libcrypt:= + bzip2? ( app-arch/bzip2 ) + dbi? ( dev-db/libdbi ) + fam? ( virtual/fam ) + gdbm? ( sys-libs/gdbm:= ) + geoip? ( dev-libs/geoip ) + ldap? ( >=net-nds/openldap-2.1.26 ) + libev? ( >=dev-libs/libev-4.01 ) + lua? ( ${LUA_DEPS} ) + memcached? ( dev-libs/libmemcached ) + mysql? ( dev-db/mysql-connector-c:= ) + pcre? ( >=dev-libs/libpcre-3.1:= ) + php? ( dev-lang/php:*[cgi] ) + postgres? ( dev-db/postgresql:* ) + rrdtool? ( net-analyzer/rrdtool ) + sasl? ( dev-libs/cyrus-sasl ) + ssl? ( + >=dev-libs/openssl-0.9.7:0= + ) + sqlite? ( dev-db/sqlite:3 ) + webdav? ( + dev-libs/libxml2 + sys-fs/e2fsprogs + ) + xattr? ( kernel_linux? ( sys-apps/attr ) ) + zlib? ( >=sys-libs/zlib-1.1 ) + acct-group/lighttpd + acct-user/lighttpd" + +DEPEND="${COMMON_DEPEND} + doc? ( dev-python/docutils ) + test? ( + virtual/perl-Test-Harness + dev-libs/fcgi + )" + +RDEPEND="${COMMON_DEPEND} + selinux? ( sec-policy/selinux-apache ) +" + +# update certain parts of lighttpd.conf based on conditionals +update_config() { + local config="${D}/etc/lighttpd/lighttpd.conf" + + # enable php/mod_fastcgi settings + use php && { sed -i -e 's|#.*\(include.*fastcgi.*$\)|\1|' ${config} || die; } + + # enable stat() caching + use fam && { sed -i -e 's|#\(.*stat-cache.*$\)|\1|' ${config} || die; } + + # automatically listen on IPv6 if built with USE=ipv6. Bug #234987 + use ipv6 && { sed -i -e 's|# server.use-ipv6|server.use-ipv6|' ${config} || die; } +} + +# remove non-essential stuff (for USE=minimal) +remove_non_essential() { + local libdir="${D}/usr/$(get_libdir)/${PN}" + + # text docs + use doc || rm -fr "${D}"/usr/share/doc/${PF}/txt + + # non-essential modules + rm -f \ + ${libdir}/mod_{compress,evhost,expire,proxy,scgi,secdownload,simple_vhost,status,setenv,trigger*,usertrack}.* || die + + # allow users to keep some based on USE flags + use pcre || rm -f ${libdir}/mod_{ssi,re{direct,write}}.* + use webdav || rm -f ${libdir}/mod_webdav.* + use mysql || rm -f ${libdir}/mod_mysql_vhost.* + use lua || rm -f ${libdir}/mod_{cml,magnet}.* + use rrdtool || rm -f ${libdir}/mod_rrdtool.* + use zlib || rm -f ${libdir}/mod_compress.* +} + +pkg_setup() { + if use lua; then + lua-single_pkg_setup + fi + + if ! use pcre ; then + ewarn "It is highly recommended that you build ${PN}" + ewarn "with perl regular expressions support via USE=pcre." + ewarn "Otherwise you lose support for some core options such" + ewarn "as conditionals and modules such as mod_re{write,direct}" + ewarn "and mod_ssi." + fi + + DOC_CONTENTS="IPv6 migration guide:\n + http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config" +} + +src_prepare() { + default + use memcached && append-ldflags -pthread + #dev-python/docutils installs rst2html.py not rst2html + sed -i -e 's|\(rst2html\)|\1.py|g' doc/outdated/Makefile.am || \ + die "sed doc/Makefile.am failed" + eautoreconf +} + +src_configure() { + # The lua bit requires a bit of explanation. The lighttpd autoconf script + # handles the value passed to --with-lua as follows: + # - "no" - do nothing + # - "yes" - query pkgconfig for VERSIONED lua packages, starting with 5.3 + # and going down; only if lua5.1 cannot be found plain "lua" is tried + # - any other value is passed to pkgconfig as the exact package name to use. + # We want a specific implementation to be used even if a newer one is present + # in the system so we use the latter mode. + econf \ + CC_FOR_BUILD=$(tc-getBUILD_CC) \ + --libdir=/usr/$(get_libdir)/${PN} \ + --enable-lfs \ + $(use_enable ipv6) \ + $(use_enable mmap) \ + $(use_with bzip2) \ + $(use_with dbi) \ + $(use_with fam) \ + $(use_with gdbm) \ + $(use_with geoip ) \ + $(use_with kerberos krb5) \ + $(use_with ldap) \ + $(use_with libev) \ + $(use_with lua lua ${ELUA}) \ + $(use_with memcached) \ + $(use_with mysql) \ + $(use_with pcre) \ + $(use_with postgres pgsql) \ + $(use_with sasl) \ + $(use_with ssl openssl) \ + $(use_with sqlite) \ + $(use_with webdav webdav-props) \ + $(use_with webdav webdav-locks) \ + $(use_with xattr attr) \ + $(use_with zlib) +} + +src_compile() { + emake + + if use doc ; then + einfo "Building HTML documentation" + cd doc || die + emake html + fi +} + +src_test() { + if [[ ${EUID} -eq 0 ]]; then + default_src_test + else + ewarn "test skipped, please re-run as root if you wish to test ${PN}" + fi +} + +src_install() { + default + + find "${D}" -name '*.la' -delete || die + + # init script stuff + newinitd "${FILESDIR}"/lighttpd.initd lighttpd + newconfd "${FILESDIR}"/lighttpd.confd lighttpd + use fam && has_version app-admin/fam && \ + { sed -i 's/after famd/need famd/g' "${D}"/etc/init.d/lighttpd || die; } + + # configs + insinto /etc/lighttpd + doins "${FILESDIR}"/conf/lighttpd.conf + doins "${FILESDIR}"/conf/mime-types.conf + doins "${FILESDIR}"/conf/mod_cgi.conf + doins "${FILESDIR}"/conf/mod_fastcgi.conf + + # update lighttpd.conf directives based on conditionals + update_config + + # docs + dodoc AUTHORS README NEWS doc/scripts/*.sh + newdoc doc/config//lighttpd.conf lighttpd.conf.distrib + use ipv6 && readme.gentoo_create_doc + + use doc && dodoc -r doc + + docinto txt + dodoc doc/outdated/*.txt + + # logrotate + insinto /etc/logrotate.d + newins "${FILESDIR}"/lighttpd.logrotate-r1 lighttpd + + keepdir /var/l{ib,og}/lighttpd /var/www/localhost/htdocs + fowners lighttpd:lighttpd /var/l{ib,og}/lighttpd + fperms 0750 /var/l{ib,og}/lighttpd + + #spawn-fcgi may optionally be installed via www-servers/spawn-fcgi + rm -f "${D}"/usr/bin/spawn-fcgi "${D}"/usr/share/man/man1/spawn-fcgi.* || die + + use minimal && remove_non_essential + + systemd_dounit "${FILESDIR}/${PN}.service" + dotmpfiles "${FILESDIR}/${PN}.tmpfiles.conf" +} + +pkg_postinst() { + use ipv6 && readme.gentoo_print_elog + + if [[ -f ${ROOT}/etc/conf.d/spawn-fcgi.conf ]] ; then + einfo "spawn-fcgi is now provided by www-servers/spawn-fcgi." + einfo "spawn-fcgi's init script configuration is now located" + einfo "at /etc/conf.d/spawn-fcgi." + fi + + if [[ -f ${ROOT}/etc/lighttpd.conf ]] ; then + elog "Gentoo has a customized configuration," + elog "which is now located in /etc/lighttpd. Please migrate your" + elog "existing configuration." + fi +} diff --git a/www-servers/lighttpd/lighttpd-1.4.58-r1.ebuild b/www-servers/lighttpd/lighttpd-1.4.58-r1.ebuild new file mode 100644 index 000000000000..ced96c23fec4 --- /dev/null +++ b/www-servers/lighttpd/lighttpd-1.4.58-r1.ebuild @@ -0,0 +1,266 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +LUA_COMPAT=( lua5-{1..4} ) + +inherit autotools flag-o-matic lua-single readme.gentoo-r1 systemd tmpfiles toolchain-funcs + +DESCRIPTION="Lightweight high-performance web server" +HOMEPAGE="https://www.lighttpd.net https://github.com/lighttpd" +SRC_URI="https://download.lighttpd.net/lighttpd/releases-1.4.x/${P}.tar.xz" + +LICENSE="BSD GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 sparc x86" +IUSE="brotli bzip2 dbi doc gdbm gnutls ipv6 kerberos ldap libev lua maxminddb minimal mbedtls mmap memcached mysql nss pcre php postgres rrdtool sasl selinux ssl sqlite test webdav xattr zlib" +RESTRICT="!test? ( test )" + +REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} ) + mysql? ( dbi ) + postgres? ( dbi ) + sqlite? ( dbi ) + webdav? ( sqlite ) +" + +BDEPEND="virtual/pkgconfig" + +COMMON_DEPEND=" + virtual/libcrypt:= + brotli? ( app-arch/brotli ) + bzip2? ( app-arch/bzip2 ) + dbi? ( + dev-db/libdbi + mysql? ( dev-db/libdbi-drivers[mysql] ) + postgres? ( dev-db/libdbi-drivers[postgres] ) + sqlite? ( dev-db/libdbi-drivers[sqlite] ) + ) + gdbm? ( sys-libs/gdbm:= ) + gnutls? ( net-libs/gnutls:= ) + kerberos? ( virtual/krb5 ) + ldap? ( >=net-nds/openldap-2.1.26 ) + libev? ( >=dev-libs/libev-4.01 ) + lua? ( ${LUA_DEPS} ) + maxminddb? ( dev-libs/libmaxminddb:= ) + mbedtls? ( net-libs/mbedtls:= ) + memcached? ( dev-libs/libmemcached ) + nss? ( dev-libs/nss ) + pcre? ( >=dev-libs/libpcre-3.1:= ) + php? ( dev-lang/php:*[cgi] ) + rrdtool? ( net-analyzer/rrdtool ) + sasl? ( dev-libs/cyrus-sasl ) + ssl? ( >=dev-libs/openssl-0.9.7:0= ) + webdav? ( + dev-libs/libxml2 + sys-fs/e2fsprogs + ) + xattr? ( kernel_linux? ( sys-apps/attr ) ) + zlib? ( >=sys-libs/zlib-1.1 ) + acct-group/lighttpd + acct-user/lighttpd" + +DEPEND="${COMMON_DEPEND} + doc? ( dev-python/docutils ) + test? ( + virtual/perl-Test-Harness + dev-libs/fcgi + )" + +RDEPEND="${COMMON_DEPEND} + selinux? ( sec-policy/selinux-apache ) +" + +# update certain parts of lighttpd.conf based on conditionals +update_config() { + local config="${D}/etc/lighttpd/lighttpd.conf" + + # enable php/mod_fastcgi settings + use php && { sed -i -e 's|#.*\(include.*fastcgi.*$\)|\1|' ${config} || die; } + + # automatically listen on IPv6 if built with USE=ipv6. Bug #234987 + use ipv6 && { sed -i -e 's|# server.use-ipv6|server.use-ipv6|' ${config} || die; } +} + +# remove non-essential stuff (for USE=minimal) +remove_non_essential() { + local libdir="${D}/usr/$(get_libdir)/${PN}" + + # text docs + use doc || rm -fr "${D}"/usr/share/doc/${PF}/txt + + # non-essential modules + rm -f \ + ${libdir}/mod_{evhost,expire,proxy,scgi,secdownload,simple_vhost,status,setenv,trigger*,usertrack}.* || die + + # allow users to keep some based on USE flags + use pcre || rm -f ${libdir}/mod_{ssi,re{direct,write}}.* + use webdav || rm -f ${libdir}/mod_webdav.* + use lua || rm -f ${libdir}/mod_{cml,magnet}.* + use rrdtool || rm -f ${libdir}/mod_rrdtool.* + use zlib || use bzip2 || use brotli || rm -f ${libdir}/mod_deflate.* +} + +pkg_setup() { + if use lua; then + lua-single_pkg_setup + fi + + if ! use pcre ; then + ewarn "It is highly recommended that you build ${PN}" + ewarn "with perl regular expressions support via USE=pcre." + ewarn "Otherwise you lose support for some core options such" + ewarn "as conditionals and modules such as mod_re{write,direct}" + ewarn "and mod_ssi." + fi + + DOC_CONTENTS="IPv6 migration guide:\n + http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config" +} + +src_prepare() { + default + use memcached && append-ldflags -pthread + # dev-python/docutils installs rst2html.py not rst2html + sed -i -e 's|\(rst2html\)|\1.py|g' doc/outdated/Makefile.am || \ + die "sed doc/Makefile.am failed" + eautoreconf +} + +src_configure() { + # The lua bit requires a bit of explanation. The lighttpd autoconf script + # handles the value passed to --with-lua as follows: + # - "no" - do nothing + # - "yes" - query pkgconfig for VERSIONED lua packages, starting with 5.3 + # and going down; only if lua5.1 cannot be found plain "lua" is tried + # - any other value is passed to pkgconfig as the exact package name to use. + # We want a specific implementation to be used even if a newer one is present + # in the system so we use the latter mode. + econf \ + CC_FOR_BUILD=$(tc-getBUILD_CC) \ + --libdir=/usr/$(get_libdir)/${PN} \ + --enable-lfs \ + $(use_enable ipv6) \ + $(use_enable mmap) \ + $(use_with brotli) \ + $(use_with bzip2) \ + $(use_with dbi) \ + $(use_with gdbm) \ + $(use_with gnutls ) \ + $(use_with kerberos krb5) \ + $(use_with ldap) \ + $(use_with libev) \ + $(use_with lua lua ${ELUA}) \ + $(use_with maxminddb) \ + $(use_with mbedtls) \ + $(use_with memcached) \ + $(use_with nss) \ + $(use_with pcre) \ + $(use_with sasl) \ + $(use_with ssl openssl) \ + $(use_with webdav webdav-props) \ + $(use_with webdav webdav-locks) \ + $(use_with xattr attr) \ + $(use_with zlib) +} + +src_compile() { + emake + + if use doc ; then + einfo "Building HTML documentation" + cd doc || die + emake html + fi +} + +src_test() { + if [[ ${EUID} -eq 0 ]]; then + default_src_test + else + ewarn "test skipped, please re-run as root if you wish to test ${PN}" + fi +} + +src_install() { + default + + find "${D}" -name '*.la' -delete || die + + # init script stuff + newinitd "${FILESDIR}"/lighttpd.initd lighttpd + newconfd "${FILESDIR}"/lighttpd.confd lighttpd + + # configs + insinto /etc/lighttpd + doins "${FILESDIR}"/conf/lighttpd.conf + doins "${FILESDIR}"/conf/mime-types.conf + doins "${FILESDIR}"/conf/mod_cgi.conf + doins "${FILESDIR}"/conf/mod_fastcgi.conf + + # update lighttpd.conf directives based on conditionals + update_config + + # docs + dodoc AUTHORS README NEWS doc/scripts/*.sh + newdoc doc/config//lighttpd.conf lighttpd.conf.distrib + use ipv6 && readme.gentoo_create_doc + + use doc && dodoc -r doc + + docinto txt + dodoc doc/outdated/*.txt + + # logrotate + insinto /etc/logrotate.d + newins "${FILESDIR}"/lighttpd.logrotate-r1 lighttpd + + keepdir /var/l{ib,og}/lighttpd /var/www/localhost/htdocs + fowners lighttpd:lighttpd /var/l{ib,og}/lighttpd + fperms 0750 /var/l{ib,og}/lighttpd + + # spawn-fcgi may optionally be installed via www-servers/spawn-fcgi + rm -f "${D}"/usr/bin/spawn-fcgi "${D}"/usr/share/man/man1/spawn-fcgi.* || die + + use minimal && remove_non_essential + + systemd_dounit "${FILESDIR}/${PN}.service" + newtmpfiles "${FILESDIR}/${PN}.tmpfiles.conf" "${PN}.conf" +} + +pkg_postinst() { + use ipv6 && readme.gentoo_print_elog + + if [[ -f ${ROOT}/etc/conf.d/spawn-fcgi.conf ]] ; then + einfo "spawn-fcgi is now provided by www-servers/spawn-fcgi." + einfo "spawn-fcgi's init script configuration is now located" + einfo "at /etc/conf.d/spawn-fcgi." + fi + + if [[ -f ${ROOT}/etc/lighttpd.conf ]] ; then + elog + elog "Gentoo has a customized configuration," + elog "which is now located in /etc/lighttpd. Please migrate your" + elog "existing configuration." + fi + + if use brotli || use bzip2 || use zlib; then + elog + elog "Remember to clean your cache directory when using" + elog "output compression!" + elog "https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModDeflate" + fi + + if use mysql; then + elog + elog "Note that upstream has moved away from using mysql directly" + elog "via mod_mysql and is now accessing it through mod_dbi. You" + elog "may need to update your configuration" + fi + + elog + elog "Upstream has deprecated a number of features. They are not missing" + elog "but have been migrated to other mechanisms. Please see upstream" + elog "changelog for details." + elog "https://www.lighttpd.net/2020/12/17/1.4.57/" +} diff --git a/www-servers/lighttpd/lighttpd-1.4.58.ebuild b/www-servers/lighttpd/lighttpd-1.4.58.ebuild deleted file mode 100644 index 825b9c477b1f..000000000000 --- a/www-servers/lighttpd/lighttpd-1.4.58.ebuild +++ /dev/null @@ -1,265 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -LUA_COMPAT=( lua5-{1..4} ) - -inherit autotools flag-o-matic lua-single readme.gentoo-r1 systemd tmpfiles toolchain-funcs - -DESCRIPTION="Lightweight high-performance web server" -HOMEPAGE="https://www.lighttpd.net https://github.com/lighttpd" -SRC_URI="https://download.lighttpd.net/lighttpd/releases-1.4.x/${P}.tar.xz" - -LICENSE="BSD GPL-2" -SLOT="0" -KEYWORDS="~alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ppc ppc64 ~s390 sparc x86" -IUSE="brotli bzip2 dbi doc gdbm gnutls ipv6 kerberos ldap libev lua maxminddb minimal mbedtls mmap memcached mysql nss pcre php postgres rrdtool sasl selinux ssl sqlite test webdav xattr zlib" -RESTRICT="!test? ( test )" - -REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} ) - mysql? ( dbi ) - postgres? ( dbi ) - sqlite? ( dbi ) - webdav? ( sqlite ) -" - -BDEPEND="virtual/pkgconfig" - -COMMON_DEPEND=" - brotli? ( app-arch/brotli ) - bzip2? ( app-arch/bzip2 ) - dbi? ( - dev-db/libdbi - mysql? ( dev-db/libdbi-drivers[mysql] ) - postgres? ( dev-db/libdbi-drivers[postgres] ) - sqlite? ( dev-db/libdbi-drivers[sqlite] ) - ) - gdbm? ( sys-libs/gdbm:= ) - gnutls? ( net-libs/gnutls ) - kerberos? ( virtual/krb5 ) - ldap? ( >=net-nds/openldap-2.1.26 ) - libev? ( >=dev-libs/libev-4.01 ) - lua? ( ${LUA_DEPS} ) - maxminddb? ( dev-libs/libmaxminddb ) - mbedtls? ( net-libs/mbedtls ) - memcached? ( dev-libs/libmemcached ) - nss? ( dev-libs/nss ) - pcre? ( >=dev-libs/libpcre-3.1 ) - php? ( dev-lang/php:*[cgi] ) - rrdtool? ( net-analyzer/rrdtool ) - sasl? ( dev-libs/cyrus-sasl ) - ssl? ( >=dev-libs/openssl-0.9.7:0= ) - webdav? ( - dev-libs/libxml2 - sys-fs/e2fsprogs - ) - xattr? ( kernel_linux? ( sys-apps/attr ) ) - zlib? ( >=sys-libs/zlib-1.1 ) - acct-group/lighttpd - acct-user/lighttpd" - -DEPEND="${COMMON_DEPEND} - doc? ( dev-python/docutils ) - test? ( - virtual/perl-Test-Harness - dev-libs/fcgi - )" - -RDEPEND="${COMMON_DEPEND} - selinux? ( sec-policy/selinux-apache ) -" - -# update certain parts of lighttpd.conf based on conditionals -update_config() { - local config="${D}/etc/lighttpd/lighttpd.conf" - - # enable php/mod_fastcgi settings - use php && { sed -i -e 's|#.*\(include.*fastcgi.*$\)|\1|' ${config} || die; } - - # automatically listen on IPv6 if built with USE=ipv6. Bug #234987 - use ipv6 && { sed -i -e 's|# server.use-ipv6|server.use-ipv6|' ${config} || die; } -} - -# remove non-essential stuff (for USE=minimal) -remove_non_essential() { - local libdir="${D}/usr/$(get_libdir)/${PN}" - - # text docs - use doc || rm -fr "${D}"/usr/share/doc/${PF}/txt - - # non-essential modules - rm -f \ - ${libdir}/mod_{evhost,expire,proxy,scgi,secdownload,simple_vhost,status,setenv,trigger*,usertrack}.* || die - - # allow users to keep some based on USE flags - use pcre || rm -f ${libdir}/mod_{ssi,re{direct,write}}.* - use webdav || rm -f ${libdir}/mod_webdav.* - use lua || rm -f ${libdir}/mod_{cml,magnet}.* - use rrdtool || rm -f ${libdir}/mod_rrdtool.* - use zlib || use bzip2 || use brotli || rm -f ${libdir}/mod_deflate.* -} - -pkg_setup() { - if use lua; then - lua-single_pkg_setup - fi - - if ! use pcre ; then - ewarn "It is highly recommended that you build ${PN}" - ewarn "with perl regular expressions support via USE=pcre." - ewarn "Otherwise you lose support for some core options such" - ewarn "as conditionals and modules such as mod_re{write,direct}" - ewarn "and mod_ssi." - fi - - DOC_CONTENTS="IPv6 migration guide:\n - http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config" -} - -src_prepare() { - default - use memcached && append-ldflags -pthread - # dev-python/docutils installs rst2html.py not rst2html - sed -i -e 's|\(rst2html\)|\1.py|g' doc/outdated/Makefile.am || \ - die "sed doc/Makefile.am failed" - eautoreconf -} - -src_configure() { - # The lua bit requires a bit of explanation. The lighttpd autoconf script - # handles the value passed to --with-lua as follows: - # - "no" - do nothing - # - "yes" - query pkgconfig for VERSIONED lua packages, starting with 5.3 - # and going down; only if lua5.1 cannot be found plain "lua" is tried - # - any other value is passed to pkgconfig as the exact package name to use. - # We want a specific implementation to be used even if a newer one is present - # in the system so we use the latter mode. - econf \ - CC_FOR_BUILD=$(tc-getBUILD_CC) \ - --libdir=/usr/$(get_libdir)/${PN} \ - --enable-lfs \ - $(use_enable ipv6) \ - $(use_enable mmap) \ - $(use_with brotli) \ - $(use_with bzip2) \ - $(use_with dbi) \ - $(use_with gdbm) \ - $(use_with gnutls ) \ - $(use_with kerberos krb5) \ - $(use_with ldap) \ - $(use_with libev) \ - $(use_with lua lua ${ELUA}) \ - $(use_with maxminddb) \ - $(use_with mbedtls) \ - $(use_with memcached) \ - $(use_with nss) \ - $(use_with pcre) \ - $(use_with sasl) \ - $(use_with ssl openssl) \ - $(use_with webdav webdav-props) \ - $(use_with webdav webdav-locks) \ - $(use_with xattr attr) \ - $(use_with zlib) -} - -src_compile() { - emake - - if use doc ; then - einfo "Building HTML documentation" - cd doc || die - emake html - fi -} - -src_test() { - if [[ ${EUID} -eq 0 ]]; then - default_src_test - else - ewarn "test skipped, please re-run as root if you wish to test ${PN}" - fi -} - -src_install() { - default - - find "${D}" -name '*.la' -delete || die - - # init script stuff - newinitd "${FILESDIR}"/lighttpd.initd lighttpd - newconfd "${FILESDIR}"/lighttpd.confd lighttpd - - # configs - insinto /etc/lighttpd - doins "${FILESDIR}"/conf/lighttpd.conf - doins "${FILESDIR}"/conf/mime-types.conf - doins "${FILESDIR}"/conf/mod_cgi.conf - doins "${FILESDIR}"/conf/mod_fastcgi.conf - - # update lighttpd.conf directives based on conditionals - update_config - - # docs - dodoc AUTHORS README NEWS doc/scripts/*.sh - newdoc doc/config//lighttpd.conf lighttpd.conf.distrib - use ipv6 && readme.gentoo_create_doc - - use doc && dodoc -r doc - - docinto txt - dodoc doc/outdated/*.txt - - # logrotate - insinto /etc/logrotate.d - newins "${FILESDIR}"/lighttpd.logrotate-r1 lighttpd - - keepdir /var/l{ib,og}/lighttpd /var/www/localhost/htdocs - fowners lighttpd:lighttpd /var/l{ib,og}/lighttpd - fperms 0750 /var/l{ib,og}/lighttpd - - # spawn-fcgi may optionally be installed via www-servers/spawn-fcgi - rm -f "${D}"/usr/bin/spawn-fcgi "${D}"/usr/share/man/man1/spawn-fcgi.* || die - - use minimal && remove_non_essential - - systemd_dounit "${FILESDIR}/${PN}.service" - newtmpfiles "${FILESDIR}/${PN}.tmpfiles.conf" "${PN}.conf" -} - -pkg_postinst() { - use ipv6 && readme.gentoo_print_elog - - if [[ -f ${ROOT}/etc/conf.d/spawn-fcgi.conf ]] ; then - einfo "spawn-fcgi is now provided by www-servers/spawn-fcgi." - einfo "spawn-fcgi's init script configuration is now located" - einfo "at /etc/conf.d/spawn-fcgi." - fi - - if [[ -f ${ROOT}/etc/lighttpd.conf ]] ; then - elog - elog "Gentoo has a customized configuration," - elog "which is now located in /etc/lighttpd. Please migrate your" - elog "existing configuration." - fi - - if use brotli || use bzip2 || use zlib; then - elog - elog "Remember to clean your cache directory when using" - elog "output compression!" - elog "https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModDeflate" - fi - - if use mysql; then - elog - elog "Note that upstream has moved away from using mysql directly" - elog "via mod_mysql and is now accessing it through mod_dbi. You" - elog "may need to update your configuration" - fi - - elog - elog "Upstream has deprecated a number of features. They are not missing" - elog "but have been migrated to other mechanisms. Please see upstream" - elog "changelog for details." - elog "https://www.lighttpd.net/2020/12/17/1.4.57/" -} diff --git a/www-servers/lighttpd/lighttpd-1.4.59.ebuild b/www-servers/lighttpd/lighttpd-1.4.59.ebuild new file mode 100644 index 000000000000..86b8878e8422 --- /dev/null +++ b/www-servers/lighttpd/lighttpd-1.4.59.ebuild @@ -0,0 +1,239 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +LUA_COMPAT=( lua5-{1..4} ) + +inherit autotools flag-o-matic lua-single readme.gentoo-r1 systemd tmpfiles toolchain-funcs + +DESCRIPTION="Lightweight high-performance web server" +HOMEPAGE="https://www.lighttpd.net https://github.com/lighttpd" +SRC_URI="https://download.lighttpd.net/lighttpd/releases-1.4.x/${P}.tar.xz" + +LICENSE="BSD GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" +IUSE="brotli bzip2 dbi doc gdbm gnutls ipv6 kerberos ldap libev lua maxminddb mbedtls mmap memcached mysql nss pcre php postgres rrdtool sasl selinux ssl sqlite test webdav xattr zlib zstd" +RESTRICT="!test? ( test )" + +REQUIRED_USE="lua? ( ${LUA_REQUIRED_USE} ) + mysql? ( dbi ) + postgres? ( dbi ) + sqlite? ( dbi ) + webdav? ( sqlite ) +" + +BDEPEND="virtual/pkgconfig" + +COMMON_DEPEND=" + acct-group/lighttpd + acct-user/lighttpd + brotli? ( app-arch/brotli ) + bzip2? ( app-arch/bzip2 ) + dbi? ( + dev-db/libdbi + mysql? ( dev-db/libdbi-drivers[mysql] ) + postgres? ( dev-db/libdbi-drivers[postgres] ) + sqlite? ( dev-db/libdbi-drivers[sqlite] ) + ) + gdbm? ( sys-libs/gdbm:= ) + gnutls? ( net-libs/gnutls ) + kerberos? ( virtual/krb5 ) + ldap? ( >=net-nds/openldap-2.1.26 ) + libev? ( >=dev-libs/libev-4.01 ) + lua? ( ${LUA_DEPS} ) + maxminddb? ( dev-libs/libmaxminddb ) + mbedtls? ( net-libs/mbedtls ) + memcached? ( dev-libs/libmemcached ) + nss? ( dev-libs/nss ) + pcre? ( >=dev-libs/libpcre-3.1 ) + php? ( dev-lang/php:*[cgi] ) + rrdtool? ( net-analyzer/rrdtool ) + sasl? ( dev-libs/cyrus-sasl ) + ssl? ( >=dev-libs/openssl-0.9.7:0= ) + webdav? ( + dev-libs/libxml2 + sys-fs/e2fsprogs + ) + xattr? ( kernel_linux? ( sys-apps/attr ) ) + zlib? ( >=sys-libs/zlib-1.1 ) + zstd? ( app-arch/zstd )" + +DEPEND="${COMMON_DEPEND} + doc? ( dev-python/docutils ) + test? ( + virtual/perl-Test-Harness + dev-libs/fcgi + )" + +RDEPEND="${COMMON_DEPEND} + selinux? ( sec-policy/selinux-apache ) +" + +PATCHES=( "${FILESDIR}"/${P}-nspr-header.patch ) + +# update certain parts of lighttpd.conf based on conditionals +update_config() { + local config="${D}/etc/lighttpd/lighttpd.conf" + + # enable php/mod_fastcgi settings + if use php; then sed -i -e 's|#.*\(include.*fastcgi.*$\)|\1|' ${config} || die; fi + + # automatically listen on IPv6 if built with USE=ipv6. Bug #234987 + if use ipv6; then sed -i -e 's|# server.use-ipv6|server.use-ipv6|' ${config} || die; fi +} + +pkg_setup() { + if use lua; then + lua-single_pkg_setup + fi + + if ! use pcre ; then + ewarn "It is highly recommended that you build ${PN}" + ewarn "with perl regular expressions support via USE=pcre." + ewarn "Otherwise you lose support for some core options such" + ewarn "as conditionals and modules such as mod_re{write,direct}" + ewarn "and mod_ssi." + fi + + DOC_CONTENTS="IPv6 migration guide:\n + http://redmine.lighttpd.net/projects/lighttpd/wiki/IPv6-Config" +} + +src_prepare() { + default + if use memcached; then append-ldflags -pthread; fi + # dev-python/docutils installs rst2html.py not rst2html + sed -i -e 's|\(rst2html\)|\1.py|g' doc/outdated/Makefile.am || \ + die "sed doc/Makefile.am failed" + eautoreconf +} + +src_configure() { + # The lua bit requires a bit of explanation. The lighttpd autoconf script + # handles the value passed to --with-lua as follows: + # - "no" - do nothing + # - "yes" - query pkgconfig for VERSIONED lua packages, starting with 5.3 + # and going down; only if lua5.1 cannot be found plain "lua" is tried + # - any other value is passed to pkgconfig as the exact package name to use. + # We want a specific implementation to be used even if a newer one is present + # in the system so we use the latter mode. + econf \ + CC_FOR_BUILD=$(tc-getBUILD_CC) \ + --libdir=/usr/$(get_libdir)/${PN} \ + --enable-lfs \ + $(use_enable ipv6) \ + $(use_enable mmap) \ + $(use_with brotli) \ + $(use_with bzip2) \ + $(use_with dbi) \ + $(use_with gdbm) \ + $(use_with gnutls ) \ + $(use_with kerberos krb5) \ + $(use_with ldap) \ + $(use_with libev) \ + $(use_with lua lua ${ELUA}) \ + $(use_with maxminddb) \ + $(use_with mbedtls) \ + $(use_with memcached) \ + $(use_with nss) \ + $(use_with pcre) \ + $(use_with sasl) \ + $(use_with ssl openssl) \ + $(use_with webdav webdav-props) \ + $(use_with webdav webdav-locks) \ + $(use_with xattr attr) \ + $(use_with zlib) \ + $(use_with zstd) +} + +src_compile() { + emake + + if use doc ; then + einfo "Building HTML documentation" + cd doc || die + emake html + fi +} + +src_test() { + if [[ ${EUID} -eq 0 ]]; then + default_src_test + else + ewarn "test skipped, please re-run as root if you wish to test ${PN}" + fi +} + +src_install() { + default + + find "${D}" -name '*.la' -delete || die + + # init script stuff + newinitd "${FILESDIR}"/lighttpd.initd lighttpd + newconfd "${FILESDIR}"/lighttpd.confd lighttpd + + # configs + insinto /etc/lighttpd + doins "${FILESDIR}"/conf/lighttpd.conf + doins "${FILESDIR}"/conf/mime-types.conf + doins "${FILESDIR}"/conf/mod_cgi.conf + doins "${FILESDIR}"/conf/mod_fastcgi.conf + + # update lighttpd.conf directives based on conditionals + update_config + + # docs + dodoc AUTHORS README NEWS doc/scripts/*.sh + newdoc doc/config//lighttpd.conf lighttpd.conf.distrib + if use ipv6; then readme.gentoo_create_doc; fi + + if use doc; then dodoc -r doc; fi + + docinto txt + dodoc doc/outdated/*.txt + + # logrotate + insinto /etc/logrotate.d + newins "${FILESDIR}"/lighttpd.logrotate-r1 lighttpd + + keepdir /var/l{ib,og}/lighttpd /var/www/localhost/htdocs + fowners lighttpd:lighttpd /var/l{ib,og}/lighttpd + fperms 0750 /var/l{ib,og}/lighttpd + + systemd_dounit "${FILESDIR}/${PN}.service" + newtmpfiles "${FILESDIR}/${PN}.tmpfiles.conf" "${PN}.conf" +} + +pkg_postinst() { + if use ipv6; then readme.gentoo_print_elog; fi + + if [[ -f ${ROOT}/etc/lighttpd.conf ]] ; then + elog + elog "Gentoo has a customized configuration," + elog "which is now located in /etc/lighttpd. Please migrate your" + elog "existing configuration." + fi + + if use brotli || use bzip2 || use zlib; then + elog + elog "Remember to clean your cache directory when using" + elog "output compression!" + elog "https://redmine.lighttpd.net/projects/lighttpd/wiki/Docs_ModDeflate" + fi + + if use mysql; then + elog + elog "Note that upstream has moved away from using mysql directly" + elog "via mod_mysql and is now accessing it through mod_dbi. You" + elog "may need to update your configuration" + fi + + elog + elog "Upstream has deprecated a number of features. They are not missing" + elog "but have been migrated to other mechanisms. Please see upstream" + elog "changelog for details." + elog "https://www.lighttpd.net/2021/2/2/1.4.59/" +} diff --git a/www-servers/lighttpd/metadata.xml b/www-servers/lighttpd/metadata.xml index bdade9103aaa..8477d5d0d91f 100644 --- a/www-servers/lighttpd/metadata.xml +++ b/www-servers/lighttpd/metadata.xml @@ -29,5 +29,6 @@ Enable rrdtool support via mod_rrdtool Enable webdav properties Enable output compression via gzip or deflate algorithms + Enable output compression via Zstandard algorithm -- cgit v1.2.3