Fetching contributors…
Cannot retrieve contributors at this time
70 lines (53 sloc) 2.03 KB
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
PortSystem 1.0
PortGroup java 1.0
name junit
version 4.6
revision 2
categories java devel
license CPL-1
platforms darwin
maintainers nomaintainer
supported_archs noarch
description Java framework for repeatable tests
long_description \
JUnit is a simple framework to write repeatable tests. \
It is an instance of the xUnit architecture for unit \
testing frameworks.
master_sites sourceforge:project/junit/junit/${version}
distname ${name}${version}
use_zip yes
checksums md5 2e59ed558001fd3b10d2146189167ff5 \
sha1 98c8c625e999f0c7463397a684a5c47a0ea106e3 \
rmd160 4f87024e91b7252af89ad925db5cda0e17128525
patchfiles patch-build.xml.diff \ \
post-extract {
file mkdir ${worksrcpath}/src/main/java
system "cd ${worksrcpath}/src/main/java && jar xvf ${worksrcpath}/${name}-${version}-src.jar"
depends_build bin:ant:apache-ant
depends_lib port:hamcrest-core
use_configure no
build.cmd ant build
build.args -Dprefix=${prefix} \
-Dtestsrc=org/junit/tests \
set docdir ${prefix}/share/doc/${name}-${version}
set javadir ${prefix}/share/java
set junitpkg junit.jar
destroot {
system "jar cvf ${worksrcpath}/${junitpkg} -C ${worksrcpath}/target/main ."
xinstall -d ${destroot}${javadir} ${destroot}${docdir}
xinstall -m 0644 ${worksrcpath}/${junitpkg} ${destroot}${javadir}
copy ${worksrcpath}/doc ${destroot}${docdir}/html
variant doc description {Install extra documentation} { javadoc
post-destroot {
file copy ${worksrcpath}/javadoc ${destroot}${docdir}/