[arch-commits] Commit in rofimoji/trunk (PKGBUILD)

Daniel M. Capella polyzen at archlinux.org
Sat Jun 19 23:31:42 UTC 2021


    Date: Saturday, June 19, 2021 @ 23:31:42
  Author: polyzen
Revision: 965707

upgpkg: rofimoji 5.2.0-1

Modified:
  rofimoji/trunk/PKGBUILD

----------+
 PKGBUILD |   25 ++++++++++++++++++-------
 1 file changed, 18 insertions(+), 7 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2021-06-19 23:23:06 UTC (rev 965706)
+++ PKGBUILD	2021-06-19 23:31:42 UTC (rev 965707)
@@ -1,14 +1,14 @@
 # Maintainer: Daniel M. Capella <polyzen at archlinux.org>
 
 pkgname=rofimoji
-pkgver=5.1.0
-pkgrel=2
+pkgver=5.2.0
+pkgrel=1
 pkgdesc='Character picker for rofi'
 arch=('any')
 url=https://github.com/fdw/rofimoji
 license=('MIT')
 depends=('python-configargparse')
-makedepends=('python-setuptools')
+makedepends=('python-build' 'python-install' 'python-setuptools' 'python-wheel')
 optdepends=('emoji-font: for the emojis character file'
             'nerd-fonts: for the nerd_font character file'
             'rofi: for the X.Org selector'
@@ -20,18 +20,29 @@
             'wtype: for the Wayland typer')
 install=$pkgname.install
 source=("$url/archive/$pkgver/$pkgname-$pkgver.tar.gz")
-b2sums=('0079ea5177fac16126b9874cca95dfe6cea2e827cc985201fe5041941dcb88e87b085dcc4228060c7c6bca473ba1171e0a96b136b7b47037a5b2156f32a7428f')
+b2sums=('9df9024215ba6998d2a2d396ed7b5da905d43eb5506bd2de3ffd163d727f30c2ac4b7e5fd27d44ea1af0ce54c8ac0a4a06b19bafab1e62d1bd5e4a3cfcf41a9c')
 
 build() {
   cd $pkgname-$pkgver
-  python setup.py build
+  python -m build --wheel --skip-dependency-check --no-isolation
 }
 
 package() {
   cd $pkgname-$pkgver
   export PYTHONHASHSEED=0
-  python setup.py install --root="$pkgdir" --optimize=1 --skip-build
-  install -Dm644 -t "$pkgdir"/usr/share/licenses/$pkgname LICENSE
+  python -m install --optimize=1 --destdir="$pkgdir" dist/*.whl
+
+  cd "$pkgdir"
+  # https://github.com/FFY00/python-install/pull/6
+  chmod +x usr/bin/$pkgname
+
+  # Symlink license file and move data files where they belong
+  local site_packages=$(python -c "import site; print(site.getsitepackages()[0])")
+  install -d usr/share/{licenses/$pkgname,man/man1}
+  ln -s $site_packages/${pkgname//-/_}-$pkgver.dist-info/LICENSE \
+    usr/share/licenses/$pkgname/LICENSE
+  mv {./$site_packages,usr}/share/man/man1/$pkgname.1
+  rm -r ./$site_packages/share
 }
 
 # vim:set ts=2 sw=2 et:



More information about the arch-commits mailing list