yochananmarqos

ulauncher

Dec 7th, 2020 (edited)
122
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. pkgname=ulauncher
  2. pkgver=5.9.0
  3. pkgrel=1
  4. pkgdesc="Application launcher for Linux"
  5. arch=('any')
  6. url="https://ulauncher.io"
  7. license=('GPL3')
  8. depends=('libkeybinder3' 'gtk3' 'webkit2gtk' 'libnotify' 'gdk-pixbuf2' 'python-dbus'
  9.          'python-levenshtein' 'python-pyinotify' 'python-websocket-client'
  10.          'python-pyxdg' 'python-gobject')
  11. makedepends=('python-distutils-extra')
  12. checkdepends=('desktop-file-utils')
  13. optdepends=('libappindicator-gtk3: tray icon'
  14.             'wmctrl: fix window focus on Wayland')
  15. install="$pkgname.install"
  16. source=("https://github.com/Ulauncher/Ulauncher/releases/download/$pkgver/${pkgname}_${pkgver}.tar.gz"
  17.         "https://github.com/Ulauncher/Ulauncher/raw/$pkgver/contrib/systemd/$pkgname.service")
  18. sha256sums=('8d10ab9097235070dddf017e1e4c60d10696ed880887bcccfca6784c01fce3f5'
  19.             'acf583f52933c0f01fb02a64f4103b235c1780d2203e644ed1c7033c22fde4a2')
  20.  
  21. prepare() {
  22.     cd "$srcdir/$pkgname"
  23.     find -iname "*.py" | xargs sed -i 's=\(^#! */usr/bin.*\)python3 *$=\1python='
  24. }
  25.  
  26. build() {
  27.     cd "$srcdir/$pkgname"
  28.     python setup.py build
  29. }
  30.  
  31. check() {
  32.     cd "$srcdir/$pkgname"
  33.     desktop-file-validate "build/share/applications/$pkgname.desktop"
  34. }
  35.  
  36. package() {
  37.     cd "$srcdir/$pkgname"
  38.    
  39.     # https://github.com/Ulauncher/Ulauncher/issues/521
  40.     install -Dm644 "build/share/applications/$pkgname.desktop" -t \
  41.         "$pkgdir/usr/share/applications"
  42.        
  43.     export PYTHONHASHSEED=0
  44.     python setup.py install --root="$pkgdir" --optimize=1 --skip-build
  45.    
  46.     install -Dm644 "$srcdir/$pkgname.service" -t "$pkgdir/usr/lib/systemd/user"
  47. }
RAW Paste Data