blob: e5fba80b739387a4507a3e2d904568cad82f7008 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
# Maintainer: Xeonacid <h.dwwwwww@gmail.com>
_name=pyhanko
pkgname=python-${_name}
pkgver=0.34.1
pkgrel=1
pkgdesc="sign and stamp PDF files"
arch=(any)
url="https://github.com/MatthiasValvekens/${_name}"
license=(MIT)
depends=(python python-asn1crypto python-qrcode python-tzlocal python-pyhanko-certvalidator python-click python-requests python-pyyaml python-cryptography python-uharfbuzz python-python-pkcs11 python-pillow python-barcode python-aiohttp python-oscrypto python-fonttools python-xsdata python-defusedxml python-dateutil)
makedepends=(python-build python-installer python-setuptools python-wheel)
checkdepends=(python-pytest python-requests-mock certomancer python-freezegun python-pytest-asyncio python-defusedxml python-certomancer-csc-dummy python-pytest-aiohttp)
source=(${_name}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz)
sha512sums=('537919670cb646ad928b98c39ce7f99a91c4e3dab9fc452c6cc95183c50973c954a4ee83df57a2a7ce045446408d3691369c02929600005c53a130223b16bf05')
prepare() {
cd pyHanko-$pkgver
cat >> pyproject.toml << EOF
[tool.setuptools]
packages = ["pkgs", "internal"]
EOF
}
build() {
cd pyHanko-$pkgver
python -m build --wheel --no-isolation
}
check(){
cd pyHanko-$pkgver
python -m venv --system-site-packages test-env
test-env/bin/python -m installer dist/*.whl
# test_simple_text_stamp_on_page_with_leaky_graphics_state fails, need investigation
test-env/bin/python -m pytest -vv pyhanko_tests || true
}
package() {
cd pyHanko-$pkgver
python -m installer --destdir="$pkgdir" dist/*.whl
install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
install -Dm644 README.md -t "$pkgdir/usr/share/doc/$pkgname"
}
|