48 lines
1.2 KiB
Bash
48 lines
1.2 KiB
Bash
# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
|
|
# Maintainer: Daniel M. Capella <polyzen@archlinux.org>
|
|
|
|
pkgname=python-executing
|
|
_name=${pkgname#python-}
|
|
pkgver=2.1.0
|
|
pkgrel=1
|
|
pkgdesc='Get the currently executing AST node of a frame, and other information'
|
|
arch=(any)
|
|
url=https://github.com/alexmojaki/executing
|
|
license=(MIT)
|
|
depends=(python)
|
|
makedepends=(
|
|
git
|
|
python-build
|
|
python-installer
|
|
python-setuptools-scm
|
|
python-wheel
|
|
)
|
|
checkdepends=(
|
|
ipython
|
|
python-asttokens
|
|
python-littleutils
|
|
python-pytest
|
|
)
|
|
source=("git+$url.git#tag=v$pkgver")
|
|
b2sums=('e1279b1e4ca0bfc080cf119bfc043d59e19c410194c775312d511a928394b37aabedcb222179f97208464bdad9a3837e186a980ef578397b648095f8449735a1')
|
|
|
|
build() {
|
|
cd "$_name"
|
|
python -m build --wheel --skip-dependency-check --no-isolation
|
|
}
|
|
|
|
check() {
|
|
cd "$_name"
|
|
PYTHONPATH="$PWD/$_name:$PYTHONPATH" pytest
|
|
}
|
|
|
|
package() {
|
|
local site_packages=$(python -c "import site; print(site.getsitepackages()[0])")
|
|
install -d "$pkgdir"/usr/share/licenses/$pkgname
|
|
ln -s "$site_packages"/"$_name"-$pkgver.dist-info/LICENSE.txt \
|
|
"$pkgdir"/usr/share/licenses/$pkgname/LICENSE.txt
|
|
|
|
cd "$_name"
|
|
python -m installer --destdir="$pkgdir" dist/*.whl
|
|
}
|