diff options
author | Erich Eckner <git@eckner.net> | 2019-04-24 20:46:06 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2019-04-24 20:46:06 +0200 |
commit | 32574cf922f412fe19aa93dd20e751795e294247 (patch) | |
tree | 8bd298550f99188da06c02bbc8b13649361b60d3 | |
parent | cbe7f7c8ca7ea004f082ea244c2a26c957917efc (diff) | |
download | archlinuxewe-32574cf922f412fe19aa93dd20e751795e294247.tar.xz |
python2-scikit-learn neu
-rw-r--r-- | python2-scikit-learn/PKGBUILD | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/python2-scikit-learn/PKGBUILD b/python2-scikit-learn/PKGBUILD new file mode 100644 index 000000000..0add0e510 --- /dev/null +++ b/python2-scikit-learn/PKGBUILD @@ -0,0 +1,47 @@ +# Maintainer: Erich Eckner <arch at eckner dot net> +# Contributor: Andrzej Giniewicz <gginiu@gmail.com> + +pkgname=python2-scikit-learn +pkgver=0.20.3 +pkgrel=1 +pkgdesc="A set of python modules for machine learning and data mining" +arch=('x86_64' i686 pentium4) +url="http://scikit-learn.sourceforge.net/" +license=('BSD') +makedepends=('python2-setuptools' 'cython2') +options=(!emptydirs) + +source=("https://github.com/scikit-learn/scikit-learn/archive/${pkgver}.tar.gz") +sha256sums=('cadeefa9a824671bdcad790a075efbaa0d5a00458c43c9b4ce7110b129df7b10') + +depends=('python2-scipy') +optdepends=('python2-matplotlib: for examples with plotting') + +prepare() { + cd "$srcdir/scikit-learn-$pkgver" + + find . -name '*.py' -exec \ + sed -e "s|#![ ]*/usr/bin/python$|#!/usr/bin/python2|" \ + -e "s|#![ ]*/usr/bin/env python$|#!/usr/bin/env python2|" \ + -e "s|#![ ]*/bin/env python$|#!/usr/bin/env python2|" \ + -i {} + +} + +build() { + msg "Building Python2" + cd "$srcdir"/scikit-learn-$pkgver + python2 setup.py build +} + +package() { + + cd "$srcdir"/scikit-learn-$pkgver + + python2 setup.py install --root="$pkgdir"/ --optimize=1 + + install -D COPYING "$pkgdir"/usr/share/licenses/$pkgname/LICENSE + + # See FS#49651 + install -d "$pkgdir"/usr/share/doc/$pkgname + cp -r doc/tutorial "$pkgdir"/usr/share/doc/$pkgname/tutorial +} |