From 1fe175ec3574ac23d27ece618ef85a897d73df2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D9=85=D9=87=D8=AF=D9=8A=20=D8=B4=D9=8A=D9=86=D9=88=D9=86?= =?UTF-8?q?=20=28Mehdi=20Chinoune=29?= <79349457+MehdiChinoune@users.noreply.github.com> Date: Fri, 29 Jul 2022 18:22:22 +0100 Subject: [PATCH] python-soupsieve: update to 2.3.2.post1 --- mingw-w64-python-soupsieve/PKGBUILD | 49 +++++++++++++---------------- 1 file changed, 21 insertions(+), 28 deletions(-) diff --git a/mingw-w64-python-soupsieve/PKGBUILD b/mingw-w64-python-soupsieve/PKGBUILD index b5b513fcea..88df62cdca 100644 --- a/mingw-w64-python-soupsieve/PKGBUILD +++ b/mingw-w64-python-soupsieve/PKGBUILD @@ -6,23 +6,27 @@ 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=2.3.1 -pkgrel=2 +pkgver=2.3.2.post1 +pkgrel=1 pkgdesc="A CSS4 selector implementation for Beautiful Soup (mingw-w64)" arch=('any') mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64') url='https://github.com/facelessuser/soupsieve' license=('MIT') depends=("${MINGW_PACKAGE_PREFIX}-python") -makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools") +makedepends=("${MINGW_PACKAGE_PREFIX}-python-build" + "${MINGW_PACKAGE_PREFIX}-python-installer" + "${MINGW_PACKAGE_PREFIX}-python-hatchling") checkdepends=("${MINGW_PACKAGE_PREFIX}-python-beautifulsoup4" "${MINGW_PACKAGE_PREFIX}-python-coverage" "${MINGW_PACKAGE_PREFIX}-python-html5lib" + "${MINGW_PACKAGE_PREFIX}-python-lxml" + "${MINGW_PACKAGE_PREFIX}-python-mypy" "${MINGW_PACKAGE_PREFIX}-python-pytest" "${MINGW_PACKAGE_PREFIX}-python-pytest-cov") options=('staticlibs' 'strip' '!debug') source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/facelessuser/soupsieve/archive/${pkgver}.tar.gz") -sha256sums=('ba774446d8d41a5388432b5a367289e89330eef590f195e6c9e3f5cf7d616a60') +sha256sums=('2f6a3926d6ee7e360654263b514c2fe850e2fecb48cee3e4a3d8afbcf059830f') # Helper macros to help make tasks easier # apply_patch_with_msg() { @@ -43,37 +47,26 @@ del_file_exists() { } # =========================================== # -prepare() { - cd "${srcdir}" - pushd "${_realname}-${pkgver}" - # apply_patch_with_msg 0001-A-really-important-fix.patch \ - # 0002-A-less-important-fix.patch - popd - - rm -rf python-build-${CARCH} | true - cp -r "${_realname}-${pkgver}" "python-build-${CARCH}" - - # Set version for setuptools_scm - export SETUPTOOLS_SCM_PRETEND_VERSION=${pkgver} -} - build() { - msg "Python build for ${CARCH}" - cd "${srcdir}/python-build-${CARCH}" - ${MINGW_PREFIX}/bin/python setup.py build + cp -r "${_realname}-${pkgver}" "python-build-${MSYSTEM}" && cd "python-build-${MSYSTEM}" + + ${MINGW_PREFIX}/bin/python -m build --wheel --skip-dependency-check --no-isolation } check() { - msg "Python test for ${CARCH}" - cd "${srcdir}/python-build-${CARCH}" - ${MINGW_PREFIX}/bin/py.test + cd "${srcdir}/python-build-${MSYSTEM}" + +# The test command will usually depend upon what is contained in the tox.ini file +# or in the [testenv:py] section of the pyproject.toml file. + ${MINGW_PREFIX}/bin/python -m pytest } package() { - cd "${srcdir}/python-build-${CARCH}" - 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 + cd "${srcdir}/python-build-${MSYSTEM}" + + MSYS2_ARG_CONV_EXCL="--prefix=" \ + ${MINGW_PREFIX}/bin/python -m installer --prefix=${MINGW_PREFIX} \ + --destdir="${pkgdir}" dist/*.whl install -Dm644 LICENSE.md "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE" }