archrelease: copy trunk to extra-x86_64
[arch-packages.git] / wireplumber / trunk / PKGBUILD
blob178fbe950f1a92b7c523f76cc6184bf162401755
1 # Maintainer: David Runge <dvzrv@archlinux.org>
2 # Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
4 pkgbase=wireplumber
5 pkgname=(wireplumber wireplumber-docs)
6 _commit=80b3559963f0ad40a7bfa6c23b0098275c0b5ebe  # tags/0.4.11
7 pkgver=0.4.11
8 pkgrel=3
9 pkgdesc="Session / policy manager implementation for PipeWire"
10 url="https://pipewire.pages.freedesktop.org/wireplumber/"
11 arch=(x86_64)
12 license=(MIT)
13 makedepends=(git meson doxygen graphviz 'pipewire>=0.3.52' systemd glib2 lua
14              gobject-introspection python-sphinx python-sphinx_rtd_theme
15              python-breathe python-lxml)
16 options=(debug)
17 source=("$pkgbase::git+https://gitlab.freedesktop.org/pipewire/wireplumber.git#commit=$_commit")
18 sha256sums=('SKIP')
20 pkgver() {
21   cd $pkgbase
22   git describe --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
25 prepare() {
26   cd $pkgbase
28   # Fix sound inside VM
29   git cherry-pick -n c16e637c329bc9dda8544b18f5bd47a8d63ee253
31   # https://bugs.archlinux.org/task/75352
32   git cherry-pick -n eb406bdb2cbbcd49c55c71285f8f2eddb624d24b
35 build() {
36   local meson_options=(
37     -D system-lua=true
38     -D elogind=disabled
39   )
41   arch-meson $pkgbase build "${meson_options[@]}"
42   meson compile -C build
45 check() {
46   meson test -C build --print-errorlogs
49 _pick() {
50   local p="$1" f d; shift
51   for f; do
52     d="$srcdir/$p/${f#$pkgdir/}"
53     mkdir -p "$(dirname "$d")"
54     mv "$f" "$d"
55     rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
56   done
59 package_wireplumber() {
60   depends=('pipewire>=0.3.52' lua libpipewire-0.3.so libsystemd.so
61            libg{lib,module,object,io}-2.0.so)
62   optdepends=('wireplumber-docs: Documentation')
63   provides=(pipewire-session-manager libwireplumber-0.4.so)
64   conflicts=(pipewire-media-session)
65   install=wireplumber.install
67   meson install -C build --destdir "$pkgdir"
69   _pick docs "$pkgdir"/usr/share/doc
71   install -Dt "$pkgdir/usr/share/doc/$pkgname" -m644 $pkgbase/{NEWS,README}*
72   install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 $pkgbase/LICENSE
75 package_wireplumber-docs() {
76   pkgdesc+=" - documentation"
78   mv docs/* "$pkgdir"
80   install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 $pkgbase/LICENSE
83 # vim:set sw=2 et: