# -*- 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                   python 1.0

name                        py-rpncalc
set my_name                 rpncalc
version                     2.7
platforms                   {darwin any}
maintainers                 ryandesign openmaintainer
license                     GPL-2+
homepage                    http://calcrpnpy.sourceforge.net/
master_sites                sourceforge:project/calcrpnpy/rpncalc/rpncalc-${version}

description                 an interpreter for Reverse Polish Notation (RPN) \
                            that easily integrates with the standard Python \
                            interpreter

long_description            ${my_name} is ${description}.

distname                    ${my_name}-${version}

checksums                   md5     92ab71d027e50097505b68fda7341f51 \
                            sha1    f81c5053854c184e6700e2fa2ed9c2a46c72ce2f \
                            rmd160  b7d7f5ae3489e76b8025b6691e0f9785339a1944

supported_archs             noarch

python.versions             26

if {$subport ne $name} {
    depends_run-append          port:py${python.version}-clnum

    post-destroot {
        set docdir ${destroot}${prefix}/share/doc/${subport}
        xinstall -d ${docdir} ${destroot}${prefix}/share/examples
        xinstall -W ${worksrcpath} \
            COPYING \
            UserManual.html \
            changelog \
            ${docdir}
        copy ${worksrcpath}/examples ${destroot}${prefix}/share/examples/${subport}
    }
    livecheck.type              none
} else {
    livecheck.regex             /${my_name}-(\[0-9.\]+)${extract.suffix}
}