# $Id: Portfile,v 1.4 2005/03/08 08:26:43 blb Exp $

PortSystem			1.0
PortGroup			python24 1.0
name				py-texml
version				1.20
revision			1
categories-append	textproc
maintainers			darwinports@opendarwin.org
description			XML vocabulary for TeX
long_description \
	TeXML is an XML vocabulary for TeX.  The processor transforms TeXML \
	markup into the TeX markup, escaping special and out-of-encoding \
	characters.  The intended audience is developers who automatically \
	generate TeX files.

platforms			darwin

homepage			http://getfo.sourceforge.net/texml/
master_sites		sourceforge:getfo
distname			texml.${version}-unix
worksrcdir			texml.${version}

checksums			md5 b13ac128ec70173fa41d972816c23150

post-patch {
	reinplace "s|#!/usr/bin/python|#!${prefix}/bin/python|" \
		${worksrcpath}/bin/texml.py
}

build				{}

destroot {
	xinstall -m 755 -d ${destroot}/${prefix}/share/${name}
	eval file copy [glob ${worksrcpath}/bin/*] \
		${destroot}/${prefix}/share/${name}
	system "ln -s ${prefix}/share/${name}/texml.py \
		${destroot}/${prefix}/bin/texml.py"
	file copy ${worksrcpath}/dtd ${destroot}/${prefix}/share/${name}
	file copy ${worksrcpath}/tests ${destroot}/${prefix}/share/${name}
	xinstall -m 644 -W ${worksrcpath} ChangeLog.txt license.txt readme.txt \
		${destroot}/${prefix}/share/doc/${name}
	eval file copy [glob ${worksrcpath}/docs/*] \
		${destroot}/${prefix}/share/doc/${name}
}

