blob: 85e13bf88cca4a8e933d44ca874f669e200e6063 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
# Maintainer: Isaac Arcia <[EMAIL]>
pkgname=yawns
pkgver=1.3.1
pkgrel=1
pkgdesc="Your Adaptable Widget Notification System"
arch=('any')
url="https://github.com/ikz87/yawns"
license=('GPL-3.0')
depends=(
'python'
'python-pyqt6'
'python-dbus-next'
'python-pillow'
'python-cssutils'
'python-xlib'
'python-gobject'
'python-setproctitle'
'gtk3'
'qt6-base'
'qt6-wayland'
'wayland'
)
makedepends=(
'make'
'gcc'
'pkgconf'
'qt6-base'
'qt6-wayland'
'wayland'
)
source=("$pkgname-$pkgver.tar.gz::$url/archive/refs/tags/v$pkgver.tar.gz")
sha256sums=('50915b3a4ef25a11e215a3021d2348a68ed01ed61f54857b9e12a1a6efd5c54b')
build() {
cd "$srcdir/$pkgname-$pkgver"
# Native Wayland helper (wlr-layer-shell). Only needed on Wayland, but it
# is cheap to build and keeps a single package for both display servers.
make -C src/backends/wayland
}
package() {
cd "$srcdir/$pkgname-$pkgver"
# Application tree
install -d "$pkgdir/usr/lib/$pkgname"
cp -r src assets LICENSE.md "$pkgdir/usr/lib/$pkgname/"
# Native helper: install next to the Python backend and drop the
# intermediate build directory copied along with the source tree.
install -Dm755 "src/backends/wayland/build/libyawns_wayland.so" \
"$pkgdir/usr/lib/$pkgname/src/backends/wayland/libyawns_wayland.so"
rm -rf "$pkgdir/usr/lib/$pkgname/src/backends/wayland/build"
# Assets
install -d "$pkgdir/usr/share/$pkgname/assets"
install -m644 assets/vinyl.png "$pkgdir/usr/share/$pkgname/assets/vinyl.png"
install -m644 assets/yawns-logo.png "$pkgdir/usr/share/$pkgname/assets/yawns-logo.png"
# Launcher: seed the user config on first run, then start yawns.
install -d "$pkgdir/usr/bin"
cat > "$pkgdir/usr/bin/$pkgname" <<'EOF'
#!/bin/bash
if [ ! -d "$HOME/.config/yawns" ]; then
mkdir -p "$HOME/.config/yawns"
cp "/usr/lib/yawns/src/config.ini" "$HOME/.config/yawns/config.ini"
cp "/usr/lib/yawns/src/style.qss" "$HOME/.config/yawns/style.qss"
fi
exec python3 /usr/lib/yawns/src/app.py "$@"
EOF
chmod +x "$pkgdir/usr/bin/$pkgname"
}
|