# $Id: Portfile 86500 2011-10-26 21:42:58Z jmr@macports.org $

PortSystem 1.0

name           		jakarta-regexp
version         	1.5

categories      	java
license         	Apache-2
maintainers     	nomaintainer
platforms       	darwin

description     	Jakarta Regular Expressions Parser.
long_description	Jakarta Regexp is a 100% Pure Java Regular Expression package.
homepage			http://jakarta.apache.org/regexp/
				
master_sites    	apache:jakarta/regexp/source

checksums           md5     b941b8f4de297827f3211c2cb34af199 \
                    sha1    a8c98ac37e2a34dd39fca1e9d4d632944ea930e1 \
                    rmd160  46bca47c9e83e6fb1a6d488f5ae5cbfa87f48401

depends_build		bin:ant:apache-ant
depends_lib			bin:java:kaffe

post-extract {
	file mkdir ${workpath}/jakarta-site2/lib
	file delete ${worksrcpath}/${distname}.jar
}
					
use_configure		no

build.cmd			ant
build.target		jar
build.args			-Dfinal.name=${name}

destroot	{
	xinstall -d ${destroot}${prefix}/share/java \
		${destroot}${prefix}/share/doc/${name}
	xinstall -m 644 \
		${worksrcpath}/build/${name}.jar \
		${destroot}${prefix}/share/java/
	foreach f [glob -directory ${worksrcpath}/docs *.html api] {
		file copy $f ${destroot}${prefix}/share/doc/${name}/
	}
}

livecheck.type  regex
livecheck.url   http://apache.crihan.fr/dist/jakarta/regexp/source/
livecheck.regex {regexp-(\d+(?:\.\d+)*)}
