about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/backup/rdedup/default.nix
blob: 10cb1edb62a93e83e2fd1fbb22d5b4e49ef6d1a0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{ stdenv, fetchFromGitHub, rustPlatform, pkgconfig, openssl, libsodium
, llvmPackages, clang_39, lzma }:

rustPlatform.buildRustPackage rec {
  name = "rdedup-${version}";
  version = "3.0.1";

  src = fetchFromGitHub {
    owner = "dpc";
    repo = "rdedup";
    rev = "e0f26f379a434f76d238c7a5fa6ddd8ae8b32f19";
    sha256 = "1nhf8ap0w99aa1h0l599cx90lcvfvjaj67nw9flq9bmmzpn53kp9";
  };

  cargoSha256 = "1x6wchlcxb1frww6y04gfx4idxv9h0g9qfxrhgb6g5qy3bqhqq3p";

  nativeBuildInputs = [ pkgconfig llvmPackages.libclang clang_39 ];
  buildInputs = [ openssl libsodium lzma ];

  configurePhase = ''
    export LIBCLANG_PATH="${llvmPackages.libclang}/lib"
  '';

  meta = with stdenv.lib; {
    description = "Data deduplication with compression and public key encryption";
    homepage = https://github.com/dpc/rdedup;
    license = licenses.mpl20;
    maintainers = with maintainers; [ dywedir ];
    platforms = platforms.all;
  };
}