-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
template
38 lines (34 loc) · 1.57 KB
/
template
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
# Template file for 'helvum'
pkgname=helvum
version=0.5.1
revision=1
build_style=cargo
hostmakedepends="pkg-config clang libclang"
makedepends="gtk4-devel pipewire-devel glib-devel libadwaita-devel"
depends="pipewire"
short_desc="GTK patchbay for pipewire"
maintainer="0x5c <dev@0x5c.io>"
license="GPL-3.0-only"
homepage="https://gitlab.freedesktop.org/pipewire/helvum"
distfiles="https://gitlab.freedesktop.org/pipewire/helvum/-/archive/${version}/helvum-${version}.tar.gz"
checksum=e7a179a35518d7add92affbe5cdaa90c4a4e20c25ae0c86c2aea470de7dcd7ed
post_patch() {
cat <<-EOF >> "Cargo.toml"
[patch.crates-io]
pipewire = {git="https://gitlab.freedesktop.org/pipewire/pipewire-rs.git", rev="ff923ee9dfe05ac50a137252ca45ac4361016360"}
EOF
# Needed to get the above to register
cargo update --package pipewire@0.7.2 --precise 0.7.2
}
post_install() {
# Normally, meson would do this, but it's simpler to use the cargo build style and do this manually
# This also avoids the need for makedeps/build steps that are made unnecessary by xbps' hooks
# On update, all meson.build files should be checked for changes
_app_id='org.pipewire.Helvum'
vinstall data/icons/$_app_id.svg 644 usr/share/icons/hicolor/scalable/apps/
vinstall data/icons/$_app_id-symbolic.svg 644 usr/share/icons/hicolor/symbolic/apps/
vsed -i data/$_app_id.desktop.in -e "s/@icon@/$_app_id/"
vinstall data/$_app_id.desktop.in 644 usr/share/applications/ $_app_id.desktop
vsed -i data/$_app_id.metainfo.xml.in -e "s/@app-id@/$_app_id/"
vinstall data/$_app_id.metainfo.xml.in 644 usr/share/metainfo/ $_app_id.metainfo.xml
}