From 4b3112f8a4798470e5896670e6f7536eae01337e Mon Sep 17 00:00:00 2001 From: Justin Bedo Date: Wed, 18 Dec 2019 15:09:56 +1100 Subject: [PATCH] pythonPackages.bx-python: init at 0.8.6 --- .../python-modules/bx-python/default.nix | 39 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 4 ++ 2 files changed, 43 insertions(+) create mode 100644 pkgs/development/python-modules/bx-python/default.nix diff --git a/pkgs/development/python-modules/bx-python/default.nix b/pkgs/development/python-modules/bx-python/default.nix new file mode 100644 index 000000000000..57a3609bad0a --- /dev/null +++ b/pkgs/development/python-modules/bx-python/default.nix @@ -0,0 +1,39 @@ +{ lib, fetchFromGitHub, buildPythonPackage, isPy27, numpy, cython, zlib, six +, python-lzo, nose }: + +buildPythonPackage rec { + pname = "bx-python"; + version = "0.8.6"; + disabled = isPy27; + + src = fetchFromGitHub { + owner = "bxlab"; + repo = "bx-python"; + rev = "v${version}"; + sha256 = "1i40vmn8n83vqcpqj843riv9vp16s753jc4wc90p0cmrnhmzcv13"; + }; + + nativeBuildInputs = [ cython ]; + buildInputs = [ zlib ]; + propagatedBuildInputs = [ numpy six python-lzo ]; + checkInputs = [ nose ]; + + postInstall = '' + cp -r scripts/* $out/bin + + # This is a small hack; the test suit uses the scripts which need to + # be patched. Linking the patched scripts in $out back to the + # working directory allows the tests to run + rm -rf scripts + ln -s $out/bin scripts + ''; + + meta = with lib; { + homepage = "https://github.com/bxlab/bx-python"; + description = + "Tools for manipulating biological data, particularly multiple sequence alignments"; + license = licenses.mit; + maintainers = [ maintainers.jbedo ]; + platforms = [ "x86_64-linux" ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 42c885c29295..4da1aeba98db 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1694,6 +1694,10 @@ in { bumps = callPackage ../development/python-modules/bumps {}; + bx-python = callPackage ../development/python-modules/bx-python { + inherit (pkgs) zlib; + }; + cached-property = callPackage ../development/python-modules/cached-property { }; caffe = toPythonModule (pkgs.caffe.override {