1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-20 09:45:12 +03:00
aports/community/py3-pefile/APKBUILD
psykose b71032c356 */*: invoke -m venv with --without-pip
we never use pip in the venv manually made for tests-
this might break 1-2 things unexpectedly, but

- those should be looked at anyway
- this has a severe speedup- even on a desktop machine with nvme, this
  makes an arbitrary venv go from 2.6s to <100ms(!) to make. a nice small
  optimisation.
2023-02-09 22:55:20 +01:00

43 lines
1.1 KiB
Text

# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=py3-pefile
pkgver=2022.5.30
pkgrel=2
pkgdesc="Python PE parsing module"
url="https://github.com/erocarrera/pefile"
arch="noarch"
license="MIT"
depends="py3-future python3"
makedepends="
py3-gpep517
py3-setuptools
py3-wheel
"
source="$pkgname-$pkgver.tar.gz::https://github.com/erocarrera/pefile/archive/v$pkgver.tar.gz"
builddir="$srcdir/pefile-$pkgver"
# tests need some intricate data unpacking..
options="!check"
replaces=py-pefile # Backwards compatibility
provides=py-pefile=$pkgver-r$pkgrel # Backwards compatibility
build() {
gpep517 build-wheel \
--wheel-dir dist \
--output-fd 3 3>&1 >&2
}
check() {
python3 -m venv --clear --without-pip --system-site-packages testenv
testenv/bin/python3 -m installer dist/*.whl
testenv/bin/python3 run_tests.py
}
package() {
python3 -m installer -d "$pkgdir" \
dist/*.whl
}
sha512sums="
6f3ade22b5a6697947daa000e9436379874bcd0520344580940a64bbb272e22569e648340bdfc37de9aca948864c6375941e785494dc6c6006e3f878fbda1984 py3-pefile-2022.5.30.tar.gz
"