updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / mathgl / PKGBUILD
blobc2eb54e366e96c5718c0e6aa5a764f60af3661b8
1 # Maintainer : SpepS <dreamspepser at yahoo dot it>
2 # Contributor: Thomas Dziedzic < gostrc at gmail >
3 # Contributor: Nick Parastatidis <nparasta@auth.gr>
4 # Contributor: Stefan Husmann <stefan-husmann@t-online.de>
5 # Contributor: oslik <oslik@mail.ru>
7 pkgname=mathgl
8 pkgver=1.11.2
9 pkgrel=2
10 pkgdesc='A library for making high-quality scientific graphics, fast data plotting and handling of large data arrays.'
11 arch=('i686' 'x86_64')
12 url='http://mathgl.sourceforge.net'
13 license=('GPL')
14 depends=('qt' 'fltk' 'wxgtk' 'giflib' 'libharu' 'gsl' 'freeglut' 'u3d' 'python2-numpy')
15 makedepends=('libtiff' 'swig' 'texi2html' 'u3d' 'octave')
16 options=('!libtool')
17 install="$pkgname.install"
18 source=("http://downloads.sourceforge.net/project/$pkgname/$pkgname/$pkgname%20${pkgver%%.1}/$pkgname-$pkgver.tar.gz"
19         "http://mathgl.sourceforge.net/${pkgname}_en.pdf")
20 md5sums=('acd33e68911d9506f60d769dce23f95e'
21          '0767e2d1dc6356dbf4fadb94b4f854f4')
23 build() {
24   cd "$srcdir/$pkgname-$pkgver"
26   # build against numpy
27   export CPPFLAGS="-I/usr/lib/python2.7/site-packages/numpy/core/include"
29   # python2 fixes
30   export PYTHON="python2"
31   sed -i "s|\(python\).*|\12|" texinfo/filter.py
32   sed -i "s|\(python\)\(-config\)|\12\2|g" configure*
34   # fltk 1.3 fix
35   sed -i "s|Fl/|FL/|" include/mgl/mgl_fltk.h
37   ./configure --prefix=/usr \
38               --enable-static=no \
39               --enable-double \
40               --enable-pthread \
41               --enable-u3d \
42               --enable-gsl \
43               --enable-glut \
44               --enable-jpeg \
45               --enable-gif \
46               --enable-pdf \
47               --enable-fltk \
48               --enable-wx \
49               --enable-qt \
50               --enable-python \
51               --enable-octave \
52               --enable-docs
54   make
57 package() {
58   cd "$srcdir/$pkgname-$pkgver"
60   make DESTDIR="$pkgdir/" install
62   # additional pdf doc
63   install -D -m644 "$srcdir/${pkgname}_en.pdf" \
64     "$pkgdir/usr/share/doc/$pkgname/${pkgname}_en.pdf"