# -*- 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 51040 2009-05-16 18:16:59Z raimue@macports.org $

PortSystem          1.0

name                frobtads
version             0.12
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 bc7402a65ad52547b5754ea3504cdd4b \
                    sha1 84be7fbf2d2927ad97766778f22dafe873b6284f \
                    rmd160 6e88266e922e71018145ac8534a386a800952a4a

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 240ba080b374089d1d2fa20bf95aadb9 \
                        sha1 163782295e0f512fd2aef311a40e5db6952bef51 \
                        rmd160 1f6ccf8bfcf6ef6601110be568fa9f8010fffe58

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