summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD38
1 files changed, 15 insertions, 23 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 58571782e337..045d7c282969 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,15 +1,16 @@
# Maintainer: Daniel Bermond <dbermond@archlinux.org>
-pkgbase=python-peachpy-git
-pkgname=('python-peachpy-git' 'python-peachpy-doc-git')
-pkgver=r371.84e60a5
+pkgname=python-peachpy-git
+pkgver=r379.349e8f8
pkgrel=1
pkgdesc='Python framework for writing high-performance assembly kernels (git version)'
arch=('any')
url='https://github.com/Maratyszcza/PeachPy/'
license=('BSD')
-makedepends=('git' 'python-setuptools' 'python-wheel' 'python-pip' 'python-sphinx'
- 'python-sphinx-bootstrap-theme')
+depends=('python' 'python-six')
+makedepends=('git' 'python-build' 'python-installer' 'python-opcodes' 'python-setuptools' 'python-wheel')
+provides=('python-peachpy')
+conflicts=('python-peachpy')
source=('git+https://github.com/Maratyszcza/PeachPy.git')
sha256sums=('SKIP')
@@ -19,26 +20,17 @@ pkgver() {
build() {
cd PeachPy
- python setup.py build
- python setup.py build_sphinx --all-files --source-dir="${srcdir}/PeachPy/sphinx"
+ python -m build --wheel --no-isolation
}
package_python-peachpy-git() {
- depends=('python' 'python-six')
- provides=('python-peachpy')
- conflicts=('python-peachpy')
-
- cd PeachPy
- python setup.py install --root="$pkgdir" --skip-build --optimize='1'
- install -D -m644 LICENSE.rst "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
-}
+ python -m installer --destdir="$pkgdir" "PeachPy/dist"/*.whl
-package_python-peachpy-doc-git() {
- pkgdesc="$(sed 's/\((git version)\)/(documentation) \1/' <<< "$pkgdesc")"
- provides=('python-peachpy-doc')
- conflicts=('python-peachpy-doc')
-
- mkdir -p "${pkgdir}/usr/share/doc/python-peachpy"
- cp -dr --no-preserve='ownership' PeachPy/build/sphinx/html/* "${pkgdir}/usr/share/doc/python-peachpy"
- install -D -m644 PeachPy/LICENSE.rst "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+ local _pyver
+ local _pkgver
+ _pyver="$(python -c 'import sys; print(".".join(map(str, sys.version_info[:2])))')"
+ _pkgver="$(awk -F'=' "/__version_info__/ { gsub(/,/, \".\"); gsub(/['()[:space:]]+/, \"\"); print \$2; exit }" PeachPy/peachpy/__init__.py)"
+ install -d -m755 "${pkgdir}/usr/share/licenses/${pkgname}"
+ ln -s "../../../lib/python${_pyver}/site-packages/PeachPy-${_pkgver}.dist-info/LICENSE.rst" \
+ "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}