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

PortSystem 1.0

name				woodstox
version				3.2.0

categories			java
maintainers			nomaintainer
platforms			darwin

description			Woodstox StAX XML parser
long_description	Woodstox is a fast Open Source fully-validating StAX-compliant \
					(JSR-173) XML-processor written in Java (processor meaning it \
					handles both input (== parsing) and output (== writing, serialization)).
homepage			http://woodstox.codehaus.org/

distname			wstx-src-${version}
master_sites		http://woodstox.codehaus.org/${version}/
checksums			sha1 7a88dc42ffb425d8c2d8a6a5677e7866bfc24a80

worksrcdir			.

depends_build		bin:ant:apache-ant
depends_lib			bin:java:kaffe \
					port:jakarta-bcel

use_configure		no

post-patch {
	# msv isn't one of our ports, so stub it out and disable it
	file mkdir ${worksrcpath}/lib/msv
	file delete -force ${worksrcpath}/src/java/com/ctc/wstx/msv
}

build.cmd			ant
build.target		compile jars javadoc
build.env			CLASSPATH=${prefix}/share/java/jakarta-bcel.jar

destroot	{
	xinstall -m 755 -d ${destroot}${prefix}/share/java \
		${destroot}${prefix}/share/doc/${name}
	xinstall -m 644 ${worksrcpath}/build/wstx-asl-${version}.jar \
		${destroot}${prefix}/share/java/woodstox.jar
	xinstall -m 644 ${worksrcpath}/build/wstx-api-${version}.jar \
		${destroot}${prefix}/share/java/woodstox-api.jar
	xinstall -m 644 ${worksrcpath}/build/stax2.jar \
		${destroot}${prefix}/share/java/
		
	file copy \
		${worksrcpath}/build/javadoc \
		${worksrcpath}/release-notes \
		${destroot}${prefix}/share/doc/${name}
}
