nixpkgs/pkgs/applications/science/biology/ants/default.nix

43 lines
1.1 KiB
Nix
Raw Normal View History

2019-09-13 10:52:54 +01:00
{ stdenv, fetchFromGitHub, fetchpatch, cmake, makeWrapper, itk4, vtk }:
2017-03-02 01:55:42 +00:00
stdenv.mkDerivation rec {
2019-09-13 10:52:54 +01:00
pname = "ANTs";
version = "2.2.0";
2017-03-02 01:55:42 +00:00
src = fetchFromGitHub {
owner = "ANTsX";
2017-03-02 01:55:42 +00:00
repo = "ANTs";
rev = "37ad4e20be3a5ecd26c2e4e41b49e778a0246c3d";
sha256 = "1hrdwv3m9xh3yf7l0rm2ggxc2xzckfb8srs88g485ibfszx7i03q";
2017-03-02 01:55:42 +00:00
};
2019-01-17 10:47:32 +00:00
patches = [
# Fix build with gcc8
(fetchpatch {
url = "https://github.com/ANTsX/ANTs/commit/89af9b2694715bf8204993e032fa132f80cf37bd.patch";
sha256 = "1glkrwa1jmxxbmzihycxr576azjqby31jwpj165qc54c91pn0ams";
})
];
nativeBuildInputs = [ cmake makeWrapper ];
2019-09-13 10:52:54 +01:00
buildInputs = [ itk4 vtk ];
2017-03-02 01:55:42 +00:00
cmakeFlags = [ "-DANTS_SUPERBUILD=FALSE" "-DUSE_VTK=TRUE" ];
enableParallelBuilding = true;
2017-03-02 01:55:42 +00:00
postInstall = ''
for file in $out/bin/*; do
wrapProgram $file --set ANTSPATH "$out/bin"
done
'';
2017-03-02 01:55:42 +00:00
meta = with stdenv.lib; {
2019-09-13 10:52:54 +01:00
homepage = https://github.com/ANTsX/ANTs;
2017-03-02 01:55:42 +00:00
description = "Advanced normalization toolkit for medical image registration and other processing";
maintainers = with maintainers; [ bcdarwin ];
platforms = platforms.unix;
license = licenses.bsd3;
};
}