From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-1545609-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id B09CA15801B for <garchives@archives.gentoo.org>; Mon, 14 Aug 2023 06:15:28 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DF3FA2BC025; Mon, 14 Aug 2023 06:15:27 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id C37392BC025 for <gentoo-commits@lists.gentoo.org>; Mon, 14 Aug 2023 06:15:27 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C66BB335DBA for <gentoo-commits@lists.gentoo.org>; Mon, 14 Aug 2023 06:15:26 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 359A3F89 for <gentoo-commits@lists.gentoo.org>; Mon, 14 Aug 2023 06:15:25 +0000 (UTC) From: "Miroslav Šulc" <fordfrog@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Miroslav Šulc" <fordfrog@gentoo.org> Message-ID: <1691993708.6f7fce2e9d4e9fc74b1ecec97f3c728259361f49.fordfrog@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-java/tomcat-native/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-java/tomcat-native/tomcat-native-1.2.38.ebuild X-VCS-Directories: dev-java/tomcat-native/ X-VCS-Committer: fordfrog X-VCS-Committer-Name: Miroslav Šulc X-VCS-Revision: 6f7fce2e9d4e9fc74b1ecec97f3c728259361f49 X-VCS-Branch: master Date: Mon, 14 Aug 2023 06:15:25 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 824134db-ff80-4312-974d-f92dccea7e71 X-Archives-Hash: c9ffa07a31732b9d066bede470ec9b18 commit: 6f7fce2e9d4e9fc74b1ecec97f3c728259361f49 Author: Volkmar W. Pogatzki <gentoo <AT> pogatzki <DOT> net> AuthorDate: Sun Aug 13 13:20:53 2023 +0000 Commit: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org> CommitDate: Mon Aug 14 06:15:08 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f7fce2e dev-java/tomcat-native: switch to java-pkg-simple - Uses junit:4 instead of junit:0 - Skips 1 failing test which didn't seem to run with versions based on java-ant-2.eclass. Signed-off-by: Volkmar W. Pogatzki <gentoo <AT> pogatzki.net> Closes: https://github.com/gentoo/gentoo/pull/32280 Signed-off-by: Miroslav Šulc <fordfrog <AT> gentoo.org> dev-java/tomcat-native/tomcat-native-1.2.38.ebuild | 85 +++++++++++++++------- 1 file changed, 59 insertions(+), 26 deletions(-) diff --git a/dev-java/tomcat-native/tomcat-native-1.2.38.ebuild b/dev-java/tomcat-native/tomcat-native-1.2.38.ebuild index c1cd66702c54..ad19397c09bf 100644 --- a/dev-java/tomcat-native/tomcat-native-1.2.38.ebuild +++ b/dev-java/tomcat-native/tomcat-native-1.2.38.ebuild @@ -3,7 +3,10 @@ EAPI=8 -inherit java-pkg-2 java-ant-2 verify-sig +JAVA_PKG_IUSE="doc source test" +JAVA_TESTING_FRAMEWORKS="junit-4" + +inherit autotools java-pkg-2 java-pkg-simple verify-sig DESCRIPTION="Allows Tomcat to use certain native resources for better performance" HOMEPAGE="https://tomcat.apache.org/native-doc/" @@ -11,55 +14,85 @@ SRC_URI="mirror://apache/tomcat/tomcat-connectors/native/${PV}/source/${P}-src.t verify-sig? ( https://downloads.apache.org/tomcat/tomcat-connectors/native/${PV}/source/tomcat-native-${PV}-src.tar.gz.asc )" +S=${WORKDIR}/${P}-src/native KEYWORDS="~amd64 ~x86" LICENSE="Apache-2.0" SLOT="0" -IUSE="static-libs test" -RESTRICT="!test? ( test )" +IUSE="static-libs" + +DEPEND=" + >=virtual/jdk-1.8:* +" +RDEPEND=" + dev-libs/apr:1= + dev-libs/openssl:0/3 + >=virtual/jre-1.8:* +" +BDEPEND="verify-sig? ( sec-keys/openpgp-keys-apache-tomcat-connectors )" +VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}/usr/share/openpgp-keys/tomcat-connectors.apache.org.asc" -RDEPEND="dev-libs/apr:1= - dev-libs/openssl:0= - >=virtual/jre-1.8:*" +JAVA_RESOURCE_DIRS="../resources" +JAVA_SRC_DIR="../java" +JAVA_TEST_GENTOO_CLASSPATH="junit-4" +JAVA_TEST_SRC_DIR="../test" -DEPEND=">=virtual/jdk-1.8:* - test? ( dev-java/ant-junit:0 )" +PATCHES=( + "${FILESDIR}"/tomcat-native-2.0.3-slibtool.patch #778914 +) -BDEPEND="verify-sig? ( sec-keys/openpgp-keys-apache-tomcat-connectors )" -VERIFY_SIG_OPENPGP_KEY_PATH="${BROOT}/usr/share/openpgp-keys/tomcat-connectors.apache.org.asc" +DOCS=( ../{CHANGELOG.txt,NOTICE,README.txt} ) -S=${WORKDIR}/${P}-src +src_prepare() { + java-pkg-2_src_prepare + mkdir -p "${JAVA_RESOURCE_DIRS}/META-INF" || die + sed -ne '/attribute name/s:^.*name="\(.*\)" value="\(.*\)".*$:\1\: \2:p' \ + ../build.xml \ + | sed "s:\${version}:${PV}:" \ + > "${JAVA_RESOURCE_DIRS}/META-INF/MANIFEST.MF" || die + default -JAVA_ANT_REWRITE_CLASSPATH="yes" + # Needed for the slibtool patch + sed -i 's/configure.in/configure.ac/' configure.in || die + eautoreconf + + # There was 1 failure: + # 1) testInfoGet(org.apache.tomcat.jni.TestFile) + # java.lang.AssertionError: File test/org/apache/tomcat/jni/TestFile.java does not exist! + # at org.junit.Assert.fail(Assert.java:89) + # at org.junit.Assert.assertTrue(Assert.java:42) + # at org.apache.tomcat.jni.TestFile.testInfoGet(TestFile.java:29) + # + # FAILURES!!! + # Tests run: 1, Failures: 1 + rm ../test/org/apache/tomcat/jni/TestFile.java || die +} src_configure() { local myeconfargs=( --with-apr="${EPREFIX}"/usr/bin/apr-1-config --with-ssl="${EPREFIX}"/usr ) - - cd native || die econf "${myeconfargs[@]}" } src_compile() { - eant jar - - cd native || die + java-pkg-simple_src_compile default } -src_install() { - java-pkg_newjar "dist/${P}.jar" "${PN}.jar" - - cd native || die - default - - ! use static-libs && find "${D}" -name '*.la' -delete || die +src_test() { + JAVA_TEST_EXTRA_ARGS=( -Djava.library.path=".libs" ) +# jar cf test.jar ../test/org/apache/tomcat/jni/TestFile.java || die +# JAVA_GENTOO_CLASSPATH_EXTRA="test.jar" + java-pkg-simple_src_test } -src_test() { - java-pkg-2_src_test +src_install() { + java-pkg-simple_src_install + java-pkg_doso .libs/*.so* + dodoc -r ../docs + ! use static-libs && find "${D}" -name '*.la' -delete || die } pkg_postinst() {