#!/bin/bash

PKG=numpy

pushd ../SOURCES
if [ ! -e numpy ]; then
    git clone git://github.com/numpy/numpy.git
else
    pushd numpy
    git pull
    popd numpy
fi
popd # ../SOURCES

function version() {
    rm -rf $PKG
    cp -r ../SOURCES/$PKG .
    pushd $PKG
    if [ -f /etc/gentoo-release ]; then
        cat >site.cfg <<EOF
[atlas]
atlas_libs = lapack, blas, cblas, atlas
EOF
    fi
    $1 setup.py build --force 
    $1 setup.py install
    popd # $PKG
}

pushd ../BUILD
version python2.5
version python2.6
version python2.7
version python3.1
version python3.2
popd # ../BUILD

# Local Variables: ***
# mode: sh ***
# End: ***
