# -*- 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 70768 2010-08-20 18:29:56Z ryandesign@macports.org $

PortSystem              1.0

name                    base91
version                 0.6.0
categories              mail
platforms               darwin
maintainers             polyphase.ca:alan.macports.sp
license                 BSD

description             Encode and decode base91 files

long_description        basE91 is an advanced method for encoding binary \
                        data as ASCII characters. It is similar to UUencode \
                        or base64, but is more efficient. The overhead \
                        produced by basE91 depends on the input data. It \
                        amounts at most to 23% (versus 33% for base64) and \
                        can range down to 14%, which typically occurs on \
                        0-byte blocks. This makes basE91 very useful for \
                        transferring larger files over binary insecure \
                        connections like e-mail or terminal lines.

homepage                http://base91.sourceforge.net/
master_sites            sourceforge

checksums               md5     e227841d900cc463a162bd79775aeb54 \
                        sha1    00cfd573ec8b3d0160dbf53e2c7a49b99a1aa720 \
                        rmd160  62ddd00e3a3dd261e7f19a6caddbec86d33146e1

use_configure           no

variant universal {}
if {[variant_isset universal]} {
    set archflags ${configure.universal_cflags}
} else {
    set archflags ${configure.cc_archflags}
}

build.args              prefix=${prefix} \
                        CC="${configure.cc}" \
                        CFLAGS="${configure.cflags} ${archflags}" \
                        LDFLAGS="${configure.ldflags} ${archflags}"

destroot.args           prefix=${prefix}
destroot.destdir        DESTDIR=${destroot}

post-destroot {
    set docdir ${destroot}${prefix}/share/doc/${name}
    xinstall -d ${docdir}
    xinstall -m 644 -W ${worksrcpath} \
        LICENSE \
        NEWS \
        README \
        ${docdir}
}
