[arch-commits] Commit in python-flit/repos (2 files)

Felix Yan felixonmars at gemini.archlinux.org
Wed Dec 1 11:10:11 UTC 2021


    Date: Wednesday, December 1, 2021 @ 11:10:11
  Author: felixonmars
Revision: 1059117

archrelease: copy trunk to community-staging-any

Added:
  python-flit/repos/community-staging-any/
  python-flit/repos/community-staging-any/PKGBUILD
    (from rev 1059116, python-flit/trunk/PKGBUILD)

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

Copied: python-flit/repos/community-staging-any/PKGBUILD (from rev 1059116, python-flit/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD	                        (rev 0)
+++ community-staging-any/PKGBUILD	2021-12-01 11:10:11 UTC (rev 1059117)
@@ -0,0 +1,60 @@
+# Maintainer: Filipe Laíns (FFY00) <lains at archlinux.org>
+# Maintainer: Eli Schwartz <eschwartz at archlinux.org>
+
+_pkgname=flit
+pkgbase=python-$_pkgname
+pkgname=($pkgbase{,-core})
+pkgver=3.5.1
+pkgrel=2
+pkgdesc='Simplified packaging of Python modules'
+arch=('any')
+url='https://github.com/takluyver/flit'
+license=('BSD')
+depends=('python' 'python-tomli' 'python-tomli-w')
+makedepends=('python-pip' 'python-poetry' 'python-requests' 'python-docutils')
+checkdepends=('python-pytest' 'python-testpath' 'python-responses')
+source=("$pkgbase-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
+sha512sums=('76a713df9a85e686b5a9516b01b02779ce9e62e5bb189724d4fb62c42324ce1607d9de334c1fa88e95a10089aebba804fac0214fcbed0c47b8fc057732d63339')
+
+prepare() {
+  cd $_pkgname-$pkgver
+  rm tests/test_sdist.py
+  cd flit_core
+  python build_dists.py
+}
+
+build() {
+  cd $_pkgname-$pkgver
+
+  PYTHONPATH=flit_core python -m flit build --format wheel
+}
+
+check() {
+  cd $_pkgname-$pkgver
+
+  PYTHONPATH=flit_core python -m pytest
+}
+
+package_python-flit() {
+  depends+=('python-flit-core' 'python-requests' 'python-docutils')
+  provides=($_pkgname)
+  conflicts=($_pkgname)
+
+  cd $_pkgname-$pkgver
+
+  PIP_CONFIG_FILE=/dev/null pip install --isolated --root="${pkgdir}" --ignore-installed --no-deps dist/*.whl
+  install -Dm 644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python-flit-core() {
+  pkgdesc+=' (core backend)'
+
+  cd $_pkgname-$pkgver/flit_core
+
+  PIP_CONFIG_FILE=/dev/null pip install --isolated --root="${pkgdir}" --ignore-installed --no-deps dist/*.whl
+  install -Dm 644 ../LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+
+  # installing tests to a subdir of your project might not conflict the toplevel, but
+  # don't do it anyway...
+  rm -r "$pkgdir"/usr/lib/python*/site-packages/flit_core/tests/
+}



More information about the arch-commits mailing list