# $Id: Portfile 57375 2009-09-10 08:16:41Z ryandesign@macports.org $

PortSystem      1.0
PortGroup       python25 1.0

name            py25-numeric
set my_name     Numeric
version         24.2
revision        1
categories-append   devel math
platforms		darwin
maintainers     nomaintainer
description     fast numerical array language for python

long_description \
    Numerical Python adds a fast, compact, \
	multidimensional array language facility to Python.

homepage        http://numpy.scipy.org/
master_sites    sourceforge:numpy \
                freebsd 
distname        ${my_name}-${version}

checksums       md5 2ae672656e06716a149acb048cca3093 \
                sha1 72869ef80c12630a9a125ba10c96093b6ae16aff \
                rmd160 c9502db28663558c535e236392c9beddec9743bb

patchfiles      patch-ranf.c

build.env CC=${configure.cc}

platform macosx {
    post-patch {
        copy -force ${filespath}/customize.py-macosx ${worksrcpath}/customize.py
    }
}

platform puredarwin {
    post-patch {
        copy -force ${filespath}/customize.py-puredarwin ${worksrcpath}/customize.py
    }
}

test.run        yes
test.env        PYTHONPATH=[glob -nocomplain ${worksrcpath}/build/lib*]
test.cmd        ${python.bin} Test/test.py
test.target


post-destroot {
    set docdir ${prefix}/share/doc/${name}-${version}

    eval xinstall -d \
        ${destroot}${docdir}/dotblas \
        ${destroot}${docdir}/MA \
        ${destroot}${docdir}/RNG

    xinstall -W ${worksrcpath} README changes.txt \
        ${destroot}${docdir}

    xinstall -m 0644 ${worksrcpath}/Packages/dotblas/doc/README.html \
        ${destroot}${docdir}/dotblas

    xinstall -m 0644 -W ${worksrcpath}/Packages/MA Legal.htm changes.txt \
        ${destroot}${docdir}/MA

    xinstall -m 0644 ${worksrcpath}/Packages/RNG/Legal.htm \
        ${destroot}${docdir}/RNG

    copy ${worksrcpath}/Demo ${destroot}${docdir}
    copy ${worksrcpath}/Packages/MA/Demo ${destroot}${docdir}/MA
}

livecheck.type   none
