mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-24 19:55:26 +03:00
this is a million times faster new only in rust 1.68, and fails on older versions, but we have only latest in aports and don't support anything else, so it's okay.
48 lines
1.1 KiB
Text
48 lines
1.1 KiB
Text
# Maintainer: psykose <alice@ayaya.dev>
|
|
pkgname=py3-orjson
|
|
pkgver=3.8.7
|
|
pkgrel=0
|
|
pkgdesc="Fast, correct Python JSON library supporting dataclasses, datetimes, and numpy"
|
|
url="https://github.com/ijl/orjson"
|
|
# s390x: segfaults
|
|
arch="all !s390x"
|
|
license="Apache-2.0 AND MIT"
|
|
makedepends="
|
|
cargo
|
|
py3-gpep517
|
|
py3-maturin
|
|
python3-dev
|
|
"
|
|
checkdepends="
|
|
py3-dateutil
|
|
py3-numpy
|
|
py3-pytest
|
|
py3-tz
|
|
tzdata
|
|
"
|
|
source="$pkgname-$pkgver.tar.gz::https://github.com/ijl/orjson/archive/refs/tags/$pkgver.tar.gz"
|
|
builddir="$srcdir/orjson-$pkgver"
|
|
options="net"
|
|
|
|
export CARGO_REGISTRIES_CRATES_IO_PROTOCOL="sparse"
|
|
|
|
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="
|
|
3210b5ec5d88ebab14515fe3e66fb12260eed9ecb69472effc3ec6f45d2abc671fd7b46430ddb0b4864b17dbba2f1efd6b0238c693fce53e305e7ae3251158ab py3-orjson-3.8.7.tar.gz
|
|
"
|