mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-05 13:27:09 +02:00
76 lines
1.9 KiB
Plaintext
76 lines
1.9 KiB
Plaintext
# Contributor: August Klein <amatcoder@gmail.com>
|
|
# Maintainer: psykose <alice@ayaya.dev>
|
|
pkgname=py3-cryptography
|
|
pkgver=40.0.2
|
|
pkgrel=1
|
|
pkgdesc="Cryptographic recipes and primitives for Python"
|
|
url="https://cryptography.io/"
|
|
arch="all"
|
|
license="Apache-2.0 OR BSD-3-Clause"
|
|
depends="python3 py3-cffi"
|
|
makedepends="
|
|
libffi-dev
|
|
openssl-dev>3
|
|
py3-gpep517
|
|
py3-setuptools
|
|
py3-setuptools-rust
|
|
py3-wheel
|
|
python3-dev
|
|
"
|
|
checkdepends="
|
|
py3-hypothesis
|
|
py3-iso8601
|
|
py3-pretend
|
|
py3-pytest
|
|
py3-pytest-benchmark
|
|
py3-pytest-subtests
|
|
py3-pytest-xdist
|
|
py3-tz
|
|
"
|
|
subpackages="$pkgname-pyc"
|
|
source="https://files.pythonhosted.org/packages/source/c/cryptography/cryptography-$pkgver.tar.gz
|
|
https://files.pythonhosted.org/packages/source/c/cryptography_vectors/cryptography_vectors-$pkgver.tar.gz
|
|
"
|
|
builddir="$srcdir/cryptography-$pkgver"
|
|
|
|
replaces="py-cryptography" # Backwards compatibility
|
|
provides="py-cryptography=$pkgver-r$pkgrel" # Backwards compatibility
|
|
|
|
# secfixes:
|
|
# 39.0.1-r0:
|
|
# - CVE-2023-23931
|
|
# 3.2.2-r0:
|
|
# - CVE-2020-36242
|
|
# 3.2.1-r0:
|
|
# - CVE-2020-25659
|
|
|
|
build() {
|
|
gpep517 build-wheel \
|
|
--wheel-dir dist \
|
|
--output-fd 3 3>&1 >&2
|
|
|
|
# prepare cryptography vectors for testing
|
|
cd "$srcdir/cryptography_vectors-$pkgver"
|
|
python3 setup.py build
|
|
}
|
|
|
|
check() {
|
|
python3 -m venv --clear --without-pip --system-site-packages test-env
|
|
test-env/bin/python3 -m installer dist/cryptography*.whl
|
|
(
|
|
cd "$srcdir"/cryptography_vectors-$pkgver
|
|
"$builddir"/test-env/bin/python3 setup.py install
|
|
)
|
|
test-env/bin/python3 -m pytest -n $JOBS
|
|
}
|
|
|
|
package() {
|
|
python3 -m installer -d "$pkgdir" \
|
|
dist/cryptography-*.whl
|
|
}
|
|
|
|
sha512sums="
|
|
391aba41fa75052d86182d39096c61eb37126a1e94499fe1934cc3307c8c7e819ead0e904c58c0b36fa4c4bc375b092d1b352217bc0d448f4aab587cff90528e cryptography-40.0.2.tar.gz
|
|
6f2a9ec715803760deb397ec810433df9e7862029b0f63ca661a9781b8dc5f18bd585438ca7781a566342967b855ce0371dbb3fc650be1fb6ca0ac6c744c05c0 cryptography_vectors-40.0.2.tar.gz
|
|
"
|