summaryrefslogtreecommitdiff
path: root/www-servers
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-07-12 08:41:54 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-07-12 08:41:54 +0100
commit4df3bf9762850b34cd1ead5c80374d1a0fc3362e (patch)
tree3080c5cb7ad17abcb63776a9f21c4947845546a6 /www-servers
parent814f4cf860e299a046b649eaee5463427984c09c (diff)
gentoo resync : 12.07.2021
Diffstat (limited to 'www-servers')
-rw-r--r--www-servers/Manifest.gzbin5033 -> 5036 bytes
-rw-r--r--www-servers/lighttpd/Manifest2
-rw-r--r--www-servers/lighttpd/lighttpd-1.4.59-r1.ebuild (renamed from www-servers/lighttpd/lighttpd-1.4.59.ebuild)1
-rw-r--r--www-servers/puma/Manifest2
-rw-r--r--www-servers/puma/files/puma-3.12.1-ruby26-waitpid.patch47
-rw-r--r--www-servers/puma/files/puma-3.12.5-cve-2020-11077.patch114
-rw-r--r--www-servers/tomcat/Manifest2
-rw-r--r--www-servers/tomcat/tomcat-8.5.69.ebuild159
8 files changed, 163 insertions, 164 deletions
diff --git a/www-servers/Manifest.gz b/www-servers/Manifest.gz
index b7c405624c72..320a03b0c914 100644
--- a/www-servers/Manifest.gz
+++ b/www-servers/Manifest.gz
Binary files differ
diff --git a/www-servers/lighttpd/Manifest b/www-servers/lighttpd/Manifest
index 3afbeebe568d..139587169c85 100644
--- a/www-servers/lighttpd/Manifest
+++ b/www-servers/lighttpd/Manifest
@@ -13,5 +13,5 @@ DIST lighttpd-1.4.58.tar.xz 956828 BLAKE2B b8b0a111db64a8af429dd9922503991e55276
DIST lighttpd-1.4.59.tar.xz 968352 BLAKE2B 8997386be24d9d84fa8012aedd8ac97b3ad4fd19bb756163d3e9b8c6984c740475c6db2810817db9d1a246320bcd81f7ab35847707316454523c614a4485299f SHA512 94d312f6ac65c32057018b749c4865220b43b3e4b7fe9396848aa403ea7fdc2ccbf3f4f91daf281b754cf272a52a8bcdc689502773ea33cae36eead2785daa0f
EBUILD lighttpd-1.4.55-r101.ebuild 6930 BLAKE2B 4c4fa416b1c16180aa963cb27142b204359720984ffda46e97b72f271f33492a2e312124f65297ebd713f416b46eae14738befacb76db774660a977d0ea20cf8 SHA512 825d5eda1bea989b061daf2deaed0a7fb4677b07c5a813b28d46a7b1232ead07013eae16d428471e812d9b614f5c5a504a9d23f1ccef6fb0dc10da951a5857e8
EBUILD lighttpd-1.4.58-r1.ebuild 7553 BLAKE2B 86e08f4bec91ec5609c202d0f9966b4aa680307dbd58f521b153ac5d31b273ea749ea51f92d5d5e05efb688a18b2fd5b072199fa62376d2f0b4837dc3d696dc4 SHA512 5e39ddbe0fc1e71ec6394e002aab4924812636768650ae79b43f38d87a4c381646ddc531ffce9b1e8cc15497f185a4073491e0df4ea63a4246f551223c1f7d33
-EBUILD lighttpd-1.4.59.ebuild 6610 BLAKE2B 4fc787aa2f3180ab55178cfb3c1be5fffcc223e738f91a562151044b19c46565f5d1df56e680e551a13ee310f7f6b11f5b8a06217177215f0b5e49083bce249e SHA512 e76181a8c1fa790f7883c5187d4c171512a67a35e2b48bb6146db5572c4fbb237ed3a5e7b416f2d04ace2448ac3c6d7117e9e18a9c73e42f6cc488621ec62129
+EBUILD lighttpd-1.4.59-r1.ebuild 6630 BLAKE2B 130dd417c1c78dafc4776379e56544b03124fa31d324145f34756fffac1e6c245a84e6eddd44c23e3827fa55518a597bc8f48e25967a430128f6444b5cd96d69 SHA512 41bdb222c0f819050a6da4bc7228ae9df9d4d11bb322f9a4acc49f78a528291a7c5a3968a1fe2d20edfd2f465c0277063c4b5dc818cc9031a50d2107d23dd47e
MISC metadata.xml 1795 BLAKE2B 40fb9d80ed77f9513c3d0c6b2ac4ee919fc496411bd003fad6f505d82eeebb4847e19def7d412939d6936d859eab088d1c345f30be4e6c4f5ca03d8a1dad7039 SHA512 b2c25885ae42fa963aad249a7f183a2093df7a612bbc7f8f33ea173f8c6ff3ebcdaa052e722a4e467ffc56815a4bf40dbb95782bb17b616be93c55a4ef5160fd
diff --git a/www-servers/lighttpd/lighttpd-1.4.59.ebuild b/www-servers/lighttpd/lighttpd-1.4.59-r1.ebuild
index 86b8878e8422..0ad33eb525b3 100644
--- a/www-servers/lighttpd/lighttpd-1.4.59.ebuild
+++ b/www-servers/lighttpd/lighttpd-1.4.59-r1.ebuild
@@ -29,6 +29,7 @@ BDEPEND="virtual/pkgconfig"
COMMON_DEPEND="
acct-group/lighttpd
acct-user/lighttpd
+ virtual/libcrypt:=
brotli? ( app-arch/brotli )
bzip2? ( app-arch/bzip2 )
dbi? (
diff --git a/www-servers/puma/Manifest b/www-servers/puma/Manifest
index becef025f34e..daf73c5f430d 100644
--- a/www-servers/puma/Manifest
+++ b/www-servers/puma/Manifest
@@ -1,5 +1,3 @@
-AUX puma-3.12.1-ruby26-waitpid.patch 1722 BLAKE2B cee9b9e89cf098a387481d754732f54274ce0f9580568e62496513d58d46578f81c13df2aa98d2da218bf9d8ad581e8728ff60be488905493e9acc6b88012a88 SHA512 86f826d7f9ac8a50d62f8cf2b87b0df5f7ce55c1a5e4ac7b928b756ece809e30750bb2a7c3c50dc95f9edcb463e9c453b5d3eb84ffe44952904200b5337351ad
-AUX puma-3.12.5-cve-2020-11077.patch 3490 BLAKE2B 08f103ed5a5cf9878404f04c139476c730f7a663681aa6cc0107c033317826ed803b72b384034b08b361ed7c99683fe3d90d51c5f97708647750db9edf59e15c SHA512 25f26889e74c98e5ee45dbdb2dad356099d15c70027f32fa2500e0f5b40d742d376b7f29560dde985c3652064f6bdec8dd411154301f6c89b1ef356632570c29
DIST puma-5.3.2.tar.gz 297673 BLAKE2B e3bfa38347526063587db966d20ea68f32cd88616d89b5f2d9152228d5d420b50c2918e24304c1bc8119af5790a2464f0a055ab92862a56262013ddbba006a1f SHA512 32e80b413184d371d451a35985a371a7655df0f7e81624f2a05e3cf65c2e1b035275a8e25ab03d13c9c1f921ec30cdeb3659e1201baae5940dcb3edcb525ff25
EBUILD puma-5.3.2-r1.ebuild 1844 BLAKE2B 50310a07c3e6556f5037dd3d4fdff779b4e4ebe62cff105dc5f916af588eda62d8b2cd302747ac6e528a4ccbc41a22392ef43757608a2feadd3f53241a3c818f SHA512 320ff5bca4e37ced62da5f8ce0c42aa1ac2cb6aa76e8ede8405762871e04ea785cc15786e2d9d424df08a7f8531cf76d2776bb6a7210affc8d2967d7567887d6
MISC metadata.xml 709 BLAKE2B f0a69d0e7f4c5e593ff5648b51de393610f579fd9fff372749fca4491e8dd57b7e853f87104e8b86f8e90013fe54f8c3141e28ae87d17432e60f329f51a67db6 SHA512 dd872907d8e164d0b63f1b4db076d9407c33581ae80ecafb119904ceebe4c05eb74d01d51c3217cf475faf02d3732e9854553fc980c1b054c42b95af58ee1c0e
diff --git a/www-servers/puma/files/puma-3.12.1-ruby26-waitpid.patch b/www-servers/puma/files/puma-3.12.1-ruby26-waitpid.patch
deleted file mode 100644
index b28c69fa4d4b..000000000000
--- a/www-servers/puma/files/puma-3.12.1-ruby26-waitpid.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From b94c3e34faff024a5b1930af36e4d64bd6dde57f Mon Sep 17 00:00:00 2001
-From: MSP-Greg <MSP-Greg@users.noreply.github.com>
-Date: Fri, 15 Mar 2019 17:26:20 -0500
-Subject: [PATCH] Puma::Cluster#stop_workers - use WNOHANG with nil return
- tests
-
-Ruby 2.6 introduced a bug that affects worker shutdown (waitpid).
-
-Added code using Process::WNOHANG along with needed logic. Adds worker status (via $?) and total shutdown time to log.
-
-Co-authored-by: MSP-Greg <greg.mpls@gmail.com>
-Co-authored-by: guilleiguaran <guilleiguaran@gmail.com>
----
- lib/puma/cluster.rb | 20 +++++++++++++++++++-
- 1 file changed, 19 insertions(+), 1 deletion(-)
-
-diff --git a/lib/puma/cluster.rb b/lib/puma/cluster.rb
-index 93d65131..0879c96c 100644
---- a/lib/puma/cluster.rb
-+++ b/lib/puma/cluster.rb
-@@ -37,7 +37,25 @@ def stop_workers
- @workers.each { |x| x.term }
-
- begin
-- @workers.each { |w| Process.waitpid(w.pid) }
-+ if RUBY_VERSION < '2.6'
-+ @workers.each { |w| Process.waitpid(w.pid) }
-+ else
-+ # below code is for a bug in Ruby 2.6+, above waitpid call hangs
-+ t_st = Process.clock_gettime(Process::CLOCK_MONOTONIC)
-+ pids = @workers.map(&:pid)
-+ loop do
-+ pids.reject! do |w_pid|
-+ if Process.waitpid(w_pid, Process::WNOHANG)
-+ log " worker status: #{$?}"
-+ true
-+ end
-+ end
-+ break if pids.empty?
-+ sleep 0.5
-+ end
-+ t_end = Process.clock_gettime(Process::CLOCK_MONOTONIC)
-+ log format(" worker shutdown time: %6.2f", t_end - t_st)
-+ end
- rescue Interrupt
- log "! Cancelled waiting for workers"
- end
diff --git a/www-servers/puma/files/puma-3.12.5-cve-2020-11077.patch b/www-servers/puma/files/puma-3.12.5-cve-2020-11077.patch
deleted file mode 100644
index 4d26da28eee8..000000000000
--- a/www-servers/puma/files/puma-3.12.5-cve-2020-11077.patch
+++ /dev/null
@@ -1,114 +0,0 @@
-From 089df0727ffab1b3b69f2e6da40597c52e346013 Mon Sep 17 00:00:00 2001
-From: Evan Phoenix <evan@phx.io>
-Date: Tue, 19 May 2020 15:20:10 -0700
-Subject: [PATCH] Reduce ambiguity of headers
-
----
- ext/puma_http11/http11_parser.c | 4 +++-
- ext/puma_http11/http11_parser.rl | 4 +++-
- lib/puma/server.rb | 31 +++++++++++++++++++++++++++++++
- 3 files changed, 37 insertions(+), 2 deletions(-)
-
-diff --git a/ext/puma_http11/http11_parser.c b/ext/puma_http11/http11_parser.c
-index 453f8cd40..e8844a37e 100644
---- a/ext/puma_http11/http11_parser.c
-+++ b/ext/puma_http11/http11_parser.c
-@@ -14,12 +14,14 @@
-
- /*
- * capitalizes all lower-case ASCII characters,
-- * converts dashes to underscores.
-+ * converts dashes to underscores, and underscores to commas.
- */
- static void snake_upcase_char(char *c)
- {
- if (*c >= 'a' && *c <= 'z')
- *c &= ~0x20;
-+ else if (*c == '_')
-+ *c = ',';
- else if (*c == '-')
- *c = '_';
- }
-diff --git a/ext/puma_http11/http11_parser.rl b/ext/puma_http11/http11_parser.rl
-index 880c1d40b..62452ba7c 100644
---- a/ext/puma_http11/http11_parser.rl
-+++ b/ext/puma_http11/http11_parser.rl
-@@ -12,12 +12,14 @@
-
- /*
- * capitalizes all lower-case ASCII characters,
-- * converts dashes to underscores.
-+ * converts dashes to underscores, and underscores to commas.
- */
- static void snake_upcase_char(char *c)
- {
- if (*c >= 'a' && *c <= 'z')
- *c &= ~0x20;
-+ else if (*c == '_')
-+ *c = ',';
- else if (*c == '-')
- *c = '_';
- }
-diff --git a/lib/puma/server.rb b/lib/puma/server.rb
-index d870b383f..5b2cd94df 100644
---- a/lib/puma/server.rb
-+++ b/lib/puma/server.rb
-@@ -665,6 +665,37 @@ def handle_request(req, lines)
- }
- end
-
-+ # Fixup any headers with , in the name to have _ now. We emit
-+ # headers with , in them during the parse phase to avoid ambiguity
-+ # with the - to _ conversion for critical headers. But here for
-+ # compatibility, we'll convert them back. This code is written to
-+ # avoid allocation in the common case (ie there are no headers
-+ # with , in their names), that's why it has the extra conditionals.
-+
-+ to_delete = nil
-+ to_add = nil
-+
-+ env.each do |k,v|
-+ if k.start_with?("HTTP_") and k.include?(",") and k != "HTTP_TRANSFER,ENCODING"
-+ if to_delete
-+ to_delete << k
-+ else
-+ to_delete = [k]
-+ end
-+
-+ unless to_add
-+ to_add = {}
-+ end
-+
-+ to_add[k.gsub(",", "_")] = v
-+ end
-+ end
-+
-+ if to_delete
-+ to_delete.each { |k| env.delete(k) }
-+ env.merge! to_add
-+ end
-+
- # A rack extension. If the app writes #call'ables to this
- # array, we will invoke them when the request is done.
- #
-From 0a3c09a0603857f088571d0eb69e0b9adee0fed1 Mon Sep 17 00:00:00 2001
-From: Evan Phoenix <evan@phx.io>
-Date: Tue, 19 May 2020 15:34:06 -0700
-Subject: [PATCH] Adjust test to match real world value
-
----
- test/test_puma_server.rb | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/test/test_puma_server.rb b/test/test_puma_server.rb
-index 9d40cd5f3..375eca399 100644
---- a/test/test_puma_server.rb
-+++ b/test/test_puma_server.rb
-@@ -137,6 +137,7 @@ def test_default_server_port
-
- req = Net::HTTP::Get.new("/")
- req['HOST'] = "example.com"
-+ req['X-FORWARDED-PROTO'] = "https,http"
-
- res = Net::HTTP.start @host, @server.connected_port do |http|
- http.request(req)
diff --git a/www-servers/tomcat/Manifest b/www-servers/tomcat/Manifest
index 60fed027d488..7273ff4be726 100644
--- a/www-servers/tomcat/Manifest
+++ b/www-servers/tomcat/Manifest
@@ -15,6 +15,7 @@ DIST apache-tomcat-10.0.8-src.tar.gz 6010420 BLAKE2B 86390f04147d3082fbc9f157041
DIST apache-tomcat-7.0.109-src.tar.gz 5314401 BLAKE2B 56583caea6879bf8ca5cc02a886de3d7af413032f88d367653e709dc1c8f590e78620c788317bbff4b6e65dd3e242cc26863164ac8e7c87334a22636f3ed0703 SHA512 ecf9c0bee0e3e1aa24f299fe633705c5a2f6aa264d9e4968cfc96aa5d0a425c2b0ff07765a8b6c67221766733bdfaed6e6c6377a8d0870d889e7063ce90a46ce
DIST apache-tomcat-8.5.66-src.tar.gz 5879748 BLAKE2B bfef20872bd19ffa2bb34b98a1da875fdd5f232e681458f0aef093b7eecd63a95c1cd26130f54251f149249e639d0da2577770e43314d2a86b8ee9b48b675f0d SHA512 322fda683197898f873feb375791092d33c90aac08a54889fabab0f59ecbc7b27784f027b37008c6893fdbf8ca7973b73268f42673d7e8df762419b5a536593b
DIST apache-tomcat-8.5.68-src.tar.gz 5907026 BLAKE2B 2312edb94f98ee98b594325fbc32521776e9cadc4422a3a46f3651f1fee072a99c5f6874378ac06215396504d34ad750edd6ec3399a3931554068195a8ee15ef SHA512 579a35f944ead756995d288b66ea8a4ab30289a90c32aa01119abcea85a8524f6594ce5cb7ac9df6d352c1e3b54a18c814b5d3a6409dce6a43614e3a89284066
+DIST apache-tomcat-8.5.69-src.tar.gz 5916996 BLAKE2B 4a3ef958b6bb0089149877c25baaa2c1a0bcee473c0942b419c5c1d7071dcae4f8a6e6f1805efdee1201042feedc64e213fffbcdb35cf2b7f9a67217b8dcad48 SHA512 467dd38bd77d8b5ac6fa2acf9f6ee71d04467a3182647757fa47f5d1d9576c96e5061db61ba08b04318f1db9ee4f2bcac7b45f1f9f4f81cd1807a57483dd7bbb
DIST apache-tomcat-9.0.46-src.tar.gz 6068533 BLAKE2B 400814281aedd588c008a1363199f8602e856870d4c39d536b13f8a357c2390d2db689940f4a6971ec74a84e8e400174e72610e0d64a220de41f2dff419dda3c SHA512 dc380e23aa87273c6ba32e79659e768c551b07812635c2f1c62d2c34b493b1d3d51b4548fec5014fdb36f8461fc90942aa7917874ddf3d6f5c5345d8ca02dfc1
DIST apache-tomcat-9.0.48-src.tar.gz 6080015 BLAKE2B 9b2cac8143ca8186857d7d53e8737f2f7d2ec8e0ca03d32447ad25b429cbf37c1c7b39bc6e4b93679c08bd5f4940280d00946a70e9fa82f8c2a596ea18a2a4c6 SHA512 9b762f6d1a1f6c75e10f1bc05c39a647ae2165f3b81c09ff73cc286f3c487b034b9d14c73b808c73b35f55f642848831a0329d9d611c8bbb3928559e552a3ff3
DIST apache-tomcat-9.0.50-src.tar.gz 6086608 BLAKE2B 59b5eb1616d377193f330fd8c5abb6e98926ab0a2f75b1ea14251d249837aad733f55a0b79f2a67de57f612dd1afdeae53836be97e81701d8dc27ecb0a381d4a SHA512 1032d2d5c342fb495b76426fdc301e0e5546815e709e604061d7aa2cdab19bcd376adc957fd25dee1d574306186eafd2e9d24140dd5e725b130128592cac47a2
@@ -26,6 +27,7 @@ EBUILD tomcat-10.0.8.ebuild 5920 BLAKE2B 6bc1cb899bfac912196be33f6e4f03dda576987
EBUILD tomcat-7.0.109.ebuild 4147 BLAKE2B 8023fb9265a3e57bbdb506559bfe9a337f566e09b6cccd0e74e84341e54d1434134eb0aecaf72a97113826d8f7359dea1e5672db44e9dfb706b020cf79c51802 SHA512 0730da2fe90a5fa203e03eef5044eb8b90c5b800d064d65467370834b788c3de03ea5c57ccfe20b29deac9c560c68029e94a80be180b240356565121d453a2a4
EBUILD tomcat-8.5.66.ebuild 4736 BLAKE2B 99ac3fe1e217729c87256b892cbd781cbda8f3235b526d19f087fcb39613f725825fde1802c013427c5b2621ca9e1380a2afe0f7fc4600570c640619d52cef0a SHA512 122f809b5148b3da0e83a3fe2e3fc4db4a6db8e0b8ec1270cde7a282ee074eaba6a8b716814b2065b9f29730a8dca221712830088f378417dd47789ab0174c62
EBUILD tomcat-8.5.68.ebuild 4737 BLAKE2B 0fc89880a266872832a8f199af5cfc3aa6ec0e14ab8214eca907dbf91e68f5306c23fcef1fdfa852c7e8051ec6953086338380552ea1c08ec45a828d6fc35d9a SHA512 f3b4c598e3a022baf63a81068751a4c73f3106a1583c5d9d3493fd6aa5fc7a87e91cc023203b81c86ed3683bacdaed728886bbffadd1bb102b5e2a678f75b26a
+EBUILD tomcat-8.5.69.ebuild 4737 BLAKE2B 0fc89880a266872832a8f199af5cfc3aa6ec0e14ab8214eca907dbf91e68f5306c23fcef1fdfa852c7e8051ec6953086338380552ea1c08ec45a828d6fc35d9a SHA512 f3b4c598e3a022baf63a81068751a4c73f3106a1583c5d9d3493fd6aa5fc7a87e91cc023203b81c86ed3683bacdaed728886bbffadd1bb102b5e2a678f75b26a
EBUILD tomcat-9.0.46.ebuild 5632 BLAKE2B 62c2441708f0213f2ca077bc7b8b52ecbf8d46f5f7c1720d30c6d93b21f82fa73613e06a9067b07a54dab2910344e7c2cdbe966f4fe5a6476998901bff4d5bc6 SHA512 d7a0f0c44598be1ff78d891894b91d9ffa2e8906a5733d1d8054f50250e7b7cb009d26416a11fad64a3b7bf6a0228930b1cf340e5a61dc4605e3865edb75c4ab
EBUILD tomcat-9.0.48.ebuild 5632 BLAKE2B 62c2441708f0213f2ca077bc7b8b52ecbf8d46f5f7c1720d30c6d93b21f82fa73613e06a9067b07a54dab2910344e7c2cdbe966f4fe5a6476998901bff4d5bc6 SHA512 d7a0f0c44598be1ff78d891894b91d9ffa2e8906a5733d1d8054f50250e7b7cb009d26416a11fad64a3b7bf6a0228930b1cf340e5a61dc4605e3865edb75c4ab
EBUILD tomcat-9.0.50.ebuild 5632 BLAKE2B 616ff7cfe9e1e408be386a2c6f9146370440ac4cd84a3afa15893bc5e00afa73a47b8760d5c2434099b38cfaa069bd65f23efe78eee64b0abcbf499bb72a97d4 SHA512 9eca0997e3559fad1b90b567a68e915e6d22a25e05eacd08cb7abba0575e7e6db76168a3aa1fd33d60b19754d6082f1578417deb4c04ae82fb1575531e50709a
diff --git a/www-servers/tomcat/tomcat-8.5.69.ebuild b/www-servers/tomcat/tomcat-8.5.69.ebuild
new file mode 100644
index 000000000000..ce92130bddc8
--- /dev/null
+++ b/www-servers/tomcat/tomcat-8.5.69.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."
+}