[arch-commits] Commit in python-pytz-deprecation-shim/repos (2 files)

Evangelos Foutras foutrelis at gemini.archlinux.org
Wed Dec 1 11:17:31 UTC 2021


    Date: Wednesday, December 1, 2021 @ 11:17:31
  Author: foutrelis
Revision: 1059148

archrelease: copy trunk to community-staging-any

Added:
  python-pytz-deprecation-shim/repos/community-staging-any/
  python-pytz-deprecation-shim/repos/community-staging-any/PKGBUILD
    (from rev 1059147, python-pytz-deprecation-shim/trunk/PKGBUILD)

----------+
 PKGBUILD |   41 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)

Copied: python-pytz-deprecation-shim/repos/community-staging-any/PKGBUILD (from rev 1059147, python-pytz-deprecation-shim/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD	                        (rev 0)
+++ community-staging-any/PKGBUILD	2021-12-01 11:17:31 UTC (rev 1059148)
@@ -0,0 +1,41 @@
+# Maintainer: Daniel M. Capella <polyzen at archlinux.org>
+
+_name=pytz_deprecation_shim
+pkgname=python-pytz-deprecation-shim
+pkgver=0.1.0.post0
+pkgrel=2
+pkgdesc='Shims to make deprecation of pytz easier'
+arch=('any')
+url=https://github.com/pganssle/pytz-deprecation-shim
+license=('Apache')
+depends=('python-tzdata')
+makedepends=('python-build' 'python-install' 'python-setuptools' 'python-wheel')
+checkdepends=('python-hypothesis' 'python-pytest' 'python-pytz')
+source=("https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz")
+sha256sums=('af097bae1b616dde5c5744441e2ddc69e74dfdcb0c263129610d85b87445a59d')
+b2sums=('a6d186ca6fff17a3fb787ad6164fcf45fbac272e6123491a6822699cf54a115c9941f2b1ee3d227f531a0ab1d11846300dc24974611cc1671c77405606704754')
+
+build() {
+  cd $_name-$pkgver
+  python -m build --wheel --skip-dependency-check --no-isolation
+}
+
+check() {
+  cd $_name-$pkgver
+  python -m venv --system-site-packages test-env
+  test-env/bin/python -m install --optimize=1 dist/*.whl
+  test-env/bin/python -m pytest
+}
+
+package() {
+  cd $_name-$pkgver
+  python -m install --optimize=1 --destdir="$pkgdir" dist/*.whl
+
+  # 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"/$_name-$pkgver.dist-info/LICENSE \
+    "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+# vim:set ts=2 sw=2 et:



More information about the arch-commits mailing list