nixpkgs/pkgs/tools/filesystems/duperemove/default.nix

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

53 lines
1.2 KiB
Nix
Raw Normal View History

2023-10-25 22:43:03 +00:00
{ lib
, stdenv
, fetchFromGitHub
, libgcrypt
, pkg-config
, glib
, linuxHeaders ? stdenv.cc.libc.linuxHeaders
, sqlite
, util-linux
, testers
, duperemove
}:
stdenv.mkDerivation rec {
pname = "duperemove";
version = "0.14.1";
src = fetchFromGitHub {
owner = "markfasheh";
repo = "duperemove";
rev = "v${version}";
hash = "sha256-iMv80UKktYOhNfVA3mW6kKv8TwLZaP6MQt24t3Rchk4=";
};
postPatch = ''
substituteInPlace util.c --replace \
"lscpu" "${lib.getBin util-linux}/bin/lscpu"
'';
nativeBuildInputs = [ pkg-config ];
2023-11-19 12:55:54 +00:00
buildInputs = [ libgcrypt glib linuxHeaders sqlite util-linux ];
2023-10-22 16:00:45 +00:00
makeFlags = [
"PREFIX=${placeholder "out"}"
"VERSION=v${version}"
];
passthru.tests.version = testers.testVersion {
package = duperemove;
command = "duperemove --version";
version = "v${version}";
};
meta = with lib; {
description = "A simple tool for finding duplicated extents and submitting them for deduplication";
homepage = "https://github.com/markfasheh/duperemove";
2024-04-26 11:35:31 +00:00
license = licenses.gpl2Only;
maintainers = with maintainers; [ bluescreen303 thoughtpolice ];
platforms = platforms.linux;
2023-11-09 09:35:26 +00:00
mainProgram = "duperemove";
};
}