Gentoo Archives: gentoo-commits

From: Florian Schmaus <flow@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-java/ant-eclipse-ecj/files/, dev-java/ant-eclipse-ecj/
Date: Mon, 30 May 2022 08:36:14
Message-Id: 1653899764.ebf1a8c251eefb23889ac984b0b033e4957df894.flow@gentoo
1 commit: ebf1a8c251eefb23889ac984b0b033e4957df894
2 Author: Volkmar W. Pogatzki <gentoo <AT> pogatzki <DOT> net>
3 AuthorDate: Sun May 15 11:27:40 2022 +0000
4 Commit: Florian Schmaus <flow <AT> gentoo <DOT> org>
5 CommitDate: Mon May 30 08:36:04 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ebf1a8c2
7
8 dev-java/ant-eclipse-ecj: virtual/jdk-11:*" -> -17:*
9
10 Bug: https://bugs.gentoo.org/831559
11 Signed-off-by: Volkmar W. Pogatzki <gentoo <AT> pogatzki.net>
12 Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>
13
14 .../ant-eclipse-ecj/ant-eclipse-ecj-4.22-r1.ebuild | 53 ++++++++++++++++++++++
15 dev-java/ant-eclipse-ecj/files/ecj-4.22-r1 | 7 +++
16 2 files changed, 60 insertions(+)
17
18 diff --git a/dev-java/ant-eclipse-ecj/ant-eclipse-ecj-4.22-r1.ebuild b/dev-java/ant-eclipse-ecj/ant-eclipse-ecj-4.22-r1.ebuild
19 new file mode 100644
20 index 000000000000..786880f955b6
21 --- /dev/null
22 +++ b/dev-java/ant-eclipse-ecj/ant-eclipse-ecj-4.22-r1.ebuild
23 @@ -0,0 +1,53 @@
24 +# Copyright 1999-2022 Gentoo Authors
25 +# Distributed under the terms of the GNU General Public License v2
26 +
27 +EAPI=8
28 +
29 +JAVA_PKG_IUSE="doc source"
30 +
31 +inherit java-pkg-2 java-pkg-simple prefix
32 +
33 +DMF="R-${PV}-202111241800"
34 +
35 +DESCRIPTION="Ant Compiler Adapter for Eclipse Java Compiler"
36 +HOMEPAGE="https://www.eclipse.org/"
37 +SRC_URI="https://download.eclipse.org/eclipse/downloads/drops4/${DMF}/ecjsrc-${PV}.jar"
38 +
39 +LICENSE="EPL-1.0"
40 +KEYWORDS="~amd64 ~ppc64 ~x86 ~amd64-linux ~x86-linux ~x86-solaris"
41 +SLOT="4.22"
42 +IUSE=""
43 +
44 +CDEPEND="~dev-java/eclipse-ecj-${PV}:${SLOT}
45 + dev-java/ant-core:0"
46 +# though technically both could be set to 1.8 and it would
47 +# compile using jdk 11+, it would not compile using jdk 1.8
48 +# because eclipse ecj has min jdk 11
49 +RDEPEND="${CDEPEND}
50 + >=virtual/jre-11:*"
51 +DEPEND="${CDEPEND}
52 + >=virtual/jdk-17:*"
53 +BDEPEND="app-arch/unzip"
54 +
55 +JAVA_GENTOO_CLASSPATH="ant-core,eclipse-ecj-${SLOT}"
56 +
57 +src_prepare() {
58 + default
59 +
60 + # Remove everything but the Ant component.
61 + find org -type f ! -path "org/eclipse/jdt/internal/antadapter/*" ! -name "JDTCompilerAdapter.java" -delete || die
62 +
63 + rm build.xml || die
64 +}
65 +
66 +src_compile() {
67 + java-pkg-simple_src_compile
68 + find org -type f ! -name "*.java" | xargs jar uvf "${PN}.jar" || die "jar update failed"
69 +}
70 +
71 +src_install() {
72 + java-pkg-simple_src_install
73 + insinto /usr/share/java-config-2/compiler
74 + doins "${FILESDIR}/ecj-${SLOT}"
75 + eprefixify "${ED}"/usr/share/java-config-2/compiler/ecj-${SLOT}
76 +}
77
78 diff --git a/dev-java/ant-eclipse-ecj/files/ecj-4.22-r1 b/dev-java/ant-eclipse-ecj/files/ecj-4.22-r1
79 new file mode 100644
80 index 000000000000..5bbcc318d9ba
81 --- /dev/null
82 +++ b/dev-java/ant-eclipse-ecj/files/ecj-4.22-r1
83 @@ -0,0 +1,7 @@
84 +JAVAC="@GENTOO_PORTAGE_EPREFIX@/usr/bin/ecj-4.22"
85 +PACKAGE="=dev-java/ant-eclipse-ecj-4.21*"
86 +SUPPORTED_TARGET="1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 9 10 11 12 13 14 15 16 17"
87 +SUPPORTED_SOURCE="1.3 1.4 1.5 1.6 1.7 1.8 9 10 11 12 13 14 15 16 17"
88 +ANT_BUILD_COMPILER="org.eclipse.jdt.core.JDTCompilerAdapter"
89 +ANT_BUILD_COMPILER_DEPS="eclipse-ecj-4.22,ant-eclipse-ecj-4.22"
90 +GENERATION="2"