ansible-core: Update to 2.20.0

* 0001-ctypes-cdll-loadlibrary-msys2.patch: drop, ctypes returns the rigth lib now
* Add missing dependencies: cryptography, resolvelib
This commit is contained in:
Christoph Reiter
2025-11-06 19:16:52 +01:00
parent 809abb5375
commit 71c9533ea9
3 changed files with 41 additions and 31 deletions

View File

@@ -1,13 +0,0 @@
diff --git a/lib/ansible/utils/display.py b/lib/ansible/utils/display.py
index 7d98ad47e9..6e6294cfca 100644
--- a/lib/ansible/utils/display.py
+++ b/lib/ansible/utils/display.py
@@ -68,7 +68,7 @@ if t.TYPE_CHECKING:
# avoid circular import at runtime
from ansible.executor.task_queue_manager import FinalQueue
-_LIBC = ctypes.cdll.LoadLibrary(ctypes.util.find_library('c'))
+_LIBC = ctypes.cdll.LoadLibrary('msys-2.0.dll')
# Set argtypes, to avoid segfault if the wrong type is provided,
# restype is assumed to be c_int
_LIBC.wcwidth.argtypes = (ctypes.c_wchar,)

View File

@@ -1,7 +1,7 @@
# Maintainer: Alexandre Ferreira <contact@alexjorgef.com>
pkgname=ansible-core
pkgver=2.19.4
pkgver=2.20.0
pkgrel=1
pkgdesc='Radically simple IT automation platform'
arch=('any')
@@ -13,7 +13,7 @@ msys2_references=(
"purl: pkg:pypi/ansible-core"
)
license=('spdx:GPL-3.0-or-later')
depends=('python' 'python-yaml' 'python-jinja' 'python-packaging')
depends=('python' 'python-yaml' 'python-jinja' 'python-packaging' 'python-cryptography' 'python-resolvelib')
provides=('python-ansible' 'ansible-base')
optdepends=(
'sshpass: for ssh connections with password'
@@ -21,28 +21,14 @@ optdepends=(
makedepends=('tar' 'python-build' 'python-installer' 'python-setuptools')
replaces=('ansible-base')
backup=('etc/ansible/ansible.cfg')
source=("https://pypi.python.org/packages/source/a/ansible-core/ansible_core-${pkgver}.tar.gz"
"0001-ctypes-cdll-loadlibrary-msys2.patch")
sha512sums=('85129bedbfeb72a8fc4cb71e72e40dd3e0db55894bdd0a0ede78c2a69a2f06fc26db9bb700f3aa5e867b93bb494c4239315c19192277c87573d353801b3b78c9'
'9932c3dfcbfc05527b26f150ba54f2f927ed47a2ff0370108d2355fb80b07440669d7d92690fb3baaf8164852eb0ef366943a561e684cfd7ddfb8b727e2b0dce')
source=("https://pypi.python.org/packages/source/a/ansible-core/ansible_core-${pkgver}.tar.gz")
sha512sums=('cdaefdf7a067b797627abe7d0f90d68bb0fa152572f69049b06c1c595818954f31160a97b82c47b0283867540682c73ed5bcbee02d94d973e8cb862d0c586ed8')
noextract=("${pkgname/-/_}-${pkgver}.tar.gz")
apply_patch_with_msg() {
for _fname in "$@"
do
msg2 "Applying ${_fname}"
patch -Nbp1 -i "${srcdir}"/${_fname}
done
}
prepare() {
tar zxf "${srcdir}/${pkgname/-/_}-${pkgver}.tar.gz" || tar zxf "${srcdir}/${pkgname/-/_}-${pkgver}.tar.gz"
cd "${srcdir}/${pkgname/-/_}-${pkgver}"
# Patches
apply_patch_with_msg \
0001-ctypes-cdll-loadlibrary-msys2.patch
}
build() {

View File

@@ -0,0 +1,37 @@
# Maintainer: Christoph Reiter <reiter.christoph@gmail.com>
_name=resolvelib
pkgname=python-resolvelib
pkgver=1.2.1
pkgrel=1
pkgdesc="Resolve abstract dependencies into concrete ones"
url="https://github.com/sarugaku/resolvelib"
msys2_repository_url="https://github.com/sarugaku/resolvelib"
msys2_references=(
'archlinux: python-resolvelib'
'gentoo: dev-python/resolvelib'
'purl: pkg:pypi/resolvelib'
)
license=(spdx:ISC)
arch=(any)
depends=(python)
makedepends=(
python-build
python-installer
python-setuptools
)
source=($_name-$pkgver.tar.gz::$url/archive/refs/tags/$pkgver.tar.gz)
sha256sums=('4d4c4137d7b8f8f27f298ff1af2faa767d790f271928506358d25e4252ed749a')
build() {
cd "$_name-$pkgver"
python -m build --wheel --no-isolation
}
package() {
cd "$_name-$pkgver"
python -m installer --destdir="$pkgdir" dist/*.whl
install -vDm 644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
}