1e4a7842d2
I use this feature for doing snapshot backups, which is way faster than copying a huge files tree. The patch is semi-official, rsync-patches is maintained by rsync upstream itself. The patch doesn't affect any behaviour, it only adds 1 option so it shouldn't affect you if you don't use it. svn path=/nixpkgs/trunk/; revision=31659
34 lines
1,006 B
Nix
34 lines
1,006 B
Nix
{ stdenv, fetchurl, perl
|
|
, enableACLs ? true, acl ? null
|
|
, enableCopyDevicesPatch ? false
|
|
}:
|
|
|
|
assert enableACLs -> acl != null;
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "rsync-3.0.9";
|
|
|
|
mainSrc = fetchurl {
|
|
url = http://rsync.samba.org/ftp/rsync/src/rsync-3.0.9.tar.gz;
|
|
sha256 = "01bw4klqsrlhh3i9lazd485sd9qx5djvnwa21lj2h3a9sn6hzw9h";
|
|
};
|
|
|
|
patchesSrc = fetchurl {
|
|
url = http://rsync.samba.org/ftp/rsync/rsync-patches-3.0.9.tar.gz;
|
|
sha256 = "0c1e9b56e99667dfc47641124460bac61a04c5d2ee89f575c6bc78c7a69005a9";
|
|
};
|
|
|
|
srcs = [mainSrc] ++ stdenv.lib.optional enableCopyDevicesPatch patchesSrc;
|
|
patches = [] ++ stdenv.lib.optional enableCopyDevicesPatch "./patches/copy-devices.diff";
|
|
|
|
buildInputs = stdenv.lib.optional enableACLs acl;
|
|
buildNativeInputs = [perl];
|
|
|
|
meta = {
|
|
homepage = http://samba.anu.edu.au/rsync/;
|
|
description = "A fast incremental file transfer utility";
|
|
|
|
platforms = stdenv.lib.platforms.unix;
|
|
maintainers = [ stdenv.lib.maintainers.simons ];
|
|
};
|
|
}
|