From a25e324e063ca3e8b3036964af16259453734823 Mon Sep 17 00:00:00 2001 From: Frederik Rietdijk Date: Sat, 12 Aug 2017 09:04:44 +0200 Subject: [PATCH] python.pkgs.audioread: move expression --- .../python-modules/audioread/default.nix | 24 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 19 +-------------- 2 files changed, 25 insertions(+), 18 deletions(-) create mode 100644 pkgs/development/python-modules/audioread/default.nix diff --git a/pkgs/development/python-modules/audioread/default.nix b/pkgs/development/python-modules/audioread/default.nix new file mode 100644 index 000000000000..bf71cf8cfbdd --- /dev/null +++ b/pkgs/development/python-modules/audioread/default.nix @@ -0,0 +1,24 @@ +{ lib +, buildPythonPackage +, fetchPypi +}: + +buildPythonPackage rec { + pname = "audioread"; + name = "${pname}-${version}"; + version = "2.1.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "ffb601de7a9e40850d4ec3256a3a6bbe8fa40466dafb5c65f41b08e4bb963f1e"; + }; + + # No tests, need to disable or py3k breaks + doCheck = false; + + meta = { + description = "Cross-platform audio decoding"; + homepage = "https://github.com/sampsyo/audioread"; + license = lib.licenses.mit; + }; +} \ No newline at end of file diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2884f39bc87f..0e308a2f64b6 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -709,24 +709,7 @@ in { }; }); - audioread = buildPythonPackage rec { - name = "audioread-${version}"; - version = "2.1.1"; - - src = pkgs.fetchurl { - url = "mirror://pypi/a/audioread/${name}.tar.gz"; - sha256 = "ffb601de7a9e40850d4ec3256a3a6bbe8fa40466dafb5c65f41b08e4bb963f1e"; - }; - - # No tests, need to disable or py3k breaks - doCheck = false; - - meta = { - description = "Cross-platform audio decoding"; - homepage = "https://github.com/sampsyo/audioread"; - license = licenses.mit; - }; - }; + audioread = callPackage ../development/python-modules/audioread { }; audiotools = buildPythonPackage rec { name = "audiotools-${version}";