Portfile

# $Id: Portfile 20412 2006-11-03 02:14:55Z jberry@macports.org $

PortSystem 1.0
name tin-devel
version 1.7.10
revision 1
categories news
platforms darwin
maintainers nomaintainer@macports.org
homepage http://www.tin.org/
description A threaded NNTP and spool based UseNet newsreader

long_description tin is a full-screen easy to use Usenet reader. It can read news \
locally or remotely via a NNTP (Network News Transport Protocol) \
server. It will automatically utilize NOV (News OVerview) style \
index files if available locally or via the NNTP XOVER command.

master_sites ftp://ftp.tin.org/tin/v1.7/ \
ftp://ftp.cuhk.edu.hk/pub/packages/news/tin/v1.7/ \
ftp://ftp.stikman.com/pub/tin/v1.7/

use_bzip2 yes

checksums md5 23473a665d6d39ed4463b77d227cbb28

distname tin-${version}

configure.args --enable-break-long-lines \
--enable-nntp \
--enable-debug \
--enable-mh-mail-handling \
--enable-included-msgs \
--with-coffee \
--mandir=${prefix}/share/man \
--infodir=${prefix}/share/info \
--datadir=${prefix}/share \
--sysconfdir=${prefix}/etc \
--disable-pgp-gpg


build.dir "${worksrcpath}/src"

pre-destroot { file mkdir "${destroot}${prefix}/share/doc/${name}"
file mkdir "${destroot}${prefix}/etc/${name}"
xinstall -m 644 -v -W "${worksrcpath}/doc" \
auth.txt CHANGES config-anomalies \
filtering good-netkeeping-seal iso2asc.txt \
keymap.sample mailcap.sample pgp.txt \
reading-mail.txt TODO umlaute.txt umlauts.txt \
WHATSNEW \
"${destroot}${prefix}/share/doc/${name}"
file copy "${worksrcpath}/doc/tin.defaults" \
"${destroot}${prefix}/etc/${name}"
}

post-destroot { xinstall -m 755 -v -W "${worksrcpath}/tools" \
expiretover tinews.pl tinlock \
"${destroot}${prefix}/bin"
}

variant ipv6 { configure.args-append --enable-ipv6 }

variant gpg { depends_run bin:gpg:gnupg
configure.args-delete --disable-pgp-gpg
configure.args-append --with-gpg=${prefix}/bin/gpg \
--without-pgp \
--without-pgpk
}

variant pgp5 { depends_run bin:pgpk:pgp
configure.args-delete --disable-pgp-gpg
configure.args-append --with-pgpk=${prefix}/bin/pgpk \
--without-gpg \
--without-pgp
}

variant ncurses { configure.args-append --with-screen=ncurses }

variant ispell { depends_build bin:ispell:ispell
configure.args-append --enable-ispell
}