1 # Copyright 1999-2014 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
7 # Tests are currently broken due to nasty -lib argument.
8 JAVA_PKG_IUSE="doc source" # test
10 inherit java-pkg-2 java-ant-2 java-osgi
15 DESCRIPTION="Lightweight, self-contained mathematics and statistics components"
16 HOMEPAGE="http://commons.apache.org/math/"
17 SRC_URI="mirror://apache/commons/math/source/${MY_P}-src.tar.gz"
23 DEPEND=">=virtual/jdk-1.5"
25 # Tests are currently broken due to nasty -lib argument.
28 # dev-java/hamcrest-core:0
31 RDEPEND=">=virtual/jre-1.5"
33 S="${WORKDIR}/${MY_P}-src"
36 cp "${FILESDIR}"/${P}-build.xml build.xml || die
38 sed -i 's/manifest=".*MANIFEST.MF"//g' build.xml || die
39 sed -i '/name="Main-Class"/d' build.xml || die
42 # Tests are currently broken due to nasty -lib argument.
44 # java-pkg_jar-from junit-4
45 # java-pkg_jar-from hamcrest-core
46 # ANT_TASKS="ant-junit4" eant -Djunit.jar=junit.jar test
50 java-osgi_newjar target/${MY_P}.jar ${MY_PN} ${MY_PN} "Export-Package: ${MY_PN}"
52 use doc && java-pkg_dojavadoc target/site/apidocs
53 use source && java-pkg_dosrc src/main/java/org