# $Id: Portfile,v 1.4 2005/04/19 18:15:08 jberry Exp $

PortSystem 1.0

name			jfreechart
version			1.0.0-pre2
categories		java graphics
platforms		darwin
maintainers		mww@opendarwin.org
description		JFreeChart is a free Java class library for generating charts.
long_description	${description}

homepage		http://www.jfree.org/jfreechart/
master_sites	sourceforge
checksums		md5 60c284085ffaa9c077215b8cfff91d52

depends_build	bin:ant:apache-ant
depends_lib		bin:java:kaffe \
				port:junit \
				port:servlet24-api

extract.post_args	"| tar -xf - --exclude 'junit.jar' --exclude 'servlet.jar'"
post-extract {
	file link ${worksrcpath}/lib/junit.jar ${prefix}/share/java/junit.jar
	file link ${worksrcpath}/lib/servlet.jar \
		${prefix}/share/java/servlet24-api.jar
}

use_configure	no

build.dir		${worksrcpath}/ant
build.cmd		ant
build.target	all

destroot {
	xinstall -m 755 -d ${destroot}${prefix}/share/java/ \
		${destroot}${prefix}/share/doc/
	xinstall -m 644 ${worksrcpath}/jfreechart-${version}.jar \
		${destroot}${prefix}/share/java/jfreechart.jar
	file copy ${worksrcpath}/javadoc ${destroot}${prefix}/share/doc/${name}
}
