# -*- 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
# $Id: Portfile 65065 2010-03-20 22:16:24Z macsforever2000@macports.org $

PortSystem          1.0

name                frobtads
version             0.13
categories          games
maintainers         josephholsten.com:joseph
description         FrobTADS is a new version of TADS for Unix
long_description    FrobTADS is a complete rewrite of the Unix version. It \
adds support for a number of relatively recent TADS features that were \
missing from the old Unix version, including full support for text and \
background colors, TADS 3 banners, and timed input. It's also much more \
portable and more easily maintainable, as it's built to modern Unix \
standards. And installing FrobTADS is greatly simplified compared to the old \
Unix port, thanks to automatic configuration.
homepage            http://www.tads.org/frobtads.htm

platforms           darwin freebsd
master_sites        http://www.tads.org/frobtads/
checksums           ${distname}${extract.suffix} \
                    md5 b6f25787b9ff7b89931d765046c68642 \
                    sha1 2a03ebba5a0332dda6e2413ff950b9c079437f96 \
                    rmd160 016c2d0af44560802d8ed8822b4599af1d68e20f

depends_lib         port:ncurses

configure.cxxflags-append -fno-strict-aliasing

variant tads3 description {Adds TADS3 Compiler} {
    set tads3file ${name}-t3compiler-${version}${extract.suffix}
    distfiles-append    ${tads3file}
    
    checksums-append    ${tads3file} \
                        md5 231d359f389be3d28e8134a2b832dd70 \
                        sha1 1c46bf86ae19297fadb2e95fdf621489b5a7465a \
                        rmd160 df2bbe12c3a28ffea1f0eb132d72879f2218a48b

    extract.only-delete ${tads3file}
    post-extract    {
        set tads3file ${name}-t3compiler-${version}${extract.suffix}
        system "tar xfz ${distpath}/${tads3file} -C ${worksrcpath}"
    }
}
