diff options
author | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:36 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2019-01-07 02:18:47 +0000 |
commit | 36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2 (patch) | |
tree | b3faaf573407b32aa645237a4d16b82778a39a92 /nixpkgs/pkgs/development/libraries/libminc/default.nix | |
parent | 4e31070265257dc67d120c27e0f75c2344fdfa9a (diff) | |
parent | abf060725d7614bd3b9f96764262dfbc2f9c2199 (diff) | |
download | nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.gz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.bz2 nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.lz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.xz nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.tar.zst nixlib-36f56d99fa0a0765c9f1de4a5f17a9b05830c3f2.zip |
Add 'nixpkgs/' from commit 'abf060725d7614bd3b9f96764262dfbc2f9c2199'
git-subtree-dir: nixpkgs git-subtree-mainline: 4e31070265257dc67d120c27e0f75c2344fdfa9a git-subtree-split: abf060725d7614bd3b9f96764262dfbc2f9c2199
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/libminc/default.nix')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/libminc/default.nix | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/libraries/libminc/default.nix b/nixpkgs/pkgs/development/libraries/libminc/default.nix new file mode 100644 index 000000000000..1e13f3238222 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/libminc/default.nix @@ -0,0 +1,47 @@ +{ stdenv, fetchFromGitHub, cmake, zlib, netcdf, nifticlib, hdf5 }: + +stdenv.mkDerivation rec { + pname = "libminc"; + name = "${pname}-2018-01-17"; + + owner = "BIC-MNI"; + + # current master is significantly ahead of most recent release, so use Git version: + src = fetchFromGitHub { + inherit owner; + repo = pname; + rev = "a9cbe1353eae9791b7d5b03af16e0f86922ce40b"; + sha256 = "0mn4n3ihzcr1jw2g1vy6c8p4lkc88jwljk04argmj7k4djrgpxpa"; + }; + + postPatch = '' + patchShebangs . + ''; + + nativeBuildInputs = [ cmake ]; + buildInputs = [ zlib netcdf nifticlib hdf5 ]; + + cmakeFlags = [ + "-DBUILD_TESTING=${if doCheck then "ON" else "OFF"}" + "-DLIBMINC_MINC1_SUPPORT=ON" + "-DLIBMINC_BUILD_SHARED_LIBS=ON" + "-DLIBMINC_USE_SYSTEM_NIFTI=ON" + ]; + + doCheck = stdenv.buildPlatform == stdenv.hostPlatform; + checkPhase = '' + export LD_LIBRARY_PATH="$(pwd)" # see #22060 + ctest -E 'ezminc_rw_test|minc_conversion' --output-on-failure + # ezminc_rw_test can't find libminc_io.so.5.2.0; minc_conversion hits netcdf compilation issue + ''; + + enableParallelBuilding = true; + + meta = with stdenv.lib; { + homepage = "https://github.com/${owner}/${pname}"; + description = "Medical imaging library based on HDF5"; + maintainers = with maintainers; [ bcdarwin ]; + platforms = platforms.unix; + license = licenses.free; + }; +} |