diff options
author | Shackra Sislock <jorgean@lavabit.com> | 2013-07-04 21:52:02 -0600 |
---|---|---|
committer | Shackra Sislock <jorgean@lavabit.com> | 2013-07-04 21:52:02 -0600 |
commit | cd298e9e8d80d387472058ff4b089f0ee509d644 (patch) | |
tree | d00e711db4fa42f10698791204a1e64ba5611f3c /java/junit/PKGBUILD | |
parent | 64e1664807a6e37d4fdfc35d271028104b54c4a1 (diff) | |
parent | 91bd98130ae07e48bd945b0b87e51a117c29ad6f (diff) | |
download | abslibre-cd298e9e8d80d387472058ff4b089f0ee509d644.tar.gz abslibre-cd298e9e8d80d387472058ff4b089f0ee509d644.tar.bz2 abslibre-cd298e9e8d80d387472058ff4b089f0ee509d644.zip |
updating my branches
Diffstat (limited to 'java/junit/PKGBUILD')
-rw-r--r-- | java/junit/PKGBUILD | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/java/junit/PKGBUILD b/java/junit/PKGBUILD new file mode 100644 index 000000000..5e466a029 --- /dev/null +++ b/java/junit/PKGBUILD @@ -0,0 +1,53 @@ +# Maintainer: Luke Shumaker <lukeshu@sbcglobal.net> +# Maintainer (Arch): Guillaume ALAUX <Guillaume at Arch Linux dot org> + +pkgname=junit +pkgver=4.11 +pkgdesc="Automated testing framework for Java" +url="http://www.junit.org/" +license=('CPL') + +pkgrel=3.1 +arch=('any') +depends=('java-runtime' 'java-hamcrest') +makedepends=('apache-ant' 'jakarta-oro' 'jh') + +source=("libre://$pkgname-$pkgver.tar.gz") +md5sums=('47c8879e05effb2ab98461c43243cc65') + +mksource=("$pkgname::git://github.com/junit-team/junit.git#tag=r$pkgver") +mkmd5sums=('SKIP') +mksource() { + cd "${srcdir}"p + if [[ -d $pkgname ]]; then + rm -rf "$pkgname"-* + mv "$pkgname" "$pkgname-$pkgver" + fi + + cd "${pkgname}-${pkgver}" + find . -name '*.jar' -delete +} + +build() { + cd "${srcdir}/${pkgname}-${pkgver}" + + ln -sf /usr/share/java/jakarta-oro.jar build/lib/ + ln -sf /usr/share/java/hamcrest-core.jar lib/hamcrest-core-1.3.jar + + ant -Dversion-status='' jars + for artifact in junit junit-dep; do + sed \ + -e "s|@artifactID@|$artifact|" \ + -e "s|@version@|$pkgver|" \ + < build/maven/$artifact-pom-template.xml > $pkgname$pkgver/$artifact-$pkgver.pom + done +} + +package() { + cd "${srcdir}/${pkgname}-${pkgver}/${pkgname}${pkgver}" + + export DESTDIR="$pkgdir" + jh mvn-install $pkgname junit $pkgver junit-$pkgver.{pom,jar} junit-$pkgver.jar + jh mvn-install $pkgname junit-dep $pkgver junit-dep-$pkgver.pom + ln -s ${pkgname}-${pkgver}.jar ${pkgdir}/usr/share/java/${pkgname}.jar +} |