3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/tools/compression/pxz/default.nix

45 lines
1.3 KiB
Nix
Raw Normal View History

2021-07-21 12:48:43 +01:00
{ lib, stdenv, fetchFromGitHub, xz }:
2014-11-01 16:08:08 +00:00
2021-07-21 12:48:43 +01:00
stdenv.mkDerivation rec {
pname = "pxz";
version = "4.999.9beta+git";
2014-11-01 16:08:08 +00:00
2021-07-21 12:48:43 +01:00
src = fetchFromGitHub {
owner = "jnovy";
repo = "pxz";
rev = "124382a6d0832b13b7c091f72264f8f3f463070a";
sha256 = "15mmv832iqsqwigidvwnf0nyivxf0y8m22j2szy4h0xr76x4z21m";
2014-11-01 16:08:08 +00:00
};
2021-03-14 18:12:53 +00:00
buildInputs = [ xz ];
2014-11-01 16:08:08 +00:00
buildPhase = ''
gcc -o pxz pxz.c -llzma \
-fopenmp -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -O2 \
-DPXZ_BUILD_DATE=\"nixpkgs\" \
-DXZ_BINARY=\"${xz.bin}/bin/xz\" \
2014-11-01 16:08:08 +00:00
-DPXZ_VERSION=\"${version}\"
'';
installPhase = ''
mkdir -p $out/bin $out/share/man/man1
cp pxz $out/bin
cp pxz.1 $out/share/man/man1
'';
2021-07-21 12:48:43 +01:00
meta = with lib; {
homepage = "https://jnovy.fedorapeople.org/pxz/";
2021-07-21 12:48:43 +01:00
license = licenses.gpl2Plus;
maintainers = with maintainers; [ pashev ];
description = "compression utility that runs LZMA compression of different parts on multiple cores simultaneously";
longDescription = ''
Parallel XZ is a compression utility that takes advantage of
2014-11-01 16:08:08 +00:00
running LZMA compression of different parts of an input file on multiple
cores and processors simultaneously. Its primary goal is to utilize all
resources to speed up compression time with minimal possible influence
2021-07-21 12:48:43 +01:00
on compression ratio
'';
platforms = with platforms; linux;
2014-11-01 16:08:08 +00:00
};
}