summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorwedjat2018-03-13 22:35:24 +0100
committerwedjat2018-03-13 22:35:24 +0100
commit1c12ffee9c3bb8b039ec867fb8bc21404f7824fd (patch)
tree0e9d5d06aecbb0295a7ba200370eefbc5b62157f
downloadaur-1c12ffee9c3bb8b039ec867fb8bc21404f7824fd.tar.gz
Initial commit
-rw-r--r--.SRCINFO23
-rw-r--r--.gitignore5
-rw-r--r--PKGBUILD69
3 files changed, 97 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..15c1694d4433
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+pkgbase = python-nipy
+ pkgdesc = Analysis of structural and functional neuroimaging data.
+ pkgver = 0.4.2
+ pkgrel = 1
+ url = http://nipy.org/nipy/
+ arch = x86_64
+ license = BSD 3-clause
+ makedepends = python-setuptools
+ makedepends = cython
+ depends = python
+ depends = python-numpy>=1.6.0
+ depends = python-scipy>=0.9.0
+ depends = python-sympy>=0.7.0
+ depends = python-nibabel>=1.2.0
+ source = python-nipy-0.4.2.tar.gz::https://github.com/nipy/nipy/archive/0.4.2.tar.gz
+ source = http://nipy.org/data-packages/nipy-templates-0.2.tar.gz
+ source = http://nipy.org/data-packages/nipy-data-0.2.tar.gz
+ md5sums = f8162b019845c41b57b44d181763e85a
+ md5sums = 8e7d607a3b83ba1216432907f0c954c8
+ md5sums = ea94bd420ce103d920cfcd0e3b551424
+
+pkgname = python-nipy
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..9cee3872c45b
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,5 @@
+*tar.gz
+*pkg.tar.xz
+pkg
+src
+*.alternative
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..876b96626d39
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,69 @@
+# Maintainer: wedjat <wedjat@protonmail.com>
+pkgname=python-nipy
+pkgver=0.4.2
+pkgrel=1
+pkgdesc="Analysis of structural and functional neuroimaging data."
+arch=("x86_64")
+url="http://nipy.org/nipy/"
+license=('BSD 3-clause')
+depends=('python' 'python-numpy>=1.6.0' 'python-scipy>=0.9.0' 'python-sympy>=0.7.0' 'python-nibabel>=1.2.0')
+makedepends=('python-setuptools' 'cython') # ('python-sphinx>=1.0' 'python-numpydoc' 'python-matplotlib' 'python-texext' 'ipython') # CAN'T BUILD DOCUMENTATION PROPERLY FOR SOME REASON
+# checkdepends=('python-nose' 'python-mock')
+optdepends=()
+options=()
+source=("$pkgname-$pkgver.tar.gz::https://github.com/nipy/nipy/archive/$pkgver.tar.gz" "http://nipy.org/data-packages/nipy-templates-0.2.tar.gz" "http://nipy.org/data-packages/nipy-data-0.2.tar.gz")
+md5sums=('f8162b019845c41b57b44d181763e85a'
+ '8e7d607a3b83ba1216432907f0c954c8'
+ 'ea94bd420ce103d920cfcd0e3b551424')
+
+prepare()
+{
+ # change "import ConfigParser" to "import configparser" (needed in python3)
+ cd "$srcdir/nipy-data-0.2/"
+ _old_line="$(sed '8q;d' setup.py)"
+ _new_line="import configparser"
+ sed --in-place "8 s/$_old_line/$_new_line/" setup.py
+
+ _old_line="$(sed '23q;d' setup.py)"
+ _new_line=$(echo "config = configparser.SafeConfigParser()")
+ sed --in-place "23 s/$_old_line/$_new_line/" setup.py
+
+
+ # change "import ConfigParser" to "import configparser" (needed in python3)
+ cd "$srcdir/nipy-templates-0.2/"
+ _old_line="$(sed '8q;d' setup.py)"
+ _new_line="import configparser"
+ sed --in-place "8 s/$_old_line/$_new_line/" setup.py
+
+ _old_line="$(sed '23q;d' setup.py)"
+ _new_line=$(echo "config = configparser.SafeConfigParser()")
+ sed --in-place "23 s/$_old_line/$_new_line/" setup.py
+
+}
+
+build()
+{
+ # buiding nipy package
+ cd "$srcdir/nipy-$pkgver"
+ make
+
+ # building documentation (CAN'T MAKE IT WORKING so far)
+# python setup.py build_sphinx
+
+}
+
+package()
+{
+ cd "$srcdir/nipy-$pkgver"
+ python setup.py install --root="$pkgdir"/ --optimize=1
+
+
+ # building nipy data
+ cd "$srcdir/nipy-data-0.2/"
+ python setup.py install --root="$pkgdir"/ --optimize=1
+
+ # building nipy templates
+
+ cd "$srcdir/nipy-templates-0.2/"
+ python setup.py install --root="$pkgdir"/ --optimize=1
+}