# $Id: Portfile 72252 2010-10-08 23:20:28Z jberry@macports.org $

PortSystem 1.0

name				commons-cli
version				1.1
revision			1

categories			java
maintainers			nomaintainer
platforms			darwin

description			Jakarta Commons-CLI
long_description	The Jakarta Commons CLI library provides an API for \
					processing command line interfaces. It was formed by \
					the merger of ideas and code from three different \
					libraries - Werken, Avalon and Optz. 
homepage			http://commons.apache.org/cli/
				
distname			${name}-${version}-src
master_sites		apache:commons/cli/source/
checksums			md5 ccc1aa194132e2387557bbb7f65391f4

depends_build		port:apache-ant

depends_lib			bin:java:kaffe \
					port:commons-logging \
					port:commons-lang \
					port:junit

use_configure		no

build.env			CLASSPATH=${prefix}/share/java/commons-logging.jar:${prefix}/share/java/commons-lang.jar:${prefix}/share/java/junit.jar
build.cmd			ant
build.target        dist
build.args          -Dfinal.name=${name} -Djunit.jar=${prefix}/share/java/junit.jar

destroot	{
	xinstall -m 755 -d ${destroot}${prefix}/share/java ${destroot}${prefix}/share/doc
	xinstall -m 644 ${worksrcpath}/dist/${name}.jar ${destroot}${prefix}/share/java/
	file copy ${worksrcpath}/dist/docs ${destroot}${prefix}/share/doc/${name}
}

livecheck.type  regex
livecheck.url   http://commons.apache.org/downloads/download_cli.cgi
livecheck.regex "cli-(\\d+\\.\\d+(\\.\\d+)?)-src.tar.gz"
