summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO29
-rw-r--r--PKGBUILD63
-rw-r--r--setup.py.patch14
3 files changed, 70 insertions, 36 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 474f6294af1e..4cb5eaa88a5c 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,20 @@
pkgbase = python-seqlearn-git
- pkgdesc = A sequence classification toolkit for Python.
- pkgver = 20141124
- pkgrel = 1
- url = http://larsmans.github.io/seqlearn/
- arch = i686
+ pkgdesc = Sequence classification toolkit for Python
+ pkgver = r89.32d4bfa
+ pkgrel = 2
+ url = https://github.com/larsmans/seqlearn
arch = x86_64
- license = custom: Copyright 2013-2014 Lars Buitinck / University of Amsterdam and contributors
+ license = MIT
+ makedepends = cython
makedepends = git
- depends = python
- depends = python-numpy>=1.6
- depends = python-scipy>=0.11
- depends = cython>=0.20.2
- options = !emptydirs
- source = git://github.com/larsmans/seqlearn.git
- md5sums = SKIP
+ makedepends = python-build
+ makedepends = python-installer
+ makedepends = python-setuptools
+ makedepends = python-wheel
+ depends = python-scikit-learn
+ source = seqlearn::git+https://github.com/larsmans/seqlearn
+ source = setup.py.patch
+ sha256sums = SKIP
+ sha256sums = bf5d8bff54489ccd71a427a1a136527b7d913ca386c770bf2de7683d6bae9f16
pkgname = python-seqlearn-git
-
diff --git a/PKGBUILD b/PKGBUILD
index f8a8ffb28f97..a0dfac6124c2 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,27 +1,46 @@
-# Maintainer: Ashley Whetter <(firstname) @ awhetter.co.uk>
+# Maintainer: Luis Martinez <luis dot martinez at disroot dot org>
+# Contributor: Michal Wojdyla < micwoj9292 at gmail dot com >
+# Contributor: Ashley Whetter <(firstname) @ awhetter.co.uk>
pkgname=python-seqlearn-git
-pkgver=20141124
-pkgrel=1
-pkgdesc="A sequence classification toolkit for Python."
-arch=('i686' 'x86_64')
-url="http://larsmans.github.io/seqlearn/"
-license=('custom: Copyright 2013-2014 Lars Buitinck / University of Amsterdam and contributors')
-groups=()
-depends=('python' 'python-numpy>=1.6' 'python-scipy>=0.11' 'cython>=0.20.2')
-makedepends=('git')
-provides=()
-conflicts=()
-replaces=()
-backup=()
-options=(!emptydirs)
-install=
-source=(git://github.com/larsmans/seqlearn.git)
-md5sums=("SKIP")
+_pkg=seqlearn
+pkgver=r89.32d4bfa
+pkgrel=2
+pkgdesc="Sequence classification toolkit for Python"
+arch=('x86_64')
+url='https://github.com/larsmans/seqlearn'
+license=('MIT')
+depends=('python-scikit-learn')
+makedepends=(
+ 'cython'
+ 'git'
+ 'python-build'
+ 'python-installer'
+ 'python-setuptools'
+ 'python-wheel')
+source=("$_pkg::git+$url"
+ 'setup.py.patch')
+sha256sums=('SKIP'
+ 'bf5d8bff54489ccd71a427a1a136527b7d913ca386c770bf2de7683d6bae9f16')
-package() {
- cd "$srcdir/seqlearn"
- python setup.py install --root="$pkgdir/" --optimize=1
+pkgver() {
+ cd "$_pkg"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+prepare() {
+ patch -p1 -d "$_pkg" < setup.py.patch
}
-# vim:set ts=2 sw=2 et:
+build() {
+ cd "$_pkg"
+ python -m build --wheel --no-isolation
+}
+
+package() {
+ cd "$_pkg"
+ python -m installer --destdir="$pkgdir" dist/*.whl
+ local _site="$(python -c 'import site; print(site.getsitepackages()[0])')"
+ install -dv "$pkgdir/usr/share/licenses/$pkgname/"
+ ln -sv "$_site/$_pkg-0.2.dist-info/COPYING" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}
diff --git a/setup.py.patch b/setup.py.patch
new file mode 100644
index 000000000000..e539419026f0
--- /dev/null
+++ b/setup.py.patch
@@ -0,0 +1,14 @@
+diff --git a/setup.py b/setup.py
+index 301e4c7..ee9b540 100644
+--- a/setup.py
++++ b/setup.py
+@@ -27,8 +27,7 @@ setup_options = dict(
+ maintainer_email="larsmans@gmail.com",
+ license="MIT",
+ url="https://github.com/larsmans/seqlearn",
+- packages=["seqlearn", "seqlearn._utils", "seqlearn._decode",
+- "seqlearn/tests"],
++ packages=["seqlearn", "seqlearn._utils", "seqlearn._decode"],
+ classifiers=[
+ "Development Status :: 3 - Alpha",
+ "Intended Audience :: Developers",