updated on Thu Jan 12 08:01:00 UTC 2012
[aur-mirror.git] / pulseaudio-git / PKGBUILD
blob440ee94d5be1ce13d9e88ace0634a96c919968fa
1 # Maintainer: Clément Démoulins <clement@archivel.fr>
2 # Contributor: Jan "heftig" Steffens <jan.steffens@gmail.com>
3 # Contributor: Daniel J Griffiths <ghost1227@archlinux.us>
4 # Contributor: Corrado Primier <bardo@aur.archlinux.org>
5 # Contributor: William Rea <sillywilly@gmail.com>
6 # Contributor: Lorenzo Nizzi Grifi Gargiolli <lorenzo.nizzi.grifi@gmail.com>
8 pkgname="pulseaudio-git"
9 _pkgname="pulseaudio"
10 pkgdesc="A featureful, general-purpose sound server"
11 pkgver=20110918
12 pkgrel=1
13 arch=(i686 x86_64)
14 url="http://pulseaudio.org/"
15 license=('GPL' 'LGPL')
16 makedepends=(git libasyncns attr libxtst libsm libsndfile
17              libtool rtkit speex libsamplerate tdb udev dbus-core xcb-util
18              avahi bluez gconf intltool jack lirc-utils pkgconfig openssl
19              json-c fftw orc sh)
20 depends=('rtkit' 'libtool' 'speex' 'libsamplerate' 'tdb' 'udev' 'fftw' 'orc'
21          'json-c' 'xcb-util' 'libasyncns' 'libxtst' 'libsm'
22          'libsamplerate' 'json-c')
23 optdepends=('alsa-plugins: ALSA support'
24             'avahi: zeroconf support'
25             'bluez: bluetooth support'
26             'gconf: configuration through gconf'
27             'jack: jack support'
28             'lirc-utils: infra-red support'
29             'openssl: RAOP support')
30 backup=(etc/pulse/{daemon.conf,default.pa,system.pa,client.conf})
31 provides=('pulseaudio=0.9.23' 'libpulse=0.9.23')
32 conflicts=('pulseaudio' 'libpulse')
33 replaces=('pulseaudio' 'libpulse')
34 options=(!emptydirs !libtool !makeflags)
36 source=(${_pkgname}.xinit)
37 md5sums=('eb1cfae28eb2e4d3fdbe45a90e4318ab')
40 _gitroot="git://anongit.freedesktop.org/pulseaudio/pulseaudio"
41 _gitname="pulseaudio"
43 build() {
44   cd "$srcdir"
45   msg "Connecting to GIT server...."
47   if [ -d $_gitname ] ; then
48     cd $_gitname && git pull origin
49     msg "The local files are updated."
50   else
51     git clone $_gitroot $_gitname
52   fi
54   msg "GIT checkout done or server timeout"
55   msg "Starting make..."
57   rm -rf "$srcdir/$_gitname-build"
58   git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build"
59   cd "$srcdir/$_gitname-build"
61   #
62   # BUILD HERE
63   #
65  ./autogen.sh --prefix=/usr \
66               --sysconfdir=/etc \
67               --libexecdir=/usr/lib \
68               --localstatedir=/var \
69               --with-database=tdb \
70               --disable-hal \
71               --disable-rpath \
72               --disable-default-build-tests
74   make
77 package() {
78   cd "$srcdir/$_gitname-build"
79   make DESTDIR="$pkgdir" install
81   # Lower resample quality
82   sed -e '/resample-method/iresample-method=speex-float-0' \
83       -i "$pkgdir/etc/pulse/daemon.conf"
85   # Disable cork-request module, can result in e.g. media players unpausing
86   # when there's a Skype call incoming
87   sed -e 's|/usr/bin/pactl load-module module-x11-cork-request|#&|' \
88       -i "$pkgdir/usr/bin/start-${_pkgname}-x11"
90   # Make module-console-kit optional
91   sed -e $'/module-console-kit/{i.nofail\n;a.fail\n;}' \
92       -i "$pkgdir/etc/pulse/default.pa"
94   install -Dm755 "$srcdir/${_pkgname}.xinit" "$pkgdir/etc/X11/xinit/xinitrc.d/${_pkgname}"
96   rm "$pkgdir/etc/dbus-1/system.d/${_pkgname}-system.conf"