# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4

PortSystem          1.0
PortGroup           texlive 1.0

name                tex-whizzytex
version             1.3.6
categories          tex
license             GPL-2+
platforms           any
supported_archs     noarch
maintainers         nomaintainer

description         An emacs minor mode for incremental viewing of LaTeX documents
long_description    {*}${description}

homepage            http://cristal.inria.fr/whizzytex
master_sites        ${homepage}
distname            whizzytex-${version}
extract.suffix      .tgz

checksums           rmd160 6dd96e7363608e98c70c1a18405dc77da45bb503 \
                    sha256 e128d36b253ec0c59f1a0321adaeba75b6ade5833060501878a9decf23a766e0

depends_lib         bin:tex:texlive

configure.pre_args  -prefix ${prefix}
configure.args      -initex \"latex -ini\"

# disable viewer test (needs X server)
build.env           DISPLAY=

post-destroot {
    xinstall -d ${destroot}${texlive_texmfports}/tex/latex/whizzytex
    ln -s ${prefix}/share/whizzytex/latex/whizzytex.sty \
        ${destroot}${texlive_texmfports}/tex/latex/whizzytex/
}

post-activate   {
    system "mktexlsr"
}

notes "WhizzyTex requires a viewer, like xdvi.\
    To use this, put the following into your ~/.emacs:
(add-to-list 'load-path \"${prefix}/share/whizzytex/emacs/\")
(autoload 'whizzytex-mode
\"whizzytex\"
\"WhizzyTeX, a minor-mode WYSIWIG environment for LaTeX\" t)"

livecheck.url       ${homepage}
livecheck.regex     {whizzytex-((\d+(\.)*)+)\.tgz}
