python-bcrypt: build against the limited API

This commit is contained in:
Christoph Reiter
2023-08-23 18:22:42 +02:00
parent d99a6f624b
commit 7a598cb4e9
2 changed files with 4 additions and 22 deletions

View File

@@ -1,15 +0,0 @@
--- a/setup.py
+++ b/setup.py
@@ -38,12 +38,6 @@
"_bcrypt",
"src/_bcrypt/Cargo.toml",
py_limited_api=True,
- # Enable abi3 mode if we're not using PyPy.
- features=(
- []
- if platform.python_implementation() == "PyPy"
- else ["pyo3/abi3-py36"]
- ),
rust_version=">=1.56.0",
),
],

View File

@@ -7,7 +7,7 @@ provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
pkgver=4.0.1
pkgrel=3
pkgrel=4
pkgdesc="Modern password hashing for your software and your servers (mingw-w64)"
arch=('any')
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
@@ -23,10 +23,8 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-python-build"
conflicts=("${MINGW_PACKAGE_PREFIX}-python-${_realname}3")
replaces=("${MINGW_PACKAGE_PREFIX}-python-${_realname}3")
options=('staticlibs' 'strip' '!debug')
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/pyca/bcrypt/archive/${pkgver}.tar.gz"
001-disable-abi3.patch)
sha512sums=('eb7b1d67a2d60e82e2d2e4dcb12d7808be910f9b7aefab714a22dedbffc3722182875fdcf3c8c650c0bb7c1122e9e8bead92f18bc660043b017a14957467e2a9'
'1ec3f6d3c0d6d7fe9f2c402be3e636929a90a95e5f26444cb3ee7269b5ee64d2e82a7dcbc24716bb7325c352bfc15312f297da8aa9a703a1d7cd7565f989894b')
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/pyca/bcrypt/archive/${pkgver}.tar.gz")
sha512sums=('eb7b1d67a2d60e82e2d2e4dcb12d7808be910f9b7aefab714a22dedbffc3722182875fdcf3c8c650c0bb7c1122e9e8bead92f18bc660043b017a14957467e2a9')
apply_patch_with_msg() {
for _patch in "$@"
@@ -47,8 +45,7 @@ del_file_exists() {
prepare() {
cd "${srcdir}"/${_realname}-${pkgver}
apply_patch_with_msg \
001-disable-abi3.patch
}
build() {