[arch-commits] Commit in python-click-log/trunk (PKGBUILD)

Daniel M. Capella polyzen at gemini.archlinux.org
Sun Sep 4 18:37:41 UTC 2022


    Date: Sunday, September 4, 2022 @ 18:37:41
  Author: polyzen
Revision: 1292869

upgpkg: python-click-log 0.4.0-2: Use PEP 517

Modified:
  python-click-log/trunk/PKGBUILD

----------+
 PKGBUILD |   29 ++++++++++++++++++-----------
 1 file changed, 18 insertions(+), 11 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2022-09-04 18:26:09 UTC (rev 1292868)
+++ PKGBUILD	2022-09-04 18:37:41 UTC (rev 1292869)
@@ -1,24 +1,26 @@
 # Maintainer: David Runge <dvzrv at archlinux.org>
+# Maintainer: Daniel M. Capella <polyzen at archlinux.org>
 # Contributor: eolianoe <eolianoe At GoogleMAIL DoT com>
 
 _name=click-log
 pkgname=python-click-log
 pkgver=0.4.0
-pkgrel=1
+pkgrel=2
 pkgdesc="Logging integration for Click"
-arch=(any)
+arch=('any')
 url="https://github.com/click-contrib/click-log"
-license=(MIT)
-depends=(python-click)
-makedepends=(python-setuptools)
-checkdepends=(python-pytest)
-source=(https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz)
-sha512sums=('95d3cb2fa9821e4f58b25072f39d34f21fe4a7600923f59f4b57b92dbcd9fa2584d710de1d4a1aa2a757c048398342aabbb1b5ab32cf4128ccecee10f9f15a5a')
+license=('MIT')
+depends=('python-click')
+makedepends=('python-build' 'python-installer' 'python-setuptools'
+             'python-wheel')
+checkdepends=('python-pytest')
+source=("https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz")
+sha256sums=('3970f8570ac54491237bcdb3d8ab5e3eef6c057df29f8c3d1151a51a9c23b975')
 b2sums=('8a7ce0c2a7617253f08d011958bce158e987faa0008065c9dac382d46b905cc88cd5cb19d0d0859bf522da6448f7c9a20c0a8efe53b3feb5efc9ca3f64cfbc27')
 
 build() {
   cd $_name-$pkgver
-  python setup.py build
+  python -m build --wheel --skip-dependency-check --no-isolation
 }
 
 check() {
@@ -29,7 +31,12 @@
 
 package() {
   cd $_name-$pkgver
-  python setup.py install --optimize=1 --root="$pkgdir"
-  install -vDm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
+  python -m installer --destdir="$pkgdir" dist/*.whl
   install -vDm 644 README.rst -t "$pkgdir/usr/share/doc/$pkgname/"
+
+  # Symlink license file
+  local site_packages=$(python -c "import site; print(site.getsitepackages()[0])")
+  install -d "$pkgdir"/usr/share/licenses/$pkgname
+  ln -s "$site_packages"/click_log-$pkgver.dist-info/LICENSE \
+    "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
 }



More information about the arch-commits mailing list