From 09a53969828ead5dd6a231e5db3b4a765fca47d3 Mon Sep 17 00:00:00 2001 From: Orivej Desh Date: Sun, 1 Oct 2017 07:30:56 +0000 Subject: [PATCH] samtools: fix up --- .../science/biology/samtools/default.nix | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/pkgs/applications/science/biology/samtools/default.nix b/pkgs/applications/science/biology/samtools/default.nix index 0f1f4692eb71..640f32671bbd 100644 --- a/pkgs/applications/science/biology/samtools/default.nix +++ b/pkgs/applications/science/biology/samtools/default.nix @@ -3,29 +3,28 @@ stdenv.mkDerivation rec { name = "${pname}-${version}"; pname = "samtools"; - major = "1.6"; - version = "${major}.0"; + version = "1.6"; src = fetchurl { - url = "https://github.com/samtools/samtools/releases/download/${major}/samtools-${major}.tar.bz2"; + url = "https://github.com/samtools/samtools/releases/download/${version}/${name}.tar.bz2"; sha256 = "17p4vdj2j2qr3b2c0v4100h6cg4jj3zrb4dmdnd9d9aqs74d4p7f"; }; - buildInputs = [ zlib ncurses ]; + nativeBuildInputs = [ perl ]; - propagatedBuildInputs = [ htslib ]; + buildInputs = [ zlib ncurses htslib ]; configureFlags = [ "--with-htslib=${htslib}" ] ++ stdenv.lib.optional (ncurses == null) "--without-curses"; + preCheck = '' + patchShebangs test/ + ''; + enableParallelBuilding = true; doCheck = true; - preCheck = '' - sed -ie 's|/usr/bin/\(env[[:space:]]\)\{0,1\}perl|${perl}/bin/perl|' test/test.pl - ''; - meta = with stdenv.lib; { description = "Tools for manipulating SAM/BAM/CRAM format"; license = licenses.mit;