summary refs log tree commit diff
path: root/pkgs/development/libraries/phonon/qt4/default.nix
blob: df32f04bb6c11c7a029b5f8302675b57a9e00d45 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ stdenv, fetchurl, cmake, automoc4, pulseaudio
, qt4 ? null, qt5 ? null, withQt5 ? false }:

assert (withQt5 -> qt5 != null); assert (!withQt5 -> qt4 != null);

with stdenv.lib;

let
  v = "4.8.1";
in

stdenv.mkDerivation rec {
  name = "phonon-${v}";

  src = fetchurl {
    url = "mirror://kde/stable/phonon/${v}/phonon-${v}.tar.xz";
    sha256 = "1l97h1jj3gvl1chx1qbipizfvjgqc05wrhdcflc76c2krlk03jmn";
  };

  buildInputs = [ (if withQt5 then qt5 else qt4) pulseaudio ];

  nativeBuildInputs = [ cmake automoc4 ];

  cmakeFlags = optional withQt5 "-DPHONON_BUILD_PHONON4QT5=ON";

  meta = {
    homepage = http://phonon.kde.org/;
    description = "Multimedia API for Qt";
    license = stdenv.lib.licenses.lgpl2;
    platforms = stdenv.lib.platforms.linux;
    maintainers = with stdenv.lib.maintainers; [ ttuegel ];
  };
}