Skip to content

Commit

Permalink
python-cryptography: Update to 3.4.4
Browse files Browse the repository at this point in the history
  • Loading branch information
lazka committed Feb 13, 2021
1 parent f462c8a commit 78fd15f
Show file tree
Hide file tree
Showing 4 changed files with 233 additions and 12 deletions.
148 changes: 148 additions & 0 deletions mingw-w64-python-cryptography/0001-update-pyo3.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,148 @@
diff --git a/src/rust/Cargo.lock b/src/rust/Cargo.lock
index 88161c27d4..94f89ff747 100644
--- a/src/rust/Cargo.lock
+++ b/src/rust/Cargo.lock
@@ -1,5 +1,11 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
+[[package]]
+name = "bitflags"
+version = "1.2.1"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cf1de2fe8c75bc145a2f577add951f8134889b4795d47466a54a5c846d691693"
+
[[package]]
name = "cfg-if"
version = "1.0.0"
@@ -36,10 +42,24 @@ dependencies = [

[[package]]
name = "indoc"
-version = "1.0.3"
+version = "0.3.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "47741a8bc60fb26eb8d6e0238bbb26d8575ff623fdc97b1a2c00c050b9684ed8"
+dependencies = [
+ "indoc-impl",
+ "proc-macro-hack",
+]
+
+[[package]]
+name = "indoc-impl"
+version = "0.3.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "e5a75aeaaef0ce18b58056d306c27b07436fbb34b8816c53094b76dd81803136"
+checksum = "ce046d161f000fffde5f432a0d034d0341dc152643b2598ed5bfce44c4f3a8f0"
dependencies = [
+ "proc-macro-hack",
+ "proc-macro2",
+ "quote",
+ "syn",
"unindent",
]

@@ -102,9 +122,9 @@ dependencies = [

[[package]]
name = "parking_lot_core"
-version = "0.8.2"
+version = "0.8.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "9ccb628cad4f84851442432c60ad8e1f607e29752d0bf072cbd0baf28aa34272"
+checksum = "fa7a782938e745763fe6907fc6ba86946d72f49fe7e21de074e08128a99fb018"
dependencies = [
"cfg-if",
"instant",
@@ -116,9 +136,28 @@ dependencies = [

[[package]]
name = "paste"
-version = "1.0.4"
+version = "0.1.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "c5d65c4d95931acda4498f675e332fcbdc9a06705cd07086c510e9b6009cd1c1"
+checksum = "45ca20c77d80be666aef2b45486da86238fabe33e38306bd3118fe4af33fa880"
+dependencies = [
+ "paste-impl",
+ "proc-macro-hack",
+]
+
+[[package]]
+name = "paste-impl"
+version = "0.1.18"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "d95a7db200b97ef370c8e6de0088252f7e0dfff7d047a28528e47456c0fc98b6"
+dependencies = [
+ "proc-macro-hack",
+]
+
+[[package]]
+name = "proc-macro-hack"
+version = "0.5.19"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "dbf0c48bc1d91375ae5c3cd81e3722dff1abcf81a30960240640d223f59fe0e5"

[[package]]
name = "proc-macro2"
@@ -131,9 +170,9 @@ dependencies = [

[[package]]
name = "pyo3"
-version = "0.13.1"
+version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "00ca634cf3acd58a599b535ed6cb188223298977d471d146121792bfa23b754c"
+checksum = "4837b8e8e18a102c23f79d1e9a110b597ea3b684c95e874eb1ad88f8683109c3"
dependencies = [
"cfg-if",
"ctor",
@@ -148,9 +187,9 @@ dependencies = [

[[package]]
name = "pyo3-macros"
-version = "0.13.1"
+version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "483ac516dbda6789a5b4be0271e7a31b9ad4ec8c0a5955050e8076f72bdbef8f"
+checksum = "a47f2c300ceec3e58064fd5f8f5b61230f2ffd64bde4970c81fdd0563a2db1bb"
dependencies = [
"pyo3-macros-backend",
"quote",
@@ -159,9 +198,9 @@ dependencies = [

[[package]]
name = "pyo3-macros-backend"
-version = "0.13.1"
+version = "0.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "15230cabcda008f03565ed8bac40f094cbb5ee1b46e6551f1ec3a0e922cf7df9"
+checksum = "87b097e5d84fcbe3e167f400fbedd657820a375b034c78bd852050749a575d66"
dependencies = [
"proc-macro2",
"quote",
@@ -170,18 +209,21 @@ dependencies = [

[[package]]
name = "quote"
-version = "1.0.8"
+version = "1.0.9"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "991431c3519a3f36861882da93630ce66b52918dcf1b8e2fd66b397fc96f28df"
+checksum = "c3d0b9745dc2debf507c8422de05d7226cc1f0644216dfdfead988f9b1ab32a7"
dependencies = [
"proc-macro2",
]

[[package]]
name = "redox_syscall"
-version = "0.1.57"
+version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "41cc0f7e4d5d4544e8861606a285bb08d3e70712ccc7d2b84d7c0ccfaf4b05ce"
+checksum = "05ec8ca9416c5ea37062b502703cd7fcb207736bc294f6e0cf367ac6fc234570"
+dependencies = [
+ "bitflags",
+]

[[package]]
name = "scopeguard"
28 changes: 16 additions & 12 deletions mingw-w64-python-cryptography/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -6,40 +6,44 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
pkgver=3.3.1
pkgver=3.4.4
pkgrel=1
pkgdesc="A package designed to expose cryptographic recipes and primitives to Python developers (mingw-w64)"
url='https://pypi.org/project/cryptography/'
license=('Apache')
arch=('any')
depends=("${MINGW_PACKAGE_PREFIX}-python-cffi"
"${MINGW_PACKAGE_PREFIX}-python-pyasn1"
"${MINGW_PACKAGE_PREFIX}-python-idna"
"${MINGW_PACKAGE_PREFIX}-python-asn1crypto")
"${MINGW_PACKAGE_PREFIX}-python-idna")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools"
"${MINGW_PACKAGE_PREFIX}-python-six")
"${MINGW_PACKAGE_PREFIX}-python-setuptools-rust")
checkdepends=("${MINGW_PACKAGE_PREFIX}-python-pytest-runner"
#"${MINGW_PACKAGE_PREFIX}-python-iso8601"
"${MINGW_PACKAGE_PREFIX}-python-pretend"
#"${MINGW_PACKAGE_PREFIX}-python-cryptography-vectors"
#"${MINGW_PACKAGE_PREFIX}-python-hypothesis"
"${MINGW_PACKAGE_PREFIX}-python-pytz")
source=(https://pypi.io/packages/source/c/cryptography/${_realname}-${pkgver}.tar.gz)
sha256sums=('7e177e4bea2de937a584b13645cab32f25e3d96fc0bc4a4cf99c27dc77682be6')
source=(https://pypi.io/packages/source/c/cryptography/${_realname}-${pkgver}.tar.gz
0001-update-pyo3.patch)
sha256sums=('ee5e19f0856b6fbbdbab15c2787ca65d203801d2d65d0b8de6218f424206c848'
'07a9af241298fb19353a4329de779865a413cd2e9f041b12b49e2998bf6ab933')

prepare() {
cd ${srcdir}
cp -r ${_realname}-${pkgver} python-build-${CARCH}
cd "${srcdir}/${_realname}-${pkgver}"

# https://github.com/PyO3/pyo3/pull/1423
patch -Np1 -i "${srcdir}"/0001-update-pyo3.patch
}

build() {
msg "Python build for ${CARCH}"
cd "${srcdir}/python-build-${CARCH}"
cd "${srcdir}/${_realname}-${pkgver}"

#export CARGO_BUILD_TARGET="x86_64-pc-windows-gnu"
${MINGW_PREFIX}/bin/python setup.py build
}

package() {
cd ${srcdir}/python-build-${CARCH}
cd "${srcdir}/${_realname}-${pkgver}"

MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" --optimize=1 --skip-build

Expand Down
30 changes: 30 additions & 0 deletions mingw-w64-python-semantic-version/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Maintainer: Christoph Reiter <[email protected]>

_realname=semantic-version
pkgbase=mingw-w64-python-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
pkgver=2.8.5
pkgrel=1
pkgdesc="A library implementing the 'SemVer' scheme (mingw-w64)"
url='https://github.com/rbarrois/python-semanticversion'
license=('BSD')
arch=('any')
depends=("${MINGW_PACKAGE_PREFIX}-python")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools")
source=("$pkgname-$pkgver.tar.gz::https://github.com/rbarrois/python-semanticversion/archive/$pkgver.tar.gz")
sha256sums=('cd50a153e3bc5a8d53b2723601532b94b23e906d82d0b07cef421945f0e02107')

build() {
cd "${srcdir}/python-semanticversion-$pkgver"

${MINGW_PREFIX}/bin/python setup.py build
}

package() {
cd "${srcdir}/python-semanticversion-$pkgver"

MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" --optimize=1 --skip-build

install -Dm644 "${srcdir}/python-semanticversion-${pkgver}/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE"
}
39 changes: 39 additions & 0 deletions mingw-w64-python-setuptools-rust/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Maintainer: Christoph Reiter <[email protected]>

_realname=setuptools-rust
pkgbase=mingw-w64-python-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
pkgver=0.11.6
pkgrel=1
pkgdesc="Compile and distribute Python extensions written in rust as easily as if they were written in C (mingw-w64)"
url='https://github.com/PyO3/setuptools-rust'
license=('MIT')
arch=('any')
depends=("${MINGW_PACKAGE_PREFIX}-rust"
"${MINGW_PACKAGE_PREFIX}-python-toml"
"${MINGW_PACKAGE_PREFIX}-python-semantic-version"
"${MINGW_PACKAGE_PREFIX}-python-setuptools")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools-scm"
"${MINGW_PACKAGE_PREFIX}-python-wheel")
source=("https://github.com/PyO3/setuptools-rust/archive/v$pkgver/$_realname-$pkgver.tar.gz")
sha256sums=('0c22494070035f43b8b1578dc28d247e3efaeea401fd67b7d062ebc5ce800786')

prepare() {
cd "${srcdir}/${_realname}-$pkgver"
export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
}

build() {
cd "${srcdir}/${_realname}-$pkgver"

${MINGW_PREFIX}/bin/python setup.py build
}

package() {
cd "${srcdir}/${_realname}-$pkgver"

MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" --optimize=1 --skip-build

install -Dm644 "${srcdir}/${_realname}-${pkgver}/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE"
}

0 comments on commit 78fd15f

Please sign in to comment.