summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMr. Tao2020-07-23 21:05:43 +0200
committerMr. Tao2020-07-23 21:08:56 +0200
commit8a47c866e41bc856c1a957af24ab219b34889095 (patch)
tree199df4cf201d421e2cc6b3a78e72a1bf92d9fdbd
downloadaur-8a47c866e41bc856c1a957af24ab219b34889095.tar.gz
Add support for AirPlay 2 devices
https://gitlab.freedesktop.org/ckdo/pulseaudio/-/commit/938fb6411540e31137396b97dd2011ebba4bd650
-rw-r--r--.SRCINFO115
-rw-r--r--0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch28
-rw-r--r--PKGBUILD193
-rw-r--r--pulseaudio.install14
4 files changed, 350 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..fb5ab4cbffa
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,115 @@
+pkgbase = pulseaudio-airplay
+ pkgdesc = A featureful, general-purpose sound server
+ pkgver = 12.0+527+g938fb6411
+ pkgrel = 1
+ url = https://www.freedesktop.org/wiki/Software/PulseAudio/
+ arch = x86_64
+ license = GPL
+ makedepends = libasyncns
+ makedepends = libcap
+ makedepends = attr
+ makedepends = libxtst
+ makedepends = libsm
+ makedepends = libsndfile
+ makedepends = rtkit
+ makedepends = libsoxr
+ makedepends = speexdsp
+ makedepends = tdb
+ makedepends = systemd
+ makedepends = dbus
+ makedepends = avahi
+ makedepends = bluez
+ makedepends = bluez-libs
+ makedepends = jack2
+ makedepends = sbc
+ makedepends = lirc
+ makedepends = openssl
+ makedepends = fftw
+ makedepends = orc
+ makedepends = gtk3
+ makedepends = webrtc-audio-processing
+ makedepends = check
+ makedepends = git
+ makedepends = meson
+ makedepends = xmltoman
+ source = git+https://gitlab.freedesktop.org/ckdo/pulseaudio.git#commit=938fb6411540e31137396b97dd2011ebba4bd650
+ source = 0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch
+ sha256sums = SKIP
+ sha256sums = 4ff133e2847baad5bb6798b5816d67551cfba2efabb2f1f348628d7217abd07d
+
+pkgname = pulseaudio-airplay
+ install = pulseaudio.install
+ depends = libpulse-airplay=12.0+527+g938fb6411-1
+ depends = rtkit
+ depends = libltdl
+ depends = speexdsp
+ depends = tdb
+ depends = orc
+ depends = libsoxr
+ depends = webrtc-audio-processing
+ optdepends = pulseaudio-alsa: ALSA configuration (recommended)
+ provides = pulseaudio
+ conflicts = pulseaudio
+ replaces = pulseaudio-xen<=9.0
+ replaces = pulseaudio-gconf<=11.1
+ backup = etc/pulse/daemon.conf
+ backup = etc/pulse/default.pa
+ backup = etc/pulse/system.pa
+
+pkgname = libpulse-airplay
+ pkgdesc = A featureful, general-purpose sound server (client library)
+ license = LGPL
+ depends = dbus
+ depends = libasyncns
+ depends = libcap
+ depends = libxtst
+ depends = libsm
+ depends = libsndfile
+ depends = systemd
+ provides = libpulse.so
+ provides = libpulse-simple.so
+ provides = libpulse-mainloop-glib.so
+ conflicts = libpulse
+ backup = etc/pulse/client.conf
+
+pkgname = pulseaudio-airplay-zeroconf
+ pkgdesc = Zeroconf support for PulseAudio
+ depends = pulseaudio-airplay=12.0+527+g938fb6411-1
+ depends = avahi
+ depends = openssl
+ provides = pulseaudio-zeroconf
+ conflicts = pulseaudio-zeroconf
+
+pkgname = pulseaudio-airplay-lirc
+ pkgdesc = IR (lirc) support for PulseAudio
+ depends = pulseaudio-airplay=12.0+527+g938fb6411-1
+ depends = lirc
+ provides = pulseaudio-lirc
+ conflicts = pulseaudio-lirc
+
+pkgname = pulseaudio-airplay-jack
+ pkgdesc = Jack support for PulseAudio
+ depends = pulseaudio-airplay=12.0+527+g938fb6411-1
+ depends = jack
+ provides = pulseaudio-jack
+ conflicts = pulseaudio-jack
+
+pkgname = pulseaudio-airplay-bluetooth
+ pkgdesc = Bluetooth support for PulseAudio
+ depends = pulseaudio-airplay=12.0+527+g938fb6411-1
+ depends = bluez
+ depends = bluez-libs
+ depends = sbc
+ provides = pulseaudio-bluetooth
+ conflicts = pulseaudio-bluetooth
+
+pkgname = pulseaudio-airplay-equalizer
+ pkgdesc = Equalizer for PulseAudio
+ depends = pulseaudio-airplay=12.0+527+g938fb6411-1
+ depends = python-pyqt5
+ depends = python-dbus
+ depends = python-sip
+ depends = fftw
+ provides = pulseaudio-equalizer
+ conflicts = pulseaudio-equalizer
+
diff --git a/0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch b/0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch
new file mode 100644
index 00000000000..6e6beeade13
--- /dev/null
+++ b/0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch
@@ -0,0 +1,28 @@
+From c7e0c4373a304e167b11a68575b9da9506345dab Mon Sep 17 00:00:00 2001
+From: "Jan Alexander Steffens (heftig)" <jan.steffens@gmail.com>
+Date: Sun, 15 Sep 2019 13:47:19 +0200
+Subject: [PATCH] meson: Define TUNNEL_SINK for module-tunnel-sink
+
+This was missing, so it was building another tunnel-source instead.
+
+Fixes https://bugs.archlinux.org/task/63755
+---
+ src/modules/meson.build | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/modules/meson.build b/src/modules/meson.build
+index 92d5871f9..dd2241f42 100644
+--- a/src/modules/meson.build
++++ b/src/modules/meson.build
+@@ -55,7 +55,7 @@ all_modules = [
+ [ 'module-suspend-on-idle', 'module-suspend-on-idle.c' ],
+ [ 'module-switch-on-connect', 'module-switch-on-connect.c' ],
+ [ 'module-switch-on-port-available', 'module-switch-on-port-available.c' ],
+- [ 'module-tunnel-sink', 'module-tunnel.c', [], [], [x11_dep] ],
++ [ 'module-tunnel-sink', 'module-tunnel.c', [], ['-DTUNNEL_SINK=1'], [x11_dep] ],
+ [ 'module-tunnel-sink-new', 'module-tunnel-sink-new.c' ],
+ [ 'module-tunnel-source', 'module-tunnel.c', [], [], [x11_dep] ],
+ [ 'module-tunnel-source-new', 'module-tunnel-source-new.c' ],
+--
+2.23.0
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..09fdff012cd
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,193 @@
+# Maintainer: Mr. Tao <tao@post.cz>
+# Contributtor: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
+# Contributor: Daniel J Griffiths <ghost1227@archlinux.us>
+# Contributor: Corrado Primier <bardo@aur.archlinux.org>
+# Contributor: William Rea <sillywilly@gmail.com>
+
+pkgname=(pulseaudio-airplay libpulse-airplay pulseaudio-airplay-{zeroconf,lirc,jack,bluetooth,equalizer})
+pkgdesc="A featureful, general-purpose sound server"
+pkgver=12.0+527+g938fb6411
+pkgrel=1
+arch=(x86_64)
+url="https://www.freedesktop.org/wiki/Software/PulseAudio/"
+license=(GPL)
+makedepends=(libasyncns libcap attr libxtst libsm libsndfile rtkit libsoxr
+ speexdsp tdb systemd dbus avahi bluez bluez-libs jack2 sbc
+ lirc openssl fftw orc gtk3 webrtc-audio-processing check git meson
+ xmltoman)
+_commit=938fb6411540e31137396b97dd2011ebba4bd650 # tags/v13.0^0
+source=("git+https://gitlab.freedesktop.org/ckdo/pulseaudio.git#commit=$_commit"
+ 0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch)
+sha256sums=('SKIP'
+ '4ff133e2847baad5bb6798b5816d67551cfba2efabb2f1f348628d7217abd07d')
+
+pkgver() {
+ cd pulseaudio
+ git describe --tags | sed 's/^v//;s/-/+/g'
+}
+
+prepare() {
+ cd pulseaudio
+
+ # Freeze version before patching
+ ./git-version-gen doesnt-exist >.tarball-version
+
+ # https://bugs.archlinux.org/task/63755
+ git apply -3 ../0001-meson-Define-TUNNEL_SINK-for-module-tunnel-sink.patch
+}
+
+build() {
+ arch-meson pulseaudio build \
+ -D gcov=false \
+ -D pulsedsp-location='/usr/\$LIB/pulseaudio' \
+ -D udevrulesdir=/usr/lib/udev/rules.d
+ ninja -C build
+}
+
+check() {
+ meson test -C build --print-errorlogs
+ ninja -C build test-daemon
+}
+
+_pick() {
+ local p="$1" f d; shift
+ for f; do
+ d="$srcdir/$p/${f#$pkgdir/}"
+ mkdir -p "$(dirname "$d")"
+ mv "$f" "$d"
+ rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")"
+ done
+}
+
+package_pulseaudio-airplay() {
+ provides=(pulseaudio)
+ conflicts=(pulseaudio)
+ depends=("libpulse-airplay=$pkgver-$pkgrel" rtkit libltdl speexdsp tdb orc libsoxr
+ webrtc-audio-processing)
+ optdepends=('pulseaudio-alsa: ALSA configuration (recommended)')
+ backup=(etc/pulse/{daemon.conf,default.pa,system.pa})
+ install=pulseaudio.install
+ replaces=('pulseaudio-xen<=9.0' 'pulseaudio-gconf<=11.1')
+
+ local pulsever=$(cd pulseaudio; ./git-version-gen .tarball-version)
+ while [[ $pulsever = *.*.* ]]; do
+ pulsever=${pulsever%.*}
+ done
+ pulsever=${pulsever%%-*}
+
+ DESTDIR="$pkgdir" meson install -C build
+
+ cd "$pkgdir"
+
+ # Assumes that any volume adjustment is intended by the user, who can control
+ # each app's volume. Misbehaving clients can trigger earsplitting volume
+ # jumps. App volumes can diverge wildly and cause apps without their own
+ # volume control to fall below sink volume; a sink-only volume control will
+ # suddenly be unable to make such an app loud enough.
+ sed -e '/flat-volumes/iflat-volumes = no' \
+ -i etc/pulse/daemon.conf
+
+ # Superseded by socket activation
+ sed -e '/autospawn/iautospawn = no' \
+ -i etc/pulse/client.conf
+
+ # Disable cork-request module, can result in e.g. media players unpausing
+ # when there's a Skype call incoming
+ sed -e 's|/usr/bin/pactl load-module module-x11-cork-request|#&|' \
+ -i usr/bin/start-pulseaudio-x11
+
+ # Required by qpaeq
+ sed -e '/Load several protocols/aload-module module-dbus-protocol' \
+ -i etc/pulse/default.pa
+
+ rm -r etc/dbus-1
+
+### Split libpulse
+ _pick libpulse etc/pulse/client.conf
+ _pick libpulse usr/bin/pa{cat,ctl,dsp,mon,play,rec,record}
+ _pick libpulse usr/lib/libpulse{,-simple,-mainloop-glib}.so*
+ _pick libpulse usr/lib/{cmake,pkgconfig}
+ _pick libpulse usr/lib/pulseaudio/libpulse{dsp,common-*}.so
+ _pick libpulse usr/include
+ _pick libpulse usr/share/man/man1/pa{cat,ctl,dsp,mon,play,rec,record}.1
+ _pick libpulse usr/share/man/man5/pulse-client.conf.5
+ _pick libpulse usr/share/vala
+
+### Split modules
+ local moddir=usr/lib/pulse-$pulsever/modules
+
+ _pick zeroconf $moddir/libavahi-wrap.so
+ _pick zeroconf $moddir/module-zeroconf-{publish,discover}.so
+ _pick zeroconf $moddir/module-raop-discover.so
+
+ _pick lirc $moddir/module-lirc.so
+
+ _pick jack $moddir/module-jack-{sink,source}.so
+ _pick jack $moddir/module-jackdbus-detect.so
+
+ _pick bluetooth $moddir/libbluez5-util.so
+ _pick bluetooth $moddir/module-bluetooth-{discover,policy}.so
+ _pick bluetooth $moddir/module-bluez5-{discover,device}.so
+
+ _pick equalizer $moddir/module-equalizer-sink.so
+ _pick equalizer usr/bin/qpaeq
+}
+
+package_libpulse-airplay() {
+ provides=(libpulse)
+ conflicts=(libpulse)
+ pkgdesc="$pkgdesc (client library)"
+ depends=(dbus libasyncns libcap libxtst libsm libsndfile systemd)
+ provides=(libpulse{,-simple,-mainloop-glib}.so)
+ license=(LGPL)
+ backup=(etc/pulse/client.conf)
+
+ mv libpulse/* "$pkgdir"
+}
+
+package_pulseaudio-airplay-zeroconf(){
+ provides=(pulseaudio-zeroconf)
+ conflicts=(pulseaudio-zeroconf)
+ pkgdesc="Zeroconf support for PulseAudio"
+ depends=("pulseaudio-airplay=$pkgver-$pkgrel" avahi openssl)
+
+ mv zeroconf/* "$pkgdir"
+}
+
+package_pulseaudio-airplay-lirc(){
+ provides=(pulseaudio-lirc)
+ conflicts=(pulseaudio-lirc)
+ pkgdesc="IR (lirc) support for PulseAudio"
+ depends=("pulseaudio-airplay=$pkgver-$pkgrel" lirc)
+
+ mv lirc/* "$pkgdir"
+}
+
+package_pulseaudio-airplay-jack(){
+ provides=(pulseaudio-jack)
+ conflicts=(pulseaudio-jack)
+ pkgdesc="Jack support for PulseAudio"
+ depends=("pulseaudio-airplay=$pkgver-$pkgrel" jack)
+
+ mv jack/* "$pkgdir"
+}
+
+package_pulseaudio-airplay-bluetooth(){
+ provides=(pulseaudio-bluetooth)
+ conflicts=(pulseaudio-bluetooth)
+ pkgdesc="Bluetooth support for PulseAudio"
+ depends=("pulseaudio-airplay=$pkgver-$pkgrel" bluez bluez-libs sbc)
+
+ mv bluetooth/* "$pkgdir"
+}
+
+package_pulseaudio-airplay-equalizer(){
+ provides=(pulseaudio-equalizer)
+ conflicts=(pulseaudio-equalizer)
+ pkgdesc="Equalizer for PulseAudio"
+ depends=("pulseaudio-airplay=$pkgver-$pkgrel" python-{pyqt5,dbus,sip} fftw)
+
+ mv equalizer/* "$pkgdir"
+}
+
+# vim:set sw=2 et:
diff --git a/pulseaudio.install b/pulseaudio.install
new file mode 100644
index 00000000000..f6f8478d05c
--- /dev/null
+++ b/pulseaudio.install
@@ -0,0 +1,14 @@
+post_install() {
+ # Enable socket by default
+ systemctl --global enable pulseaudio.socket
+}
+
+post_upgrade() {
+ if (( $(vercmp $2 8.0-3) < 0)); then
+ systemctl --global enable pulseaudio.socket
+ fi
+}
+
+pre_remove() {
+ systemctl --global disable pulseaudio.socket
+}