1{ lib, stdenv, fetchFromGitHub
2, openssl
3, pandoc
4, which
5}:
6
7stdenv.mkDerivation rec {
8 pname = "bdsync";
9 version = "0.11.2";
10
11 src = fetchFromGitHub {
12 owner = "rolffokkens";
13 repo = pname;
14 rev = "v${version}";
15 sha256 = "0kx422cp1bxr62i1mi7dzrpwmys1kdp865rcymdp4knb5rr5864k";
16 };
17
18 nativeBuildInputs = [ pandoc which ];
19 buildInputs = [ openssl ];
20
21 postPatch = ''
22 patchShebangs ./tests.sh
23 patchShebangs ./tests/
24 '';
25
26 doCheck = true;
27
28 installPhase = ''
29 install -Dm755 bdsync -t $out/bin/
30 install -Dm644 bdsync.1 -t $out/share/man/man1/
31 '';
32
33 meta = with lib; {
34 description = "Fast block device synchronizing tool";
35 homepage = "https://github.com/TargetHolding/bdsync";
36 license = licenses.gpl2;
37 platforms = platforms.linux;
38 maintainers = with maintainers; [ jluttine ];
39 };
40}