blob: 0bb21854e881ffa86b10d97ad1ab2a84b23dfb57 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
JAVA_PKG_IUSE="doc examples source test"
inherit java-pkg-2 java-ant-2
DESCRIPTION="Ant-tasks to compile various source languages and produce executables"
HOMEPAGE="http://ant-contrib.sourceforge.net/"
SRC_URI="mirror://sourceforge/ant-contrib/ant-contrib/${P/_/-}/${P/_beta/b}.tar.gz"
S="${WORKDIR}/${P/_beta/b}"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~x86"
CP_DEPEND="
dev-java/ant-core:0
dev-java/xerces:2
"
DEPEND="
>=virtual/jdk-1.8:*
${CP_DEPEND}
test? (
dev-java/ant-junit:0
dev-java/junit:0
)
"
RDEPEND="
>=virtual/jre-1.8:*
${CP_DEPEND}
"
JAVA_ANT_REWRITE_CLASSPATH="yes"
JAVA_ANT_CLASSPATH_TAGS="javac javadoc"
EANT_BUILD_TARGET="jars"
EANT_TEST_TARGET="run-tests -Djunit-available=true"
EANT_DOC_TARGET="javadocs -Dbuild.javadocs=build/api"
src_prepare() {
java-pkg_clean
use test && eapply "${FILESDIR}/${P}-test-classpath.patch"
java-pkg-2_src_prepare
}
src_test() {
java-pkg-2_src_test
}
src_install() {
java-pkg_dojar target/lib/${PN}.jar
java-pkg_register-ant-task
dodoc NOTICE
use doc && java-pkg_dojavadoc build/api
use examples && java-pkg_doexamples src/samples/*
use source && java-pkg_dosrc src/main/java/*
}
|