summaryrefslogtreecommitdiff
path: root/community/python-matplotlib
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-12-01 01:52:00 -0800
committerroot <root@rshg054.dnsready.net>2012-12-01 01:52:00 -0800
commitc31ace4c6175db330d7e4aac1e7388fe5ca5d4f3 (patch)
tree305ea12a2bf8d2d9c7a36e52f68dba9fdb801548 /community/python-matplotlib
parent51867161079ab52d5152105142a3bc965c63ca03 (diff)
Sat Dec 1 01:48:48 PST 2012
Diffstat (limited to 'community/python-matplotlib')
-rw-r--r--community/python-matplotlib/PKGBUILD30
-rw-r--r--community/python-matplotlib/python-matplotlib-tk.patch35
2 files changed, 55 insertions, 10 deletions
diff --git a/community/python-matplotlib/PKGBUILD b/community/python-matplotlib/PKGBUILD
index 7e90764c9..d47ac8e7a 100644
--- a/community/python-matplotlib/PKGBUILD
+++ b/community/python-matplotlib/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 80031 2012-11-15 15:02:41Z stephane $
+# $Id: PKGBUILD 80710 2012-11-30 12:11:12Z stephane $
# Maintainer: Stéphane Gaudreault <stephane@archlinux.org>
# Contributor: Stefan Husmann <stefan-husmann@t-online.de>
# Contributor: Angel 'angvp' Velasquez <angvp[at]archlinux.com.ve>
@@ -7,25 +7,35 @@
pkgbase=python-matplotlib
pkgname=('python2-matplotlib' 'python-matplotlib')
pkgver=1.2.0
-pkgrel=3
+pkgrel=6
pkgdesc="A python plotting library, making publication quality plots"
arch=('i686' 'x86_64')
-url="http://matplotlib.sourceforge.net/"
+url='http://matplotlib.org'
license=('custom')
-makedepends=('python2-pytz' 'python2-numpy' 'python2-pyqt'
- 'python-pytz' 'python-numpy' 'pyqt')
+makedepends=('python2-pytz' 'python2-numpy' 'python2-pyqt' 'python-pytz' 'python-numpy' 'pyqt'
+ 'tk' 'python-cairo' 'python2-cairo' 'python-dateutil' 'python2-dateutil'
+ 'python-gobject' 'python2-gobject' 'python-pyparsing' 'python2-pyparsing'
+ 'pygtk' 'python-six' 'ghostscript' 'texlive-bin')
+optdepends=('pygtk: for use with the GTK or GTKAgg backend'
+ 'tk: used by the TkAgg backend'
+ 'ghostscript: usetex dependencies'
+ 'texlive-bin: usetex dependencies')
source=("https://github.com/downloads/matplotlib/matplotlib/matplotlib-${pkgver}.tar.gz"
- setup.cfg)
+ python-matplotlib-tk.patch)
sha1sums=('1d0c319b2bc545f1a7002f56768e5730fe573518'
- '370a08120bcb3046f590c527b3d29d18ae874818')
+ '6f27ff74a7752700758d081d3235a61a89b8ea95')
build() {
cd "${srcdir}"/matplotlib-${pkgver}
+ patch -Np1 -i ../python-matplotlib-tk.patch
+
# use system python-six
rm lib/six.py
- cp ../setup.cfg .
+ # remove internal copies of pyparsing
+ rm -r lib/matplotlib/pyparsing_py{2,3}.py
+ sed -i -e 's/matplotlib.pyparsing_py[23]/pyparsing/g' lib/matplotlib/{mathtext,fontconfig_pattern}.py
# For numpy 1.7
sed -i '/include/s/numpy\/arrayobject.h/numpy\/oldnumeric.h/g' \
@@ -54,7 +64,7 @@ build() {
}
package_python2-matplotlib() {
- depends=('python2-pytz' 'python2-numpy' 'python2-pyqt' 'python2-dateutil')
+ depends=('python2-pytz' 'python2-numpy' 'python2-cairo' 'python2-pyqt' 'python2-dateutil' 'python2-pyparsing')
cd "${srcdir}"/matplotlib-${pkgver}
python2 setup.py install -O1 --skip-build --root "${pkgdir}" --prefix=/usr
@@ -64,7 +74,7 @@ package_python2-matplotlib() {
}
package_python-matplotlib() {
- depends=('python-pytz' 'python-numpy' 'pyqt' 'python-dateutil')
+ depends=('python-pytz' 'python-numpy' 'python-cairo' 'pyqt' 'python-dateutil' 'python-pyparsing')
cd "${srcdir}"/matplotlib-${pkgver}-py3
python3 setup.py install -O1 --skip-build --root "${pkgdir}" --prefix=/usr
diff --git a/community/python-matplotlib/python-matplotlib-tk.patch b/community/python-matplotlib/python-matplotlib-tk.patch
new file mode 100644
index 000000000..10480195a
--- /dev/null
+++ b/community/python-matplotlib/python-matplotlib-tk.patch
@@ -0,0 +1,35 @@
+diff -up matplotlib-1.2.0/setupext.py.orig matplotlib-1.2.0/setupext.py
+--- matplotlib-1.2.0/setupext.py.orig 2012-11-23 14:50:48.954715965 -0200
++++ matplotlib-1.2.0/setupext.py 2012-11-23 14:55:53.731727636 -0200
+@@ -898,12 +898,12 @@ def parse_tcl_config(tcl_lib_dir, tk_lib
+
+ tcl_poss = [tcl_lib_dir,
+ os.path.normpath(os.path.join(tcl_lib_dir, '..')),
+- "/usr/lib/tcl"+str(Tkinter.TclVersion),
+- "/usr/lib"]
++ "@@libdir@@/tcl"+str(Tkinter.TclVersion),
++ "@@lib@@"]
+ tk_poss = [tk_lib_dir,
+ os.path.normpath(os.path.join(tk_lib_dir, '..')),
+- "/usr/lib/tk"+str(Tkinter.TkVersion),
+- "/usr/lib"]
++ "@@libdir@@/tk"+str(Tkinter.TkVersion),
++ "@@libdir@@"]
+ for ptcl, ptk in zip(tcl_poss, tk_poss):
+ tcl_config = os.path.join(ptcl, "tclConfig.sh")
+ tk_config = os.path.join(ptk, "tkConfig.sh")
+@@ -974,10 +974,10 @@ def guess_tcl_config(tcl_lib_dir, tk_lib
+ return tcl_lib, tcl_inc, 'tcl' + tk_ver, tk_lib, tk_inc, 'tk' + tk_ver
+
+ def hardcoded_tcl_config():
+- tcl_inc = "/usr/local/include"
+- tk_inc = "/usr/local/include"
+- tcl_lib = "/usr/local/lib"
+- tk_lib = "/usr/local/lib"
++ tcl_inc = "/usr/include"
++ tk_inc = "/usr/include"
++ tcl_lib = "@@libdir@@"
++ tk_lib = "@@libdir@@"
+ return tcl_lib, tcl_inc, 'tcl', tk_lib, tk_inc, 'tk'
+
+ def add_tk_flags(module):