Add quodlibet-2.5: GTK+Python based music player (close #481)

authored by Jonas Hoersch and committed by Vladimír Čunát aa88e726 6c63a857

+89
+67
pkgs/applications/audio/quodlibet/default.nix
··· 1 + { stdenv, fetchurl, python, buildPythonPackage, mutagen, pygtk, pygobject 2 + , pythonDBus, gst_python, gst_plugins_base, gst_plugins_good, gst_plugins_ugly }: 3 + 4 + let version = "2.5"; in 5 + 6 + buildPythonPackage { 7 + # call the package quodlibet and just quodlibet 8 + name = "quodlibet-${version}"; 9 + namePrefix = ""; 10 + 11 + # XXX, tests fail 12 + doCheck = false; 13 + 14 + src = [ 15 + (fetchurl { 16 + url = "https://quodlibet.googlecode.com/files/quodlibet-${version}.tar.gz"; 17 + sha256 = "0qrmlz7m1jpmriy8bgycjiwzbf3annznkn4x5k32yy9bylxa7lwb"; 18 + }) 19 + (fetchurl { 20 + url = "https://quodlibet.googlecode.com/files/quodlibet-plugins-${version}.tar.gz"; 21 + sha256 = "0kf2mkq2zk38626bn48gscvy6ir04f5b2z57ahlxlqy8imv2cjff"; 22 + }) 23 + ]; 24 + 25 + sourceRoot = "quodlibet-${version}"; 26 + postUnpack = '' 27 + # the patch searches for plugins in directory ../plugins 28 + # so link the appropriate directory there 29 + ln -sf quodlibet-plugins-${version} plugins 30 + ''; 31 + patches = [ ./quodlibet-package-plugins.patch ]; 32 + 33 + buildInputs = [ 34 + gst_plugins_base gst_plugins_good gst_plugins_ugly 35 + ]; 36 + 37 + propagatedBuildInputs = [ 38 + mutagen pygtk pygobject pythonDBus gst_python 39 + ]; 40 + 41 + postInstall = '' 42 + # Wrap quodlibet so it finds the GStreamer plug-ins 43 + wrapProgram "$out/bin/quodlibet" --prefix \ 44 + GST_PLUGIN_PATH ":" \ 45 + "${gst_plugins_base}/lib/gstreamer-0.10:${gst_plugins_good}/lib/gstreamer-0.10:${gst_plugins_ugly}/lib/gstreamer-0.10" 46 + ''; 47 + 48 + meta = { 49 + description = "Quod Libet is a GTK+-based audio player written in Python, using the Mutagen tagging library."; 50 + 51 + longDescription = '' 52 + Quod Libet is a GTK+-based audio player written in Python, using 53 + the Mutagen tagging library. It's designed around the idea that 54 + you know how to organize your music better than we do. It lets 55 + you make playlists based on regular expressions (don't worry, 56 + regular searches work too). It lets you display and edit any 57 + tags you want in the file. And it lets you do this for all the 58 + file formats it supports. Quod Libet easily scales to libraries 59 + of thousands (or even tens of thousands) of songs. It also 60 + supports most of the features you expect from a modern media 61 + player, like Unicode support, tag editing, Replay Gain, podcasts 62 + & internet radio, and all major audio formats. 63 + ''; 64 + 65 + homepage = http://code.google.com/p/quodlibet/; 66 + }; 67 + }
+18
pkgs/applications/audio/quodlibet/quodlibet-package-plugins.patch
··· 1 + diff -Naur quodlibet-2.5.orig/setup.py quodlibet-2.5.new/setup.py 2 + --- quodlibet-2.5.orig/setup.py 2012-12-19 08:47:41.000000000 +0000 3 + +++ quodlibet-2.5.new/setup.py 2013-04-22 19:27:07.152631051 +0000 4 + @@ -337,5 +338,14 @@ 5 + } 6 + } 7 + }) 8 + + else: 9 + + from os.path import join 10 + + 11 + + data_files = [] 12 + + for type in ["playorder", "songsmenu", "editing", "events", "gstreamer"]: 13 + + data_files.append((join('quodlibet', 'plugins', type), 14 + + glob.glob(join('..', 'plugins', type, '*.py')))) 15 + + setup_kwargs.update({ 'data_files': data_files }); 16 + + 17 + setup(**setup_kwargs) 18 +
+4
pkgs/top-level/all-packages.nix
··· 8266 8266 8267 8267 qtractor = callPackage ../applications/audio/qtractor { }; 8268 8268 8269 + quodlibet = callPackage ../applications/audio/quodlibet { 8270 + inherit (pythonPackages) mutagen; 8271 + }; 8272 + 8269 8273 rakarrack = callPackage ../applications/audio/rakarrack { 8270 8274 inherit (xorg) libXpm libXft; 8271 8275 fltk = fltk13;