41 lines
1.2 KiB
Plaintext

# Automatically generated by apkbuild-pypi, template 4
# Contributor: Niklas Meyer <derlinkman@gmail.com>
# Maintainer: Wen Heping <wenhepingalpine@sohu.com>
pkgname=py3-python-iptables
#_pkgreal is used by apkbuild-pypi to find modules at PyPI
_pkgreal=python_iptables
pkgver=1.2.0
pkgrel=1
pkgdesc="Python bindings for iptables"
url="https://pypi.org/project/python-iptables/"
arch="all"
license="Apache-2.0"
depends="iptables"
makedepends="py3-gpep517 py3-setuptools py3-wheel"
checkdepends="py3-pytest"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/p/python-iptables/python_iptables-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"
options="!check" #needs iptables for check
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 -m pytest
}
package() {
python3 -m installer -d "$pkgdir" \
.dist/*.whl
}
sha512sums="
434dbb756d6cc3e5b02e30cf1c806d211771227f21736f4f3f63551b725fbca6a347377c6005297d5b5266167f84e681468172184e83a68caacbed0423a76b84 python_iptables-1.2.0.tar.gz
"