gnu: facter: Update to 4.0.33.
[jackhill/guix/guix.git] / gnu / packages / bittorrent.scm
CommitLineData
3963a729 1;;; GNU Guix --- Functional package management for GNU
df66fee7 2;;; Copyright © 2014 Taylan Ulrich Bayirli/Kammer <taylanbayirli@gmail.com>
07366434 3;;; Copyright © 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
9c77cbba 4;;; Copyright © 2016, 2017, 2018, 2019, 2020 Leo Famulari <leo@famulari.name>
7b6a8e23 5;;; Copyright © 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
4b67098d 6;;; Copyright © 2016 Tomáš Čech <sleep_walker@gnu.org>
dbd0b46d 7;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
4e58e9d0 8;;; Copyright © 2017 Jelle Licht <jlicht@fsfe.org>
f8fbe376 9;;; Copyright © 2018 Fis Trivial <ybbs.daans@hotmail.com>
39da44c2 10;;; Copyright © 2018 Nam Nguyen <namn@berkeley.edu>
8322ecb0 11;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net>
c15a2cd9 12;;; Copyright © 2019, 2020 Brett Gilio <brettg@gnu.org>
3963a729
LC
13;;;
14;;; This file is part of GNU Guix.
15;;;
16;;; GNU Guix is free software; you can redistribute it and/or modify it
17;;; under the terms of the GNU General Public License as published by
18;;; the Free Software Foundation; either version 3 of the License, or (at
19;;; your option) any later version.
20;;;
21;;; GNU Guix is distributed in the hope that it will be useful, but
22;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24;;; GNU General Public License for more details.
25;;;
26;;; You should have received a copy of the GNU General Public License
27;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
29(define-module (gnu packages bittorrent)
30 #:use-module (guix packages)
31 #:use-module (guix download)
e906f4e1 32 #:use-module (guix git-download)
3963a729 33 #:use-module (guix build-system gnu)
feb767b2 34 #:use-module (guix build-system python)
4cdec09a 35 #:use-module (guix build-system glib-or-gtk)
b5b73a82 36 #:use-module ((guix licenses) #:prefix l:)
3c569804 37 #:use-module (gnu packages)
f66842dc 38 #:use-module (gnu packages adns)
4e58e9d0 39 #:use-module (gnu packages boost)
f66842dc
EF
40 #:use-module (gnu packages check)
41 #:use-module (gnu packages compression)
4b67098d 42 #:use-module (gnu packages crypto)
3963a729 43 #:use-module (gnu packages curl)
f66842dc 44 #:use-module (gnu packages cyrus-sasl)
c2be790f 45 #:use-module (gnu packages freedesktop)
3963a729 46 #:use-module (gnu packages glib)
4b67098d
47 #:use-module (gnu packages gnome)
48 #:use-module (gnu packages gnupg)
49 #:use-module (gnu packages gstreamer)
df66fee7 50 #:use-module (gnu packages gtk)
f66842dc 51 #:use-module (gnu packages libevent)
f66842dc
EF
52 #:use-module (gnu packages multiprecision)
53 #:use-module (gnu packages nettle)
2d8dc79c 54 #:use-module (gnu packages ncurses)
f66842dc 55 #:use-module (gnu packages pkg-config)
feb767b2 56 #:use-module (gnu packages python)
c2be790f 57 #:use-module (gnu packages python-crypto)
44d10b1f 58 #:use-module (gnu packages python-xyz)
f8fbe376 59 #:use-module (gnu packages qt)
cd0322a3 60 #:use-module (gnu packages sqlite)
f66842dc
EF
61 #:use-module (gnu packages ssh)
62 #:use-module (gnu packages tls)
63 #:use-module (gnu packages xml))
3963a729
LC
64
65(define-public transmission
66 (package
67 (name "transmission")
7233b19f 68 (version "3.00")
3963a729
LC
69 (source (origin
70 (method url-fetch)
7233b19f
LF
71 (uri (string-append "https://github.com/transmission/transmission"
72 "/releases/download/" version "/transmission-"
73 version ".tar.xz"))
3963a729
LC
74 (sha256
75 (base32
7233b19f 76 "1wjmn96zrvmk8j1yz2ysmqd7a2x6ilvnwwapcvfzgxs2wwpnai4i"))))
4cdec09a 77 (build-system glib-or-gtk-build-system)
3963a729
LC
78 (outputs '("out" ; library and command-line interface
79 "gui")) ; graphical user interface
80 (arguments
4cdec09a 81 '(#:glib-or-gtk-wrap-excluded-outputs '("out")
dc1d3cde
KK
82 #:phases
83 (modify-phases %standard-phases
84 (add-after 'install 'move-gui
85 (lambda* (#:key outputs #:allow-other-keys)
86 ;; Move the GUI to its own output, so that "out" doesn't
87 ;; depend on GTK+.
88 (let ((out (assoc-ref outputs "out"))
89 (gui (assoc-ref outputs "gui")))
90 (mkdir-p (string-append gui "/bin"))
91 (rename-file (string-append out "/bin/transmission-gtk")
7233b19f 92 (string-append gui "/bin/transmission-gtk"))
07366434 93
bf155ce3 94 ;; Move the '.desktop' and icon files as well.
dc1d3cde 95 (mkdir (string-append gui "/share"))
bf155ce3
PN
96 (for-each
97 (lambda (dir)
98 (rename-file (string-append out "/share/" dir)
99 (string-append gui "/share/" dir)))
100 '("applications" "icons" "pixmaps")))
dc1d3cde 101 #t)))))
3963a729 102 (inputs
559491ea 103 `(("libevent" ,libevent)
3963a729
LC
104 ("curl" ,curl)
105 ("openssl" ,openssl)
3963a729
LC
106 ("zlib" ,zlib)
107 ("gtk+" ,gtk+)))
108 (native-inputs
109 `(("intltool" ,intltool)
110 ("pkg-config" ,pkg-config)))
c4cfa9c6 111 (home-page "https://transmissionbt.com/")
3963a729
LC
112 (synopsis "Fast and easy BitTorrent client")
113 (description
114 "Transmission is a BitTorrent client that comes with graphical,
115textual, and Web user interfaces. Transmission also has a daemon for
e881752c 116unattended operations. It supports local peer discovery, full encryption,
3963a729
LC
117DHT, µTP, PEX and Magnet Links.")
118
119 ;; COPYING reads:
120 ;;
121 ;; Transmission can be redistributed and/or modified under the terms of
122 ;; the GNU GPLv2 (http://www.gnu.org/licenses/license-list.html#GPLv2),
123 ;; the GNU GPLv3 (http://www.gnu.org/licenses/license-list.html#GNUGPLv3),
124 ;; or any future license endorsed by Mnemosyne LLC.
125 ;;
126 ;; A few files files carry an MIT/X11 license header.
559491ea 127 (license (list l:gpl2 l:gpl3))))
df66fee7
LC
128
129(define-public libtorrent
130 (package
131 (name "libtorrent")
9e171634 132 (version "0.13.8")
df66fee7
LC
133 (source (origin
134 (method url-fetch)
135 (uri (string-append
29b4c57b 136 "http://rtorrent.net/downloads/libtorrent-"
df66fee7
LC
137 version ".tar.gz"))
138 (sha256
139 (base32
9e171634 140 "10z9i1rc41cmmi7nx8k7k1agsx6afv09g9cl7g9zr35fyhl5l4gd"))))
df66fee7
LC
141 (build-system gnu-build-system)
142 (inputs `(("openssl" ,openssl)
143 ("zlib" ,zlib)))
144 (native-inputs `(("pkg-config" ,pkg-config)
29b4c57b 145 ("cppunit" ,cppunit)))
df66fee7
LC
146 (synopsis "BitTorrent library of rtorrent")
147 (description
148 "LibTorrent is a BitTorrent library used by and developed in parallel
149with the BitTorrent client rtorrent. It is written in C++ with emphasis on
150speed and efficiency.")
9db04bf5 151 (home-page "https://github.com/rakshasa/libtorrent")
df66fee7 152 (license l:gpl2+)))
2d8dc79c
TUBK
153
154(define-public rtorrent
155 (package
156 (name "rtorrent")
0cbec2aa 157 (version "0.9.8")
2d8dc79c
TUBK
158 (source (origin
159 (method url-fetch)
160 (uri (string-append
9fbd458b 161 "http://rtorrent.net/downloads/rtorrent-"
2d8dc79c
TUBK
162 version ".tar.gz"))
163 (sha256
164 (base32
0cbec2aa 165 "1bs2fnf4q7mlhkhzp3i1v052v9xn8qa7g845pk9ia8hlpw207pwy"))))
2d8dc79c
TUBK
166 (build-system gnu-build-system)
167 (inputs `(("libtorrent" ,libtorrent)
168 ("ncurses" ,ncurses)
169 ("curl" ,curl)
170 ("cyrus-sasl" ,cyrus-sasl)
171 ("openssl" ,openssl)
172 ("zlib" ,zlib)))
173 (native-inputs `(("pkg-config" ,pkg-config)
174 ("cppunit" ,cppunit)))
175 (synopsis "BitTorrent client with ncurses interface")
176 (description
177 "rTorrent is a BitTorrent client with an ncurses interface. It supports
178full encryption, DHT, PEX, and Magnet Links. It can also be controlled via
179XML-RPC over SCGI.")
9db04bf5 180 (home-page "https://github.com/rakshasa/rtorrent")
2d8dc79c 181 (license l:gpl2+)))
e906f4e1
LF
182
183(define-public tremc
9c77cbba
LF
184 (package
185 (name "tremc")
186 (version "0.9.2")
187 (source
188 (origin
189 (method git-fetch)
190 (uri (git-reference
191 (url "https://github.com/tremc/tremc")
192 (commit version)))
193 (file-name (git-file-name name version))
194 (sha256
195 (base32
196 "1fqspp2ckafplahgba54xmx0sjidx1pdzyjaqjhz0ivh98dkx2n5"))))
197 (build-system gnu-build-system)
198 (arguments
199 `(#:tests? #f ; no test suite
200 #:make-flags
201 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
202 #:phases
203 (modify-phases %standard-phases
204 ;; The software is just a Python script that must be copied into place.
205 (delete 'configure)
206 (delete 'build))))
207 (inputs
208 `(("python" ,python)))
209 (synopsis "Console client for the Transmission BitTorrent daemon")
210 (description "Tremc is a console client, with a curses interface, for the
e906f4e1 211Transmission BitTorrent daemon.")
9c77cbba
LF
212 (home-page "https://github.com/tremc/tremc")
213 (license l:gpl3+)))
feb767b2
LF
214
215(define-public transmission-remote-cli
216 (package
217 (name "transmission-remote-cli")
218 (version "1.7.1")
219 (source (origin
8322ecb0
RW
220 (method git-fetch)
221 (uri (git-reference
b0e7b699 222 (url "https://github.com/fagga/transmission-remote-cli")
8322ecb0
RW
223 (commit (string-append "v" version))))
224 (file-name (git-file-name name version))
feb767b2
LF
225 (sha256
226 (base32
8322ecb0 227 "09w9f8vrm61lapin8fmq4rgahr95y3c6wss10g0fgd0kl16f895v"))))
feb767b2
LF
228 (build-system python-build-system)
229 (arguments
230 `(#:python ,python-2 ; only supports Python 2
231 #:tests? #f ; no test suite
232 #:phases (modify-phases %standard-phases
233 ;; The software is just a Python script that must be
234 ;; copied into place.
235 (delete 'build)
236 (replace 'install
237 (lambda* (#:key outputs #:allow-other-keys)
238 (let* ((out (assoc-ref outputs "out"))
239 (bin (string-append out "/bin"))
240 (man (string-append out "/share/man/man1"))
241 ;; FIXME install zsh completions
242 (completions (string-append out "/etc/bash_completion.d")))
243 (install-file "transmission-remote-cli" bin)
244 (install-file "transmission-remote-cli.1" man)
245 (install-file
246 (string-append
247 "completion/bash/"
248 "transmission-remote-cli-bash-completion.sh")
249 completions)))))))
250 (synopsis "Console client for the Transmission BitTorrent daemon")
251 (description "Transmission-remote-cli is a console client, with a curses
aaf111a2
LF
252interface, for the Transmission BitTorrent daemon. This package is no longer
253maintained upstream.")
feb767b2 254 (home-page "https://github.com/fagga/transmission-remote-cli")
aaf111a2
LF
255 (license l:gpl3+)
256 (properties `((superseded . ,tremc)))))
f66842dc
EF
257
258(define-public aria2
259 (package
260 (name "aria2")
7b6a8e23 261 (version "1.35.0")
f66842dc
EF
262 (source (origin
263 (method url-fetch)
7b6a8e23
EF
264 (uri (string-append "https://github.com/aria2/aria2/releases/"
265 "download/release-" version
266 "/aria2-" version ".tar.xz"))
f66842dc
EF
267 (sha256
268 (base32
7b6a8e23 269 "1zbxc517d97lb96f15xcy4l7b66grxrp3h2ids2jiwkaip87yaqy"))))
f66842dc
EF
270 (build-system gnu-build-system)
271 (arguments
d2a7a145
EF
272 `(#:configure-flags (list "--enable-libaria2"
273 (string-append "--with-bashcompletiondir="
274 %output "/etc/bash_completion.d/"))
f66842dc
EF
275 #:phases
276 (modify-phases %standard-phases
277 (add-after 'unpack 'delete-socket-tests
278 (lambda _
279 (substitute* "test/LpdMessageDispatcherTest.cc"
280 (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageDispatcherTest\\);" text)
281 (string-append "// " text)))
282 (substitute* "test/LpdMessageReceiverTest.cc"
283 (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageReceiverTest\\);" text)
9c64f76e
EF
284 (string-append "// " text)))
285 #t)))))
f66842dc 286 (native-inputs
5bed95ef
EF
287 `(("cppunit" ,cppunit) ; for the tests
288 ("pkg-config" ,pkg-config)))
f66842dc
EF
289 (inputs
290 `(("c-ares" ,c-ares)
f66842dc
EF
291 ("gnutls" ,gnutls)
292 ("gmp" ,gmp)
293 ("libssh2" ,libssh2)
294 ("libxml2" ,libxml2)
295 ("nettle" ,nettle)
296 ("sqlite" ,sqlite)
297 ("zlib" ,zlib)))
5bed95ef 298 (home-page "https://aria2.github.io/")
f66842dc
EF
299 (synopsis "Utility for parallel downloading files")
300 (description
301 "Aria2 is a lightweight, multi-protocol & multi-source command-line
302download utility. It supports HTTP/HTTPS, FTP, SFTP, BitTorrent and Metalink.
303Aria2 can be manipulated via built-in JSON-RPC and XML-RPC interfaces.")
304 (license l:gpl2+)))
4b67098d 305
4b67098d
306(define-public uget
307 (package
308 (name "uget")
b2d35dd9
NG
309 (version "2.2.0")
310 (source
311 (origin
312 (method url-fetch)
313 (uri (string-append "mirror://sourceforge/urlget/"
314 "uget%20%28stable%29/" version "/uget-"
315 version ".tar.gz"))
316 (sha256
317 (base32 "0rg2mr2cndxvnjib8zm5dp7y2hgbvnqkz2j2jmg0xlzfh9d34b2m"))))
4b67098d 318 (build-system gnu-build-system)
4b67098d
319 (inputs
320 `(("curl" ,curl)
321 ("gtk+" ,gtk+)
322 ("glib" ,glib)
323 ("gnutls" ,gnutls)
324 ("gstreamer" ,gstreamer)
325 ("libgcrypt" ,libgcrypt)
326 ("libnotify" ,libnotify)
327 ("openssl" ,openssl)))
328 (native-inputs
c7ad32d9
EF
329 `(("intltool" ,intltool)
330 ("pkg-config" ,pkg-config)))
950f1697 331 (home-page "https://ugetdm.com/")
4b67098d
332 (synopsis "Universal download manager with GTK+ interface")
333 (description
334 "uGet is portable download manager with GTK+ interface supporting
335HTTP, HTTPS, BitTorrent and Metalink, supporting multi-connection
336downloads, download scheduling, download rate limiting.")
337 (license l:lgpl2.1+)))
8975d00c
TGR
338
339(define-public mktorrent
340 (package
341 (name "mktorrent")
fd90e396 342 (version "1.1")
8975d00c 343 (source (origin
4342a046
RW
344 (method git-fetch)
345 (uri (git-reference
b0e7b699 346 (url "https://github.com/Rudde/mktorrent")
4342a046
RW
347 (commit (string-append "v" version))))
348 (file-name (git-file-name name version))
8975d00c
TGR
349 (sha256
350 (base32
4342a046 351 "17pdc5mandl739f8q26n5is8ga56s83aqcrwhlnnplbxwx2inidr"))))
8975d00c
TGR
352 (build-system gnu-build-system)
353 (arguments
354 `(#:phases (modify-phases %standard-phases
355 (delete 'configure)) ; no configure script
356 #:make-flags (list "CC=gcc"
357 (string-append "PREFIX=" (assoc-ref %outputs "out"))
358 "NO_HASH_CHECK=1"
359 "USE_LARGE_FILES=1"
360 "USE_LONG_OPTIONS=1"
361 "USE_PTHREADS=1")
362 #:tests? #f)) ; no tests
fd90e396 363 (home-page "https://github.com/Rudde/mktorrent")
8975d00c 364 (synopsis "Utility to create BitTorrent metainfo files")
897bd0b5
TGR
365 (description
366 "mktorrent is a simple command-line utility to create BitTorrent
367@dfn{metainfo} files, often known simply as @dfn{torrents}, from both single
368files and whole directories. It can add multiple trackers and web seed URLs,
369and set the @code{private} flag to disallow advertisement through the
370distributed hash table (@dfn{DHT}) and Peer Exchange. Hashing is multi-threaded
8975d00c
TGR
371and will take advantage of multiple processor cores where possible.")
372 (license (list l:public-domain ; sha1.*, used to build without OpenSSL
373 l:gpl2+)))) ; with permission to link with OpenSSL
4e58e9d0
JL
374
375(define-public libtorrent-rasterbar
376 (package
377 (name "libtorrent-rasterbar")
c15a2cd9 378 (version "1.2.7")
4e58e9d0
JL
379 (source (origin
380 (method url-fetch)
381 (uri
382 (string-append
c15a2cd9 383 "https://github.com/arvidn/libtorrent/releases/download/libtorrent_"
3c569804
MB
384 (string-join (string-split version #\.) "_")
385 "/libtorrent-rasterbar-" version ".tar.gz"))
4e58e9d0
JL
386 (sha256
387 (base32
c15a2cd9 388 "001g35janbxi20c7jzsf3ii9mkagz4kdsp7f3sz5r0n0cng0c05w"))))
4e58e9d0
JL
389 (build-system gnu-build-system)
390 (arguments
391 `(#:configure-flags
392 (list (string-append "--with-boost-libdir="
393 (assoc-ref %build-inputs "boost")
394 "/lib")
395 "--enable-python-binding"
7960bb27 396 "--enable-tests")
4e58e9d0
JL
397 #:make-flags (list
398 (string-append "LDFLAGS=-Wl,-rpath="
0fe041bd 399 (assoc-ref %outputs "out") "/lib"))))
4e58e9d0
JL
400 (inputs `(("boost" ,boost)
401 ("openssl" ,openssl)))
e22c2c78 402 (native-inputs `(("python" ,python-wrapper)
4e58e9d0 403 ("pkg-config" ,pkg-config)))
9270b2fb 404 (home-page "https://www.libtorrent.org/")
4e58e9d0
JL
405 (synopsis "Feature complete BitTorrent implementation")
406 (description
407 "libtorrent-rasterbar is a feature complete C++ BitTorrent implementation
408focusing on efficiency and scalability. It runs on embedded devices as well as
409desktops.")
410 (license l:bsd-2)))
411
f8fbe376
FT
412(define-public qbittorrent
413 (package
414 (name "qbittorrent")
dce70d0e 415 (version "4.2.5")
0748a7b2
TGR
416 (source
417 (origin
418 (method git-fetch)
419 (uri (git-reference
b0e7b699 420 (url "https://github.com/qbittorrent/qBittorrent")
0748a7b2
TGR
421 (commit (string-append "release-" version))))
422 (file-name (git-file-name name version))
423 (sha256
dce70d0e 424 (base32 "1n613ylg6i9gisgk0dbr2kpfasyizrkdjff1r8smd4vri2qrdksn"))))
f8fbe376
FT
425 (build-system gnu-build-system)
426 (arguments
427 `(#:configure-flags
428 (list (string-append "--with-boost-libdir="
429 (assoc-ref %build-inputs "boost")
430 "/lib")
431 "--enable-debug"
aaa88937
GLV
432 "QMAKE_LRELEASE=lrelease")
433 #:modules ((guix build gnu-build-system)
434 (guix build qt-utils)
435 (guix build utils))
436 #:imported-modules (,@%gnu-build-system-modules
437 (guix build qt-utils))
438 #:phases
439 (modify-phases %standard-phases
440 (add-after 'install 'wrap-qt
441 (lambda* (#:key outputs #:allow-other-keys)
442 (wrap-qt-program (assoc-ref outputs "out") "qbittorrent")
443 #t)))))
f8fbe376
FT
444 (native-inputs
445 `(("pkg-config" ,pkg-config)
446 ("qttools" ,qttools)))
447 (inputs
448 `(("boost" ,boost)
449 ("libtorrent-rasterbar" ,libtorrent-rasterbar)
450 ("openssl" ,openssl)
ea236462 451 ("python" ,python-wrapper)
f8fbe376
FT
452 ("qtbase" ,qtbase)
453 ("qtsvg" ,qtsvg)
454 ("zlib" ,zlib)))
455 (home-page "https://www.qbittorrent.org/")
456 (synopsis "Graphical BitTorrent client")
457 (description
458 "qBittorrent is a BitTorrent client programmed in C++/Qt that uses
459libtorrent (sometimes called libtorrent-rasterbar) by Arvid Norberg.
4e58e9d0 460
f8fbe376
FT
461It aims to be a good alternative to all other BitTorrent clients out there.
462qBittorrent is fast, stable and provides unicode support as well as many
463features.")
464 (license l:gpl2+)))
c2be790f
NN
465
466(define-public deluge
467 (package
468 (name "deluge")
469 (version "1.3.15")
470 (source
471 (origin
472 (method url-fetch)
473 (uri (string-append
474 "http://download.deluge-torrent.org/source/deluge-"
475 version ".tar.xz"))
476 (sha256
477 (base32
478 "0b7rri4x0wrcj7rjghrnw1kfrsd5i7i6aq85dsg5dg1w1qa0ar59"))))
479 (build-system python-build-system)
480 (inputs
481 `(("libtorrent" ,libtorrent-rasterbar)
482 ("python2-chardet" ,python2-chardet)
483 ("python2-pygtk" ,python2-pygtk)
484 ("python2-pyopenssl" ,python2-pyopenssl)
485 ("python2-pyxdg" ,python2-pyxdg)
486 ("python2-service-identity" ,python2-service-identity)
487 ("python2-twisted" ,python2-twisted)))
488 (native-inputs
489 `(("intltool" ,intltool)))
490 (arguments
491 `(#:python ,python-2))
492 (home-page "https://www.deluge-torrent.org/")
493 (synopsis "Fully-featured cross-platform ​BitTorrent client")
494 (description
495 "Deluge contains the common features to BitTorrent clients such as
496Protocol Encryption, DHT, Local Peer Discovery (LSD), Peer Exchange
497(PEX), UPnP, NAT-PMP, Proxy support, Web seeds, global and per-torrent
498speed limits. Deluge heavily utilises the ​libtorrent library. It is
499designed to run as both a normal standalone desktop application and as a
500​client-server.")
501 (license l:gpl3+)))