about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorRickard Nilsson <rickynils@gmail.com>2013-02-26 19:42:04 +0100
committerRickard Nilsson <rickynils@gmail.com>2013-02-26 19:42:57 +0100
commit566d5d3fb5497b1bd466bcb8c2bc24678240be87 (patch)
tree5d0e966385e1d191ccb0225fb9a3d385eed4d9b1 /pkgs
parentc308b10ec027c98d9df9e43f50d79203491fa85e (diff)
downloadnixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar.gz
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar.bz2
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar.lz
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar.xz
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.tar.zst
nixlib-566d5d3fb5497b1bd466bcb8c2bc24678240be87.zip
Add mopidy, a music server supporting spotify and the mpd protocol
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/applications/audio/mopidy/default.nix44
-rw-r--r--pkgs/applications/audio/mopidy/git.nix44
-rw-r--r--pkgs/top-level/all-packages.nix3
-rw-r--r--pkgs/top-level/python-packages.nix54
4 files changed, 145 insertions, 0 deletions
diff --git a/pkgs/applications/audio/mopidy/default.nix b/pkgs/applications/audio/mopidy/default.nix
new file mode 100644
index 000000000000..934669f225c6
--- /dev/null
+++ b/pkgs/applications/audio/mopidy/default.nix
@@ -0,0 +1,44 @@
+{ stdenv, fetchgit, pythonPackages, pygobject, gst_python
+, gst_plugins_good, gst_plugins_base
+}:
+
+pythonPackages.buildPythonPackage rec {
+  name = "mopidy-${version}";
+
+  version = "0.11.1";
+
+  src = fetchgit {
+    url = "https://github.com/mopidy/mopidy.git";
+    rev = "refs/tags/v${version}";
+    sha256 = "123p9hsnlgwvrw4vzlxjf5f43rqzqa3ynbqha8pyi6r0q3ln7qjn";
+  };
+
+  propagatedBuildInputs = with pythonPackages; [
+   gst_python pygobject pykka pyspotify pylast
+  ];
+
+  # python zip complains about old timestamps
+  preConfigure = ''
+    find -print0 | xargs -0 touch
+  '';
+
+  # There are no tests
+  doCheck = false;
+
+  postInstall = ''
+    for p in $out/bin/mopidy $out/bin/mopidy-scan; do
+      wrapProgram $p \
+        --prefix GST_PLUGIN_PATH : ${gst_plugins_good}/lib/gstreamer-0.10 \
+        --prefix GST_PLUGIN_PATH : ${gst_plugins_base}/lib/gstreamer-0.10
+    done
+  '';
+
+  meta = {
+    homepage = http://www.mopidy.com/;
+    description = ''
+      A music server which can play music from Spotify and from your
+      local hard drive.
+    '';
+    maintainers = [ stdenv.lib.maintainers.rickynils ];
+  };
+}
diff --git a/pkgs/applications/audio/mopidy/git.nix b/pkgs/applications/audio/mopidy/git.nix
new file mode 100644
index 000000000000..81728e646c3e
--- /dev/null
+++ b/pkgs/applications/audio/mopidy/git.nix
@@ -0,0 +1,44 @@
+{ stdenv, fetchgit, pythonPackages, pygobject, gst_python
+, gst_plugins_good, gst_plugins_base
+}:
+
+pythonPackages.buildPythonPackage rec {
+  name = "mopidy-${version}";
+
+  version = "git-20130226";
+
+  src = fetchgit {
+    url = "https://github.com/mopidy/mopidy.git";
+    rev = "86a7c2d7519680c6b9130795d35c4654958f4c04";
+    sha256 = "00fxcfkpl19nslv4f4bspzw0kvjjp6hhcwag7rknmb8scfinqfac";
+  };
+
+  propagatedBuildInputs = with pythonPackages; [
+   gst_python pygobject pykka pyspotify pylast
+  ];
+
+  # python zip complains about old timestamps
+  preConfigure = ''
+    find -print0 | xargs -0 touch
+  '';
+
+  # There are no tests
+  doCheck = false;
+
+  postInstall = ''
+    for p in $out/bin/mopidy $out/bin/mopidy-scan; do
+      wrapProgram $p \
+        --prefix GST_PLUGIN_PATH : ${gst_plugins_good}/lib/gstreamer-0.10 \
+        --prefix GST_PLUGIN_PATH : ${gst_plugins_base}/lib/gstreamer-0.10
+    done
+  '';
+
+  meta = {
+    homepage = http://www.mopidy.com/;
+    description = ''
+      A music server which can play music from Spotify and from your
+      local hard drive.
+    '';
+    maintainers = [ stdenv.lib.maintainers.rickynils ];
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index d16d12367ca3..60c2e02d5f48 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -7522,6 +7522,9 @@ let
     inherit (gnome) libgnomecanvas;
   };
 
+  mopidy = callPackage ../applications/audio/mopidy { };
+  mopidy_git = callPackage ../applications/audio/mopidy/git.nix { };
+
   mozilla = callPackage ../applications/networking/browsers/mozilla {
     inherit (gnome) libIDL;
   };
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 43c2aa4dba5b..f98a3f083206 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -4664,4 +4664,58 @@ pythonPackages = python.modules // rec {
     };
   };
 
+  pyspotify = buildPythonPackage rec {
+    name = "pyspotify-${version}";
+  
+    version = "1.10";
+  
+    src = fetchgit {
+      url = "https://github.com/mopidy/pyspotify.git";
+      rev = "refs/tags/v${version}";
+      sha256 = "1rvgrviwn6f037m8vq395chz6a1119dbsdhfwdbv5ambi0bak6ll";
+    };
+  
+    buildInputs = [ pkgs.libspotify ];
+  
+    # python zip complains about old timestamps
+    preConfigure = ''
+      find -print0 | xargs -0 touch
+    '';
+  
+    # There are no tests
+    doCheck = false;
+  
+    meta = {
+      homepage = http://pyspotify.mopidy.com;
+      description = "A Python interface to Spotify’s online music streaming service";
+      maintainers = [ stdenv.lib.maintainers.rickynils ];
+    };
+  };
+
+  pykka = buildPythonPackage rec {
+    name = "pykka-${version}";
+  
+    version = "1.1.0";
+  
+    src = fetchgit {
+      url = "https://github.com/jodal/pykka.git";
+      rev = "refs/tags/v${version}";
+      sha256 = "0w6bcaqkzwmd9habszlgjkp3kkhkna08s9aivnmna5hddsghfqmz";
+    };
+  
+    # python zip complains about old timestamps
+    preConfigure = ''
+      find -print0 | xargs -0 touch
+    '';
+  
+    # There are no tests
+    doCheck = false;
+  
+    meta = {
+      homepage = http://www.pykka.org;
+      description = "A Python implementation of the actor model";
+      maintainers = [ stdenv.lib.maintainers.rickynils ];
+    };
+  };
+
 }; in pythonPackages