blob: 6380f5f145b07a8ddfcbab327c533d7d7b146aff (
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
|
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-java/jmock/jmock-1.0.1.ebuild,v 1.2 2005/01/05 09:20:39 luckyduck Exp $
inherit eutils java-pkg
DESCRIPTION="Library for testing Java code using mock objects."
SRC_URI="http://dist.codehaus.org/${PN}/distributions/${P}-src.jar"
HOMEPAGE="http://jmock.codehaus.org"
LICENSE="BSD"
SLOT="1.0"
KEYWORDS="~x86 ~amd64"
IUSE="doc examples jikes"
DEPEND=">=virtual/jdk-1.4
jikes? ( >=dev-java/jikes-1.21 )
>=dev-java/ant-core-1.4"
RDEPEND=">=virtual/jre-1.4
>=dev-java/cglib-2"
src_unpack() {
jar xf ${DISTDIR}/${A}
cd ${S}
epatch ${FILESDIR}/jmock-1.0.1-buildxml.patch
cd ${S}/lib
rm -f *.jar
java-pkg_jar-from cglib-2
}
src_compile() {
local antflags="core.jar cglib.jar"
if use doc; then
antflags="${antflags} javadoc"
fi
if use jikes; then
antflags="${antflags} -Dbuild.compiler=jikes"
fi
ant ${antflags} || die "failed to build"
}
src_install() {
java-pkg_dojar build/dist/jars/*.jar
dodoc CHANGELOG VERSION LICENSE.txt
if use doc; then
java-pkg_dohtml -r build/javadoc-${PV}/*
fi
if use examples; then
dodir /usr/share/doc/${PF}/examples
cp -r examples/* ${D}/usr/share/doc/${PF}/examples
fi
}
|