2015-04-08 13:49:23 +02:00
|
|
|
{ stdenv, fetchurl, pkgconfig
|
|
|
|
, avahi, boost, libopus, libsndfile, protobuf, qt4, speex
|
|
|
|
, jackSupport ? false, jack2 ? null
|
|
|
|
, speechdSupport ? false, speechd ? null
|
|
|
|
, pulseSupport ? false, pulseaudio ? null
|
2014-01-31 02:01:22 +01:00
|
|
|
}:
|
|
|
|
|
2014-07-31 12:47:17 +02:00
|
|
|
assert jackSupport -> jack2 != null;
|
2014-01-31 02:01:22 +01:00
|
|
|
assert speechdSupport -> speechd != null;
|
2015-01-10 21:36:17 +01:00
|
|
|
assert pulseSupport -> pulseaudio != null;
|
2014-01-31 02:01:22 +01:00
|
|
|
|
|
|
|
let
|
|
|
|
optional = stdenv.lib.optional;
|
|
|
|
optionalString = stdenv.lib.optionalString;
|
|
|
|
in
|
2011-02-10 20:23:27 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "mumble-" + version;
|
2014-10-07 19:19:47 +02:00
|
|
|
version = "1.2.8";
|
2011-02-10 20:23:27 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/mumble/${name}.tar.gz";
|
2014-10-07 19:19:47 +02:00
|
|
|
sha256 = "0ng1xd7i0951kqnd9visf84y2dcwia79a1brjwfvr1wnykgw6bsc";
|
2011-02-10 20:23:27 +01:00
|
|
|
};
|
|
|
|
|
2014-01-31 02:01:22 +01:00
|
|
|
patches = optional jackSupport ./mumble-jack-support.patch;
|
2011-02-10 20:23:27 +01:00
|
|
|
|
2015-04-08 13:49:23 +02:00
|
|
|
configureFlags = [
|
|
|
|
"CONFIG+=shared"
|
|
|
|
"CONFIG+=no-g15"
|
|
|
|
"CONFIG+=packaged"
|
|
|
|
"CONFIG+=no-update"
|
|
|
|
"CONFIG+=no-server"
|
|
|
|
"CONFIG+=no-embed-qt-translations"
|
|
|
|
"CONFIG+=bundled-celt"
|
|
|
|
"CONFIG+=no-bundled-opus"
|
|
|
|
"CONFIG+=no-bundled-speex"
|
|
|
|
] ++ optional (!speechdSupport) "CONFIG+=no-speechd"
|
|
|
|
++ optional jackSupport "CONFIG+=no-oss CONFIG+=no-alsa CONFIG+=jackaudio";
|
|
|
|
|
2011-02-12 21:31:25 +01:00
|
|
|
configurePhase = ''
|
2015-04-08 13:49:23 +02:00
|
|
|
qmake $configureFlags
|
2011-02-12 21:31:25 +01:00
|
|
|
'';
|
2011-02-10 20:23:27 +01:00
|
|
|
|
2015-04-08 13:49:23 +02:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2011-05-10 09:07:35 +02:00
|
|
|
|
2015-04-08 13:49:23 +02:00
|
|
|
buildInputs = [ avahi boost libopus libsndfile protobuf qt4 speex ]
|
|
|
|
++ optional jackSupport jack2
|
|
|
|
++ optional speechdSupport speechd
|
|
|
|
++ optional pulseSupport pulseaudio;
|
2011-02-10 20:23:27 +01:00
|
|
|
|
2011-04-17 10:27:04 +02:00
|
|
|
installPhase = ''
|
2012-01-18 21:16:00 +01:00
|
|
|
mkdir -p $out
|
2011-04-17 10:27:04 +02:00
|
|
|
cp -r ./release $out/bin
|
2015-04-08 13:49:23 +02:00
|
|
|
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
cp scripts/mumble.desktop $out/share/applications
|
|
|
|
|
|
|
|
mkdir -p $out/share/icons
|
|
|
|
cp icons/mumble.svg $out/share/icons
|
2011-04-17 10:27:04 +02:00
|
|
|
'';
|
|
|
|
|
2015-04-08 13:49:23 +02:00
|
|
|
meta = with stdenv.lib; {
|
2011-02-10 20:23:27 +01:00
|
|
|
description = "Low-latency, high quality voice chat software";
|
2015-04-08 13:49:23 +02:00
|
|
|
homepage = "http://mumble.sourceforge.net/";
|
2014-01-31 02:01:22 +01:00
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ viric ];
|
2015-04-08 13:49:23 +02:00
|
|
|
platforms = platforms.linux;
|
2011-02-10 20:23:27 +01:00
|
|
|
};
|
|
|
|
}
|