# Maintainer: Stefan Husmann # Contributor: Angel 'angvp' Velasquez # Contributor: Douglas Soares de Andrade pkgname=python-matplotlib pkgver=0.99.1.1 pkgrel=1 pkgdesc="A python plotting library, making publication quality plots" arch=('i686' 'x86_64') url="http://matplotlib.sourceforge.net/" backup=(usr/lib/python2.6/site-packages/matplotlib/mpl-data/matplotlibrc) depends=('python-numpy' 'python-pytz' 'python-dateutil') optdepends=('tk: for the TkAgg backend' 'pygtk: for use with the GTK or GTKAgg backend' 'wxpython: for use with the WXAgg backend') provides=('matplotlib') source=(license \ "http://downloads.sourceforge.net/matplotlib/matplotlib-$pkgver.tar.gz") md5sums=('5e579927a4d338bba112471e52555d02' 'bd0894dd924eb5bec84c42d26041a544') license=('custom') build() { cd $srcdir/matplotlib-$pkgver sed -i "s/rc =.*/rc = dict({'backend':'GTKAgg', 'numerix':'numpy'})/g" \ setup.py || return 1 sed -i "s/^BUILD_GTKAGG .*/BUILD_GTKAGG = 1/g" setup.py || return 1 sed -i "s/^BUILD_GTK .*/BUILD_GTK = 1/g" setup.py || return 1 sed -i "s/^BUILD_WXAGG .*/BUILD_WXAGG = 1/g" setup.py || return 1 sed -i "s/^BUILD_TKAGG .*/BUILD_TKAGG = 1/g" setup.py || return 1 sed -i 's/^macosx = True/macosx = False/' setup.cfg || return 1 sed -i 's/^pytz = True/pytz = False/' setup.cfg || return 1 sed -i 's/^dateutil = True/Dateutil = False/' setup.cfg || return 1 python setup.py build || return 1 python setup.py build || return 1 python setup.py install --root $pkgdir --prefix=/usr || return 1 rm -rf $pkgdir/usr/lib/python2.6/site-packages/configobj.py* || return 1 install -Dm644 $srcdir/license \ $pkgdir/usr/share/licenses/$pkgname/license || return 1 }