diff options
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | PKGBUILD | 38 | ||||
-rw-r--r-- | setup.py.patch | 26 |
3 files changed, 82 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..ec51dec2c6ae --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,18 @@ +pkgbase = python-rfoo-git + pkgver = r10.8688a3e + pkgrel = 1 + url = https://github.com/aaiyer/rfoo + arch = any + license = Apache + makedepends = cython + makedepends = git + depends = python + provides = python-rfoo-git + conflicts = python-rfoo-git + source = git+https://github.com/aaiyer/rfoo.git + source = setup.py.patch + sha512sums = SKIP + sha512sums = SKIP + +pkgname = python-rfoo-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..758275c175fa --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,38 @@ +# Maintainer: awe00 < awe00 AT hotmail DOT fr> + +pkgbase=python-rfoo-git +pkgname=python-rfoo-git +_name=rfoo +pkgver=r10.8688a3e +pkgrel=1 +pkgdesc="" +arch=('any') +url="https://github.com/aaiyer/rfoo" +license=('Apache') +makedepends=('cython' 'git') +depends=('python') +source=("git+https://github.com/aaiyer/rfoo.git" "setup.py.patch") +sha512sums=('SKIP' 'SKIP') +provides=("${pkgname%}") +conflicts=("${pkgname%}") + +pkgver() { + # Git, no tags available + cd "$srcdir/${_name}" + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +prepare() { + cd "$srcdir/${_name}" +} + +build() { + cd "$srcdir/${_name}" + patch -Np1 -i $srcdir/setup.py.patch + python setup.py build +} + +package() { + cd "$srcdir/${_name}" + python setup.py install --root="${pkgdir}" +} diff --git a/setup.py.patch b/setup.py.patch new file mode 100644 index 000000000000..cdff5151fb39 --- /dev/null +++ b/setup.py.patch @@ -0,0 +1,26 @@ +diff --git a/setup.py b/setup.py +index 8d08855..ea0abf1 100644 +--- a/setup.py ++++ b/setup.py +@@ -35,9 +35,10 @@ + + import sys + +-from distutils.core import setup +-from distutils.extension import Extension ++from setuptools import setup ++from setuptools import Extension + from distutils.command.build_ext import build_ext ++from Cython.Build import cythonize + + if 'bdist_egg' in sys.argv: + sys.stderr.write("""=========================================================== +@@ -53,6 +54,7 @@ and install with: + + + ext_modules = [Extension("rfoo.marsh", ["rfoo/marsh.pyx"])] ++ext_modules = cythonize(ext_modules) + + + setup( + |