From b4ff81ffd629d3f699b880ad62eaabf364a32d1d Mon Sep 17 00:00:00 2001 From: Thomas Tuegel Date: Fri, 22 Apr 2016 08:11:10 -0500 Subject: [PATCH] phonon-backend-vlc: init at 0.9.0 --- .../services/x11/desktop-managers/kde4.nix | 4 +- pkgs/applications/audio/tomahawk/default.nix | 4 +- .../applications/graphics/digikam/default.nix | 6 +-- pkgs/applications/video/minitube/default.nix | 6 +-- .../libraries/phonon/backends/vlc.nix | 39 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++ 6 files changed, 53 insertions(+), 10 deletions(-) create mode 100644 pkgs/development/libraries/phonon/backends/vlc.nix diff --git a/nixos/modules/services/x11/desktop-managers/kde4.nix b/nixos/modules/services/x11/desktop-managers/kde4.nix index 80e408be4923..3b639f672170 100644 --- a/nixos/modules/services/x11/desktop-managers/kde4.nix +++ b/nixos/modules/services/x11/desktop-managers/kde4.nix @@ -29,7 +29,7 @@ let phononBackends = { gstreamer = [ - pkgs.phonon_backend_gstreamer + pkgs.phonon-backend-gstreamer pkgs.gst_all.gstPluginsBase pkgs.gst_all.gstPluginsGood pkgs.gst_all.gstPluginsUgly @@ -38,7 +38,7 @@ let pkgs.gst_all.gstreamer # needed? ]; - vlc = [pkgs.phonon_backend_vlc]; + vlc = [pkgs.phonon-backend-vlc]; }; phononBackendPackages = flip concatMap cfg.phononBackends diff --git a/pkgs/applications/audio/tomahawk/default.nix b/pkgs/applications/audio/tomahawk/default.nix index 61cb6b9896e3..7021cd165cfd 100644 --- a/pkgs/applications/audio/tomahawk/default.nix +++ b/pkgs/applications/audio/tomahawk/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, cmake, pkgconfig, attica, boost, gnutls, libechonest -, liblastfm, lucenepp, phonon, phonon_backend_vlc, qca2, qjson, qt4 +, liblastfm, lucenepp, phonon, phonon-backend-vlc, qca2, qjson, qt4 , qtkeychain, quazip, sparsehash, taglib, websocketpp, makeWrapper , enableXMPP ? true, libjreen ? null @@ -35,7 +35,7 @@ stdenv.mkDerivation rec { postInstall = let pluginPath = stdenv.lib.concatStringsSep ":" [ - "${phonon_backend_vlc}/lib/kde4/plugins" + "${phonon-backend-vlc}/lib/kde4/plugins" ]; in '' for i in "$out"/bin/*; do diff --git a/pkgs/applications/graphics/digikam/default.nix b/pkgs/applications/graphics/digikam/default.nix index 119125066bda..453dc0809956 100644 --- a/pkgs/applications/graphics/digikam/default.nix +++ b/pkgs/applications/graphics/digikam/default.nix @@ -19,7 +19,7 @@ # Supplementary packages required only by the wrapper. , bash, kde_runtime, kde_baseapps, makeWrapper, oxygen_icons -, phonon_backend_vlc /*phonon_backend_gstreamer,*/ +, phonon-backend-vlc /*phonon-backend-gstreamer,*/ , ffmpegthumbs /*mplayerthumbs*/ , runCommand, shared_mime_info, writeScriptBin }: @@ -93,7 +93,7 @@ let kdePkgs = [ build # digikam's own build kdelibs kdepimlibs kde_runtime kde_baseapps libkdcraw oxygen_icons - /*phonon_backend_gstreamer*/ phonon_backend_vlc + /*phonon-backend-gstreamer*/ phonon-backend-vlc ffmpegthumbs /*mplayerthumbs*/ shared_mime_info ] # Optional build time dependencies ++ [ @@ -208,7 +208,7 @@ TODO - Per lib `KDELIBS` environment variable export. See above in-code TODO comment. - Missing optional `qt_soap` or `herqq` (av + normal package) dependencies. Those are not yet (or not fully) packaged in nix. Mainly required for upnp export. - - Possibility to use the `phonon_backend_gstreamer` with its own user specified set of backend. + - Possibility to use the `phonon-backend-gstreamer` with its own user specified set of backend. - Allow user to disable optional features or dependencies reacting properly. - Compile `kipiplugins` as a separate package (so that it can be used by other kde packages and so that this package's build time is reduced). diff --git a/pkgs/applications/video/minitube/default.nix b/pkgs/applications/video/minitube/default.nix index 1a621032125b..971588901b46 100644 --- a/pkgs/applications/video/minitube/default.nix +++ b/pkgs/applications/video/minitube/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchFromGitHub, makeWrapper, phonon, phonon_backend_vlc, qt4, qmake4Hook +{ stdenv, fetchFromGitHub, makeWrapper, phonon, phonon-backend-vlc, qt4, qmake4Hook # "Free" API key generated by nckx , withAPIKey ? "AIzaSyBtFgbln3bu1swQC-naMxMtKh384D3xJZE" }: @@ -13,7 +13,7 @@ stdenv.mkDerivation rec { owner = "flaviotordini"; }; - buildInputs = [ phonon phonon_backend_vlc qt4 ]; + buildInputs = [ phonon phonon-backend-vlc qt4 ]; nativeBuildInputs = [ makeWrapper qmake4Hook ]; qmakeFlags = [ "DEFINES+=APP_GOOGLE_API_KEY=${withAPIKey}" ]; @@ -22,7 +22,7 @@ stdenv.mkDerivation rec { postInstall = '' wrapProgram $out/bin/minitube \ - --prefix QT_PLUGIN_PATH : "${phonon_backend_vlc}/lib/kde4/plugins" + --prefix QT_PLUGIN_PATH : "${phonon-backend-vlc}/lib/kde4/plugins" ''; meta = with stdenv.lib; { diff --git a/pkgs/development/libraries/phonon/backends/vlc.nix b/pkgs/development/libraries/phonon/backends/vlc.nix new file mode 100644 index 000000000000..1f14ec575a0e --- /dev/null +++ b/pkgs/development/libraries/phonon/backends/vlc.nix @@ -0,0 +1,39 @@ +{ stdenv, lib, fetchurl, cmake, phonon, pkgconfig, vlc +, extra-cmake-modules ? null, qtbase ? null, qtx11extras ? null, qt4 ? null +, debug ? false }: + +with lib; + +let + v = "0.9.0"; + pname = "phonon-backend-vlc"; + withQt5 = extra-cmake-modules != null; +in + +assert withQt5 -> qtbase != null; +assert withQt5 -> qtx11extras != null; + +stdenv.mkDerivation rec { + name = "${pname}-${if withQt5 then "qt5" else "qt4"}-${v}"; + + meta = with stdenv.lib; { + homepage = http://phonon.kde.org/; + description = "GStreamer backend for Phonon"; + platforms = platforms.linux; + }; + + src = fetchurl { + url = "mirror://kde/stable/phonon/${pname}/${v}/src/${pname}-${v}.tar.xz"; + sha256 = "1gnd1j305mqajw5gxm42vg6ajkvi8611bxgc3qhj5k0saz5dgkn0"; + }; + + buildInputs = + [ phonon vlc ] + ++ (if withQt5 then [ qtbase qtx11extras ] else [ qt4 ]); + + nativeBuildInputs = [ cmake pkgconfig ] ++ optional withQt5 extra-cmake-modules; + + cmakeFlags = + [ "-DCMAKE_BUILD_TYPE=${if debug then "Debug" else "Release"}" ] + ++ optional withQt5 "-DPHONON_BUILD_PHONON4QT5=ON"; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index ed5684073cad..db687ba4a5d8 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8439,6 +8439,8 @@ in phonon-backend-gstreamer = callPackage ../development/libraries/phonon/backends/gstreamer.nix {}; + phonon-backend-vlc = callPackage ../development/libraries/phonon/backends/vlc.nix {}; + physfs = callPackage ../development/libraries/physfs { }; pipelight = callPackage ../tools/misc/pipelight { @@ -15459,6 +15461,8 @@ in phonon-backend-gstreamer = callPackage ../development/libraries/phonon/backends/gstreamer.nix { }; + phonon-backend-vlc = callPackage ../development/libraries/phonon/backends/vlc.nix { }; + quassel = callPackage ../applications/networking/irc/quassel/qt-5.nix { monolithic = true; daemon = false;