| 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 | (define-module (gnu packages rsync)
|
| 27 | #:use-module (gnu packages)
|
| 28 | #:use-module (gnu packages acl)
|
| 29 | #:use-module (gnu packages base)
|
| 30 | #:use-module (gnu packages compression)
|
| 31 | #:use-module (gnu packages digest)
|
| 32 | #:use-module (gnu packages libidn)
|
| 33 | #:use-module (gnu packages perl)
|
| 34 | #:use-module (gnu packages python)
|
| 35 | #:use-module (gnu packages popt)
|
| 36 | #:use-module (gnu packages tls)
|
| 37 | #:use-module ((guix licenses) #:prefix license:)
|
| 38 | #:use-module (guix packages)
|
| 39 | #:use-module (guix download)
|
| 40 | #:use-module (guix gexp)
|
| 41 | #:use-module (guix git-download)
|
| 42 | #:use-module (guix build-system cmake)
|
| 43 | #:use-module (guix build-system gnu)
|
| 44 | #:use-module (guix utils))
|
| 45 |
|
| 46 | (define-public rsync
|
| 47 | (package
|
| 48 | (name "rsync")
|
| 49 | (version "3.5.1")
|
| 50 | (source (origin
|
| 51 | (method url-fetch)
|
| 52 | (uri (string-append "https://rsync.samba.org/ftp/rsync/src/rsync-"
|
| 53 | version ".tar.gz"))
|
| 54 | (sha256
|
| 55 | (base32
|
| 56 | "1vvvqcjlswk31nxr2273v2icjg6mvvys16dkjz1vxf0gq6frqpy5"))))
|
| 57 | (build-system gnu-build-system)
|
| 58 | (arguments
|
| 59 | `(#:configure-flags
|
| 60 | |
| 61 | (list "--without-included-zlib"
|
| 62 | "--without-included-popt")
|
| 63 | #:make-flags
|
| 64 | ,#~(list (string-append "CC=" #$(cc-for-target)))
|
| 65 | #:phases
|
| 66 | ,#~(modify-phases %standard-phases
|
| 67 | (add-after 'unpack 'patch-testsuite
|
| 68 | (lambda _
|
| 69 | (let ((sh-file (which "sh"))
|
| 70 | (python-file (which "python3"))
|
| 71 | (bash-file (which "bash"))
|
| 72 | (cc (string-append "'"
|
| 73 | #$(cc-for-target)
|
| 74 | "'")))
|
| 75 | (substitute* (find-files "testsuite/" "\\.py$")
|
| 76 | (("'cc'") cc)
|
| 77 | (("/usr/bin/env python3") python-file)
|
| 78 | (("/usr/bin/env bash") bash-file)
|
| 79 | (("/bin/sh") sh-file))))))))
|
| 80 | (native-inputs
|
| 81 | (list perl python-minimal)) |
| 82 | (inputs
|
| 83 | (list acl
|
| 84 | libidn2
|
| 85 | lz4
|
| 86 | openssl
|
| 87 | popt
|
| 88 | xxhash
|
| 89 | zlib
|
| 90 | `(,zstd "lib")))
|
| 91 | (synopsis "Remote (and local) file copying tool")
|
| 92 | (description
|
| 93 | "Rsync is a fast and versatile file copying tool. It can copy locally,
|
| 94 | to/from another host over any remote shell, or to/from a remote rsync daemon.
|
| 95 | Its delta-transfer algorithm reduces the amount of data sent over the network
|
| 96 | by sending only the differences between the source files and the existing
|
| 97 | files in the destination.")
|
| 98 | (license license:gpl3+)
|
| 99 | (home-page "https://rsync.samba.org/")))
|
| 100 |
|
| 101 | (define-public librsync
|
| 102 | (package
|
| 103 | (name "librsync")
|
| 104 | (version "2.3.4")
|
| 105 | (source (origin
|
| 106 | (method git-fetch)
|
| 107 | (uri (git-reference
|
| 108 | (url "https://github.com/librsync/librsync")
|
| 109 | (commit (string-append "v" version))))
|
| 110 | (file-name (git-file-name name version))
|
| 111 | (sha256
|
| 112 | (base32
|
| 113 | "07yd45r9fkgw55m47xh2aqgflagzw5kh2w764w5gv1jfrg5rn8vy"))))
|
| 114 | (build-system cmake-build-system)
|
| 115 | (inputs
|
| 116 | (list popt))
|
| 117 | (native-inputs
|
| 118 | (list which perl))
|
| 119 | (home-page "https://librsync.sourceforge.net/")
|
| 120 | (synopsis "Implementation of the rsync remote-delta algorithm")
|
| 121 | (description
|
| 122 | "Librsync is a free software library that implements the rsync
|
| 123 | remote-delta algorithm. This algorithm allows efficient remote updates of a
|
| 124 | file, without requiring the old and new versions to both be present at the
|
| 125 | sending end. The library uses a \"streaming\" design similar to that of zlib
|
| 126 | with the aim of allowing it to be embedded into many different applications.")
|
| 127 | (license license:lgpl2.1+)))
|
| 128 |
|
| 129 | (define-public openrsync
|
| 130 | (let ((base-version "0.5.0")
|
| 131 | (revision "0")
|
| 132 | (commit "a257c0f495af2b5ee6b41efc6724850a445f87ed"))
|
| 133 | (package
|
| 134 | (name "openrsync")
|
| 135 | (version (git-version base-version revision commit))
|
| 136 | (source
|
| 137 | (origin
|
| 138 | (method git-fetch)
|
| 139 | (uri (git-reference
|
| 140 | (url "https://github.com/kristapsdz/openrsync/")
|
| 141 | (commit commit)))
|
| 142 | (file-name (git-file-name name version))
|
| 143 | (sha256
|
| 144 | (base32 "1jfz10psi1qw842hwip7p01sgd4ns9n53amdshzqy5brqyinbkd5"))))
|
| 145 | (build-system gnu-build-system)
|
| 146 | (arguments
|
| 147 | (list
|
| 148 | #:tests? #f |
| 149 | #:phases
|
| 150 | #~(modify-phases %standard-phases
|
| 151 | (add-after 'unpack 'patch-hurd
|
| 152 | (lambda _
|
| 153 | (substitute* "configure"
|
| 154 | (("defined\\(__linux__\\)" all)
|
| 155 | (string-append all "|| defined(__GNU__)")))))
|
| 156 | (replace 'configure
|
| 157 | |
| 158 | |
| 159 | (lambda _
|
| 160 | (setenv "DESTDIR" #$output)
|
| 161 | (setenv "PREFIX" "")
|
| 162 | (setenv "CFLAGS" "-O2")
|
| 163 | (setenv "CC" #$(cc-for-target))
|
| 164 | (invoke "./configure" "PREFIX=\"\""))))))
|
| 165 | (synopsis "OpenBSD implementation of @command{rsync}")
|
| 166 | (description
|
| 167 | "Openrsync is an alternate implementation of @command{rsync},
|
| 168 | originally written for OpenBSD and ported to Linux and other Unix-like
|
| 169 | systems. It supports a subset of @command{rsync}'s options.")
|
| 170 | (license license:isc)
|
| 171 | (home-page "https://github.com/kristapsdz/openrsync"))))
|