2021-03-23 19:24:49 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2020-02-08 01:22:42 +00:00
|
|
|
, fetchFromGitHub
|
2021-03-23 19:24:49 +00:00
|
|
|
, argp-standalone
|
|
|
|
, curl
|
2020-02-08 01:22:42 +00:00
|
|
|
, meson
|
|
|
|
, ninja
|
2021-03-23 19:24:49 +00:00
|
|
|
, pkg-config
|
2020-02-08 01:22:42 +00:00
|
|
|
, zstd
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "zchunk";
|
2022-03-08 01:30:39 +00:00
|
|
|
version = "1.2.0";
|
2020-02-08 01:22:42 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "zchunk";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2022-03-08 01:30:39 +00:00
|
|
|
hash = "sha256-7H1WF5VkpA65xCdEa0Sw4r4jj+kGhDVCMr5AeE+3Ii4=";
|
2020-02-08 01:22:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
meson
|
|
|
|
ninja
|
2021-01-19 06:50:56 +00:00
|
|
|
pkg-config
|
2020-02-08 01:22:42 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
curl
|
2021-03-23 19:24:49 +00:00
|
|
|
zstd
|
2021-01-21 17:00:13 +00:00
|
|
|
] ++ lib.optional stdenv.isDarwin argp-standalone;
|
2020-12-29 10:00:55 +00:00
|
|
|
|
2021-08-02 07:19:27 +00:00
|
|
|
outputs = [ "out" "lib" "dev" ];
|
2021-07-31 22:26:30 +00:00
|
|
|
|
2021-01-21 17:00:13 +00:00
|
|
|
meta = with lib; {
|
2020-02-08 01:22:42 +00:00
|
|
|
homepage = "https://github.com/zchunk/zchunk";
|
2021-03-23 19:24:49 +00:00
|
|
|
description = "File format designed for highly efficient deltas while maintaining good compression";
|
|
|
|
longDescription = ''
|
|
|
|
zchunk is a compressed file format that splits the file into independent
|
|
|
|
chunks. This allows you to only download changed chunks when downloading a
|
|
|
|
new version of the file, and also makes zchunk files efficient over rsync.
|
|
|
|
|
|
|
|
zchunk files are protected with strong checksums to verify that the file
|
|
|
|
you downloaded is, in fact, the file you wanted.
|
|
|
|
'';
|
2020-02-08 01:22:42 +00:00
|
|
|
license = licenses.bsd2;
|
2021-03-23 19:24:49 +00:00
|
|
|
maintainers = with maintainers; [ AndersonTorres ];
|
2020-02-08 01:22:42 +00:00
|
|
|
platforms = platforms.unix;
|
2022-03-09 14:59:37 +00:00
|
|
|
broken = stdenv.isDarwin; # does not find argp-standalone
|
2020-02-08 01:22:42 +00:00
|
|
|
};
|
|
|
|
}
|