diff options
Diffstat (limited to 'www-servers')
22 files changed, 1985 insertions, 413 deletions
diff --git a/www-servers/Manifest.gz b/www-servers/Manifest.gz Binary files differindex 11de02edec7a..e106b2284179 100644 --- a/www-servers/Manifest.gz +++ b/www-servers/Manifest.gz diff --git a/www-servers/apache/Manifest b/www-servers/apache/Manifest index 31f6e8c3e711..2169d4e26236 100644 --- a/www-servers/apache/Manifest +++ b/www-servers/apache/Manifest @@ -1,7 +1,9 @@ AUX 41_mod_http2.conf 189 BLAKE2B 70f006ead657b250bb4c30a332484baf698541d44d922453bae6133e2458a7009035156f47c1dbba42bd6830ab5bef8c56d151821b0b56e9b41ef9b3db885411 SHA512 3d56a24ea98bc3188e5d6f8e2e0148e4b718e04f23452e77750bca984c44fc7c3acd4521a945b4c415284d0a5dac0f7e846bb60daf70fe61ce2632e8fa201ed6 +AUX apache-2.4.51-mpm-itk.patch 890 BLAKE2B 882a0c92334a30c61733fe4acb314e6b25f6bd3f09fa92caf4ed29091e8e86132d184979f4b246cbb1f341aeaec309267c1313e806ea6ed0ba20b8b4981bdf4d SHA512 a15c7b53719b9a296053ae31ba0021ef6126ecab6b661229ac9bb5e448ddd8c870be004e71d328c9dbc8e8cbc70009278403b0329628acf10ba0fccb5d6bbe17 AUX apache.conf 55 BLAKE2B 05ab58ac12e51c7aa548a71a2da43bbf80e53ef8ebe7d143f698b118621f2af1498a1362e7f30b82dc12a96485652cb0c34248c290f6a1aab6a3f378d9843c2a SHA512 3a53beb7a283d17c14383f16ad14c0602681ac1b193cce8f5aca50ae9d9af3a71054ce4a9ab11cbcb72fe913459e1b306fd54660154e66afe10272f8c0f149f3 AUX apache2.2-hardened.service 970 BLAKE2B 77bf52cd0e5793aa81ad2b16267c1339e10fc4875704add053fd9ec67db60d2e175cb7a271c8d36b5e675a9cddd431062a6c31730510a921357b472383b502e4 SHA512 c206e7103d592dcf4f2d62979a20f7ab3cc7ce357ffe3c06ae8137064c812b9727e01a53fd602a0a55a64ed609664061de680ff42329381db787e2dae9310c48 DIST gentoo-apache-2.4.46-r6-20210212.tar.bz2 25854 BLAKE2B 001f16c1beac8c90fd407bb2f77417f886296baf02acf0f6d81dc0f10c209270db7005f58d845d309dec8332773556da88db41a57c6ecc86f24b8a5141ba07d0 SHA512 976dde952277542efca70831b67da32b8bf636a346adeeb6e0bc5a65b3543a7ca4fb182bc01204f747b583dd753607d184d91ef46a93d5e2f3ab55ed787860a2 DIST httpd-2.4.51.tar.bz2 7653609 BLAKE2B a0743327f0411f5cb8b7d0426bf78db0f370e3d587f3a4c4bb7de0e4499effa3f44f5998e19e9ca3ed7b6fc9a8c0867cbe62134b5af7e6ed6c3bc29770b797df SHA512 9fb07c4b176f5c0485a143e2b1bb1085345ca9120b959974f68c37a8911a57894d2cb488b1b42fdf3102860b99e890204f5e9fa7ae3828b481119c563812cc66 +EBUILD apache-2.4.51-r1.ebuild 8311 BLAKE2B 8d798a311304fc639fd5d7e327c67346771f7bea356da5d82c0f87308f82909499b4d3b18833e061764a84da33b371bf10542f34974243a32c44e3a9fc362bfe SHA512 196fe69be7ee634fb0b52d64252b41bd3c0df6ae8940f73ca90cdb73b700064e71126214b13544576f47c6d563efd485734cbcbe0827656948da015da5343916 EBUILD apache-2.4.51.ebuild 8256 BLAKE2B 11bb21bf6f5bc9b13b57f83350b8efc5fe9a39da063a887a281f137951d7a40d305ff395406d30b8dfb5817319d132807b06698f86f278b92d0fb2adf3416f02 SHA512 281026c9f861bacfaa6664eda7701063eb1698f00f71117951944d7fa408df11367bbc10bafede5d0a9f88c62344f94fe6b12d384af6e92f2ab5db1bded68660 MISC metadata.xml 901 BLAKE2B 126de8b6d9c924dc1bfedecc23b0ea5b5b3881b13cda7dd35d1ba04c30dabef619b2a57ac83e65695ce5e6e51b0f17c69cf752d6505c0d146dca8e2b7d90cbc6 SHA512 453b98f9ee9af6ebfc11d55e2218d1877a5a3f45fd969f6b3708f97216776c41deb651116826b15d744ea54fdd283497bc4f14917a9b00ae8b6e7af126441263 diff --git a/www-servers/apache/apache-2.4.51-r1.ebuild b/www-servers/apache/apache-2.4.51-r1.ebuild new file mode 100644 index 000000000000..bc81f071d01c --- /dev/null +++ b/www-servers/apache/apache-2.4.51-r1.ebuild @@ -0,0 +1,264 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# latest gentoo apache files +GENTOO_PATCHSTAMP="20210212" +GENTOO_DEVELOPER="polynomial-c" +GENTOO_PATCHNAME="gentoo-apache-2.4.46-r6" + +# IUSE/USE_EXPAND magic +IUSE_MPMS_FORK="prefork" +IUSE_MPMS_THREAD="event worker" + +# << obsolete modules: +# authn_default authz_default mem_cache +# mem_cache is replaced by cache_disk +# ?? buggy modules +# proxy_scgi: startup error: undefined symbol "ap_proxy_release_connection", no fix found +# >> added modules for reason: +# compat: compatibility with 2.2 access control +# authz_host: new module for access control +# authn_core: functionality provided by authn_alias in previous versions +# authz_core: new module, provides core authorization capabilities +# cache_disk: replacement for mem_cache +# lbmethod_byrequests: Split off from mod_proxy_balancer in 2.3 +# lbmethod_bytraffic: Split off from mod_proxy_balancer in 2.3 +# lbmethod_bybusyness: Split off from mod_proxy_balancer in 2.3 +# lbmethod_heartbeat: Split off from mod_proxy_balancer in 2.3 +# slotmem_shm: Slot-based shared memory provider (for lbmethod_byrequests). +# socache_shmcb: shared object cache provider. Default config with ssl needs it +# unixd: fixes startup error: Invalid command 'User' +IUSE_MODULES="access_compat actions alias asis auth_basic auth_digest auth_form +authn_alias authn_anon authn_core authn_dbd authn_dbm authn_file authn_socache authz_core +authz_dbd authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex +brotli cache cache_disk cache_socache cern_meta charset_lite cgi cgid dav dav_fs dav_lock +dbd deflate dir dumpio env expires ext_filter file_cache filter headers http2 +ident imagemap include info lbmethod_byrequests lbmethod_bytraffic lbmethod_bybusyness +lbmethod_heartbeat log_config log_forensic logio lua macro md mime mime_magic negotiation +proxy proxy_ajp proxy_balancer proxy_connect proxy_ftp proxy_html proxy_http proxy_scgi +proxy_http2 proxy_fcgi proxy_uwsgi proxy_wstunnel rewrite ratelimit remoteip reqtimeout +session session_cookie session_crypto session_dbd setenvif slotmem_shm speling +socache_memcache socache_shmcb status substitute unique_id userdir usertrack +unixd version vhost_alias watchdog xml2enc" +# The following are also in the source as of this version, but are not available +# for user selection: +# bucketeer case_filter case_filter_in echo http isapi optional_fn_export +# optional_fn_import optional_hook_export optional_hook_import + +# inter-module dependencies +# TODO: this may still be incomplete +MODULE_DEPENDS=" + auth_form:session + brotli:filter + dav_fs:dav + dav_lock:dav + deflate:filter + cache_disk:cache + ext_filter:filter + file_cache:cache + lbmethod_byrequests:proxy_balancer + lbmethod_byrequests:slotmem_shm + lbmethod_bytraffic:proxy_balancer + lbmethod_bybusyness:proxy_balancer + lbmethod_heartbeat:proxy_balancer + log_forensic:log_config + logio:log_config + cache_disk:cache + cache_socache:cache + md:watchdog + mime_magic:mime + proxy_ajp:proxy + proxy_balancer:proxy + proxy_balancer:slotmem_shm + proxy_connect:proxy + proxy_ftp:proxy + proxy_html:proxy + proxy_html:xml2enc + proxy_http:proxy + proxy_http2:proxy + proxy_scgi:proxy + proxy_uwsgi:proxy + proxy_fcgi:proxy + proxy_wstunnel:proxy + session_cookie:session + session_dbd:dbd + session_dbd:session + socache_memcache:cache + substitute:filter +" + +# module<->define mappings +MODULE_DEFINES=" + auth_digest:AUTH_DIGEST + authnz_ldap:AUTHNZ_LDAP + cache:CACHE + cache_disk:CACHE + cache_socache:CACHE + dav:DAV + dav_fs:DAV + dav_lock:DAV + file_cache:CACHE + http2:HTTP2 + info:INFO + ldap:LDAP + lua:LUA + md:SSL + proxy:PROXY + proxy_ajp:PROXY + proxy_balancer:PROXY + proxy_connect:PROXY + proxy_ftp:PROXY + proxy_html:PROXY + proxy_http:PROXY + proxy_fcgi:PROXY + proxy_scgi:PROXY + proxy_wstunnel:PROXY + socache_shmcb:SSL + socache_memcache:CACHE + ssl:SSL + status:STATUS + suexec:SUEXEC + userdir:USERDIR +" + +# critical modules for the default config +MODULE_CRITICAL=" + authn_core + authz_core + authz_host + dir + mime + unixd +" +inherit apache-2 systemd tmpfiles toolchain-funcs + +DESCRIPTION="The Apache Web Server" +HOMEPAGE="https://httpd.apache.org/" + +# some helper scripts are Apache-1.1, thus both are here +LICENSE="Apache-2.0 Apache-1.1" +SLOT="2" +KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x64-macos ~sparc64-solaris ~x64-solaris" + +# FIXME! Move this to eclass once all ebuilds are EAPI-7 +RDEPEND+=" apache2_modules_lua? ( ${LUA_DEPS} )" +REQUIRED_USE+=" apache2_modules_lua? ( ${LUA_REQUIRED_USE} )" + +PATCHES=( "${FILESDIR}/apache-2.4.51-mpm-itk.patch" ) + +pkg_setup() { + # dependend critical modules which are not allowed in global scope due + # to USE flag conditionals (bug #499260) + use ssl && MODULE_CRITICAL+=" socache_shmcb" + use doc && MODULE_CRITICAL+=" alias negotiation setenvif" + apache-2_pkg_setup +} + +src_configure() { + # Brain dead check. + tc-is-cross-compiler && export ap_cv_void_ptr_lt_long="no" + + apache-2_src_configure +} + +src_compile() { + if tc-is-cross-compiler ; then + # This header is the same across targets, so use the build compiler. + pushd server >/dev/null + emake gen_test_char + tc-export_build_env BUILD_CC + ${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_CPPFLAGS} ${BUILD_LDFLAGS} \ + gen_test_char.c -o gen_test_char $(apr-1-config --includes) || die + popd >/dev/null + fi + + default +} + +src_install() { + apache-2_src_install + local i + local apache_tools_prune_list=( + /usr/bin/{htdigest,logresolve,htpasswd,htdbm,ab,httxt2dbm} + /usr/sbin/{checkgid,fcgistarter,htcacheclean,rotatelogs} + /usr/share/man/man1/{logresolve.1,htdbm.1,htdigest.1,htpasswd.1,dbmmanage.1,ab.1} + /usr/share/man/man8/{rotatelogs.8,htcacheclean.8} + ) + for i in ${apache_tools_prune_list[@]} ; do + rm "${ED}"/${i} || die "Failed to prune apache-tools bits" + done + + # install apxs in /usr/bin (bug #502384) and put a symlink into the + # old location until all ebuilds and eclasses have been modified to + # use the new location. + dobin support/apxs + use split-usr && dosym ../bin/apxs /usr/sbin/apxs + + # Note: wait for mod_systemd to be included in some forthcoming release, + # Then apache2.4.service can be used and systemd support controlled + # through --enable-systemd + systemd_newunit "${FILESDIR}/apache2.2-hardened.service" "apache2.service" + dotmpfiles "${FILESDIR}/apache.conf" + #insinto /etc/apache2/modules.d + #doins "${FILESDIR}/00_systemd.conf" + + # Install http2 module config + insinto /etc/apache2/modules.d + doins "${FILESDIR}"/41_mod_http2.conf + + # Fix path to apache libdir + sed "s|@LIBDIR@|$(get_libdir)|" -i "${ED}"/usr/sbin/apache2ctl || die +} + +pkg_postinst() { + echo + ewarn "Downgrading to pre-GLEP 81 user for now." + ewarn "See bug #802495 and bug #803500 for more information." + ewarn "" + ewarn "You will need to run the following command to unlock the user:" + ewarn "usermod -e '' -U apache 2>/dev/null" + echo + + apache-2_pkg_postinst || die "apache-2_pkg_postinst failed" + + tmpfiles_process apache.conf #662544 + + # warnings that default config might not work out of the box + local mod cmod + for mod in ${MODULE_CRITICAL} ; do + if ! use "apache2_modules_${mod}"; then + echo + ewarn "Warning: Critical module not installed!" + ewarn "Modules 'authn_core', 'authz_core' and 'unixd'" + ewarn "are highly recomended but might not be in the base profile yet." + ewarn "Default config for ssl needs module 'socache_shmcb'." + ewarn "Enabling the following flags is highly recommended:" + for cmod in ${MODULE_CRITICAL} ; do + use "apache2_modules_${cmod}" || \ + ewarn "+ apache2_modules_${cmod}" + done + echo + break + fi + done + # warning for proxy_balancer and missing load balancing scheduler + if use apache2_modules_proxy_balancer; then + local lbset= + for mod in lbmethod_byrequests lbmethod_bytraffic lbmethod_bybusyness lbmethod_heartbeat; do + if use "apache2_modules_${mod}"; then + lbset=1 && break + fi + done + if [[ ! ${lbset} ]] ; then + echo + ewarn "Info: Missing load balancing scheduler algorithm module" + ewarn "(They were split off from proxy_balancer in 2.3)" + ewarn "In order to get the ability of load balancing, at least" + ewarn "one of these modules has to be present:" + ewarn "lbmethod_byrequests lbmethod_bytraffic lbmethod_bybusyness lbmethod_heartbeat" + echo + fi + fi +} diff --git a/www-servers/apache/files/apache-2.4.51-mpm-itk.patch b/www-servers/apache/files/apache-2.4.51-mpm-itk.patch new file mode 100644 index 000000000000..4d36fe03dffb --- /dev/null +++ b/www-servers/apache/files/apache-2.4.51-mpm-itk.patch @@ -0,0 +1,34 @@ +Backport of upstream r1894171 to fix segfaults with mpm-itk. + +https://bugs.gentoo.org/816258 +https://bz.apache.org/bugzilla/show_bug.cgi?id=65627 + +--- a/server/connection.c 2021/09/21 20:03:52 1893497 ++++ b/server/connection.c 2021/10/12 16:48:18 1894171 +@@ -145,9 +145,7 @@ + { + apr_socket_t *csd = ap_get_conn_socket(c); + +- if (!csd) { +- return 1; +- } ++ ap_assert(csd != NULL); + + if (ap_prep_lingering_close(c)) { + return 1; +@@ -178,6 +176,15 @@ + apr_time_t now, timeup = 0; + apr_socket_t *csd = ap_get_conn_socket(c); + ++ if (!csd) { ++ /* Be safe with third-party modules that: ++ * ap_set_core_module_config(c->conn_config, NULL) ++ * to no-op ap_lingering_close(). ++ */ ++ c->aborted = 1; ++ return; ++ } ++ + if (ap_start_lingering_close(c)) { + apr_socket_close(csd); + return; diff --git a/www-servers/nginx-unit/Manifest b/www-servers/nginx-unit/Manifest index 5d0ff8c6734d..b3423557e6b0 100644 --- a/www-servers/nginx-unit/Manifest +++ b/www-servers/nginx-unit/Manifest @@ -1,9 +1,9 @@ -AUX nginx-unit-1.25.0-glibc-2.34.patch 623 BLAKE2B 4836aa03f0d4090d132046c0c2cbda8f17dc5c1e3a374f0675e0a310d8f66f0fb37869f435c693791afbfc728b2ba6fd76359808c2dadc3d70c40e96267d0f51 SHA512 ecb60becb4a2a5944b7c401b6b96461cea40a8b2d7f22338647a4fd1ea67b304966cf388de91f1f734efdae13749b329f2bed8671ca7b375d4302f8683f3ebed AUX nginx-unit.initd 291 BLAKE2B e0d8b4bbdd9d57214551f4257b95271210a942fed747797f102b7932323b9bcbe871d9fd7cd0e8dee81eca2b41f21d5118a7f4f31c3fe6cbe18c1df09b164be0 SHA512 1212b49a56e4318476d051f8a3a82c6bb65f55adadd2dc51e3e91100823f6bdd8f82f162041db92fbc4f1a777cdafd22c32efce121a57f5d6eb3f5883da1abaa AUX nginx-unit.service 237 BLAKE2B 7e8b373372b7908bee80f4a57718a6b9ef7fd99872057006377284fb3bda088a0b6720b0246e5a27b6853d6351244432482f12afe5758b0f36dbdd1c04cce118 SHA512 fdf7ec12f58064c9a9fbd431fc4f56699563ff6bbf8124195810ca7a2e0ed813dbfdc41e6e1455b12960bd8d96fcf0eb2b632243d71d6a3b74d93a263c11596d DIST nginx-unit-1.22.0.tar.gz 824763 BLAKE2B 3ef343d62f3cfe793840c78fe18fd68ecad93170c87df1769636e8516df21901712d7e82caa5bafc3bf76231f32531cb7b0c1bdbe04706ee176a1e57526c50eb SHA512 7418e9dd86c10d64184f5a2f3e26c27bacc53b90ba35658fba6af00a57df89645c16c16b510d3e570eee6f8fdeef4ec7f92971f7231093e3da118e858ed386f5 -DIST nginx-unit-1.25.0.tar.gz 853280 BLAKE2B 7aa33e687ba754ebaaca4a0076df3f1cc05e83213de1b64cf28718bf53b9085a26a78c036f4e98308cabec0026ce2b4e91718dfb9d8d83fdad779a587e1c1d71 SHA512 fc001ab21c5aa6c07b092f7b1f44be3b88636f9e2059c8bc4049a06d863daae1bbfa2531a4a24bdd5976250d7a0e260dcf0dbb0dec63efcc008b5398c6bb4bbd +DIST nginx-unit-1.26.0.tar.gz 865556 BLAKE2B 8ef2f32364ae9858ec41c21639c2b9514d7aed4d4150d2952634946b0b180f5fee7c4be6e67e3608040d9bc7bd0f4fd19c158b5457fe629566bc42ff845f599b SHA512 9e10cd320bc6182e94f8b5296367922b39e2149166793f46c5012f9dbba806a4508ee4ec65a8677391f5c4d7b06481c176ccf94b8fd1ab5d4b018eb167877f5f +DIST nginx-unit-1.26.1.tar.gz 865811 BLAKE2B eb0b62e48a8d0f9199dfe77a2d6ec90a06ac24f83b362ae16fde83eea53e03923127be7b24da47a83cf51fc4ebe7930cba9a3ee7550a5243f242cc4bfba3a3b9 SHA512 1caadb35cb208067a5d437e1f649c9f9a833a39c4344b2c3a5ae94d9fcd811913e2f23114cf8d7886030306e036da18c55f09044b8a575c1616568321b8d84ec EBUILD nginx-unit-1.22.0-r1.ebuild 1986 BLAKE2B 3acda1df9975cb822bb051544984567dc47e5ac7b57ee848235d5bce2cd0173e39ec26e43d7fea1f2b01c6280c348bba24b5fdd77b9f82fcbb4b3a9fc712c5eb SHA512 1115deb7a894188cf819b2611651f7b3515145e33f378d2ecf1f44d053b76722b3dade71d83faf9591d1bdb983737366958b201cb0e14a254343c32651fc5fda -EBUILD nginx-unit-1.25.0-r1.ebuild 2089 BLAKE2B 77878fc08dd4fb2dffff5f042324c9cc11bc5f58edf0bfdb35a16b559d65207bc9e6d966164de12643ae5b31c5fffd8a9812991042d78c62a36ca956a96d7923 SHA512 bec3902e163eb05dc53f2627e01af02f9ac0511043702f4a08b90f6fa5af7bbda35f43342c0fe607197555d77671414cc44475dd8d0e696311c8ecf7b4482ad3 -EBUILD nginx-unit-1.25.0-r2.ebuild 2089 BLAKE2B 402140a7c4e024e11325bf91c8faf50a88a3ff0805cb6ec1ce6616125766dcbff2037b9aeb7cf168362178a861e8d2036e849115ed52c64eecf1d7905d383450 SHA512 ceeebf4b46cd0ac752a338b75636e4987b284c841e5b503d011e76d8a0e0e9306461d66de904285aad9d5a23fbc3047f926b35ffcfe55dd1735814eee77f9d34 +EBUILD nginx-unit-1.26.0.ebuild 2040 BLAKE2B 0ceaf50b6da5a0dbc00938a7c6a3bc72b7f30bd214e363cb457c5828da8077fb1db0aadf4e5558c8cb7103d30248a0bf551b6c6177fa850ae7f51344cbbb1dc4 SHA512 a733c96ce5f4be49fc0db1d2389313544e0a072d98b6e38e41b57b274148d2e281ee10723314000b827de97ada5fa1b6a46abafd33574b78cda5083bb60d8928 +EBUILD nginx-unit-1.26.1.ebuild 2040 BLAKE2B 0ceaf50b6da5a0dbc00938a7c6a3bc72b7f30bd214e363cb457c5828da8077fb1db0aadf4e5558c8cb7103d30248a0bf551b6c6177fa850ae7f51344cbbb1dc4 SHA512 a733c96ce5f4be49fc0db1d2389313544e0a072d98b6e38e41b57b274148d2e281ee10723314000b827de97ada5fa1b6a46abafd33574b78cda5083bb60d8928 MISC metadata.xml 1100 BLAKE2B aace2457ae0f0c2d4f294b4e4b596e4939dd967ea0126c40ae39d34c9ae9257d527b54f0f4e2dd315e944c59bac4319b6c4b6b9a5a2de2239bd35accb1a93b36 SHA512 91af085df5d35fd10de25cf5d4c843d03d38aac302c825566ee7db801923b69ef4f35ab7b3a9e2b7d670a5b4785bdad7ab902ffb6b8a5c23b42a7cae98407e38 diff --git a/www-servers/nginx-unit/files/nginx-unit-1.25.0-glibc-2.34.patch b/www-servers/nginx-unit/files/nginx-unit-1.25.0-glibc-2.34.patch deleted file mode 100644 index c2f5165402ac..000000000000 --- a/www-servers/nginx-unit/files/nginx-unit-1.25.0-glibc-2.34.patch +++ /dev/null @@ -1,22 +0,0 @@ -From 0125873b1dfbe6e671e3c9874ec2653f1b7832fa Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@remirepo.net> -Date: Fri, 3 Sep 2021 18:03:38 +0200 -Subject: [PATCH] fix build with recent glibc - ---- - src/nxt_thread.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/nxt_thread.h b/src/nxt_thread.h -index d7800cc6..36e74cde 100644 ---- a/src/nxt_thread.h -+++ b/src/nxt_thread.h -@@ -142,7 +142,7 @@ nxt_thread_yield() \ - #endif - - --#if (PTHREAD_STACK_MIN) -+#if defined(PTHREAD_STACK_MIN) - #define NXT_THREAD_STACK_MIN PTHREAD_STACK_MIN - - #else diff --git a/www-servers/nginx-unit/nginx-unit-1.25.0-r2.ebuild b/www-servers/nginx-unit/nginx-unit-1.26.0.ebuild index 1d9e098f0bcb..dcbeae43d4de 100644 --- a/www-servers/nginx-unit/nginx-unit-1.25.0-r2.ebuild +++ b/www-servers/nginx-unit/nginx-unit-1.26.0.ebuild @@ -34,8 +34,6 @@ DEPEND="perl? ( dev-lang/perl:= ) virtual/libcrypt:0=" RDEPEND="${DEPEND}" -PATCHES=( "${FILESDIR}"/${P}-glibc-2.34.patch ) - pkg_setup() { use python && python-single-r1_pkg_setup } diff --git a/www-servers/nginx-unit/nginx-unit-1.25.0-r1.ebuild b/www-servers/nginx-unit/nginx-unit-1.26.1.ebuild index b4fa47193ab9..dcbeae43d4de 100644 --- a/www-servers/nginx-unit/nginx-unit-1.25.0-r1.ebuild +++ b/www-servers/nginx-unit/nginx-unit-1.26.1.ebuild @@ -27,15 +27,13 @@ DEPEND="perl? ( dev-lang/perl:= ) php7-4? ( dev-lang/php:7.4[embed] ) python? ( ${PYTHON_DEPS} ) ruby? ( - dev-lang/ruby:* - dev-ruby/rubygems:* + dev-lang/ruby:= + dev-ruby/rubygems:= ) ssl? ( dev-libs/openssl:0= ) virtual/libcrypt:0=" RDEPEND="${DEPEND}" -PATCHES=( "${FILESDIR}"/${P}-glibc-2.34.patch ) - pkg_setup() { use python && python-single-r1_pkg_setup } diff --git a/www-servers/nginx/Manifest b/www-servers/nginx/Manifest index 1dc12ff61032..edf1d9749f8e 100644 --- a/www-servers/nginx/Manifest +++ b/www-servers/nginx/Manifest @@ -11,6 +11,7 @@ AUX nginx.logrotate-r1 257 BLAKE2B d62c57377efd5259b6c776861d921b6e4ea026387157d AUX nginx.service-r1 356 BLAKE2B 05d89efcc73b70a26655f306f1e074e61c81063cb4e949161efbe95dc375e63807233f38c9af6723801e8f653cfad08f62fbec225b061d1179b7d05fe761afc4 SHA512 e51f4e88abe10555afe79d4d029651a4de42a5dc1dddaf951f13c021453da00e0c56a3fa2129d08fcd090909a54564e76887c93fdf72952021f5a2b09f6097eb DIST modsecurity-2.9.3.tar.gz 4307670 BLAKE2B 337ea15cc8805af7ab43aed8aecf4c72ccc586d0d7e9d9b91f036a61baa70d1ac8b4ad8045a2bb7a13515912a15fba7d3cdb9670ae6730de43b1e44ee90ded6d SHA512 4e1ea5dd8edadf8f630e4fe92a200d3a8e78963fce3128b5975a1e1ecd0e8bf9ceecd9905c95f8c508932ccd837f1d8ae8bb2ba423307718c3c6a4ae9b783ddd DIST nginx-1.20.1.tar.gz 1061461 BLAKE2B ed359db6486fd2152e0246663b8d8f4fc6980594945212545d301ce6ce16088c760d11b26fa1f6e9c392b9464103c570ddccc4343f5ab3f84ede011bb7a6458d SHA512 3d9fd4bf2740eaf20fcc3c77260a3556aaf9dff2879afc2dbb5fff364dea27313ffbc51d335e9fc9c0186a2a44dac055ef60fde0d411b8cf842fdf661478c961 +DIST nginx-1.20.2.tar.gz 1062124 BLAKE2B dc2fb9e7316ccac433c1f06c59d2738358c16194fe0ece80f54d145e2c4e3c3a8d6ebc4badb97580a000d721197a865bcc8c94a4d671af94be4bc3181974c586 SHA512 8b65e881ea4ac6162cbf32e5e95cf47a6d5418819f8763ca4a781cffa38187dd7886d4bc195d000a7046111a27121ff25800f8645405174995247e6738b4279a DIST nginx-1.21.0.tar.gz 1063682 BLAKE2B 3c29a8832e879677ff6df198aa420bbe546322a9d8b000827fdfbeb7e3519374cafd5a75910880f5ae07e78f0096952498c8515be788cf62916e3470d93c66d1 SHA512 1f0c790e5ba104278ef5fc357e60ba2fddd2d8abda1363e26b418324b050f0e9f4901ce23949adede699e9f1340e8480ad8a6c811b7420a74c8f5c101be8a7ad DIST nginx-1.21.1.tar.gz 1064925 BLAKE2B ff5dfb4a07d0dd3c8dd10e2545659cc25e15db71109c39ddb315f2949b0ec033ffa6df226f9f882e605bbac0b19a57f85eade41060c3317c9f07231ef496dcea SHA512 4fee94e9981abf4506cc3a24053828e81c763e98a3704b1cc54944cf09b49269a04495aca154b2dc6e065551d60f3f9f219659e93056b67952ecf8d07f9fcd98 DIST nginx-1.21.2.tar.gz 1066678 BLAKE2B 7af3a6f4cfc84c98058cb5ef3e0991b4f3cc2d8d9ca3b84111c30eac158253ac7f444e5b6ac9fd3a296f03a6c906e8a411b02c54e8df199f67a9ee0acce683d4 SHA512 5fa9c8f3a1bd9366b30de2bdbbd5baef47381e6d8672341ed601116baeb077ea1b596716ca06ec03d8a2773a437b78acd408084e49ba239f74de915f1b7fb8a5 @@ -42,6 +43,7 @@ DIST njs-0.6.0.tar.gz 528419 BLAKE2B 7b3c9dd4be8182298cc283e8b19eb4efeef66416d26 DIST njs-0.6.1.tar.gz 529124 BLAKE2B a24b6542dcef6599d18b86d38dbaeb554beeddb5c100f5bfb97c87c81bd66842afc6f77f23ef2c542ba32da96d5c2f999d3c869fa8d76d919a4f964020d19e30 SHA512 996cdc11d65af5e3d5b3a8f28087868c40409a062e6e1ed3eac8e516cb60b13f88a945c86bea5dde1bc089fe5f96f3ba351d87dbfd513f7140ea4ce98119959f DIST njs-0.6.2.tar.gz 538303 BLAKE2B 6c505a6ec20222095d4d10efdf274d2ea2fa61f236ceae71311f2c47dacc4b21f6af2a7b6f8bde21db6453455aff2994341c420fa14722120a98ac9d8bd6e934 SHA512 0c359501665ca303fcfb29353d4ad6ed398679b10906a6bbe6f6f6f69418f08adce9849a50206fdbd4e8fa89a5b73ea4fa43f1f02a28b7bd02e3f990d11263d0 EBUILD nginx-1.20.1-r2.ebuild 40243 BLAKE2B cbf3725815a2f941c0e276a415363d80ea873570f335c3a7013e11e4d4aaf40041ae3bc51360373f84f4a7e29a20df1bfa8c1fe226fe49e64a92c7b15f8d35ad SHA512 1d2b89c0242db11cdf3d3c402f47f0b4b7ed77e250a3fd10a9c2f021962b2b00d27dc5131d83f44d37481af5bbe1f0f54745f6ad52eb8fc33ac65c771643cb48 +EBUILD nginx-1.20.2.ebuild 40247 BLAKE2B bb7d8cc8fea4c79528ac8a4630699ea420a923eb43a8e0d21ede77f74d7df746bbc7d3835c222d2091c883fa6c12903855288a254c0d30c0572b18159c71d2bb SHA512 e3a7e38d226bbee5fea44c76da55d26ee791c4fbc52da24dfdc942c51f271d2b590127d7fe90b5db81b2bebf508e65c64b61b1c14aaadbda5bdfa86e3e070a08 EBUILD nginx-1.21.0-r2.ebuild 40247 BLAKE2B 030d4299eb71c2c15c128d6999de8e37a82b231c2944cacd2d43b86c7b192f2abe43bd87aec89d28b343e9f915947850efc2a05eae9d77083c84de9915c8107f SHA512 39e598591c3ecf5d0b28558375a04c53188b6dfaf44b301ea55a5fe5354bc0e2bf800f0d3167414713369c57627beaa9d7a92242e59eacb30ca3c3d36b586377 EBUILD nginx-1.21.1.ebuild 40254 BLAKE2B 39d149c942a6e7b4b80f9a9f4e34901218f7c58b040deecd7e1a63624125ac9579bb8df2afed47654bf4884fa8494e61953c7842aefc79f9f8685257cffc65d3 SHA512 4f241d292ef1a255c1938fc3c241800247d0fd2250debf40a33c476a0ed3b36945d245827b24cf31e8df60e6c39dec9dbf7d29c9b612d588fa43502c49e1fca8 EBUILD nginx-1.21.2.ebuild 40254 BLAKE2B 1743ba466f530a0010ac6dc0a3f084d82f2710d98ba696f1973cf0eab9a48d4a67c44f4c96f0238077eb3677ca02c7fd107218335a5e770ccb92177e3cc5eee9 SHA512 1d6ab4babb710bcf6833a515661225c49cd4df520b4056950717e642e007e2655f57e8b52b23969ae03580782b404b704588e45546c9ad1d8ac856cff7d0dad1 diff --git a/www-servers/nginx/nginx-1.20.2.ebuild b/www-servers/nginx/nginx-1.20.2.ebuild new file mode 100644 index 000000000000..3f56502d4648 --- /dev/null +++ b/www-servers/nginx/nginx-1.20.2.ebuild @@ -0,0 +1,1087 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +# Maintainer notes: +# - http_rewrite-independent pcre-support makes sense for matching locations without an actual rewrite +# - any http-module activates the main http-functionality and overrides USE=-http +# - keep the following requirements in mind before adding external modules: +# * alive upstream +# * sane packaging +# * builds cleanly +# * does not need a patch for nginx core +# - TODO: test the google-perftools module (included in vanilla tarball) + +# prevent perl-module from adding automagic perl DEPENDs +GENTOO_DEPEND_ON_PERL="no" + +# devel_kit (https://github.com/simpl/ngx_devel_kit, BSD license) +DEVEL_KIT_MODULE_PV="0.3.1" +DEVEL_KIT_MODULE_P="ngx_devel_kit-${DEVEL_KIT_MODULE_PV}" +DEVEL_KIT_MODULE_URI="https://github.com/simpl/ngx_devel_kit/archive/v${DEVEL_KIT_MODULE_PV}.tar.gz" +DEVEL_KIT_MODULE_WD="${WORKDIR}/ngx_devel_kit-${DEVEL_KIT_MODULE_PV}" + +# ngx_brotli (https://github.com/google/ngx_brotli, BSD-2) +HTTP_BROTLI_MODULE_PV="1.0.0rc" +HTTP_BROTLI_MODULE_P="ngx_brotli-${HTTP_BROTLI_MODULE_PV}" +HTTP_BROTLI_MODULE_URI="https://github.com/google/ngx_brotli/archive/v${HTTP_BROTLI_MODULE_PV}.tar.gz" +HTTP_BROTLI_MODULE_WD="${WORKDIR}/ngx_brotli-${HTTP_BROTLI_MODULE_PV}" + +# http_uploadprogress (https://github.com/masterzen/nginx-upload-progress-module, BSD-2 license) +HTTP_UPLOAD_PROGRESS_MODULE_PV="0.9.2" +HTTP_UPLOAD_PROGRESS_MODULE_P="ngx_http_upload_progress-${HTTP_UPLOAD_PROGRESS_MODULE_PV}-r1" +HTTP_UPLOAD_PROGRESS_MODULE_URI="https://github.com/masterzen/nginx-upload-progress-module/archive/v${HTTP_UPLOAD_PROGRESS_MODULE_PV}.tar.gz" +HTTP_UPLOAD_PROGRESS_MODULE_WD="${WORKDIR}/nginx-upload-progress-module-${HTTP_UPLOAD_PROGRESS_MODULE_PV}" + +# http_headers_more (https://github.com/agentzh/headers-more-nginx-module, BSD license) +HTTP_HEADERS_MORE_MODULE_PV="0.33" +HTTP_HEADERS_MORE_MODULE_P="ngx_http_headers_more-${HTTP_HEADERS_MORE_MODULE_PV}" +HTTP_HEADERS_MORE_MODULE_URI="https://github.com/agentzh/headers-more-nginx-module/archive/v${HTTP_HEADERS_MORE_MODULE_PV}.tar.gz" +HTTP_HEADERS_MORE_MODULE_WD="${WORKDIR}/headers-more-nginx-module-${HTTP_HEADERS_MORE_MODULE_PV}" + +# http_cache_purge (http://labs.frickle.com/nginx_ngx_cache_purge/, https://github.com/FRiCKLE/ngx_cache_purge, BSD-2 license) +HTTP_CACHE_PURGE_MODULE_PV="2.3" +HTTP_CACHE_PURGE_MODULE_P="ngx_http_cache_purge-${HTTP_CACHE_PURGE_MODULE_PV}" +HTTP_CACHE_PURGE_MODULE_URI="http://labs.frickle.com/files/ngx_cache_purge-${HTTP_CACHE_PURGE_MODULE_PV}.tar.gz" +HTTP_CACHE_PURGE_MODULE_WD="${WORKDIR}/ngx_cache_purge-${HTTP_CACHE_PURGE_MODULE_PV}" + +# http_slowfs_cache (http://labs.frickle.com/nginx_ngx_slowfs_cache/, BSD-2 license) +HTTP_SLOWFS_CACHE_MODULE_PV="1.10" +HTTP_SLOWFS_CACHE_MODULE_P="ngx_http_slowfs_cache-${HTTP_SLOWFS_CACHE_MODULE_PV}" +HTTP_SLOWFS_CACHE_MODULE_URI="http://labs.frickle.com/files/ngx_slowfs_cache-${HTTP_SLOWFS_CACHE_MODULE_PV}.tar.gz" +HTTP_SLOWFS_CACHE_MODULE_WD="${WORKDIR}/ngx_slowfs_cache-${HTTP_SLOWFS_CACHE_MODULE_PV}" + +# http_fancyindex (https://github.com/aperezdc/ngx-fancyindex, BSD license) +HTTP_FANCYINDEX_MODULE_PV="0.4.4" +HTTP_FANCYINDEX_MODULE_P="ngx_http_fancyindex-${HTTP_FANCYINDEX_MODULE_PV}" +HTTP_FANCYINDEX_MODULE_URI="https://github.com/aperezdc/ngx-fancyindex/archive/v${HTTP_FANCYINDEX_MODULE_PV}.tar.gz" +HTTP_FANCYINDEX_MODULE_WD="${WORKDIR}/ngx-fancyindex-${HTTP_FANCYINDEX_MODULE_PV}" + +# http_lua (https://github.com/openresty/lua-nginx-module, BSD license) +HTTP_LUA_MODULE_PV="0.10.15" +HTTP_LUA_MODULE_P="ngx_http_lua-${HTTP_LUA_MODULE_PV}" +HTTP_LUA_MODULE_URI="https://github.com/openresty/lua-nginx-module/archive/v${HTTP_LUA_MODULE_PV}.tar.gz" +HTTP_LUA_MODULE_WD="${WORKDIR}/lua-nginx-module-${HTTP_LUA_MODULE_PV}" +LUA_COMPAT=( luajit ) + +# http_auth_pam (https://github.com/stogh/ngx_http_auth_pam_module/, http://web.iti.upv.es/~sto/nginx/, BSD-2 license) +HTTP_AUTH_PAM_MODULE_PV="1.5.2" +HTTP_AUTH_PAM_MODULE_P="ngx_http_auth_pam-${HTTP_AUTH_PAM_MODULE_PV}" +HTTP_AUTH_PAM_MODULE_URI="https://github.com/stogh/ngx_http_auth_pam_module/archive/v${HTTP_AUTH_PAM_MODULE_PV}.tar.gz" +HTTP_AUTH_PAM_MODULE_WD="${WORKDIR}/ngx_http_auth_pam_module-${HTTP_AUTH_PAM_MODULE_PV}" + +# http_upstream_check (https://github.com/yaoweibin/nginx_upstream_check_module, BSD license) +HTTP_UPSTREAM_CHECK_MODULE_PV="9aecf15ec379fe98f62355c57b60c0bc83296f04" +HTTP_UPSTREAM_CHECK_MODULE_P="ngx_http_upstream_check-${HTTP_UPSTREAM_CHECK_MODULE_PV}" +HTTP_UPSTREAM_CHECK_MODULE_URI="https://github.com/yaoweibin/nginx_upstream_check_module/archive/${HTTP_UPSTREAM_CHECK_MODULE_PV}.tar.gz" +HTTP_UPSTREAM_CHECK_MODULE_WD="${WORKDIR}/nginx_upstream_check_module-${HTTP_UPSTREAM_CHECK_MODULE_PV}" + +# http_metrics (https://github.com/zenops/ngx_metrics, BSD license) +HTTP_METRICS_MODULE_PV="0.1.1" +HTTP_METRICS_MODULE_P="ngx_metrics-${HTTP_METRICS_MODULE_PV}" +HTTP_METRICS_MODULE_URI="https://github.com/madvertise/ngx_metrics/archive/v${HTTP_METRICS_MODULE_PV}.tar.gz" +HTTP_METRICS_MODULE_WD="${WORKDIR}/ngx_metrics-${HTTP_METRICS_MODULE_PV}" + +# http_vhost_traffic_status (https://github.com/vozlt/nginx-module-vts, BSD license) +HTTP_VHOST_TRAFFIC_STATUS_MODULE_PV="46d85558e344dfe2b078ce757fd36c69a1ec2dd3" +HTTP_VHOST_TRAFFIC_STATUS_MODULE_P="ngx_http_vhost_traffic_status-${HTTP_VHOST_TRAFFIC_STATUS_MODULE_PV}" +HTTP_VHOST_TRAFFIC_STATUS_MODULE_URI="https://github.com/vozlt/nginx-module-vts/archive/${HTTP_VHOST_TRAFFIC_STATUS_MODULE_PV}.tar.gz" +HTTP_VHOST_TRAFFIC_STATUS_MODULE_WD="${WORKDIR}/nginx-module-vts-${HTTP_VHOST_TRAFFIC_STATUS_MODULE_PV}" + +# naxsi-core (https://github.com/nbs-system/naxsi, GPLv2+) +HTTP_NAXSI_MODULE_PV="0.56" +HTTP_NAXSI_MODULE_P="ngx_http_naxsi-${HTTP_NAXSI_MODULE_PV}" +HTTP_NAXSI_MODULE_URI="https://github.com/nbs-system/naxsi/archive/${HTTP_NAXSI_MODULE_PV}.tar.gz" +HTTP_NAXSI_MODULE_WD="${WORKDIR}/naxsi-${HTTP_NAXSI_MODULE_PV}/naxsi_src" + +# nginx-rtmp-module (https://github.com/arut/nginx-rtmp-module, BSD license) +RTMP_MODULE_PV="1.2.1" +RTMP_MODULE_P="ngx_rtmp-${RTMP_MODULE_PV}" +RTMP_MODULE_URI="https://github.com/arut/nginx-rtmp-module/archive/v${RTMP_MODULE_PV}.tar.gz" +RTMP_MODULE_WD="${WORKDIR}/nginx-rtmp-module-${RTMP_MODULE_PV}" + +# nginx-dav-ext-module (https://github.com/arut/nginx-dav-ext-module, BSD license) +HTTP_DAV_EXT_MODULE_PV="3.0.0" +HTTP_DAV_EXT_MODULE_P="ngx_http_dav_ext-${HTTP_DAV_EXT_MODULE_PV}" +HTTP_DAV_EXT_MODULE_URI="https://github.com/arut/nginx-dav-ext-module/archive/v${HTTP_DAV_EXT_MODULE_PV}.tar.gz" +HTTP_DAV_EXT_MODULE_WD="${WORKDIR}/nginx-dav-ext-module-${HTTP_DAV_EXT_MODULE_PV}" + +# echo-nginx-module (https://github.com/openresty/echo-nginx-module, BSD license) +HTTP_ECHO_MODULE_PV="0.62" +HTTP_ECHO_MODULE_P="ngx_http_echo-${HTTP_ECHO_MODULE_PV}" +HTTP_ECHO_MODULE_URI="https://github.com/openresty/echo-nginx-module/archive/v${HTTP_ECHO_MODULE_PV}.tar.gz" +HTTP_ECHO_MODULE_WD="${WORKDIR}/echo-nginx-module-${HTTP_ECHO_MODULE_PV}" + +# mod_security for nginx (https://modsecurity.org/, Apache-2.0) +# keep the MODULE_P here consistent with upstream to avoid tarball duplication +HTTP_SECURITY_MODULE_PV="2.9.3" +HTTP_SECURITY_MODULE_P="modsecurity-${HTTP_SECURITY_MODULE_PV}" +HTTP_SECURITY_MODULE_URI="https://www.modsecurity.org/tarball/${HTTP_SECURITY_MODULE_PV}/${HTTP_SECURITY_MODULE_P}.tar.gz" +HTTP_SECURITY_MODULE_WD="${WORKDIR}/${HTTP_SECURITY_MODULE_P}" + +# push-stream-module (http://www.nginxpushstream.com, https://github.com/wandenberg/nginx-push-stream-module, GPL-3) +HTTP_PUSH_STREAM_MODULE_PV="0.5.4" +HTTP_PUSH_STREAM_MODULE_P="ngx_http_push_stream-${HTTP_PUSH_STREAM_MODULE_PV}" +HTTP_PUSH_STREAM_MODULE_URI="https://github.com/wandenberg/nginx-push-stream-module/archive/${HTTP_PUSH_STREAM_MODULE_PV}.tar.gz" +HTTP_PUSH_STREAM_MODULE_WD="${WORKDIR}/nginx-push-stream-module-${HTTP_PUSH_STREAM_MODULE_PV}" + +# sticky-module (https://bitbucket.org/nginx-goodies/nginx-sticky-module-ng, BSD-2) +HTTP_STICKY_MODULE_PV="1.2.6-10-g08a395c66e42" +HTTP_STICKY_MODULE_P="nginx_http_sticky_module_ng-${HTTP_STICKY_MODULE_PV}" +HTTP_STICKY_MODULE_URI="https://bitbucket.org/nginx-goodies/nginx-sticky-module-ng/get/${HTTP_STICKY_MODULE_PV}.tar.bz2" +HTTP_STICKY_MODULE_WD="${WORKDIR}/nginx-goodies-nginx-sticky-module-ng-08a395c66e42" + +# mogilefs-module (https://github.com/vkholodkov/nginx-mogilefs-module, BSD-2) +HTTP_MOGILEFS_MODULE_PV="1.0.4" +HTTP_MOGILEFS_MODULE_P="ngx_mogilefs_module-${HTTP_MOGILEFS_MODULE_PV}" +HTTP_MOGILEFS_MODULE_URI="https://github.com/vkholodkov/nginx-mogilefs-module/archive/${HTTP_MOGILEFS_MODULE_PV}.tar.gz" +HTTP_MOGILEFS_MODULE_WD="${WORKDIR}/nginx_mogilefs_module-${HTTP_MOGILEFS_MODULE_PV}" + +# memc-module (https://github.com/openresty/memc-nginx-module, BSD-2) +HTTP_MEMC_MODULE_PV="0.19" +HTTP_MEMC_MODULE_P="ngx_memc_module-${HTTP_MEMC_MODULE_PV}" +HTTP_MEMC_MODULE_URI="https://github.com/openresty/memc-nginx-module/archive/v${HTTP_MEMC_MODULE_PV}.tar.gz" +HTTP_MEMC_MODULE_WD="${WORKDIR}/memc-nginx-module-${HTTP_MEMC_MODULE_PV}" + +# nginx-ldap-auth-module (https://github.com/kvspb/nginx-auth-ldap, BSD-2) +HTTP_LDAP_MODULE_PV="42d195d7a7575ebab1c369ad3fc5d78dc2c2669c" +HTTP_LDAP_MODULE_P="nginx-auth-ldap-${HTTP_LDAP_MODULE_PV}" +HTTP_LDAP_MODULE_URI="https://github.com/kvspb/nginx-auth-ldap/archive/${HTTP_LDAP_MODULE_PV}.tar.gz" +HTTP_LDAP_MODULE_WD="${WORKDIR}/nginx-auth-ldap-${HTTP_LDAP_MODULE_PV}" + +# geoip2 (https://github.com/leev/ngx_http_geoip2_module, BSD-2) +GEOIP2_MODULE_PV="3.3" +GEOIP2_MODULE_P="ngx_http_geoip2_module-${GEOIP2_MODULE_PV}" +GEOIP2_MODULE_URI="https://github.com/leev/ngx_http_geoip2_module/archive/${GEOIP2_MODULE_PV}.tar.gz" +GEOIP2_MODULE_WD="${WORKDIR}/ngx_http_geoip2_module-${GEOIP2_MODULE_PV}" + +# njs-module (https://github.com/nginx/njs, as-is) +NJS_MODULE_PV="0.6.2" +NJS_MODULE_P="njs-${NJS_MODULE_PV}" +NJS_MODULE_URI="https://github.com/nginx/njs/archive/${NJS_MODULE_PV}.tar.gz" +NJS_MODULE_WD="${WORKDIR}/njs-${NJS_MODULE_PV}" + +# We handle deps below ourselves +SSL_DEPS_SKIP=1 +AUTOTOOLS_AUTO_DEPEND="no" + +inherit autotools lua-single ssl-cert toolchain-funcs perl-module flag-o-matic user systemd multilib pax-utils + +DESCRIPTION="Robust, small and high performance http and reverse proxy server" +HOMEPAGE="https://nginx.org" +SRC_URI="https://nginx.org/download/${P}.tar.gz + ${DEVEL_KIT_MODULE_URI} -> ${DEVEL_KIT_MODULE_P}.tar.gz + nginx_modules_http_auth_ldap? ( ${HTTP_LDAP_MODULE_URI} -> ${HTTP_LDAP_MODULE_P}.tar.gz ) + nginx_modules_http_auth_pam? ( ${HTTP_AUTH_PAM_MODULE_URI} -> ${HTTP_AUTH_PAM_MODULE_P}.tar.gz ) + nginx_modules_http_brotli? ( ${HTTP_BROTLI_MODULE_URI} -> ${HTTP_BROTLI_MODULE_P}.tar.gz ) + nginx_modules_http_cache_purge? ( ${HTTP_CACHE_PURGE_MODULE_URI} -> ${HTTP_CACHE_PURGE_MODULE_P}.tar.gz ) + nginx_modules_http_dav_ext? ( ${HTTP_DAV_EXT_MODULE_URI} -> ${HTTP_DAV_EXT_MODULE_P}.tar.gz ) + nginx_modules_http_echo? ( ${HTTP_ECHO_MODULE_URI} -> ${HTTP_ECHO_MODULE_P}.tar.gz ) + nginx_modules_http_fancyindex? ( ${HTTP_FANCYINDEX_MODULE_URI} -> ${HTTP_FANCYINDEX_MODULE_P}.tar.gz ) + nginx_modules_http_geoip2? ( ${GEOIP2_MODULE_URI} -> ${GEOIP2_MODULE_P}.tar.gz ) + nginx_modules_http_headers_more? ( ${HTTP_HEADERS_MORE_MODULE_URI} -> ${HTTP_HEADERS_MORE_MODULE_P}.tar.gz ) + nginx_modules_http_javascript? ( ${NJS_MODULE_URI} -> ${NJS_MODULE_P}.tar.gz ) + nginx_modules_http_lua? ( ${HTTP_LUA_MODULE_URI} -> ${HTTP_LUA_MODULE_P}.tar.gz ) + nginx_modules_http_memc? ( ${HTTP_MEMC_MODULE_URI} -> ${HTTP_MEMC_MODULE_P}.tar.gz ) + nginx_modules_http_metrics? ( ${HTTP_METRICS_MODULE_URI} -> ${HTTP_METRICS_MODULE_P}.tar.gz ) + nginx_modules_http_mogilefs? ( ${HTTP_MOGILEFS_MODULE_URI} -> ${HTTP_MOGILEFS_MODULE_P}.tar.gz ) + nginx_modules_http_naxsi? ( ${HTTP_NAXSI_MODULE_URI} -> ${HTTP_NAXSI_MODULE_P}.tar.gz ) + nginx_modules_http_push_stream? ( ${HTTP_PUSH_STREAM_MODULE_URI} -> ${HTTP_PUSH_STREAM_MODULE_P}.tar.gz ) + nginx_modules_http_security? ( ${HTTP_SECURITY_MODULE_URI} -> ${HTTP_SECURITY_MODULE_P}.tar.gz ) + nginx_modules_http_slowfs_cache? ( ${HTTP_SLOWFS_CACHE_MODULE_URI} -> ${HTTP_SLOWFS_CACHE_MODULE_P}.tar.gz ) + nginx_modules_http_sticky? ( ${HTTP_STICKY_MODULE_URI} -> ${HTTP_STICKY_MODULE_P}.tar.bz2 ) + nginx_modules_http_upload_progress? ( ${HTTP_UPLOAD_PROGRESS_MODULE_URI} -> ${HTTP_UPLOAD_PROGRESS_MODULE_P}.tar.gz ) + nginx_modules_http_upstream_check? ( ${HTTP_UPSTREAM_CHECK_MODULE_URI} -> ${HTTP_UPSTREAM_CHECK_MODULE_P}.tar.gz ) + nginx_modules_http_vhost_traffic_status? ( ${HTTP_VHOST_TRAFFIC_STATUS_MODULE_URI} -> ${HTTP_VHOST_TRAFFIC_STATUS_MODULE_P}.tar.gz ) + nginx_modules_stream_geoip2? ( ${GEOIP2_MODULE_URI} -> ${GEOIP2_MODULE_P}.tar.gz ) + nginx_modules_stream_javascript? ( ${NJS_MODULE_URI} -> ${NJS_MODULE_P}.tar.gz ) + rtmp? ( ${RTMP_MODULE_URI} -> ${RTMP_MODULE_P}.tar.gz )" + +LICENSE="BSD-2 BSD SSLeay MIT GPL-2 GPL-2+ + nginx_modules_http_security? ( Apache-2.0 ) + nginx_modules_http_push_stream? ( GPL-3 )" + +SLOT="0" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" + +# Package doesn't provide a real test suite +RESTRICT="test" + +NGINX_MODULES_STD="access auth_basic autoindex browser charset empty_gif + fastcgi geo grpc gzip limit_req limit_conn map memcached mirror + proxy referer rewrite scgi ssi split_clients upstream_hash + upstream_ip_hash upstream_keepalive upstream_least_conn + upstream_zone userid uwsgi" +NGINX_MODULES_OPT="addition auth_request dav degradation flv geoip gunzip + gzip_static image_filter mp4 perl random_index realip secure_link + slice stub_status sub xslt" +NGINX_MODULES_STREAM_STD="access geo limit_conn map return split_clients + upstream_hash upstream_least_conn upstream_zone" +NGINX_MODULES_STREAM_OPT="geoip realip ssl_preread" +NGINX_MODULES_MAIL="imap pop3 smtp" +NGINX_MODULES_3RD=" + http_auth_ldap + http_auth_pam + http_brotli + http_cache_purge + http_dav_ext + http_echo + http_fancyindex + http_geoip2 + http_headers_more + http_javascript + http_lua + http_memc + http_metrics + http_mogilefs + http_naxsi + http_push_stream + http_security + http_slowfs_cache + http_sticky + http_upload_progress + http_upstream_check + http_vhost_traffic_status + stream_geoip2 + stream_javascript +" + +IUSE="aio debug +http +http2 +http-cache +ipv6 libatomic +pcre + pcre-jit rtmp selinux ssl threads userland_GNU vim-syntax" + +for mod in $NGINX_MODULES_STD; do + IUSE="${IUSE} +nginx_modules_http_${mod}" +done + +for mod in $NGINX_MODULES_OPT; do + IUSE="${IUSE} nginx_modules_http_${mod}" +done + +for mod in $NGINX_MODULES_STREAM_STD; do + IUSE="${IUSE} nginx_modules_stream_${mod}" +done + +for mod in $NGINX_MODULES_STREAM_OPT; do + IUSE="${IUSE} nginx_modules_stream_${mod}" +done + +for mod in $NGINX_MODULES_MAIL; do + IUSE="${IUSE} nginx_modules_mail_${mod}" +done + +for mod in $NGINX_MODULES_3RD; do + IUSE="${IUSE} nginx_modules_${mod}" +done + +# Add so we can warn users updating about config changes +# @TODO: jbergstroem: remove on next release series +IUSE="${IUSE} nginx_modules_http_spdy" + +CDEPEND=" + virtual/libcrypt:= + pcre? ( dev-libs/libpcre:= ) + pcre-jit? ( dev-libs/libpcre:=[jit] ) + ssl? ( + dev-libs/openssl:0= + ) + http2? ( + >=dev-libs/openssl-1.0.1c:0= + ) + http-cache? ( + userland_GNU? ( + dev-libs/openssl:0= + ) + ) + nginx_modules_http_brotli? ( app-arch/brotli:= ) + nginx_modules_http_geoip? ( dev-libs/geoip ) + nginx_modules_http_geoip2? ( dev-libs/libmaxminddb:= ) + nginx_modules_http_gunzip? ( sys-libs/zlib ) + nginx_modules_http_gzip? ( sys-libs/zlib ) + nginx_modules_http_gzip_static? ( sys-libs/zlib ) + nginx_modules_http_image_filter? ( media-libs/gd:=[jpeg,png] ) + nginx_modules_http_perl? ( >=dev-lang/perl-5.8:= ) + nginx_modules_http_rewrite? ( dev-libs/libpcre:= ) + nginx_modules_http_secure_link? ( + userland_GNU? ( + dev-libs/openssl:0= + ) + ) + nginx_modules_http_xslt? ( dev-libs/libxml2:= dev-libs/libxslt ) + nginx_modules_http_lua? ( ${LUA_DEPS} ) + nginx_modules_http_auth_pam? ( sys-libs/pam ) + nginx_modules_http_metrics? ( dev-libs/yajl:= ) + nginx_modules_http_dav_ext? ( dev-libs/libxml2 ) + nginx_modules_http_security? ( + dev-libs/apr:= + dev-libs/apr-util:= + dev-libs/libxml2:= + net-misc/curl + www-servers/apache + ) + nginx_modules_http_auth_ldap? ( net-nds/openldap[ssl?] ) + nginx_modules_stream_geoip? ( dev-libs/geoip ) + nginx_modules_stream_geoip2? ( dev-libs/libmaxminddb:= )" +RDEPEND="${CDEPEND} + selinux? ( sec-policy/selinux-nginx ) + !www-servers/nginx:mainline" +DEPEND="${CDEPEND} + arm? ( dev-libs/libatomic_ops ) + libatomic? ( dev-libs/libatomic_ops )" +BDEPEND="nginx_modules_http_brotli? ( virtual/pkgconfig ) + nginx_modules_http_security? ( ${AUTOTOOLS_DEPEND} )" +PDEPEND="vim-syntax? ( app-vim/nginx-syntax )" + +REQUIRED_USE="pcre-jit? ( pcre ) + nginx_modules_http_fancyindex? ( nginx_modules_http_addition ) + nginx_modules_http_grpc? ( http2 ) + nginx_modules_http_lua? ( + ${LUA_REQUIRED_USE} + nginx_modules_http_rewrite + ) + nginx_modules_http_naxsi? ( pcre ) + nginx_modules_http_dav_ext? ( nginx_modules_http_dav nginx_modules_http_xslt ) + nginx_modules_http_metrics? ( nginx_modules_http_stub_status ) + nginx_modules_http_security? ( pcre ) + nginx_modules_http_push_stream? ( ssl )" + +pkg_setup() { + NGINX_HOME="/var/lib/nginx" + NGINX_HOME_TMP="${NGINX_HOME}/tmp" + + ebegin "Creating nginx user and group" + enewgroup ${PN} + enewuser ${PN} -1 -1 "${NGINX_HOME}" ${PN} + eend $? + + if use libatomic; then + ewarn "GCC 4.1+ features built-in atomic operations." + ewarn "Using libatomic_ops is only needed if using" + ewarn "a different compiler or a GCC prior to 4.1" + fi + + if [[ -n $NGINX_ADD_MODULES ]]; then + ewarn "You are building custom modules via \$NGINX_ADD_MODULES!" + ewarn "This nginx installation is not supported!" + ewarn "Make sure you can reproduce the bug without those modules" + ewarn "_before_ reporting bugs." + fi + + if use !http; then + ewarn "To actually disable all http-functionality you also have to disable" + ewarn "all nginx http modules." + fi + + if use nginx_modules_http_mogilefs && use threads; then + eerror "mogilefs won't compile with threads support." + eerror "Please disable either flag and try again." + die "Can't compile mogilefs with threads support" + fi + + use nginx_modules_http_lua && lua-single_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}/${PN}-1.4.1-fix-perl-install-path.patch" + eapply "${FILESDIR}/${PN}-httpoxy-mitigation-r1.patch" + + if use nginx_modules_http_brotli; then + cd "${HTTP_BROTLI_MODULE_WD}" || die + eapply "${FILESDIR}"/http_brotli-detect-brotli-r3.patch + cd "${S}" || die + fi + + if use nginx_modules_http_upstream_check; then + eapply -p0 "${FILESDIR}"/http_upstream_check-nginx-1.11.5+.patch + fi + + if use nginx_modules_http_cache_purge; then + cd "${HTTP_CACHE_PURGE_MODULE_WD}" || die + eapply "${FILESDIR}"/http_cache_purge-1.11.6+.patch + cd "${S}" || die + fi + + if use nginx_modules_http_security; then + cd "${HTTP_SECURITY_MODULE_WD}" || die + + eautoreconf + + if use nginx_modules_http_lua; then + sed -i \ + -e "s|^\(LUA_PKGNAMES\)=.*|\1=\"${ELUA}\"|" \ + configure || die + fi + + cd "${S}" || die + fi + + if use nginx_modules_http_upload_progress; then + cd "${HTTP_UPLOAD_PROGRESS_MODULE_WD}" || die + eapply "${FILESDIR}"/http_uploadprogress-issue_50-r1.patch + cd "${S}" || die + fi + + find auto/ -type f -print0 | xargs -0 sed -i 's:\&\& make:\&\& \\$(MAKE):' || die + # We have config protection, don't rename etc files + sed -i 's:.default::' auto/install || die + # remove useless files + sed -i -e '/koi-/d' -e '/win-/d' auto/install || die + + # don't install to /etc/nginx/ if not in use + local module + for module in fastcgi scgi uwsgi ; do + if ! use nginx_modules_http_${module}; then + sed -i -e "/${module}/d" auto/install || die + fi + done + + eapply_user +} + +src_configure() { + # mod_security needs to generate nginx/modsecurity/config before including it + if use nginx_modules_http_security; then + cd "${HTTP_SECURITY_MODULE_WD}" || die + + ./configure \ + --enable-standalone-module \ + --disable-mlogc \ + --with-ssdeep=no \ + $(use_enable pcre-jit) \ + $(use_with nginx_modules_http_lua lua) || die "configure failed for mod_security" + + cd "${S}" || die + fi + + local myconf=() http_enabled= mail_enabled= stream_enabled= + + use aio && myconf+=( --with-file-aio ) + use debug && myconf+=( --with-debug ) + use http2 && myconf+=( --with-http_v2_module ) + use libatomic && myconf+=( --with-libatomic ) + use pcre && myconf+=( --with-pcre ) + use pcre-jit && myconf+=( --with-pcre-jit ) + use threads && myconf+=( --with-threads ) + + # HTTP modules + for mod in $NGINX_MODULES_STD; do + if use nginx_modules_http_${mod}; then + http_enabled=1 + else + myconf+=( --without-http_${mod}_module ) + fi + done + + for mod in $NGINX_MODULES_OPT; do + if use nginx_modules_http_${mod}; then + http_enabled=1 + myconf+=( --with-http_${mod}_module ) + fi + done + + if use nginx_modules_http_fastcgi; then + myconf+=( --with-http_realip_module ) + fi + + # third-party modules + if use nginx_modules_http_upload_progress; then + http_enabled=1 + myconf+=( --add-module=${HTTP_UPLOAD_PROGRESS_MODULE_WD} ) + fi + + if use nginx_modules_http_headers_more; then + http_enabled=1 + myconf+=( --add-module=${HTTP_HEADERS_MORE_MODULE_WD} ) + fi + + if use nginx_modules_http_cache_purge; then + http_enabled=1 + myconf+=( --add-module=${HTTP_CACHE_PURGE_MODULE_WD} ) + fi + + if use nginx_modules_http_slowfs_cache; then + http_enabled=1 + myconf+=( --add-module=${HTTP_SLOWFS_CACHE_MODULE_WD} ) + fi + + if use nginx_modules_http_fancyindex; then + http_enabled=1 + myconf+=( --add-module=${HTTP_FANCYINDEX_MODULE_WD} ) + fi + + if use nginx_modules_http_lua; then + http_enabled=1 + export LUAJIT_LIB=$(dirname $(lua_get_shared_lib)) + export LUAJIT_INC=$(lua_get_include_dir) + myconf+=( --add-module=${DEVEL_KIT_MODULE_WD} ) + myconf+=( --add-module=${HTTP_LUA_MODULE_WD} ) + fi + + if use nginx_modules_http_auth_pam; then + http_enabled=1 + myconf+=( --add-module=${HTTP_AUTH_PAM_MODULE_WD} ) + fi + + if use nginx_modules_http_upstream_check; then + http_enabled=1 + myconf+=( --add-module=${HTTP_UPSTREAM_CHECK_MODULE_WD} ) + fi + + if use nginx_modules_http_metrics; then + http_enabled=1 + myconf+=( --add-module=${HTTP_METRICS_MODULE_WD} ) + fi + + if use nginx_modules_http_naxsi ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_NAXSI_MODULE_WD} ) + fi + + if use rtmp ; then + http_enabled=1 + myconf+=( --add-module=${RTMP_MODULE_WD} ) + fi + + if use nginx_modules_http_dav_ext ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_DAV_EXT_MODULE_WD} ) + fi + + if use nginx_modules_http_echo ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_ECHO_MODULE_WD} ) + fi + + if use nginx_modules_http_security ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_SECURITY_MODULE_WD}/nginx/modsecurity ) + fi + + if use nginx_modules_http_push_stream ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_PUSH_STREAM_MODULE_WD} ) + fi + + if use nginx_modules_http_sticky ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_STICKY_MODULE_WD} ) + fi + + if use nginx_modules_http_mogilefs ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_MOGILEFS_MODULE_WD} ) + fi + + if use nginx_modules_http_memc ; then + http_enabled=1 + myconf+=( --add-module=${HTTP_MEMC_MODULE_WD} ) + fi + + if use nginx_modules_http_auth_ldap; then + http_enabled=1 + myconf+=( --add-module=${HTTP_LDAP_MODULE_WD} ) + fi + + if use nginx_modules_http_vhost_traffic_status; then + http_enabled=1 + myconf+=( --add-module=${HTTP_VHOST_TRAFFIC_STATUS_MODULE_WD} ) + fi + + if use nginx_modules_http_geoip2 || use nginx_modules_stream_geoip2; then + myconf+=( --add-module=${GEOIP2_MODULE_WD} ) + fi + + if use nginx_modules_http_javascript || use nginx_modules_stream_javascript; then + myconf+=( --add-module="${NJS_MODULE_WD}/nginx" ) + fi + + if use nginx_modules_http_brotli; then + http_enabled=1 + myconf+=( --add-module=${HTTP_BROTLI_MODULE_WD} ) + fi + + if use http || use http-cache || use http2 || use nginx_modules_http_javascript; then + http_enabled=1 + fi + + if [ $http_enabled ]; then + use http-cache || myconf+=( --without-http-cache ) + use ssl && myconf+=( --with-http_ssl_module ) + else + myconf+=( --without-http --without-http-cache ) + fi + + # Stream modules + for mod in $NGINX_MODULES_STREAM_STD; do + if use nginx_modules_stream_${mod}; then + stream_enabled=1 + else + myconf+=( --without-stream_${mod}_module ) + fi + done + + for mod in $NGINX_MODULES_STREAM_OPT; do + if use nginx_modules_stream_${mod}; then + stream_enabled=1 + myconf+=( --with-stream_${mod}_module ) + fi + done + + if use nginx_modules_stream_geoip2 || use nginx_modules_stream_javascript; then + stream_enabled=1 + fi + + if [ $stream_enabled ]; then + myconf+=( --with-stream ) + use ssl && myconf+=( --with-stream_ssl_module ) + fi + + # MAIL modules + for mod in $NGINX_MODULES_MAIL; do + if use nginx_modules_mail_${mod}; then + mail_enabled=1 + else + myconf+=( --without-mail_${mod}_module ) + fi + done + + if [ $mail_enabled ]; then + myconf+=( --with-mail ) + use ssl && myconf+=( --with-mail_ssl_module ) + fi + + # custom modules + for mod in $NGINX_ADD_MODULES; do + myconf+=( --add-module=${mod} ) + done + + # https://bugs.gentoo.org/286772 + export LANG=C LC_ALL=C + tc-export AR CC + + if ! use prefix; then + myconf+=( --user=${PN} ) + myconf+=( --group=${PN} ) + fi + + local WITHOUT_IPV6= + if ! use ipv6; then + WITHOUT_IPV6=" -DNGX_HAVE_INET6=0" + fi + + if [[ -n "${EXTRA_ECONF}" ]]; then + myconf+=( ${EXTRA_ECONF} ) + ewarn "EXTRA_ECONF applied. Now you are on your own, good luck!" + fi + + ./configure \ + --prefix="${EPREFIX}"/usr \ + --conf-path="${EPREFIX}"/etc/${PN}/${PN}.conf \ + --error-log-path="${EPREFIX}"/var/log/${PN}/error_log \ + --pid-path="${EPREFIX}"/run/${PN}.pid \ + --lock-path="${EPREFIX}"/run/lock/${PN}.lock \ + --with-cc-opt="-I${ESYSROOT}/usr/include${WITHOUT_IPV6}" \ + --with-ld-opt="-L${ESYSROOT}/usr/$(get_libdir)" \ + --http-log-path="${EPREFIX}"/var/log/${PN}/access_log \ + --http-client-body-temp-path="${EPREFIX}${NGINX_HOME_TMP}"/client \ + --http-proxy-temp-path="${EPREFIX}${NGINX_HOME_TMP}"/proxy \ + --http-fastcgi-temp-path="${EPREFIX}${NGINX_HOME_TMP}"/fastcgi \ + --http-scgi-temp-path="${EPREFIX}${NGINX_HOME_TMP}"/scgi \ + --http-uwsgi-temp-path="${EPREFIX}${NGINX_HOME_TMP}"/uwsgi \ + --with-compat \ + "${myconf[@]}" || die "configure failed" + + # A purely cosmetic change that makes nginx -V more readable. This can be + # good if people outside the gentoo community would troubleshoot and + # question the users setup. + sed -i -e "s|${WORKDIR}|external_module|g" objs/ngx_auto_config.h || die +} + +src_compile() { + use nginx_modules_http_security && emake -C "${HTTP_SECURITY_MODULE_WD}" + + # https://bugs.gentoo.org/286772 + export LANG=C LC_ALL=C + emake LINK="${CC} ${LDFLAGS}" OTHERLDFLAGS="${LDFLAGS}" +} + +src_install() { + emake DESTDIR="${D}" install + + cp "${FILESDIR}"/nginx.conf-r2 "${ED}"/etc/nginx/nginx.conf || die + + newinitd "${FILESDIR}"/nginx.initd-r4 nginx + newconfd "${FILESDIR}"/nginx.confd nginx + + systemd_newunit "${FILESDIR}"/nginx.service-r1 nginx.service + + doman man/nginx.8 + dodoc CHANGES* README + + # just keepdir. do not copy the default htdocs files (bug #449136) + keepdir /var/www/localhost + rm -rf "${ED}"/usr/html || die + + # set up a list of directories to keep + local keepdir_list="${NGINX_HOME_TMP}"/client + local module + for module in proxy fastcgi scgi uwsgi; do + use nginx_modules_http_${module} && keepdir_list+=" ${NGINX_HOME_TMP}/${module}" + done + + keepdir /var/log/nginx ${keepdir_list} + + # this solves a problem with SELinux where nginx doesn't see the directories + # as root and tries to create them as nginx + fperms 0750 "${NGINX_HOME_TMP}" + fowners ${PN}:0 "${NGINX_HOME_TMP}" + + fperms 0700 ${keepdir_list} + fowners ${PN}:${PN} ${keepdir_list} + + fperms 0710 /var/log/nginx + fowners 0:${PN} /var/log/nginx + + # logrotate + insinto /etc/logrotate.d + newins "${FILESDIR}"/nginx.logrotate-r1 nginx + + # Don't create /run + rm -rf "${ED}"/run || die + + if use lua_single_target_luajit; then + pax-mark m "${ED}/usr/sbin/nginx" + fi + + if use nginx_modules_http_perl; then + cd "${S}"/objs/src/http/modules/perl/ || die + emake DESTDIR="${D}" INSTALLDIRS=vendor + perl_delete_localpod + cd "${S}" || die + fi + + if use nginx_modules_http_cache_purge; then + docinto ${HTTP_CACHE_PURGE_MODULE_P} + dodoc "${HTTP_CACHE_PURGE_MODULE_WD}"/{CHANGES,README.md,TODO.md} + fi + + if use nginx_modules_http_slowfs_cache; then + docinto ${HTTP_SLOWFS_CACHE_MODULE_P} + dodoc "${HTTP_SLOWFS_CACHE_MODULE_WD}"/{CHANGES,README.md} + fi + + if use nginx_modules_http_fancyindex; then + docinto ${HTTP_FANCYINDEX_MODULE_P} + dodoc "${HTTP_FANCYINDEX_MODULE_WD}"/README.rst + fi + + if use nginx_modules_http_lua; then + docinto ${HTTP_LUA_MODULE_P} + dodoc "${HTTP_LUA_MODULE_WD}"/README.markdown + fi + + if use nginx_modules_http_auth_pam; then + docinto ${HTTP_AUTH_PAM_MODULE_P} + dodoc "${HTTP_AUTH_PAM_MODULE_WD}"/{README.md,ChangeLog} + fi + + if use nginx_modules_http_upstream_check; then + docinto ${HTTP_UPSTREAM_CHECK_MODULE_P} + dodoc "${HTTP_UPSTREAM_CHECK_MODULE_WD}"/{README,CHANGES} + fi + + if use nginx_modules_http_naxsi; then + insinto /etc/nginx + doins "${HTTP_NAXSI_MODULE_WD}"/../naxsi_config/naxsi_core.rules + fi + + if use rtmp; then + docinto ${RTMP_MODULE_P} + dodoc "${RTMP_MODULE_WD}"/{AUTHORS,README.md,stat.xsl} + fi + + if use nginx_modules_http_dav_ext; then + docinto ${HTTP_DAV_EXT_MODULE_P} + dodoc "${HTTP_DAV_EXT_MODULE_WD}"/README.rst + fi + + if use nginx_modules_http_echo; then + docinto ${HTTP_ECHO_MODULE_P} + dodoc "${HTTP_ECHO_MODULE_WD}"/README.markdown + fi + + if use nginx_modules_http_security; then + docinto ${HTTP_SECURITY_MODULE_P} + dodoc "${HTTP_SECURITY_MODULE_WD}"/{CHANGES,README.md,authors.txt} + fi + + if use nginx_modules_http_push_stream; then + docinto ${HTTP_PUSH_STREAM_MODULE_P} + dodoc "${HTTP_PUSH_STREAM_MODULE_WD}"/{AUTHORS,CHANGELOG.textile,README.textile} + fi + + if use nginx_modules_http_sticky; then + docinto ${HTTP_STICKY_MODULE_P} + dodoc "${HTTP_STICKY_MODULE_WD}"/{README.md,Changelog.txt,docs/sticky.pdf} + fi + + if use nginx_modules_http_memc; then + docinto ${HTTP_MEMC_MODULE_P} + dodoc "${HTTP_MEMC_MODULE_WD}"/README.markdown + fi + + if use nginx_modules_http_auth_ldap; then + docinto ${HTTP_LDAP_MODULE_P} + dodoc "${HTTP_LDAP_MODULE_WD}"/example.conf + fi +} + +pkg_postinst() { + if use ssl; then + if [[ ! -f "${EROOT}"/etc/ssl/${PN}/${PN}.key ]]; then + install_cert /etc/ssl/${PN}/${PN} + use prefix || chown ${PN}:${PN} "${EROOT}"/etc/ssl/${PN}/${PN}.{crt,csr,key,pem} + fi + fi + + if use nginx_modules_http_spdy; then + ewarn "" + ewarn "In nginx 1.9.5 the spdy module was superseded by http2." + ewarn "Update your configs and package.use accordingly." + fi + + if use nginx_modules_http_lua; then + ewarn "" + ewarn "While you can build lua 3rd party module against ${P}" + ewarn "the author warns that >=${PN}-1.11.11 is still not an" + ewarn "officially supported target yet. You are on your own." + ewarn "Expect runtime failures, memory leaks and other problems!" + fi + + if use nginx_modules_http_lua && use http2; then + ewarn "" + ewarn "Lua 3rd party module author warns against using ${P} with" + ewarn "NGINX_MODULES_HTTP=\"lua http2\". For more info, see https://git.io/OldLsg" + fi + + local _n_permission_layout_checks=0 + local _has_to_adjust_permissions=0 + local _has_to_show_permission_warning=0 + + # Defaults to 1 to inform people doing a fresh installation + # that we ship modified {scgi,uwsgi,fastcgi}_params files + local _has_to_show_httpoxy_mitigation_notice=1 + + local _replacing_version= + for _replacing_version in ${REPLACING_VERSIONS}; do + _n_permission_layout_checks=$((${_n_permission_layout_checks}+1)) + + if [[ ${_n_permission_layout_checks} -gt 1 ]]; then + # Should never happen: + # Package is abusing slots but doesn't allow multiple parallel installations. + # If we run into this situation it is unsafe to automatically adjust any + # permission... + _has_to_show_permission_warning=1 + + ewarn "Replacing multiple ${PN}' versions is unsupported! " \ + "You will have to adjust permissions on your own." + + break + fi + + local _replacing_version_branch=$(ver_cut 1-2 "${_replacing_version}") + debug-print "Updating an existing installation (v${_replacing_version}; branch '${_replacing_version_branch}') ..." + + # Do we need to adjust permissions to fix CVE-2013-0337 (bug #458726, #469094)? + # This was before we introduced multiple nginx versions so we + # do not need to distinguish between stable and mainline + local _need_to_fix_CVE2013_0337=1 + + if ver_test ${_replacing_version} -ge 1.4.1-r2; then + # We are updating an installation which should already be fixed + _need_to_fix_CVE2013_0337=0 + debug-print "Skipping CVE-2013-0337 ... existing installation should not be affected!" + else + _has_to_adjust_permissions=1 + debug-print "Need to adjust permissions to fix CVE-2013-0337!" + fi + + # Do we need to inform about HTTPoxy mitigation? + # In repository since commit 8be44f76d4ac02cebcd1e0e6e6284bb72d054b0f + if ver_test ${_replacing_version_branch} -lt 1.10; then + # Updating from <1.10 + _has_to_show_httpoxy_mitigation_notice=1 + debug-print "Need to inform about HTTPoxy mitigation!" + else + # Updating from >=1.10 + local _fixed_in_pvr= + case "${_replacing_version_branch}" in + "1.10") + _fixed_in_pvr="1.10.1-r2" + ;; + "1.11") + _fixed_in_pvr="1.11.3-r1" + ;; + *) + # This should be any future branch. + # If we run this code it is safe to assume that the user has + # already seen the HTTPoxy mitigation notice because he/she is doing + # an update from previous version where we have already shown + # the warning. Otherwise, we wouldn't hit this code path ... + _fixed_in_pvr= + esac + + if [[ -z "${_fixed_in_pvr}" ]] || ver_test ${_replacing_version} -ge ${_fixed_in_pvr}; then + # We are updating an installation where we already informed + # that we are mitigating HTTPoxy per default + _has_to_show_httpoxy_mitigation_notice=0 + debug-print "No need to inform about HTTPoxy mitigation ... information was already shown for existing installation!" + else + _has_to_show_httpoxy_mitigation_notice=1 + debug-print "Need to inform about HTTPoxy mitigation!" + fi + fi + + # Do we need to adjust permissions to fix CVE-2016-1247 (bug #605008)? + # All branches up to 1.11 are affected + local _need_to_fix_CVE2016_1247=1 + + if ver_test ${_replacing_version_branch} -lt 1.10; then + # Updating from <1.10 + _has_to_adjust_permissions=1 + debug-print "Need to adjust permissions to fix CVE-2016-1247!" + else + # Updating from >=1.10 + local _fixed_in_pvr= + case "${_replacing_version_branch}" in + "1.10") + _fixed_in_pvr="1.10.2-r3" + ;; + "1.11") + _fixed_in_pvr="1.11.6-r1" + ;; + *) + # This should be any future branch. + # If we run this code it is safe to assume that we have already + # adjusted permissions or were never affected because user is + # doing an update from previous version which was safe or did + # the adjustments. Otherwise, we wouldn't hit this code path ... + _fixed_in_pvr= + esac + + if [[ -z "${_fixed_in_pvr}" ]] || ver_test ${_replacing_version} -ge ${_fixed_in_pvr}; then + # We are updating an installation which should already be adjusted + # or which was never affected + _need_to_fix_CVE2016_1247=0 + debug-print "Skipping CVE-2016-1247 ... existing installation should not be affected!" + else + _has_to_adjust_permissions=1 + debug-print "Need to adjust permissions to fix CVE-2016-1247!" + fi + fi + done + + if [[ ${_has_to_adjust_permissions} -eq 1 ]]; then + # We do not DIE when chmod/chown commands are failing because + # package is already merged on user's system at this stage + # and we cannot retry without losing the information that + # the existing installation needs to adjust permissions. + # Instead we are going to a show a big warning ... + + if [[ ${_has_to_show_permission_warning} -eq 0 ]] && [[ ${_need_to_fix_CVE2013_0337} -eq 1 ]]; then + ewarn "" + ewarn "The world-readable bit (if set) has been removed from the" + ewarn "following directories to mitigate a security bug" + ewarn "(CVE-2013-0337, bug #458726):" + ewarn "" + ewarn " ${EPREFIX}/var/log/nginx" + ewarn " ${EPREFIX}${NGINX_HOME_TMP}/{,client,proxy,fastcgi,scgi,uwsgi}" + ewarn "" + ewarn "Check if this is correct for your setup before restarting nginx!" + ewarn "This is a one-time change and will not happen on subsequent updates." + ewarn "Furthermore nginx' temp directories got moved to '${EPREFIX}${NGINX_HOME_TMP}'" + chmod o-rwx \ + "${EPREFIX}"/var/log/nginx \ + "${EPREFIX}"${NGINX_HOME_TMP}/{,client,proxy,fastcgi,scgi,uwsgi} || \ + _has_to_show_permission_warning=1 + fi + + if [[ ${_has_to_show_permission_warning} -eq 0 ]] && [[ ${_need_to_fix_CVE2016_1247} -eq 1 ]]; then + ewarn "" + ewarn "The permissions on the following directory have been reset in" + ewarn "order to mitigate a security bug (CVE-2016-1247, bug #605008):" + ewarn "" + ewarn " ${EPREFIX}/var/log/nginx" + ewarn "" + ewarn "Check if this is correct for your setup before restarting nginx!" + ewarn "Also ensure that no other log directory used by any of your" + ewarn "vhost(s) is not writeable for nginx user. Any of your log files" + ewarn "used by nginx can be abused to escalate privileges!" + ewarn "This is a one-time change and will not happen on subsequent updates." + chown 0:nginx "${EPREFIX}"/var/log/nginx || _has_to_show_permission_warning=1 + chmod 710 "${EPREFIX}"/var/log/nginx || _has_to_show_permission_warning=1 + fi + + if [[ ${_has_to_show_permission_warning} -eq 1 ]]; then + # Should never happen ... + ewarn "" + ewarn "*************************************************************" + ewarn "*************** W A R N I N G ***************" + ewarn "*************************************************************" + ewarn "The one-time only attempt to adjust permissions of the" + ewarn "existing nginx installation failed. Be aware that we will not" + ewarn "try to adjust the same permissions again because now you are" + ewarn "using a nginx version where we expect that the permissions" + ewarn "are already adjusted or that you know what you are doing and" + ewarn "want to keep custom permissions." + ewarn "" + fi + fi + + # Sanity check for CVE-2016-1247 + # Required to warn users who received the warning above and thought + # they could fix it by unmerging and re-merging the package or have + # unmerged a affected installation on purpose in the past leaving + # /var/log/nginx on their system due to keepdir/non-empty folder + # and are now installing the package again. + local _sanity_check_testfile=$(mktemp --dry-run "${EPREFIX}"/var/log/nginx/.CVE-2016-1247.XXXXXXXXX) + su -s /bin/sh -c "touch ${_sanity_check_testfile}" nginx >&/dev/null + if [ $? -eq 0 ] ; then + # Cleanup -- no reason to die here! + rm -f "${_sanity_check_testfile}" + + ewarn "" + ewarn "*************************************************************" + ewarn "*************** W A R N I N G ***************" + ewarn "*************************************************************" + ewarn "Looks like your installation is vulnerable to CVE-2016-1247" + ewarn "(bug #605008) because nginx user is able to create files in" + ewarn "" + ewarn " ${EPREFIX}/var/log/nginx" + ewarn "" + ewarn "Also ensure that no other log directory used by any of your" + ewarn "vhost(s) is not writeable for nginx user. Any of your log files" + ewarn "used by nginx can be abused to escalate privileges!" + fi + + if [[ ${_has_to_show_httpoxy_mitigation_notice} -eq 1 ]]; then + # HTTPoxy mitigation + ewarn "" + ewarn "This nginx installation comes with a mitigation for the HTTPoxy" + ewarn "vulnerability for FastCGI, SCGI and uWSGI applications by setting" + ewarn "the HTTP_PROXY parameter to an empty string per default when you" + ewarn "are sourcing one of the default" + ewarn "" + ewarn " - 'fastcgi_params' or 'fastcgi.conf'" + ewarn " - 'scgi_params'" + ewarn " - 'uwsgi_params'" + ewarn "" + ewarn "files in your server block(s)." + ewarn "" + ewarn "If this is causing any problems for you make sure that you are sourcing the" + ewarn "default parameters _before_ you set your own values." + ewarn "If you are relying on user-supplied proxy values you have to remove the" + ewarn "correlating lines from the file(s) mentioned above." + ewarn "" + fi +} diff --git a/www-servers/puma/Manifest b/www-servers/puma/Manifest index 467bfb6f09e2..fde0d41257f9 100644 --- a/www-servers/puma/Manifest +++ b/www-servers/puma/Manifest @@ -3,5 +3,5 @@ DIST puma-5.4.0.tar.gz 298525 BLAKE2B d93231582cd83519c258093fd9ac5e2b06398133e8 DIST puma-5.5.2.tar.gz 302778 BLAKE2B 5911accde19aaed34cffecc71eb2db02f0d9f9ea7b57437ff7cf7580b0b51245ed68b254778cbdc11bea624b9f192aef0bfa7e24acde73b77290d780ab177933 SHA512 9887b465c6ed2a8e551b15fd161f19a9d2baa96b8eb8e247f13c98df9d34f6097bce81a52e8f88d69088d9b5f8477137af9110b7546afabc53767f337ad00ef8 EBUILD puma-5.3.2-r1.ebuild 1851 BLAKE2B 56e2293d48a3a862bea7b875afb7bc86d743996abdb0d9c2f7db0b962e5bd1616ea213b2c8eb6f4cdbaa6b2c0a9ae1d7a1f87e2943931c05cd14c9efd4acf095 SHA512 d3de6f6d1c5ace870b89e08a9169dd05ce10e5cc65e8c7013bcb1cd7b6902e9acfb73ce6d95f3ca7806c1b8106460529a51000f3e6b49296fb38c4c6780faa73 EBUILD puma-5.4.0.ebuild 1853 BLAKE2B 7568cd85ec3925a107a4f4c6dcfff0764eb307bf211b3c0c1fa4b340ef29f8a3a8cf617009ff6382fed5db8d06a3d93fb6d256404649d616b4a655023ea392b6 SHA512 28ea6e783aeacd7f33451b5600fb33921760b2297b236e8f141caa01b8f807d05093ef1b910f260a22e9c2eed293e21d287eb27dd274cff46a99f8bc56b3a8b6 -EBUILD puma-5.5.2.ebuild 1828 BLAKE2B 5efc426114d94b15e351b5d64f23e393a76456a0859e4fa370064fe890627b737650a501d308bdf734a5d2fd0a770176a12ffd1cfb58fdac19c79735a6ef8110 SHA512 398e95cb60b9164fef3499159c02e806489febd324d52f2e922e930ee6be272cefd853460c5bc101eaf505d82428b5d13aaaec7bc003cc27f49615fc3a2067fe +EBUILD puma-5.5.2.ebuild 1841 BLAKE2B ef72d41e82b086f448b76d6bd6d36e48da0b24ac25fa134aa3e644e763f0b0d61a8ccdcd468fba82066f649008d9b9c5933f49271b852905a592df0e9d6ee412 SHA512 1b2a7bda52d23dcf115482e5cb07e90a4696b8b9ce2097f4e168f3fbfc408e991d46995c95877e6a81907b35c998851b492399a2438db083d2e039a81e1bdcfa MISC metadata.xml 710 BLAKE2B bf109653812999e453fb414a83bf404786d16df301ba9dff87c123e0f1dbff8e3024109e96b7f36a3d9e1ebe57eb7aecc7acfd923f0de1bc8c4f358a87b32379 SHA512 894c677c61b3c7f8081b1511c64c274497c4ea85171f5b19d9606a19e4dff33df00d169653e3aede3eee07737b1cf9faadb812eebcf67292be68150c026b7f8e diff --git a/www-servers/puma/puma-5.5.2.ebuild b/www-servers/puma/puma-5.5.2.ebuild index 75cc0bbcb1f3..c4482fd742c1 100644 --- a/www-servers/puma/puma-5.5.2.ebuild +++ b/www-servers/puma/puma-5.5.2.ebuild @@ -18,7 +18,7 @@ SRC_URI="https://github.com/puma/puma/archive/v${PV}.tar.gz -> ${P}.tar.gz" LICENSE="BSD" SLOT="3" -KEYWORDS="~amd64 ~x86" +KEYWORDS="~amd64 ~arm64 ~hppa ~x86" IUSE="" DEPEND+=" dev-libs/openssl:0 test? ( net-misc/curl )" diff --git a/www-servers/servefile/Manifest b/www-servers/servefile/Manifest index dde3cd67efef..a5fa42d2314c 100644 --- a/www-servers/servefile/Manifest +++ b/www-servers/servefile/Manifest @@ -2,6 +2,8 @@ AUX servefile-0.4.4_p20200211-ipv6-absent-tests.patch 776 BLAKE2B db36dc2c79bd55 AUX servefile-0.5.2-ipv6-absent-tests.patch 794 BLAKE2B 7a4218f9524059f6de64608ddfdf914271c07f55137320f9557d677a22e36d935971306d7f154cf0324ebd9754f6feefde8bfa2c40754af2362f7ba99843a633 SHA512 3c0a37b3d51c4854fd4f0d706a017791d86e521b25ca1f3ef04b035aeaf868dddeacd8175ba9a3d8992c74102851e36f701c366289d3957396ba3d3d5f2222ea DIST servefile-0.5.1.tar.gz 19390 BLAKE2B 4443471870650f03564d6f574b633630fac4e1f9f6e6a9807b1baa4d3aaa6284f803fa9dc0c7c07f53cc343f89687db5f6b5a4ebf09e9fd327369e2b3aecddc5 SHA512 2502f3072522a8f460d3711dccbaa3fa57e34915313aaad475e5831962adc92c0728c2598f9f78ee99e60731cdc2d3026488ce8050369ab0c967246cd9372f44 DIST servefile-0.5.2.tar.gz 20622 BLAKE2B 3d4f02803ec5228dd463313197718b0aced1f5ceaa3438c1e8a8605cdf5d6a87e38a8bb702dc24a15cb974076f185dfbc0af95b60f394612835d3286474cdcc4 SHA512 1abeef3ff1a9f21be079329616d78811412eb2f371e11e383dc23b586f8c7edc593539b6fa641e5d91bb6c1ab81a1f39f83e45bf7c55e904c9b683166ff79622 +DIST servefile-0.5.3.tar.gz 20761 BLAKE2B bc4bd25aca01e0ac7d00e684cc8b0f848b295df2f02fe441c05d634cd415f395b0e5e083b5771c1d0dcd45ad897ac00e75ca999a76a9d0d0719c82ddb558a029 SHA512 9e6dd5927808cbb66163f207bed28f2c044d996ef1f4e77163cbf257e3e66169f58e92dba252ae389660d11e01d307fc1d8c749e903e232853c70867ce44e219 EBUILD servefile-0.5.1-r1.ebuild 799 BLAKE2B f6a14184fdf3508f4ec28e16068d8308fd17869f1d37e98959491c06a1f1f7ff1f09a7f9786281fe7ed07251f0d05b825ae0f6a5e2842c8f2999b027619afdc9 SHA512 d6c4952e640e767267c50797f24692c26afea1aabb5c8868113224206b657aa5049226819cc4deaff34a222f569af1009dfda57fb107c4585de95ecc44784301 EBUILD servefile-0.5.2.ebuild 789 BLAKE2B 8ea12f703f38e7ca44d04a0b9be22d0329953f385fef507f8f600ad000544b47658363f845e41eac18143c8a51ac975842f5f35d590722cc85e884932ea9da76 SHA512 049a68be8e152e40c451f77753fd3d8d3cabc33b49b7471848dbb934030a0df63610be20cc598228f612a04bbd9451d44c244595ff8fd820b4ad68906d9db743 +EBUILD servefile-0.5.3.ebuild 789 BLAKE2B 8ea12f703f38e7ca44d04a0b9be22d0329953f385fef507f8f600ad000544b47658363f845e41eac18143c8a51ac975842f5f35d590722cc85e884932ea9da76 SHA512 049a68be8e152e40c451f77753fd3d8d3cabc33b49b7471848dbb934030a0df63610be20cc598228f612a04bbd9451d44c244595ff8fd820b4ad68906d9db743 MISC metadata.xml 250 BLAKE2B 2bc2e14adc90cf0097dec7f5c2eeeaebecbd404252555385c3455d81ea3a22eecc3dc27aa17699ab500fdfcb737f58a6cc981aeb691fe6266537c290655ca54f SHA512 913641ea55e6cbeb7ca80b13ed2161dd3d22e6d2f59408bf272c4a79e4590b4f2c726f4025d190e58617e262313fbf9ba0892b72773e4769466f812b5c009374 diff --git a/www-servers/servefile/servefile-0.5.3.ebuild b/www-servers/servefile/servefile-0.5.3.ebuild new file mode 100644 index 000000000000..e086cb75329e --- /dev/null +++ b/www-servers/servefile/servefile-0.5.3.ebuild @@ -0,0 +1,40 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 +PYTHON_COMPAT=( python3_{7..10} ) + +inherit distutils-r1 + +DESCRIPTION="Serve a single file via HTTP" +HOMEPAGE="https://github.com/sebageek/servefile" +SRC_URI="https://github.com/sebageek/servefile/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="ssl test" + +RDEPEND=" + ssl? ( dev-python/pyopenssl[${PYTHON_USEDEP}] ) + sys-apps/grep + sys-apps/iproute2 + sys-apps/net-tools + sys-apps/sed" +DEPEND="test? ( + ${RDEPEND} + dev-python/requests[${PYTHON_USEDEP}] + )" + +S="${WORKDIR}"/${P} + +PATCHES=( + "${FILESDIR}"/${PN}-0.5.2-ipv6-absent-tests.patch +) + +distutils_enable_tests pytest + +src_install() { + distutils-r1_src_install + doman ${PN}.1 +} diff --git a/www-servers/thin/Manifest b/www-servers/thin/Manifest index 4948ade3dfc5..aa98a36d7445 100644 --- a/www-servers/thin/Manifest +++ b/www-servers/thin/Manifest @@ -1,5 +1,5 @@ AUX thin.confd-2 1335 BLAKE2B c6821353bbf2dd35d7161394247c4c3d88237c94f976a693ef95d19f7b751256c2f943250737c9f66777df6520feadad853a4ccdcb2fafa779c39d4456d2a78b SHA512 1f6eb02faf7bea7da3be56fd358846c0d5b7fa177d4dbfbb9930cc6496848917a0ae88394d58a7631e78a36c62394b4893d238bee2226568dbc2868627c2105c AUX thin.initd-r4 1841 BLAKE2B 4cdf853cb536011d582c729d3c48d7335cd3fa508c5281139220d624c204fae1460d4d1c0252d42ff3d277eaaaedfe1259e895335fcf9c8b9134d3f288f2ba44 SHA512 08d06627bf61737837af40fc4253afbecf753e3c74edacb038e59e66b95ef6bb56d55065e7d02d393ba2df45b93c9882788debdd4965404a8088c0e52ec98c0a DIST thin-1.8.1.tar.gz 181377 BLAKE2B 883a35d60d5845defa1f20a85b90269838a1b1ebeb4d4f32561af061cdac05b545c254fe65cca828ccfed033ad934ad3b72f1795407734d3b377a6022b57397f SHA512 221ef0c0369c449f2ca121c435ffebed318d6179a3b5d52e24d2bd80212df9cac35db39d156275c915c24550f6d8ded9f29616785d0a38e85cd13a1702e31298 -EBUILD thin-1.8.1.ebuild 2518 BLAKE2B e5cf15e48256e80ad1c9220908cc13f652e8bcf0c2d2e57e4faa2e38d48572d237779b7c9135f1d8910cac194b166f552a5b8ec0c2cfc62f3b9a31bb24558a7e SHA512 d08482ce5496fce22918d833d0b154ef5b6c13aef315c10e3911a4c7a0aa6a352e7544c302479437745824d579d378334263936c4cba0c1b8307e7a998ae6834 +EBUILD thin-1.8.1.ebuild 2525 BLAKE2B a94a70719c1e60e9aaf9c0b70144060b030b3cf5c5ea783a806e8b363dbe6d92d3a5365991f058190e757ffb83b59fa198cae7e1b1fbb0443713252c628d7c31 SHA512 6a8182b208ef3acf96053f066ab57be871c0ccdc00957d15d01a2f1e7b6017e7ae1e973829ecf8719055728099cc3593ff6b1a871e8c9357cb1a096f318d3b57 MISC metadata.xml 606 BLAKE2B 2108fe753bae9f5c059ab822cc68159a8b4e2751b9ef110d2d9201d5ee2136b7ad62cdcf2ba9de16117cb66d675fa80680338f99998f98233fa460c4283fb96c SHA512 30603daa98715ea038459ae97ec0880cd01499faf2a94e670f91c54dbf08da901e5374dee8532e7ec7e8aeee19c6f3bdff49d1f6fc1f1ba59ff1b79a907a8a4e diff --git a/www-servers/thin/thin-1.8.1.ebuild b/www-servers/thin/thin-1.8.1.ebuild index d9b781364f18..49580a63fd0f 100644 --- a/www-servers/thin/thin-1.8.1.ebuild +++ b/www-servers/thin/thin-1.8.1.ebuild @@ -3,7 +3,7 @@ EAPI=7 -USE_RUBY="ruby25 ruby26" +USE_RUBY="ruby25 ruby26 ruby27" RUBY_FAKEGEM_RECIPE_TEST="rspec" RUBY_FAKEGEM_GEMSPEC="${PN}.gemspec" diff --git a/www-servers/tomcat/Manifest b/www-servers/tomcat/Manifest index d3f36d8a9188..0de108532896 100644 --- a/www-servers/tomcat/Manifest +++ b/www-servers/tomcat/Manifest @@ -9,13 +9,19 @@ AUX tomcat-instance-manager-r2.bash 6999 BLAKE2B f1c771678bd8b894ecf242d5a8fb22f AUX tomcat-r1.init 3200 BLAKE2B eb913d32bb8c1883e58551a25ff9516337d947c6fd2c7b449601a89a4518286d61dbca76417265289782a7a08540d8e78a3ea1cd1427d43d87e24813261c0fee SHA512 3d32e2ad998adfbaea5fe0ffcbbe6659dcb530a110faed5f2712ae2fd767353b1fc3f1ac83a24d43138c1bfc55949e645833a428ab982be14415887fc46d9fab AUX tomcat.conf 1811 BLAKE2B a92606e113172c6f0f73e18ab8ad8796f38bd8c741bb2fd1f6c43d7682728729d0198d4150e42282c7e732750231b7cdbfb51de9b24f2ba780a22700965113c5 SHA512 0747dd2fdad6c68123425adce39f625d34924ae3e7c9d5a00361565a593047d7a4d01dee64c1ef831e5ad79b51750babaf642b0588d4b5948bbed441d53d654d DIST apache-tomcat-10.0.12-src.tar.gz 6066701 BLAKE2B 24acb9e10de923c9d6443c956cd6e6c5b5463f4f6af72d89445c7d635731449afc9b7050c95af3cbd3653168c073840f02472dd01bde65c1bcbdfcba41814117 SHA512 753d36edb5ce873e346856305d6a7f40d762ae8fb9ecd20406ed9ff400e9e1261f66d4549fc98f20a05b01136ff4beaacb462147e84a306858e2acc7fcd98d5b +DIST apache-tomcat-10.0.13-src.tar.gz 6070494 BLAKE2B f588dc6fac49b07dcdd70958ed477cc9e5e4f5c76f56d41e4baf654b8b7e4be80432b3a4510fdb030855940d3e93045c0f54adde277bec2fe1152b43a96c6f85 SHA512 91993c9236af381cc7ae6f96126d0fba30c2d082ad88b816b151fb847373d93d527de5784dd1e2295adb6cfbb5fd591e8a9cab0c1b1ef96ba54b8b3ec0f91e9e DIST apache-tomcat-7.0.109-src.tar.gz 5314401 BLAKE2B 56583caea6879bf8ca5cc02a886de3d7af413032f88d367653e709dc1c8f590e78620c788317bbff4b6e65dd3e242cc26863164ac8e7c87334a22636f3ed0703 SHA512 ecf9c0bee0e3e1aa24f299fe633705c5a2f6aa264d9e4968cfc96aa5d0a425c2b0ff07765a8b6c67221766733bdfaed6e6c6377a8d0870d889e7063ce90a46ce DIST apache-tomcat-8.5.72-src.tar.gz 5954383 BLAKE2B ddf342e3bb604ffd5d70e9b822a110654434aac0da0bd28e8649a0ce312706c202f48077ee18f43398d91bc000ea5287d87e0fd2bda9d2c8493e1b6b012945fc SHA512 69c27076d193a874416c83a1dcb80f71af78cb201b0990795d389f0a389e0537749b62256408c6249031abd2e62f268c8b451328284dbbff50a457937cfa6f6d +DIST apache-tomcat-8.5.73-src.tar.gz 5973026 BLAKE2B d3d275b7462a3bd2ce9ce03869e09e42ec0da064eb764cf8168b8d003431d075952f15c083b5486e006629ec1f9dade154b0fceb20f2584168b36599c3c5485b SHA512 6190d78e2dd5d478131443807e464821a337c5c6c24ee91953fece377ad1c758339ce1588a7a5e90443ababac239b45e4aaa0422d68cba988d7c3da5fe95d1c6 DIST apache-tomcat-9.0.54-src.tar.gz 6132613 BLAKE2B 5d37359ac9cac2a1387675a095aa0bea3e2bc74740d761a13fb2313aaca8ddb14f10922a8edc0932c9139c04b4df7f5735b067a71ac75ebbfe16ff6066311993 SHA512 e9d532a966aa8e7c2fcf28e4ecb0a618a8be4dacf8dc579a407483de86ef969383e3662fba07be629bfb8fbd85c041a5a2f1dd8875cc309b69a147b37c58974b +DIST apache-tomcat-9.0.55-src.tar.gz 6136319 BLAKE2B ac49abc3198bcc2fed1310839d0c9a30b5aefb7c0a679c3bb69f7aadd82b32b7d523cc24bdd55ba9edc363e181fc93c323944ebd5801ed2b9d38e8d1b3486d4f SHA512 abfb1824387045fc6b5a5077179149e6c348c0deae933e8766c60cbf92466f5e8883ebe4cc260c23ece6d3975ab2e25f7cdde58f9dd83dfdd22cab33c967b28c DIST biz.aQute.bnd-5.1.1.jar 16088761 BLAKE2B 59906cc39ea27ef20cbf82de1ba78096f34dc417da6dc5c28e21f6e92c0625efecf14cec6c5faf0ab17551c31a6c87a24614c2ac75ac902cfea30199ecc0d39f SHA512 8092b083e7b86e75bf27233964763b88bee74d8ae141c85e387c1cc8bd0cbf3a54be27afea29931fb3ae950700a515fd4a28cfe8e7f26cbaaec506aa06357a37 DIST biz.aQute.bndlib-5.1.1.jar 3652944 BLAKE2B dad9f9835fb407a36e0eae4b65fa2fda147e06ab3f3211a2ed2f1631aeccd6d14d198c325793cb1ce9a57b719a836db230d0452715744ba5a4a6c2983c17916b SHA512 d7da056ba541ae0862159bf5e38e1a5351b2ab5388c88733b46601c2d7dab8970f16af00df186a6cb67fbe81ef53f2c8402db9d28a8c6819dadf60a1df40879b EBUILD tomcat-10.0.12.ebuild 5920 BLAKE2B 6bc1cb899bfac912196be33f6e4f03dda576987af8786ae5233981b930a39d1b1f7600410d7a0c9cb80e8a0e345e12218de8129121c58480c882ba4f350b12c6 SHA512 7a68ce76cb33398a8a4d3a1eb93139be2f14e5e22c75421dc03136aeed06a8bcc3d5d5bd94bea93d8f8c6c2d0625fb0c2d1aac73838ff3d6eaeaddf900b6fd6b +EBUILD tomcat-10.0.13.ebuild 5920 BLAKE2B 6bc1cb899bfac912196be33f6e4f03dda576987af8786ae5233981b930a39d1b1f7600410d7a0c9cb80e8a0e345e12218de8129121c58480c882ba4f350b12c6 SHA512 7a68ce76cb33398a8a4d3a1eb93139be2f14e5e22c75421dc03136aeed06a8bcc3d5d5bd94bea93d8f8c6c2d0625fb0c2d1aac73838ff3d6eaeaddf900b6fd6b EBUILD tomcat-7.0.109.ebuild 4147 BLAKE2B 8023fb9265a3e57bbdb506559bfe9a337f566e09b6cccd0e74e84341e54d1434134eb0aecaf72a97113826d8f7359dea1e5672db44e9dfb706b020cf79c51802 SHA512 0730da2fe90a5fa203e03eef5044eb8b90c5b800d064d65467370834b788c3de03ea5c57ccfe20b29deac9c560c68029e94a80be180b240356565121d453a2a4 EBUILD tomcat-8.5.72.ebuild 4736 BLAKE2B 99ac3fe1e217729c87256b892cbd781cbda8f3235b526d19f087fcb39613f725825fde1802c013427c5b2621ca9e1380a2afe0f7fc4600570c640619d52cef0a SHA512 122f809b5148b3da0e83a3fe2e3fc4db4a6db8e0b8ec1270cde7a282ee074eaba6a8b716814b2065b9f29730a8dca221712830088f378417dd47789ab0174c62 +EBUILD tomcat-8.5.73.ebuild 4737 BLAKE2B 0fc89880a266872832a8f199af5cfc3aa6ec0e14ab8214eca907dbf91e68f5306c23fcef1fdfa852c7e8051ec6953086338380552ea1c08ec45a828d6fc35d9a SHA512 f3b4c598e3a022baf63a81068751a4c73f3106a1583c5d9d3493fd6aa5fc7a87e91cc023203b81c86ed3683bacdaed728886bbffadd1bb102b5e2a678f75b26a EBUILD tomcat-9.0.54.ebuild 5632 BLAKE2B 616ff7cfe9e1e408be386a2c6f9146370440ac4cd84a3afa15893bc5e00afa73a47b8760d5c2434099b38cfaa069bd65f23efe78eee64b0abcbf499bb72a97d4 SHA512 9eca0997e3559fad1b90b567a68e915e6d22a25e05eacd08cb7abba0575e7e6db76168a3aa1fd33d60b19754d6082f1578417deb4c04ae82fb1575531e50709a +EBUILD tomcat-9.0.55.ebuild 5632 BLAKE2B 616ff7cfe9e1e408be386a2c6f9146370440ac4cd84a3afa15893bc5e00afa73a47b8760d5c2434099b38cfaa069bd65f23efe78eee64b0abcbf499bb72a97d4 SHA512 9eca0997e3559fad1b90b567a68e915e6d22a25e05eacd08cb7abba0575e7e6db76168a3aa1fd33d60b19754d6082f1578417deb4c04ae82fb1575531e50709a MISC metadata.xml 713 BLAKE2B 8a4ecfb2190e156b77598a825550953f936ddc1a1303a95bcae173592ac4f482e81af1d7b62bc62248c20ac92cdd1dd3a9c351c74f684193085c0b242043fee7 SHA512 946fed270cb43e9c239f6f831ac2e8021526a9c3b1b8fea91d00d1b48f979273de3f7c227bce03009de04bcc8386803606864ffdb85666005d6b0ef5c49f01c5 diff --git a/www-servers/tomcat/tomcat-10.0.13.ebuild b/www-servers/tomcat/tomcat-10.0.13.ebuild new file mode 100644 index 000000000000..0b16b403fb0f --- /dev/null +++ b/www-servers/tomcat/tomcat-10.0.13.ebuild @@ -0,0 +1,192 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +JAVA_PKG_IUSE="doc source test" + +inherit java-pkg-2 java-ant-2 prefix + +MY_P="apache-${PN}-${PV}-src" + +# Currently we bundle binary versions of bnd.jar and bndlib.jar +# See bugs #203080 and #676116 +BND_VERSION="5.1.1" +BND="biz.aQute.bnd-${BND_VERSION}.jar" +BNDLIB="biz.aQute.bndlib-${BND_VERSION}.jar" + +DESCRIPTION="Tomcat Servlet-5.0/JSP-3.0/EL-4.0/WebSocket-2.0/JASIC-2.0 Container" +HOMEPAGE="https://tomcat.apache.org/" +SRC_URI="mirror://apache/${PN}/tomcat-9/v${PV}/src/${MY_P}.tar.gz + https://repo.maven.apache.org/maven2/biz/aQute/bnd/biz.aQute.bnd/${BND_VERSION}/${BND} + https://repo.maven.apache.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/${BND_VERSION}/${BNDLIB}" + +LICENSE="Apache-2.0" +SLOT="10" +KEYWORDS="~amd64 ~amd64-linux" +IUSE="extra-webapps" + +RESTRICT="test" # can we run them on a production system? + +ECJ_SLOT="4.15" +SAPI_SLOT="5.0" + +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT} + dev-java/glassfish-xmlrpc-api:0 + dev-java/jakartaee-migration:0 + ~dev-java/tomcat-servlet-api-${PV}:${SAPI_SLOT} + dev-java/wsdl4j:0" +RDEPEND="${COMMON_DEP} + acct-group/tomcat + acct-user/tomcat + virtual/jre" +DEPEND="${COMMON_DEP} + app-admin/pwgen + dev-java/ant-core + virtual/jdk:1.8 + test? ( + dev-java/ant-junit:0 + dev-java/easymock:3.2 + )" + +S=${WORKDIR}/${MY_P} + +PATCHES=( + "${FILESDIR}/${PN}-9.0.50-insufficient-ecj.patch" +) + +BND_HOME="${S}/tomcat-build-libs/bnd" +BNDLIB_HOME="${S}/tomcat-build-libs/bndlib" +BND_JAR="${BND_HOME}/${BND}" +BNDLIB_JAR="${BNDLIB_HOME}/${BND_LIB}" + +src_unpack() { + unpack ${MY_P}.tar.gz + + mkdir -p "${BND_HOME}" "${BNDLIB_HOME}" || die "Failed to create dir" + ln -s "${DISTDIR}/${BND}" "${BND_HOME}/" || die "Failed to symlink bnd-*.jar" + ln -s "${DISTDIR}/${BND}" "${BNDLIB_HOME}/" || die "Failed to symlink bndlib-*.jar" +} + +src_prepare() { + default + + find -name '*.jar' -type f -delete -print || die + + # Remove bundled servlet-api + rm -rv java/jakarta/{el,servlet} || die + + eapply "${FILESDIR}/${PN}-10.0.4-build.xml.patch" + + # For use of catalina.sh in netbeans + sed -i -e "/^# ----- Execute The Requested Command/ a\ + CLASSPATH=\`java-config --with-dependencies --classpath ${PN}-${SLOT}\`" \ + bin/catalina.sh || die + + java-pkg-2_src_prepare +} + +JAVA_ANT_REWRITE_CLASSPATH="true" + +EANT_BUILD_TARGET="deploy" +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},jakartaee-migration,tomcat-servlet-api-${SAPI_SLOT},wsdl4j" +EANT_TEST_GENTOO_CLASSPATH="easymock-3.2" +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes" +EANT_NEEDS_TOOLS="true" +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false -Dbnd.jar=${BND_JAR} -Dbndlib.jar=${BNDLIB_JAR}" + +# revisions of the scripts +IM_REV="-r2" +INIT_REV="-r1" + +src_configure() { + java-ant-2_src_configure + + eapply "${FILESDIR}/${PN}-9.0.37-fix-build-rewrite.patch" +} + +src_compile() { + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar):$(java-pkg_getjars --build-only glassfish-xmlrpc-api)" + LC_ALL=C java-pkg-2_src_compile +} + +src_test() { + java-pkg-2_src_test +} + +src_install() { + local dest="/usr/share/${PN}-${SLOT}" + + java-pkg_jarinto "${dest}"/bin + java-pkg_dojar output/build/bin/*.jar + exeinto "${dest}"/bin + doexe output/build/bin/*.sh + + java-pkg_jarinto "${dest}"/lib + java-pkg_dojar output/build/lib/*.jar + + dodoc RELEASE-NOTES RUNNING.txt + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api + use source && java-pkg_dosrc java/* + + ### Webapps ### + + # add missing docBase + local apps="host-manager manager" + for app in ${apps}; do + sed -i -e "s|=\"true\" >|=\"true\" docBase=\"\$\{catalina.home\}/webapps/${app}\" >|" \ + output/build/webapps/${app}/META-INF/context.xml || die + done + + insinto "${dest}"/webapps + doins -r output/build/webapps/{host-manager,manager,ROOT} + use extra-webapps && doins -r output/build/webapps/{docs,examples} + + ### Config ### + + # create "logs" directory in $CATALINA_BASE + # and set correct perms, see #458890 + dodir "${dest}"/logs + fperms 0750 "${dest}"/logs + + # replace the default pw with a random one, see #92281 + local randpw="$(pwgen -s -B 15 1)" + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die + + # prepend gentoo.classpath to common.loader, see #453212 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die + + insinto "${dest}" + doins -r output/build/conf + + ### rc ### + + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die + + insinto "${dest}"/gentoo + doins "${T}"/tomcat.conf + exeinto "${dest}"/gentoo + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash +} + +pkg_postinst() { + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version" + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat." + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat" + + elog "To manage Tomcat instances, run:" + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help" + + ewarn "Please note that since version 10 the primary package for all implemented APIs" + ewarn "has changed from javax.* to jakarta.*. This will almost certainly require code" + ewarn "changes to enable applications to migrate from Tomcat 9 and earlier to Tomcat 10 and later." + + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar" + ewarn "from upstream binary if you need it. Gentoo Bug # 144276" + + einfo "Please read https://wiki.gentoo.org/wiki/Apache_Tomcat and" + einfo "https://wiki.gentoo.org/wiki/Project:Java/Tomcat_6_Guide for more information." +} diff --git a/www-servers/tomcat/tomcat-8.5.73.ebuild b/www-servers/tomcat/tomcat-8.5.73.ebuild new file mode 100644 index 000000000000..ce92130bddc8 --- /dev/null +++ b/www-servers/tomcat/tomcat-8.5.73.ebuild @@ -0,0 +1,159 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +JAVA_PKG_IUSE="doc source test" + +inherit java-pkg-2 java-ant-2 prefix + +MY_P="apache-${P}-src" + +DESCRIPTION="Tomcat Servlet-3.1/JSP-2.3/EL-3.0/WebSocket-1.1/JASPIC-1.1 Container" +HOMEPAGE="https://tomcat.apache.org/" +SRC_URI="mirror://apache/${PN}/tomcat-8/v${PV}/src/${MY_P}.tar.gz" + +LICENSE="Apache-2.0" +SLOT="8.5" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x86-solaris" +IUSE="extra-webapps" + +RESTRICT="test" # can we run them on a production system? + +ECJ_SLOT="4.5" +SAPI_SLOT="3.1" + +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT} + ~dev-java/tomcat-servlet-api-${PV}:${SAPI_SLOT}" +RDEPEND="${COMMON_DEP} + acct-group/tomcat + acct-user/tomcat + virtual/jre" +DEPEND="${COMMON_DEP} + app-admin/pwgen + dev-java/ant-core + virtual/jdk:1.8 + doc? ( + dev-java/glassfish-xmlrpc-api:0 + dev-java/wsdl4j:0 + ) + test? ( + >=dev-java/ant-junit-1.9:0 + dev-java/easymock:3.2 + )" + +S=${WORKDIR}/${MY_P} + +src_prepare() { + default + + find -name '*.jar' -type f -delete -print || die + + # Remove bundled servlet-api + rm -rv java/javax/{el,servlet} || die + + eapply "${FILESDIR}/${PN}-8.5.66-build.xml.patch" + + # For use of catalina.sh in netbeans + sed -i -e "/^# ----- Execute The Requested Command/ a\ + CLASSPATH=\`java-config --with-dependencies --classpath ${PN}-${SLOT}\`" \ + bin/catalina.sh || die + + java-pkg-2_src_prepare +} + +JAVA_ANT_REWRITE_CLASSPATH="true" + +EANT_BUILD_TARGET="deploy" +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},tomcat-servlet-api-${SAPI_SLOT}" +EANT_TEST_GENTOO_CLASSPATH="easymock-3.2" +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes" +EANT_NEEDS_TOOLS="true" +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false -Dexecute.validate=false" + +# revisions of the scripts +IM_REV="-r2" +INIT_REV="-r1" + +src_compile() { + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar)" + use doc && EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only glassfish-xmlrpc-api glassfish-xmlrpc-api.jar):$(java-pkg_getjar --build-only wsdl4j wsdl4j.jar)" + LC_ALL=C java-pkg-2_src_compile +} + +src_test() { + java-pkg-2_src_test +} + +src_install() { + local dest="/usr/share/${PN}-${SLOT}" + + java-pkg_jarinto "${dest}"/bin + java-pkg_dojar output/build/bin/*.jar + exeinto "${dest}"/bin + doexe output/build/bin/*.sh + + java-pkg_jarinto "${dest}"/lib + java-pkg_dojar output/build/lib/*.jar + + dodoc RELEASE-NOTES RUNNING.txt + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api + use source && java-pkg_dosrc java/* + + ### Webapps ### + + # add missing docBase + local apps="host-manager manager" + for app in ${apps}; do + sed -i -e "s|=\"true\" >|=\"true\" docBase=\"\$\{catalina.home\}/webapps/${app}\" >|" \ + output/build/webapps/${app}/META-INF/context.xml || die + done + + insinto "${dest}"/webapps + doins -r output/build/webapps/{host-manager,manager,ROOT} + use extra-webapps && doins -r output/build/webapps/{docs,examples} + + ### Config ### + + # create "logs" directory in $CATALINA_BASE + # and set correct perms, see #458890 + dodir "${dest}"/logs + fperms 0750 "${dest}"/logs + + # replace the default pw with a random one, see #92281 + local randpw="$(pwgen -s -B 15 1)" + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die + + # prepend gentoo.classpath to common.loader, see #453212 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die + + insinto "${dest}" + doins -r output/build/conf + + ### rc ### + + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die + + insinto "${dest}"/gentoo + doins "${T}"/tomcat.conf + exeinto "${dest}"/gentoo + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash +} + +pkg_postinst() { + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version" + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat." + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat" + + elog "To manage Tomcat instances, run:" + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help" + + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar" + ewarn "from upstream binary if you need it. Gentoo Bug # 144276" + + einfo "Please read https://wiki.gentoo.org/wiki/Apache_Tomcat and" + einfo "https://wiki.gentoo.org/wiki/Project:Java/Tomcat_6_Guide for more information." +} diff --git a/www-servers/tomcat/tomcat-9.0.55.ebuild b/www-servers/tomcat/tomcat-9.0.55.ebuild new file mode 100644 index 000000000000..8905e0fad241 --- /dev/null +++ b/www-servers/tomcat/tomcat-9.0.55.ebuild @@ -0,0 +1,187 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +JAVA_PKG_IUSE="doc source test" + +inherit java-pkg-2 java-ant-2 prefix + +MY_P="apache-${PN}-${PV}-src" + +# Currently we bundle binary versions of bnd.jar and bndlib.jar +# See bugs #203080 and #676116 +BND_VERSION="5.1.1" +BND="biz.aQute.bnd-${BND_VERSION}.jar" +BNDLIB="biz.aQute.bndlib-${BND_VERSION}.jar" + +DESCRIPTION="Tomcat Servlet-4.0/JSP-2.3/EL-3.0/WebSocket-1.1/JASPIC-1.1 Container" +HOMEPAGE="https://tomcat.apache.org/" +SRC_URI="mirror://apache/${PN}/tomcat-9/v${PV}/src/${MY_P}.tar.gz + https://repo.maven.apache.org/maven2/biz/aQute/bnd/biz.aQute.bnd/${BND_VERSION}/${BND} + https://repo.maven.apache.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/${BND_VERSION}/${BNDLIB}" + +LICENSE="Apache-2.0" +SLOT="9" +KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x86-solaris" +IUSE="extra-webapps" + +RESTRICT="test" # can we run them on a production system? + +ECJ_SLOT="4.15" +SAPI_SLOT="4.0" + +COMMON_DEP="dev-java/eclipse-ecj:${ECJ_SLOT} + dev-java/glassfish-xmlrpc-api:0 + ~dev-java/tomcat-servlet-api-${PV}:${SAPI_SLOT} + dev-java/wsdl4j:0" +RDEPEND="${COMMON_DEP} + acct-group/tomcat + acct-user/tomcat + virtual/jre" +DEPEND="${COMMON_DEP} + app-admin/pwgen + >=dev-java/ant-core-1.9.13 + virtual/jdk:1.8 + test? ( + >=dev-java/ant-junit-1.9:0 + dev-java/easymock:3.2 + )" + +S=${WORKDIR}/${MY_P} + +PATCHES=( + "${FILESDIR}/${PN}-9.0.50-insufficient-ecj.patch" +) + +BND_HOME="${S}/tomcat-build-libs/bnd" +BNDLIB_HOME="${S}/tomcat-build-libs/bndlib" +BND_JAR="${BND_HOME}/${BND}" +BNDLIB_JAR="${BNDLIB_HOME}/${BND_LIB}" + +src_unpack() { + unpack ${MY_P}.tar.gz + + mkdir -p "${BND_HOME}" "${BNDLIB_HOME}" || die "Failed to create dir" + ln -s "${DISTDIR}/${BND}" "${BND_HOME}/" || die "Failed to symlink bnd-*.jar" + ln -s "${DISTDIR}/${BND}" "${BNDLIB_HOME}/" || die "Failed to symlink bndlib-*.jar" +} + +src_prepare() { + default + + find -name '*.jar' -type f -delete -print || die + + # Remove bundled servlet-api + rm -rv java/javax/{el,servlet} || die + + eapply "${FILESDIR}/${PN}-9.0.46-build.xml.patch" + + # For use of catalina.sh in netbeans + sed -i -e "/^# ----- Execute The Requested Command/ a\ + CLASSPATH=\`java-config --with-dependencies --classpath ${PN}-${SLOT}\`" \ + bin/catalina.sh || die + + java-pkg-2_src_prepare +} + +JAVA_ANT_REWRITE_CLASSPATH="true" + +EANT_BUILD_TARGET="deploy" +EANT_GENTOO_CLASSPATH="eclipse-ecj-${ECJ_SLOT},tomcat-servlet-api-${SAPI_SLOT},wsdl4j" +EANT_TEST_GENTOO_CLASSPATH="easymock-3.2" +EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes" +EANT_NEEDS_TOOLS="true" +EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false -Dbnd.jar=${BND_JAR} -Dbndlib.jar=${BNDLIB_JAR}" + +# revisions of the scripts +IM_REV="-r2" +INIT_REV="-r1" + +src_configure() { + java-ant-2_src_configure + + eapply "${FILESDIR}/${PN}-9.0.37-fix-build-rewrite.patch" +} + +src_compile() { + EANT_GENTOO_CLASSPATH_EXTRA+=":$(java-pkg_getjar --build-only ant-core ant.jar):$(java-pkg_getjars --build-only glassfish-xmlrpc-api)" + LC_ALL=C java-pkg-2_src_compile +} + +src_test() { + java-pkg-2_src_test +} + +src_install() { + local dest="/usr/share/${PN}-${SLOT}" + + java-pkg_jarinto "${dest}"/bin + java-pkg_dojar output/build/bin/*.jar + exeinto "${dest}"/bin + doexe output/build/bin/*.sh + + java-pkg_jarinto "${dest}"/lib + java-pkg_dojar output/build/lib/*.jar + + dodoc RELEASE-NOTES RUNNING.txt + use doc && java-pkg_dojavadoc output/dist/webapps/docs/api + use source && java-pkg_dosrc java/* + + ### Webapps ### + + # add missing docBase + local apps="host-manager manager" + for app in ${apps}; do + sed -i -e "s|=\"true\" >|=\"true\" docBase=\"\$\{catalina.home\}/webapps/${app}\" >|" \ + output/build/webapps/${app}/META-INF/context.xml || die + done + + insinto "${dest}"/webapps + doins -r output/build/webapps/{host-manager,manager,ROOT} + use extra-webapps && doins -r output/build/webapps/{docs,examples} + + ### Config ### + + # create "logs" directory in $CATALINA_BASE + # and set correct perms, see #458890 + dodir "${dest}"/logs + fperms 0750 "${dest}"/logs + + # replace the default pw with a random one, see #92281 + local randpw="$(pwgen -s -B 15 1)" + sed -i -e "s|SHUTDOWN|${randpw}|" output/build/conf/server.xml || die + + # prepend gentoo.classpath to common.loader, see #453212 + sed -i -e 's/^common\.loader=/\0${gentoo.classpath},/' output/build/conf/catalina.properties || die + + insinto "${dest}" + doins -r output/build/conf + + ### rc ### + + cp "${FILESDIR}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} "${T}" || die + eprefixify "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} + sed -i -e "s|@SLOT@|${SLOT}|g" "${T}"/tomcat{.conf,${INIT_REV}.init,-instance-manager${IM_REV}.bash} || die + + insinto "${dest}"/gentoo + doins "${T}"/tomcat.conf + exeinto "${dest}"/gentoo + newexe "${T}"/tomcat${INIT_REV}.init tomcat.init + newexe "${T}"/tomcat-instance-manager${IM_REV}.bash tomcat-instance-manager.bash +} + +pkg_postinst() { + elog "New ebuilds of Tomcat support running multiple instances. If you used prior version" + elog "of Tomcat (<7.0.32), you have to migrate your existing instance to work with new Tomcat." + elog "You can find more information at https://wiki.gentoo.org/wiki/Apache_Tomcat" + + elog "To manage Tomcat instances, run:" + elog " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help" + + ewarn "tomcat-dbcp.jar is not built at this time. Please fetch jar" + ewarn "from upstream binary if you need it. Gentoo Bug # 144276" + + einfo "Please read https://wiki.gentoo.org/wiki/Apache_Tomcat and" + einfo "https://wiki.gentoo.org/wiki/Project:Java/Tomcat_6_Guide for more information." +} diff --git a/www-servers/uwsgi/Manifest b/www-servers/uwsgi/Manifest index b74647b8527c..0a4bef321e05 100644 --- a/www-servers/uwsgi/Manifest +++ b/www-servers/uwsgi/Manifest @@ -2,6 +2,5 @@ AUX gentoo.buildconf 490 BLAKE2B 320b0471c0c76ab6c8ada7b034f612fc20398eb60e1edc3 AUX uwsgi.confd-r4 1849 BLAKE2B 80afdf7a5ebc520d887061aba9f7cd64b1bca06d3da478d8d1090a8b9cba973ac2d3dbcbc2ceb980415e98317bc55b07a9a7e6641fac593dc4dd5466bd8d67c9 SHA512 041d1bd694fad6f7c5e28944aab6d7ba53b3c7fc990ce6b7c2d97b9f3d6650c46dda8069e545c252a7400e1d825c8e46d7393a289757b1bd665e64241ca3789a AUX uwsgi.initd-r7 3746 BLAKE2B a56c5f4e32ccb415fab10f357e2a7404179285e656d9f886809da281b214e2110c76e2cf8826d8fd90aba01262a5edc7a941522ff59348972c5a4325c784b9b9 SHA512 81ed974fb2957e05c890cab29f5b5a75845e6b7de899d2695fb2fa5f49b4545daa437c81c8dc5c735b24a45655cf6320c9256bc8faa7e32ffd7a2d981922def5 DIST uwsgi-2.0.19.1.tar.gz 804398 BLAKE2B 73fc19990866eb1058a742b34a817b3bd87e00c838da055bece2bff5e13c161f53c642866ed591aa4afeb23ef924205502f2cb0a4cf9d303b5b63fb9a53f57e2 SHA512 34b55f7c7a77dc0b0dab34d1a9ca9a4cba8a9261969656c88435e7f32fe8a0c5654e1562706775f77e2f60c4ad0f5c6055257a23ab7d387c1579639e054807b5 -EBUILD uwsgi-2.0.19.1-r106.ebuild 11511 BLAKE2B 690f25947b578387c65b5cbdfa52c55bffc0ac155db10dc172458aaa6175f9ab48623a3809544222b95d743dab7ad72c58abc6a61a83c4c26aa427b90a88dd23 SHA512 b593fa88bf9b653400fa227af638150d1310df99c9940cecc2bf7d1c42803769b7801f5f3fd7219c4784d1ec3bcdcdf1752ed4223e2b372325c536800f1be929 EBUILD uwsgi-2.0.19.1-r107.ebuild 11520 BLAKE2B 022aeefd01cd4a672f2dfdedf16e3c4a26e4ce6c28101073b0a2f030c0fb83ae2771f7b5cf547a176724b1226a8aad25e3439cf803593799e4d069000bb04cef SHA512 215b6f4af79daeb6e0b2cb14b688383951ab59d1429fc30532a8dae689d34db06efe48be024669ef367de5b6ecfb093259356f31c9b94d599aee6aaa9af62e01 MISC metadata.xml 1412 BLAKE2B c4f2831a4f5e53f49953045619adbe15ae45dc5d9c019eae8defe3de586121b3fe2292c9c7921b086d8bbf6a0c727ef1cd443c01df99e7532db9126f1b82bdb6 SHA512 2fa796e52f80dc37fe43190541675bd69a082932b00b8c92998b717d8a332300a12b19dab7cfdf1ebf0c1363252b6035a8f17e285bd86bbd685aaa2ac3464dd8 diff --git a/www-servers/uwsgi/uwsgi-2.0.19.1-r106.ebuild b/www-servers/uwsgi/uwsgi-2.0.19.1-r106.ebuild deleted file mode 100644 index b5a71218edef..000000000000 --- a/www-servers/uwsgi/uwsgi-2.0.19.1-r106.ebuild +++ /dev/null @@ -1,376 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -LUA_COMPAT=( lua5-1 ) -PYTHON_COMPAT=( python3_{7,8} ) -PYTHON_REQ_USE="threads(+)" - -RUBY_OPTIONAL="yes" -USE_RUBY="ruby23 ruby24 ruby25 ruby26" - -PHP_EXT_INI="no" -PHP_EXT_NAME="dummy" -PHP_EXT_OPTIONAL_USE="php" -USE_PHP="php7-3 php7-4" # deps must be registered separately below - -MY_P="${P/_/-}" - -inherit flag-o-matic lua-single pax-utils php-ext-source-r3 python-r1 ruby-ng - -DESCRIPTION="uWSGI server for Python web applications" -HOMEPAGE="https://projects.unbit.it/uwsgi/" -SRC_URI="https://github.com/unbit/uwsgi/archive/${PV}.tar.gz -> ${P}.tar.gz" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="amd64 arm x86 ~amd64-linux" - -UWSGI_PLUGINS_STD=( ping cache carbon nagios rpc rrdtool - http ugreen signal syslog rsyslog - router_{uwsgi,redirect,basicauth,rewrite,http,cache,static,memcached,redis,hash,expires,metrics} - {core,fast,raw,ssl}router - redislog mongodblog log{file,socket} - spooler cheaper_busyness symcall - transformation_{chunked,gzip,offload,tofile} - zergpool ) -UWSGI_PLUGINS_OPT=( alarm_{curl,xmpp} clock_{monotonic,realtime} curl_cron - dumbloop echo emperor_{amqp,pg,zeromq} forkptyrouter - geoip graylog2 legion_cache_fetch ldap log{crypto,pipe} notfound pam - rados router_{access,radius,spnego,xmldir} - sqlite ssi stats_pusher_statsd - systemd_logger transformation_toupper tuntap webdav xattr xslt zabbix ) - -LANG_SUPPORT_SIMPLE=( cgi mono perl ) # plugins which can be built in the main build process -LANG_SUPPORT_EXTENDED=( go lua php python python-asyncio python-gevent ruby ) - -# plugins to be ignored (for now): -# cheaper_backlog2: example plugin -# coroae: TODO -# cplusplus: partially example code, needs explicit class -# dummy: no idea -# example: example plugin -# exception_log: example plugin -# *java*: TODO -# v8: TODO -# matheval: TODO -IUSE="apache2 +caps debug +embedded expat jemalloc json +pcre +routing selinux +ssl +xml yajl yaml zeromq" - -for plugin in ${UWSGI_PLUGINS_STD[@]}; do IUSE="${IUSE} +uwsgi_plugins_${plugin}"; done -for plugin in ${UWSGI_PLUGINS_OPT[@]}; do IUSE="${IUSE} uwsgi_plugins_${plugin}"; done -IUSE="${IUSE} ${LANG_SUPPORT_SIMPLE[@]} ${LANG_SUPPORT_EXTENDED[@]}" - -REQUIRED_USE="|| ( ${LANG_SUPPORT_SIMPLE[@]} ${LANG_SUPPORT_EXTENDED[@]} ) - uwsgi_plugins_logcrypto? ( ssl ) - uwsgi_plugins_sslrouter? ( ssl ) - routing? ( pcre ) - uwsgi_plugins_emperor_zeromq? ( zeromq ) - uwsgi_plugins_forkptyrouter? ( uwsgi_plugins_corerouter ) - uwsgi_plugins_router_xmldir? ( xml !expat ) - lua? ( ${LUA_REQUIRED_USE} ) - python? ( ${PYTHON_REQUIRED_USE} ) - python-asyncio? ( || ( $(python_gen_useflags -3) ) ) - python-gevent? ( python ) - expat? ( xml )" - -# util-linux is required for libuuid when requesting zeromq support -# Order: -# 1. Unconditional -# 2. General features -# 3. Plugins -# 4. Language/app support -CDEPEND=" - sys-libs/zlib - virtual/libcrypt:= - caps? ( sys-libs/libcap ) - json? ( - !yajl? ( dev-libs/jansson:= ) - yajl? ( dev-libs/yajl ) - ) - pcre? ( dev-libs/libpcre:3 ) - ssl? ( dev-libs/openssl:0= ) - xml? ( - !expat? ( dev-libs/libxml2 ) - expat? ( dev-libs/expat ) - ) - yaml? ( dev-libs/libyaml ) - zeromq? ( net-libs/zeromq sys-apps/util-linux ) - uwsgi_plugins_alarm_curl? ( net-misc/curl ) - uwsgi_plugins_alarm_xmpp? ( net-libs/gloox ) - uwsgi_plugins_curl_cron? ( net-misc/curl ) - uwsgi_plugins_emperor_pg? ( dev-db/postgresql:= ) - uwsgi_plugins_geoip? ( dev-libs/geoip ) - uwsgi_plugins_ldap? ( net-nds/openldap ) - uwsgi_plugins_pam? ( sys-libs/pam ) - uwsgi_plugins_sqlite? ( dev-db/sqlite:3 ) - uwsgi_plugins_rados? ( sys-cluster/ceph ) - uwsgi_plugins_router_access? ( sys-apps/tcp-wrappers ) - uwsgi_plugins_router_spnego? ( virtual/krb5 ) - uwsgi_plugins_systemd_logger? ( sys-apps/systemd ) - uwsgi_plugins_webdav? ( dev-libs/libxml2 ) - uwsgi_plugins_xslt? ( dev-libs/libxslt ) - go? ( sys-devel/gcc:=[go] ) - lua? ( ${LUA_DEPS} ) - mono? ( dev-lang/mono:= ) - perl? ( dev-lang/perl:= ) - php? ( - php_targets_php7-3? ( dev-lang/php:7.3[embed] ) - php_targets_php7-4? ( dev-lang/php:7.4[embed] ) - ) - python? ( ${PYTHON_DEPS} ) - python-asyncio? ( virtual/python-greenlet[${PYTHON_USEDEP}] ) - python-gevent? ( >=dev-python/gevent-1.3.5[${PYTHON_USEDEP}] ) - ruby? ( $(ruby_implementations_depend) )" -DEPEND="${CDEPEND}" -RDEPEND="${CDEPEND} - selinux? ( sec-policy/selinux-uwsgi ) - uwsgi_plugins_rrdtool? ( net-analyzer/rrdtool )" -BDEPEND="virtual/pkgconfig" - -S="${WORKDIR}/${MY_P}" - -src_unpack() { - echo ${PYTHON_USEDEP} - default -} - -pkg_setup() { - python_setup - use lua && lua-single_pkg_setup - use ruby && ruby-ng_pkg_setup -} - -src_prepare() { - default - - sed -i \ - -e "s|'-O2', ||" \ - -e "s|'-Werror', ||" \ - -e "s|uc.get('plugin_dir')|uc.get('plugin_build_dir')|" \ - uwsgiconfig.py || die "sed failed" - - sed -i \ - -e "s|/lib|/$(get_libdir)|" \ - plugins/php/uwsgiplugin.py || die "sed failed" -} - -src_configure() { - local embedded_plugins=() - local plugins=() - local malloc_impl="libc" - local json="false" - local xml="false" - - for p in ${UWSGI_PLUGINS_STD[@]} ${UWSGI_PLUGINS_OPT[@]} ; do - use uwsgi_plugins_${p} && embedded_plugins+=("${p}") - done - for p in ${LANG_SUPPORT_SIMPLE[@]} ; do - use ${p} && plugins+=("${p}") - done - - # do not embed any plugins - if ! use embedded; then - plugins=( ${plugins[@]} ${embedded_plugins[@]} ) - embedded_plugins=() - fi - - # flatten the arrays - plugins=${plugins[@]} - embedded_plugins=${embedded_plugins[@]} - - # rename some of the use flags, language plugins are always real plugins - plugins="${plugins/perl/psgi}" - plugins="${plugins/sqlite/sqlite3}" - embedded_plugins="${embedded_plugins/sqlite/sqlite3}" - - # override defaults as requested by the user - if use xml; then - use expat && xml="expat" || xml="libxml2" - fi - if use json; then - use yajl && json="yajl" || json="jansson" - fi - use jemalloc && malloc_impl="jemalloc" - - # prepare the buildconf for gentoo - cp "${FILESDIR}"/gentoo.buildconf buildconf/gentoo.ini || die - sed -i \ - -e "s|VAR_XML|${xml}|" \ - -e "s|VAR_YAML|$(usex yaml libyaml true)|" \ - -e "s|VAR_JSON|${json}|" \ - -e "s|VAR_SSL|$(usex ssl true false)|" \ - -e "s|VAR_PCRE|$(usex pcre true false)|" \ - -e "s|VAR_ZMQ|$(usex zeromq true false)|" \ - -e "s|VAR_ROUTING|$(usex routing true false)|" \ - -e "s|VAR_DEBUG|$(usex debug true false)|" \ - -e "s|VAR_MALLOC|${malloc_impl}|" \ - -e "s|VAR_PLUGINS|${plugins// /, }|" \ - -e "s|VAR_PLUGIN_DIR|${EPREFIX}/usr/$(get_libdir)/uwsgi|" \ - -e "s|VAR_BUILD_DIR|${T}/plugins|" \ - -e "s|VAR_EMBEDDED|${embedded_plugins// /, }|" \ - buildconf/gentoo.ini || die "sed failed" - - if ! use caps; then - sed -i -e 's|sys/capability.h|DISABLED|' uwsgiconfig.py || die "sed failed" - fi - - if ! use zeromq; then - sed -i -e 's|uuid/uuid.h|DISABLED|' uwsgiconfig.py || die "sed failed" - fi - - if use uwsgi_plugins_emperor_pg ; then - PGPV="$(best_version dev-db/postgresql)" - PGSLOT="$(ver_cut 1-2 ${PGPV##dev-db/postgresql-})" - sed -i \ - -e "s|pg_config|pg_config${PGSLOT/.}|" \ - plugins/emperor_pg/uwsgiplugin.py || die "sed failed" - fi -} - -each_ruby_compile() { - cd "${WORKDIR}/${MY_P}" || die "sed failed" - - UWSGICONFIG_RUBYPATH="${RUBY}" python uwsgiconfig.py --plugin plugins/rack gentoo rack_${RUBY##*/} || die "building plugin for ${RUBY} failed" - UWSGICONFIG_RUBYPATH="${RUBY}" python uwsgiconfig.py --plugin plugins/fiber gentoo fiber_${RUBY##*/}|| die "building fiber plugin for ${RUBY} failed" - UWSGICONFIG_RUBYPATH="${RUBY}" python uwsgiconfig.py --plugin plugins/rbthreads gentoo rbthreads_${RUBY##*/}|| die "building rbthreads plugin for ${RUBY} failed" -} - -python_compile_plugins() { - local EPYV - local PYV - EPYV=${EPYTHON/.} - PYV=${EPYV/python} - - ${PYTHON} uwsgiconfig.py --plugin plugins/python gentoo ${EPYV} || die "building plugin for ${EPYTHON} failed" - - if use python-asyncio ; then - if [[ "${PYV}" != "27" ]] ; then - ${PYTHON} uwsgiconfig.py --plugin plugins/asyncio gentoo asyncio${PYV} || die "building plugin for asyncio-support in ${EPYTHON} failed" - fi - fi - - if use python-gevent ; then - ${PYTHON} uwsgiconfig.py --plugin plugins/gevent gentoo gevent${PYV} || die "building plugin for gevent-support in ${EPYTHON} failed" - fi - - if use python-gevent || use python-asyncio; then - ${PYTHON} uwsgiconfig.py --plugin plugins/greenlet gentoo greenlet${PYV} || die "building plugin for greenlet-support in ${EPYTHON} failed" - fi -} - -python_install_symlinks() { - dosym uwsgi /usr/bin/uwsgi_${EPYTHON/.} -} - -src_compile() { - mkdir -p "${T}/plugins" || die - - CPUCOUNT=1 python uwsgiconfig.py --build gentoo || die "building uwsgi failed" - - if use go ; then - python uwsgiconfig.py --plugin plugins/gccgo gentoo || die "building plugin for go failed" - fi - - if use lua ; then - # setting the name for the pkg-config file to lua, since that is the name - # provided by the wrapper from Lua eclasses - UWSGICONFIG_LUAPC="lua" python uwsgiconfig.py --plugin plugins/lua gentoo || die "building plugin for lua failed" - fi - - if use php ; then - for s in $(php_get_slots); do - UWSGICONFIG_PHPDIR="/usr/$(get_libdir)/${s}" python uwsgiconfig.py --plugin plugins/php gentoo ${s/.} || die "building plugin for ${s} failed" - done - fi - - if use python ; then - python_foreach_impl python_compile_plugins - fi - - if use ruby ; then - ruby-ng_src_compile - fi -} - -src_install() { - dobin uwsgi - pax-mark m "${D}"/usr/bin/uwsgi - - insinto /usr/$(get_libdir)/uwsgi - doins "${T}/plugins"/*.so - - use cgi && dosym uwsgi /usr/bin/uwsgi_cgi - use go && dosym uwsgi /usr/bin/uwsgi_go - use lua && dosym uwsgi /usr/bin/uwsgi_lua - use mono && dosym uwsgi /usr/bin/uwsgi_mono - use perl && dosym uwsgi /usr/bin/uwsgi_psgi - - if use php ; then - for s in $(php_get_slots); do - dosym uwsgi /usr/bin/uwsgi_${s/.} - done - fi - - if use python ; then - python_foreach_impl python_install_symlinks - python_foreach_impl python_domodule uwsgidecorators.py - fi - - newinitd "${FILESDIR}"/uwsgi.initd-r7 uwsgi - newconfd "${FILESDIR}"/uwsgi.confd-r4 uwsgi - keepdir /etc/"${PN}".d - use uwsgi_plugins_spooler && keepdir /var/spool/"${PN}" -} - -pkg_postinst() { - if use apache2 ; then - ewarn "As reported on bug #650776 [1], Apache module mod_proxy_uwsgi" - ewarn "is being transferred to upstream Apache since 2.4.30, see [2]." - ewarn "We therefore do not build them any more." - ewarn " [1] https://bugs.gentoo.org/650776" - ewarn " [2] https://github.com/unbit/uwsgi/issues/1636" - fi - - elog "Append the following options to the uwsgi call to load the respective language plugin:" - use cgi && elog " '--plugins cgi' for cgi" - use lua && elog " '--plugins lua' for lua" - use mono && elog " '--plugins mono' for mono" - use perl && elog " '--plugins psgi' for perl" - - if use php ; then - for s in $(php_get_slots); do - elog " '--plugins ${s/.}' for ${s}" - done - fi - - python_pkg_postinst() { - local EPYV - local PYV - EPYV=${EPYTHON/.} - PYV=${EPYV/python} - - elog " " - elog " '--plugins ${EPYV}' for ${EPYTHON}" - if use python-asyncio ; then - if [[ ${EPYV} == python34 ]] ; then - elog " '--plugins ${EPYV},asyncio${PYV}' for asyncio support in ${EPYTHON}" - else - elog " (asyncio is only supported in python3.4)" - fi - fi - if use python-gevent ; then - elog " '--plugins ${EPYV},gevent${PYV}' for gevent support in ${EPYTHON}" - fi - } - - use python && python_foreach_impl python_pkg_postinst - - if use ruby ; then - for ruby in $(ruby_get_use_implementations) ; do - elog " '--plugins rack_${ruby/.}' for ${ruby}" - elog " '--plugins fiber_${ruby/.}' for ${ruby} fibers" - elog " '--plugins rbthreads_${ruby/.}' for ${ruby} rbthreads" - done - fi -} |