# $Id: Portfile 90526 2012-03-08 07:52:44Z jeremyhu@macports.org $

PortSystem 1.0

name            xorg-libXtst
version         1.2.1
categories      x11 devel
license         X11
maintainers     jeremyhu openmaintainer
description     X.org libXt
homepage        http://www.x.org
platforms       darwin macosx
long_description X.org libXtst library.
master_sites     xorg:individual/lib/

distname    libXtst-${version}
checksums           sha1    44e19899f9938d3db5546e51c338d6f86d88cfe2 \
                    rmd160  2e41994b87fe6c77345990255545b1d140b46206 \
                    sha256  7eea3e66e392aca3f9dad6238198753c28e1c32fa4903cbb7739607a2504e5e0

use_bzip2   yes
use_parallel_build      yes

depends_build   port:pkgconfig

depends_lib     port:xorg-libXext \
                port:xorg-libXi \
                port:xorg-recordproto

configure.args \
	--without-xmlto \
	--without-fop \
	--disable-specs

build.args V=1

# Depending on ghostscript for the PDF documentation creates a dependency
# loop, so you may want to install first without the docs variant
variant docs description "Install extra documentation" {
	depends_build-append \
		port:fop \
		port:xmlto \
		port:xorg-sgml-doctools

	depends_skip_archcheck-append \
		xmlto

	configure.args-delete \
		--without-xmlto \
		--without-fop \
		--disable-specs

	configure.args-append \
		--with-xmlto \
		--with-fop \
		--enable-specs

	configure.env-append \
		XMLTO="${prefix}/bin/xmlto" \
		FOP="${prefix}/bin/fop"
}

livecheck.type  regex
livecheck.url   http://xorg.freedesktop.org/archive/individual/lib/?C=M&O=D
livecheck.regex libXtst-(\\d+(?:\\.\\d+)*)
