2010-07-31 15:05:58 +02:00
|
|
|
{ stdenv, fetchurl, pkgconfig, gnum4, gdbm, libtool, glib, dbus, avahi
|
2011-07-07 19:24:31 +02:00
|
|
|
, gconf, gtk, libX11, libICE, libSM, libXtst, libXi, intltool, gettext
|
2011-07-31 21:44:58 +02:00
|
|
|
, alsaLib, libsamplerate, libsndfile, speex, bluez, udev
|
|
|
|
, jackaudioSupport ? false, jackaudio ? null }:
|
2008-12-19 15:56:37 +01:00
|
|
|
|
2011-07-30 20:51:42 +02:00
|
|
|
assert jackaudioSupport -> jackaudio != null;
|
2008-12-19 15:56:37 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2011-07-07 19:24:31 +02:00
|
|
|
name = "pulseaudio-0.9.23";
|
2008-12-19 15:56:37 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2011-07-07 19:24:31 +02:00
|
|
|
url = "http://freedesktop.org/software/pulseaudio/releases/${name}.tar.gz";
|
2011-07-31 21:44:58 +02:00
|
|
|
sha256 = "0kms3w1i48j9368amr8wv83gk4szrnglh1biyp8jyqyb2k388gmg";
|
2008-12-19 15:56:37 +01:00
|
|
|
};
|
|
|
|
|
2009-05-11 23:11:25 +02:00
|
|
|
# Since `libpulse*.la' contain `-lgdbm', it must be propagated.
|
|
|
|
propagatedBuildInputs = [ gdbm ];
|
|
|
|
|
2011-07-07 19:24:31 +02:00
|
|
|
buildInputs =
|
|
|
|
[ pkgconfig gnum4 libtool intltool glib dbus avahi
|
|
|
|
libsamplerate libsndfile speex alsaLib bluez udev
|
|
|
|
#gtk gconf libX11 libICE libSM libXtst libXi
|
2011-07-31 21:44:58 +02:00
|
|
|
]
|
2011-07-30 20:51:42 +02:00
|
|
|
++ stdenv.lib.optional jackaudioSupport jackaudio;
|
2008-12-19 15:56:37 +01:00
|
|
|
|
2009-01-19 21:22:54 +01:00
|
|
|
preConfigure = ''
|
2009-01-29 20:27:31 +01:00
|
|
|
# Change the `padsp' script so that it contains the full path to
|
|
|
|
# `libpulsedsp.so'.
|
|
|
|
sed -i "src/utils/padsp" \
|
|
|
|
-e "s|libpulsedsp\.so|$out/lib/libpulsedsp.so|g"
|
2009-12-13 21:19:19 +01:00
|
|
|
|
|
|
|
# Move the udev rules under $(prefix).
|
|
|
|
sed -i "src/Makefile.in" \
|
|
|
|
-e "s|udevrulesdir[[:blank:]]*=.*$|udevrulesdir = $out/lib/udev/rules.d|g"
|
2009-01-19 21:22:54 +01:00
|
|
|
'';
|
|
|
|
|
2008-12-19 15:56:37 +01:00
|
|
|
configureFlags = ''
|
2011-07-26 17:25:21 +02:00
|
|
|
--disable-solaris --disable-hal --disable-jack
|
2010-07-31 15:05:58 +02:00
|
|
|
--disable-oss-output --disable-oss-wrapper
|
2011-07-26 17:25:21 +02:00
|
|
|
--localstatedir=/var --sysconfdir=/etc
|
2011-07-31 21:44:58 +02:00
|
|
|
${if jackaudioSupport then "--enable-jack" else ""}
|
2008-12-19 15:56:37 +01:00
|
|
|
'';
|
|
|
|
|
2011-07-26 17:25:21 +02:00
|
|
|
installFlags = "sysconfdir=$(out)/etc";
|
|
|
|
|
2011-07-07 19:24:31 +02:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2008-12-19 15:56:37 +01:00
|
|
|
meta = {
|
|
|
|
description = "PulseAudio, a sound server for POSIX and Win32 systems";
|
|
|
|
|
|
|
|
longDescription = ''
|
|
|
|
PulseAudio is a sound server for POSIX and Win32 systems. A
|
|
|
|
sound server is basically a proxy for your sound applications.
|
|
|
|
It allows you to do advanced operations on your sound data as it
|
|
|
|
passes between your application and your hardware. Things like
|
|
|
|
transferring the audio to a different machine, changing the
|
|
|
|
sample format or channel count and mixing several sounds into
|
|
|
|
one are easily achieved using a sound server.
|
|
|
|
'';
|
|
|
|
|
|
|
|
homepage = http://www.pulseaudio.org/;
|
|
|
|
|
|
|
|
# Note: Practically, the server is under the GPL due to the
|
|
|
|
# dependency on `libsamplerate'. See `LICENSE' for details.
|
|
|
|
licenses = "LGPLv2+";
|
2009-12-13 22:14:45 +01:00
|
|
|
|
|
|
|
maintainers = [ stdenv.lib.maintainers.ludo ];
|
|
|
|
platforms = stdenv.lib.platforms.gnu;
|
2008-12-19 15:56:37 +01:00
|
|
|
};
|
|
|
|
}
|