summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVolkmar W. Pogatzki <gentoo@pogatzki.net>2022-01-23 00:14:59 +0100
committerMiroslav Šulc <fordfrog@gentoo.org>2022-01-26 09:38:24 +0100
commit3f3b4b6110086b11bf2b7681aae7b0c5f9a9780b (patch)
treec9db2189b36c7cee5fb397b783127ff2db88424f /dev-java/javax-mail
parentdev-python/numpy: Remove old (diff)
downloadgentoo-3f3b4b6110086b11bf2b7681aae7b0c5f9a9780b.tar.gz
gentoo-3f3b4b6110086b11bf2b7681aae7b0c5f9a9780b.tar.bz2
gentoo-3f3b4b6110086b11bf2b7681aae7b0c5f9a9780b.zip
dev-java/javax-mail: new package
Needed for dev-java/log4j-core-2.17.1 Package name to reflect artifactId 'javax.mail'. Reserve 'javamail' for the source tarball containing more artifacts. Package-Manager: Portage-3.0.28, Repoman-3.0.3 Signed-off-by: Volkmar W. Pogatzki <gentoo@pogatzki.net> Closes: https://github.com/gentoo/gentoo/pull/23930 Signed-off-by: Miroslav Šulc <fordfrog@gentoo.org>
Diffstat (limited to 'dev-java/javax-mail')
-rw-r--r--dev-java/javax-mail/Manifest1
-rw-r--r--dev-java/javax-mail/javax-mail-1.6.2.ebuild83
-rw-r--r--dev-java/javax-mail/metadata.xml7
3 files changed, 91 insertions, 0 deletions
diff --git a/dev-java/javax-mail/Manifest b/dev-java/javax-mail/Manifest
new file mode 100644
index 000000000000..23cb84a4759c
--- /dev/null
+++ b/dev-java/javax-mail/Manifest
@@ -0,0 +1 @@
+DIST JAVAMAIL-1_6_2.tar.gz 1107140 BLAKE2B c0f84bad014af1146bc2bb7f4f58924edf8f6762c222f979d1fec787e8dc93861691cd95c23eb663924597277607d2ce5058c232ad1e8626ed2d0f1e17c34a98 SHA512 6c07490fabbcf5969a2d8946bd9f38187cd33b864985e8183f15d9e1ba1508e445f2050633d9054f9ad546fede7790e64d31956bf23eb2ff8dae45129bd43534
diff --git a/dev-java/javax-mail/javax-mail-1.6.2.ebuild b/dev-java/javax-mail/javax-mail-1.6.2.ebuild
new file mode 100644
index 000000000000..864ef388d4f4
--- /dev/null
+++ b/dev-java/javax-mail/javax-mail-1.6.2.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# Skeleton command:
+# java-ebuilder --generate-ebuild --workdir . --pom mail/pom.xml --download-uri https://github.com/javaee/javamail/archive/refs/tags/JAVAMAIL-1_6_2.tar.gz --slot 0 --keywords "~amd64 ~arm ~arm64 ~ppc64 ~x86" --ebuild oracle-javamail-1.6.2.ebuild
+
+EAPI=8
+
+JAVA_PKG_IUSE="doc source test"
+MAVEN_ID="com.sun.mail:javax.mail:1.6.2"
+JAVA_TESTING_FRAMEWORKS="junit-4"
+
+inherit java-pkg-2 java-pkg-simple
+
+DESCRIPTION="JavaMail API"
+HOMEPAGE="https://javaee.github.io/javamail/"
+SRC_URI="https://github.com/javaee/javamail/archive/refs/tags/JAVAMAIL-${PV//./_}.tar.gz"
+
+LICENSE="|| ( CDDL GPL-2-with-classpath-exception )"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
+
+# No clue how to deal with ${S}/exclude.xml
+# RESTRICT="test"
+
+# Common dependencies
+# POM: mail/pom.xml
+# javax.activation:activation:1.1 -> !!!groupId-not-found!!!
+
+CP_DEPEND="
+ dev-java/jakarta-activation-api:1
+"
+
+DEPEND="${CP_DEPEND}
+ >=virtual/jdk-1.8:*"
+
+RDEPEND="${CP_DEPEND}
+ >=virtual/jre-1.8:*"
+
+DOCS=( ../{LICENSE.txt,README.md} )
+
+S="${WORKDIR}/javamail-JAVAMAIL-${PV//./_}/mail"
+
+JAVA_ENCODING="iso-8859-1"
+
+JAVA_SRC_DIR="src/main/java"
+JAVA_RESOURCE_DIRS="src/main/resources"
+
+JAVA_TEST_GENTOO_CLASSPATH="junit-4"
+JAVA_TEST_SRC_DIR="src/test/java"
+JAVA_TEST_RESOURCE_DIRS="src/test/resources"
+
+src_prepare() {
+ default
+ mv src/main/{resources,java}/javax/mail/Version.java || die
+}
+
+src_test() {
+ pushd src/test/java || die
+ # Selection according to 201,202 pom.xml
+ local JAVA_TEST_RUN_ONLY=$(find * \
+ -name "*TestSuite.java" -o -name "*Test.java" \
+ ! -name "MailHandlerTest.java" \
+ ! -name "DurationFilterTest.java" \
+ ! -name "CompactFormatterTest.java" \
+ ! -name "CollectorFormatterTest.java" \
+ ! -name "WriteTimeoutSocketTest.java" \
+ )
+ JAVA_TEST_RUN_ONLY="${JAVA_TEST_RUN_ONLY//.java}"
+ JAVA_TEST_RUN_ONLY="${JAVA_TEST_RUN_ONLY//\//.}"
+ popd
+
+ # With higher Java versions tests run forever.
+ local vm_version="$(java-config -g PROVIDES_VERSION)"
+ if [[ "${vm_version}" == "1.8" ]] ; then
+ java-pkg-simple_src_test
+ fi
+}
+
+src_install() {
+ default # https://bugs.gentoo.org/789582
+ java-pkg-simple_src_install
+}
diff --git a/dev-java/javax-mail/metadata.xml b/dev-java/javax-mail/metadata.xml
new file mode 100644
index 000000000000..75321cfb5598
--- /dev/null
+++ b/dev-java/javax-mail/metadata.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>java@gentoo.org</email>
+ </maintainer>
+</pkgmetadata>