mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-05 05:37:15 +08:00
75 lines
2.5 KiB
Bash
75 lines
2.5 KiB
Bash
#
|
|
# Platform Packages for Chakra, part of chakra-project.org
|
|
#
|
|
# maintainer abveritas@chakra-project.org
|
|
|
|
pkgname=pulseaudio
|
|
pkgdesc="A featureful, general-purpose sound server"
|
|
pkgver=2.1
|
|
pkgrel=6
|
|
arch=('i686' 'x86_64')
|
|
url="http://pulseaudio.org/"
|
|
license=('GPL' 'LGPL')
|
|
depends=('dbus-core' 'xcb-util' 'libasyncns' 'libcap' 'libxtst' 'libsm'
|
|
'libsamplerate' 'json-c' 'rtkit' 'libltdl' 'speex' 'tdb'
|
|
'fftw' 'orc' 'webrtc-audio-processing' 'systemd>=189')
|
|
makedepends=('attr' 'libltdl' 'avahi' 'bluez' 'intltool' 'jack' 'lirc-utils' 'openssl')
|
|
optdepends=('avahi: zeroconf support'
|
|
'bluez: bluetooth support'
|
|
'jack: jack support'
|
|
'lirc-utils: infra-red support'
|
|
'openssl: RAOP support')
|
|
backup=(etc/pulse/{daemon.conf,default.pa,system.pa})
|
|
install="pulseaudio.install"
|
|
provides=('libpulse=${pkgver}')
|
|
replaces=('libpulse')
|
|
conflicts=('libpulse')
|
|
options=(!emptydirs !libtool !makeflags)
|
|
source=("http://freedesktop.org/software/${pkgbase}/releases/${pkgname}-${pkgver}.tar.xz")
|
|
sha256sums=('ef6b347bf47abfb98080795f1583018ac959b4aeb4df916b879f9e1eaba0ca7f')
|
|
|
|
build() {
|
|
cd "${srcdir}/${pkgname}-${pkgver}"
|
|
|
|
./configure --prefix=/usr \
|
|
--sysconfdir=/etc \
|
|
--libexecdir=/usr/lib \
|
|
--localstatedir=/var \
|
|
--with-udev-rules-dir=/usr/lib/udev/rules.d \
|
|
--with-database=tdb \
|
|
--disable-hal \
|
|
--disable-tcpwrap \
|
|
--disable-rpath \
|
|
--disable-default-build-tests
|
|
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd "${srcdir}/${pkgname}-${pkgver}"
|
|
make DESTDIR="${pkgdir}" install
|
|
|
|
# Lower resample quality, saves CPU
|
|
sed -e '/resample-method/iresample-method=speex-float-0' \
|
|
-i "${pkgdir}/etc/pulse/daemon.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 "${pkgdir}/usr/bin/start-pulseaudio-x11"
|
|
|
|
# Make some modules optional
|
|
sed -e $'/load-module module-console-kit/{i.nofail\n;a.fail\n;}' \
|
|
-e '/load-module module-jackdbus-detect/s/^/#/' \
|
|
-i "${pkgdir}/etc/pulse/default.pa"
|
|
|
|
# Python fix
|
|
sed -i '1s:python$:&2:' "${pkgdir}/usr/bin/qpaeq"
|
|
|
|
rm "${pkgdir}/etc/dbus-1/system.d/pulseaudio-system.conf"
|
|
|
|
# Delay of sound notification workaround, needs to be removed once fixed in systemd
|
|
sed -i -e 's/load-module module-udev-detect/load-module module-udev-detect tsched=0/' "${pkgdir}/etc/pulse/default.pa"
|
|
|
|
}
|