dcm2niix: wrap with pigz binary for parallel output compression (#325863)

This commit is contained in:
Peder Bergebakken Sundt
2025-01-17 03:20:14 +01:00
committed by GitHub
+12 -1
View File
@@ -2,13 +2,16 @@
lib,
stdenv,
fetchFromGitHub,
makeBinaryWrapper,
replaceVars,
cmake,
openjpeg,
pigz,
yaml-cpp,
batchVersion ? false,
withJpegLs ? true,
withOpenJpeg ? true,
withPigz ? true,
withCloudflareZlib ? true,
}:
@@ -39,7 +42,11 @@ stdenv.mkDerivation (finalAttrs: {
})
];
nativeBuildInputs = [ cmake ];
nativeBuildInputs = [
cmake
makeBinaryWrapper
];
buildInputs =
lib.optionals batchVersion [ yaml-cpp ]
++ lib.optionals withOpenJpeg [
@@ -63,6 +70,10 @@ stdenv.mkDerivation (finalAttrs: {
"-DZLIB_IMPLEMENTATION=Cloudflare"
];
postInstall = lib.optionalString withPigz ''
wrapProgram $out/bin/dcm2niix --prefix PATH : "${lib.makeBinPath [ pigz ]}"
'';
meta = {
description = "DICOM to NIfTI converter";
mainProgram = "dcm2niix";