summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolkmar W. Pogatzki <gentoo@pogatzki.net>2024-06-19 10:59:44 +0200
committerMiroslav Šulc <fordfrog@gentoo.org>2024-06-19 12:01:37 +0200
commit22ffbb374cff2baf6e6f77d2cf90d49f33d860e0 (patch)
treee8062960a2f93f8c88eebed469e0003363888442 /www-servers
parentsec-keys/openpgp-keys-apache-tomcat: add 9.0.90 (diff)
downloadgentoo-22ffbb374cff2baf6e6f77d2cf90d49f33d860e0.tar.gz
gentoo-22ffbb374cff2baf6e6f77d2cf90d49f33d860e0.tar.bz2
gentoo-22ffbb374cff2baf6e6f77d2cf90d49f33d860e0.zip
www-servers/tomcat: add 9.0.90
Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net> Closes: https://github.com/gentoo/gentoo/pull/37215 Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
Diffstat (limited to 'www-servers')
-rw-r--r--www-servers/tomcat/Manifest2
-rw-r--r--www-servers/tomcat/tomcat-9.0.90.ebuild168
2 files changed, 170 insertions, 0 deletions
diff --git a/www-servers/tomcat/Manifest b/www-servers/tomcat/Manifest
index e0144b71cd34..0c4aabcffb51 100644
--- a/www-servers/tomcat/Manifest
+++ b/www-servers/tomcat/Manifest
@@ -6,4 +6,6 @@ DIST apache-tomcat-10.1.24-src.tar.gz 6230916 BLAKE2B ac2329499d9afa37a62ad00b5c
DIST apache-tomcat-10.1.24-src.tar.gz.asc 833 BLAKE2B aa1a6b3698b80f16ed567153d42655b425597bacc2cc1aee7a73e8cb20db22c57d827d2400df045a828d1cca017ffc5af1c941b9c0f94369fcf7d52458061b01 SHA512 cedc2128b2877bb4470d06df9618c403c49f488eb5006b3561f39b98b2ff7539819b931813c9af484f62a57a582e36730ed25e8f30a8743631b4d72bca4be386
DIST apache-tomcat-9.0.89-src.tar.gz 6319184 BLAKE2B a3c9539fe25a5ca87820214a7b7b8376c05383d940bfa19f7811f3fb5e90e2bd392f46c3f1a08a8949256bde5855bd479ac3754245dc953aa78e5f73e23f8849 SHA512 c2e8e45a98cd30764b507bb997c7cf1b8e337be9c6d1833bb5f916a5d86d96cb095f430884d0a248cdc3b510beb11e227cc160f8402ba5b2e3952399a44461d1
DIST apache-tomcat-9.0.89-src.tar.gz.asc 833 BLAKE2B 7629f94f4d036a6fc307bc6d157758eb5291a0b854bed20f0341ef0dffda8cff4722d4e47c2ad5f7e8d331ab0563532d53596859dcd990a75809f0432862f63a SHA512 5cf7dc5890f928acb43d2401e196166cfbd473236a27afde9fed621e0eefd3b9b59abe3ad8ac4e77086752e67afd0d60af9003e84f5cb2e66a58e6dee89b7366
+DIST apache-tomcat-9.0.90-src.tar.gz 6311070 BLAKE2B 0e585a798f3bc476e826296a4fb77fde479dd88be7ea4c7f94982714a16ffca7b57ffa4cb527322192631a4eb617c6a3a19d338e592e9642c7e771cc77f7d9a7 SHA512 ade9eda20fe137080eb4fb43a36e510025822acabaf5564a950d24eded491e3f8846dff6ab6382716cd2f3aa676e4f134d28d7c1fa5f9d89230aa600d18071cb
+DIST apache-tomcat-9.0.90-src.tar.gz.asc 833 BLAKE2B d8c145bc9d13f79dfe3515a0dad0d389803a1e4353a0d4a164d8837fc037319b04d632db7b4c3aca55e493b9e0e1e0267d5d34f22c3bede143937c0702721d08 SHA512 74ed315b748be390e7a74705a209316625a811d163d0ed1149d58f93c02558953023836422fffbfe9b9bb68036563ad7e764d07dd65fe531fd361dda5ce8192c
DIST biz.aQute.bnd-7.0.0.jar 16567341 BLAKE2B 329b3b750e917ad513a1f767f63b96b1d0b10177a0f3c079bbf07e02aff77607e1f869bae09d09709d8cfef27cd802585e7f332e2a3e3f0ee1c31a4890e53fce SHA512 42b2e43f3e437c7b06f0d168eaf5ee499a4c517b1a01bec67fd6df92d01d037dd9088e0d5b013dfa1839f9dee35bf74903c1af7204712bf4aa72412e071ac503
diff --git a/www-servers/tomcat/tomcat-9.0.90.ebuild b/www-servers/tomcat/tomcat-9.0.90.ebuild
new file mode 100644
index 000000000000..ca10cc20e118
--- /dev/null
+++ b/www-servers/tomcat/tomcat-9.0.90.ebuild
@@ -0,0 +1,168 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+JAVA_PKG_IUSE="doc source test"
+
+inherit java-pkg-2 java-ant-2 prefix verify-sig
+
+MY_P="apache-${P}-src"
+
+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
+ verify-sig? ( https://downloads.apache.org/tomcat/tomcat-$(ver_cut 1)/v${PV}/src/${MY_P}.tar.gz.asc )"
+S=${WORKDIR}/${MY_P}
+
+LICENSE="Apache-2.0"
+SLOT="9"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="extra-webapps"
+
+RESTRICT="test" # can we run them on a production system?
+
+ECJ_SLOT="4.20"
+
+COMMON_DEP="dev-java/bnd-annotation:0
+ dev-java/eclipse-ecj:${ECJ_SLOT}
+ dev-java/jax-rpc-api:0
+ dev-java/wsdl4j:0"
+RDEPEND="${COMMON_DEP}
+ acct-group/tomcat
+ acct-user/tomcat
+ >=virtual/jre-1.8:*"
+DEPEND="${COMMON_DEP}
+ app-admin/pwgen
+ >=dev-java/ant-1.10.14-r3:0
+ dev-java/bnd-ant:0
+ dev-java/bnd-util:0
+ dev-java/bndlib:0
+ dev-java/libg:0
+ dev-java/osgi-cmpn:8
+ dev-java/osgi-core:0
+ dev-java/slf4j-api:0
+ >=virtual/jdk-17:*
+ test? (
+ >=dev-java/ant-1.10.14-r3:0[junit]
+ dev-java/easymock:3.2
+ )"
+
+BDEPEND="verify-sig? ( ~sec-keys/openpgp-keys-apache-tomcat-${PV}:${PV} )"
+VERIFY_SIG_OPENPGP_KEY_PATH="/usr/share/openpgp-keys/tomcat-${PV}.apache.org.asc"
+
+PATCHES=(
+ "${FILESDIR}/tomcat-9.0.87-build.xml.patch"
+ "${FILESDIR}/tomcat-9.0.87-gentoo-bnd.patch"
+)
+
+src_prepare() {
+ default #780585
+ java-pkg-2_src_prepare
+ java-pkg_clean
+
+ cat > build.properties <<-EOF || die
+ execute.download=false
+ exist=true # skip target="downloadfile-2"
+ ant.jar=$(java-pkg_getjar --build-only ant ant.jar)
+ bnd-annotation.jar=$(java-pkg_getjars bnd-annotation)
+ bnd-ant.jar=$(java-pkg_getjars --build-only bnd-ant)
+ bnd-util.jar=$(java-pkg_getjars --build-only bnd-util)
+ bnd.jar=$(java-pkg_getjars --build-only bnd)
+ bndlib.jar=$(java-pkg_getjars --build-only bndlib)
+ jaxrpc-lib.jar=$(java-pkg_getjars jax-rpc-api)
+ jdt.jar=$(java-pkg_getjars eclipse-ecj-${ECJ_SLOT})
+ libg.jar=$(java-pkg_getjars --build-only libg)
+ osgi-cmpn.jar=$(java-pkg_getjars --build-only osgi-cmpn-8)
+ osgi-core.jar=$(java-pkg_getjars --build-only osgi-core)
+ slf4j-api.jar=$(java-pkg_getjars --build-only slf4j-api)
+ wsdl4j-lib.jar=$(java-pkg_getjars wsdl4j)
+ EOF
+
+ # 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
+}
+
+EANT_BUILD_TARGET="deploy"
+EANT_TEST_GENTOO_CLASSPATH="easymock-3.2"
+EANT_GENTOO_CLASSPATH_EXTRA="${S}/output/classes"
+EANT_EXTRA_ARGS="-Dversion=${PV}-gentoo -Dversion.number=${PV} -Dcompile.debug=false"
+
+# revisions of the scripts
+IM_REV="-r2"
+INIT_REV="-r1"
+
+src_compile() {
+ 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() {
+ einfo "Ebuilds of Tomcat support running multiple instances. To manage Tomcat instances, run:"
+ einfo " ${EPREFIX}/usr/share/${PN}-${SLOT}/gentoo/tomcat-instance-manager.bash --help"
+
+ einfo "Please read https://wiki.gentoo.org/wiki/Apache_Tomcat"
+}