nixpkgs/pkgs/by-name/lz/lz4/package.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

59 lines
1.5 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub, cmake
, valgrind, testers
2018-12-13 20:39:04 +00:00
}:
stdenv.mkDerivation (finalAttrs: {
pname = "lz4";
2024-09-12 01:20:59 +00:00
version = "1.10.0";
src = fetchFromGitHub {
repo = "lz4";
owner = "lz4";
rev = "v${finalAttrs.version}";
2024-09-12 01:20:59 +00:00
hash = "sha256-/dG1n59SKBaEBg72pAWltAtVmJ2cXxlFFhP+klrkTos=";
};
nativeBuildInputs = [
cmake
];
buildInputs = lib.optionals finalAttrs.finalPackage.doCheck [
valgrind
];
outputs = [ "dev" "lib" "man" "out" ];
cmakeDir = "../build/cmake";
cmakeBuildDir = "build-dist";
doCheck = false; # tests take a very long time
2015-01-20 06:31:00 +00:00
checkTarget = "test";
passthru.tests = {
version = testers.testVersion {
package = finalAttrs.finalPackage;
version = "v${finalAttrs.version}";
};
pkg-config = testers.hasPkgConfigModules {
package = finalAttrs.finalPackage;
moduleNames = [ "liblz4" ];
};
};
meta = with lib; {
description = "Extremely fast compression algorithm";
longDescription = ''
Very fast lossless compression algorithm, providing compression speed
at 400 MB/s per core, with near-linear scalability for multi-threaded
applications. It also features an extremely fast decoder, with speed in
multiple GB/s per core, typically reaching RAM speed limits on
multi-core systems.
'';
homepage = "https://lz4.github.io/lz4/";
license = with licenses; [ bsd2 gpl2Plus ];
2019-11-12 19:47:47 +00:00
platforms = platforms.all;
mainProgram = "lz4";
2024-06-24 03:57:47 +00:00
maintainers = [ maintainers.tobim ];
};
})