# $Id: Portfile 102584 2013-02-05 04:25:13Z larryv@macports.org $

PortSystem 1.0
PortGroup python 1.0

name			py-numarray
version			1.5.2
categories-append	devel math
license			BSD
platforms		darwin
maintainers		nomaintainer
description		array manipulation and computational library for python
long_description	Numarray provides array manipulation and computational \
				capabilities similar to those found in IDL, Matlab, or \
				Octave. Using numarray, it is possible to write many \
				efficient numerical data processing applications \
				directly in Python without using any C, C++ or Fortran \
				code.

homepage		http://www.stsci.edu/resources/software_hardware/numarray
master_sites	sourceforge:numpy
distname		numarray-${version}
checksums		sha1 17f6c4bb5f0d97e93923b8ca4f55fccc1ee985e9

python.versions	24 25 26

if {$subport != $name} {
    # numarray does not understand setup.py --no-user-cfg from PortGroup
    build.cmd		${python.bin} setup.py
    build.args		--gencode
    destroot.cmd	${python.bin} setup.py

    variant smp description {Specify this to try to exploit multiple processors. A work in progress ...} {
        build.args-append		--smp
        destroot.args-append	--smp
    }

    post-destroot {
        xinstall -m 644 -W ${worksrcpath} Doc/Announce.txt \
            Doc/Repackaging.txt Doc/INSTALL.txt Doc/Design.txt \
            Doc/UsersGuide.txt LICENSE.txt README.txt \
            ${destroot}${prefix}/share/doc/${subport}
        file delete ${destroot}${prefix}/share/doc/${subport}/examples
        file copy ${worksrcpath}/Examples \
            ${destroot}${prefix}/share/doc/${subport}/examples
    }
    livecheck.type none
} else {
    livecheck.regex "<title>Old Numarray (.*) released.*</title>"
}
