summaryrefslogtreecommitdiff
path: root/community/jack2/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/jack2/PKGBUILD')
-rw-r--r--community/jack2/PKGBUILD87
1 files changed, 63 insertions, 24 deletions
diff --git a/community/jack2/PKGBUILD b/community/jack2/PKGBUILD
index 45e9753e2..f457100d7 100644
--- a/community/jack2/PKGBUILD
+++ b/community/jack2/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 52694 2011-07-27 17:23:48Z schiv $
+# $Id: PKGBUILD 60072 2011-12-04 18:08:53Z schiv $
# Maintainer: Ray Rashif <schiv@archlinux.org>
# Contributor: Daniele Paolella <danielepaolella@email.it>
# Contributor: Philipp Überbacher <hollunder at gmx dot at>
@@ -6,30 +6,45 @@
pkgbase=jack2
pkgname=('jack2' 'jack2-dbus')
+#pkgname= # single build (overrides split)
_tarname=jack
pkgver=1.9.7
-pkgrel=2
+pkgrel=3
arch=('i686' 'x86_64' 'mips64el')
url="http://jackaudio.org/"
+backup=(etc/security/limits.d/99-audio.conf)
license=('GPL')
-makedepends=('python2' 'doxygen' 'libffado' 'celt'
- 'libsamplerate' 'dbus-core')
+makedepends=('python2' 'doxygen' 'libffado'
+ 'libsamplerate' 'dbus-core' 'celt')
[ "$CARCH" = "mips64el" ] && \
-makedepends=('python2' 'doxygen' 'celt'
- 'libsamplerate' 'dbus-core')
-source=("http://www.grame.fr/~letz/$_tarname-$pkgver.tar.bz2")
-md5sums=('9759670feecbd43eeccf1c0f743ec199')
+makedepends=('python2' 'doxygen'
+ 'libsamplerate' 'dbus-core' 'celt')
+source=("http://www.grame.fr/~letz/$_tarname-$pkgver.tar.bz2"
+ '99-audio.conf'
+ '40-hpet-permissions.rules')
+md5sums=('9759670feecbd43eeccf1c0f743ec199'
+ 'ae65b7c9ebe0fff6c918ba9d97ae342d'
+ '471aad533ff56c5d3cbbf65ce32cadef')
_pyfix() {
- sed -i 's:bin/env python:bin/env python2:' "$pkgdir/usr/bin/jack_control"
+ sed -i 's:bin/env python:bin/env python2:' \
+ "$pkgdir/usr/bin/jack_control"
}
_wafconf() {
if [ "$CARCH" = "mips64el" ]; then
- python2 waf configure --prefix=/usr --alsa --doxygen $@
+ firewire=""
else
- python2 waf configure --prefix=/usr --alsa --firewire --doxygen $@
+ firewire=--firewire
fi
+ python2 waf configure --prefix=/usr \
+ --alsa \
+ $firewire \
+ --doxygen $@
+}
+
+_isbuild() {
+ printf "%s\n" ${pkgname[@]} | grep -qx $1
}
build() {
@@ -38,23 +53,31 @@ build() {
# fix doxygen building
sed -i 's:build/default/html:html:' $_tarname-$pkgver/wscript
- # we're going to do 2 different builds
+ # we may do 2 different builds
cp -r $_tarname-$pkgver $_tarname-dbus-$pkgver
# mixed dbus/classic build
- cd $_tarname-$pkgver
- msg2 "Running Mixed D-Bus/Classic build"
- _wafconf --classic --dbus
- python2 waf build $MAKEFLAGS
+ if _isbuild jack2; then
+ cd $_tarname-$pkgver
+ msg2 "Running Mixed D-Bus/Classic build"
+ _wafconf --classic --dbus
+ python2 waf build $MAKEFLAGS
+ cd ..
+ fi
# dbus-ONLY build
- cd ../$_tarname-dbus-$pkgver
- msg2 "Running D-Bus-only build"
- _wafconf --dbus
- python2 waf build $MAKEFLAGS
+ if _isbuild jack2-dbus; then
+ cd $_tarname-dbus-$pkgver
+ msg2 "Running D-Bus-only build"
+ _wafconf --dbus
+ python2 waf build $MAKEFLAGS
+ cd ..
+ fi
}
package_jack2() {
+ ! _isbuild jack2 && return
+
pkgdesc="The next-generation JACK with SMP support"
depends=('libsamplerate')
optdepends=('libffado: FireWire support'
@@ -66,8 +89,8 @@ package_jack2() {
'dbus-core: jackdbus'
'python2: jack_control')
conflicts=('jack')
- provides=('jack' 'jack-audio-connection-kit' 'jackdbus'
- 'jack-audio-connection-kit-mp' 'jackmp' 'jackdmp')
+ provides=('jack' 'jack-audio-connection-kit'
+ 'jackmp' 'jackdmp' 'jackdbus')
cd "$srcdir/$_tarname-$pkgver"
@@ -75,9 +98,19 @@ package_jack2() {
# fix for major python transition
_pyfix
+
+ # configure realtime access/scheduling
+ # see https://bugs.archlinux.org/task/26343
+ install -Dm644 "$srcdir/99-audio.conf" \
+ "$pkgdir/etc/security/limits.d/99-audio.conf"
+
+ install -Dm644 "$srcdir/40-hpet-permissions.rules" \
+ "$pkgdir/lib/udev/rules.d/40-hpet-permissions.rules"
}
package_jack2-dbus() {
+ ! _isbuild jack2-dbus && return
+
pkgdesc="The next-generation JACK with SMP support (for D-BUS interaction only)"
depends=('libsamplerate' 'dbus-core')
optdepends=('libffado: FireWire support'
@@ -87,14 +120,20 @@ package_jack2-dbus() {
optdepends=('celt: NetJACK2 driver'
'python2: jack_control')
conflicts=('jack' 'jack2')
- provides=('jack' 'jack2' 'jack-audio-connection-kit' 'jackdbus'
- 'jack-audio-connection-kit-mp' 'jackmp' 'jackdmp')
+ provides=('jack' 'jack2' 'jack-audio-connection-kit'
+ 'jackmp' 'jackdmp' 'jackdbus')
cd "$srcdir/$_tarname-dbus-$pkgver"
python2 waf install --destdir="$pkgdir"
_pyfix
+
+ install -Dm644 "$srcdir/99-audio.conf" \
+ "$pkgdir/etc/security/limits.d/99-audio.conf"
+
+ install -Dm644 "$srcdir/40-hpet-permissions.rules" \
+ "$pkgdir/lib/udev/rules.d/40-hpet-permissions.rules"
}
# vim:set ts=2 sw=2 et: