# -*- 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 107245 2013-06-24 03:46:33Z aronnax@macports.org $

PortSystem          1.0
PortGroup           python 1.0
PortGroup           select 1.0

set realname        pyfits

name                py-${realname}
version             3.1.2
revision            1
categories-append   science
license             BSD
platforms           darwin
maintainers         aronnax openmaintainer

# FIXME: Stealth update. Remove this line after the next upstream release.
dist_subdir         ${name}/${version}_1

python.versions     25 26 27 31 32 33

description         Python interface to FITS formatted files

long_description    PyFITS provides an interface to FITS formatted files \
                    under Python. It is useful both for interactive data \
                    analysis and for writing analysis scripts in Python \
                    using FITS files as either input or output. PyFITS is \
                    a development project of the Science Software Branch \
                    at the Space Telescope Science Institute.

homepage            http://www.stsci.edu/resources/software_hardware/${realname}
master_sites        http://pypi.python.org/packages/source/[string index ${realname} 0]/${realname}
distname            ${realname}-${version}

checksums           md5     d0f1dce1719170b0c9777bbb15bbd8b3 \
                    sha1    feec80bbd210ec86242c88f86a6acb32a062f7a2 \
                    rmd160  5230b2b8db4eebcba9e883e30877b2cd52718261

if {$subport != $name} {
    depends_lib-append  port:py${python.version}-numpy

    livecheck.type  none
} else {
    livecheck.type      regex
    livecheck.url       ${homepage}/Download
    livecheck.regex     ${realname}-(\[0-9.\]+)\\.
}
