1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014 Taylan Ulrich Bayirli/Kammer <taylanbayirli@gmail.com>
3 ;;; Copyright © 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
5 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
6 ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2016 Tomáš Čech <sleep_walker@gnu.org>
8 ;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
9 ;;; Copyright © 2017 Jelle Licht <jlicht@fsfe.org>
11 ;;; This file is part of GNU Guix.
13 ;;; GNU Guix is free software; you can redistribute it and/or modify it
14 ;;; under the terms of the GNU General Public License as published by
15 ;;; the Free Software Foundation; either version 3 of the License, or (at
16 ;;; your option) any later version.
18 ;;; GNU Guix is distributed in the hope that it will be useful, but
19 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ;;; GNU General Public License for more details.
23 ;;; You should have received a copy of the GNU General Public License
24 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
26 (define-module (gnu packages bittorrent)
27 #:use-module (guix packages)
28 #:use-module (guix download)
29 #:use-module (guix git-download)
30 #:use-module (guix build-system gnu)
31 #:use-module (guix build-system python)
32 #:use-module (guix build-system glib-or-gtk)
33 #:use-module ((guix licenses) #:prefix l:)
34 #:use-module (gnu packages adns)
35 #:use-module (gnu packages boost)
36 #:use-module (gnu packages check)
37 #:use-module (gnu packages compression)
38 #:use-module (gnu packages crypto)
39 #:use-module (gnu packages curl)
40 #:use-module (gnu packages cyrus-sasl)
41 #:use-module (gnu packages databases)
42 #:use-module (gnu packages file)
43 #:use-module (gnu packages glib)
44 #:use-module (gnu packages gnome)
45 #:use-module (gnu packages gnupg)
46 #:use-module (gnu packages gstreamer)
47 #:use-module (gnu packages gtk)
48 #:use-module (gnu packages libevent)
49 #:use-module (gnu packages linux)
50 #:use-module (gnu packages multiprecision)
51 #:use-module (gnu packages nettle)
52 #:use-module (gnu packages ncurses)
53 #:use-module (gnu packages pkg-config)
54 #:use-module (gnu packages python)
55 #:use-module (gnu packages ssh)
56 #:use-module (gnu packages tls)
57 #:use-module (gnu packages xml))
59 (define-public transmission
66 "https://transmission.cachefly.net/transmission-"
70 "0pykmhi7pdmzq47glbj8i2im6iarp4wnj4l1pyvsrnba61f0939s"))))
71 (build-system glib-or-gtk-build-system)
72 (outputs '("out" ; library and command-line interface
73 "gui")) ; graphical user interface
75 '(#:glib-or-gtk-wrap-excluded-outputs '("out")
76 #:phases (alist-cons-after
78 (lambda* (#:key outputs #:allow-other-keys)
79 ;; Move the GUI to its own output, so that "out" doesn't
81 (let ((out (assoc-ref outputs "out"))
82 (gui (assoc-ref outputs "gui")))
83 (mkdir-p (string-append gui "/bin"))
84 (rename-file (string-append out "/bin/transmission-gtk")
86 "/bin/transmission-gtk"))
88 ;; Move the '.desktop' file as well.
89 (mkdir (string-append gui "/share"))
90 (rename-file (string-append out "/share/applications")
91 (string-append gui "/share/applications"))))
94 `(("inotify-tools" ,inotify-tools)
95 ("libevent" ,libevent)
97 ("cyrus-sasl" ,cyrus-sasl)
103 `(("intltool" ,intltool)
104 ("pkg-config" ,pkg-config)))
105 (home-page "http://www.transmissionbt.com/")
106 (synopsis "Fast and easy BitTorrent client")
108 "Transmission is a BitTorrent client that comes with graphical,
109 textual, and Web user interfaces. Transmission also has a daemon for
110 unattended operations. It supports local peer discovery, full encryption,
111 DHT, µTP, PEX and Magnet Links.")
115 ;; Transmission can be redistributed and/or modified under the terms of
116 ;; the GNU GPLv2 (http://www.gnu.org/licenses/license-list.html#GPLv2),
117 ;; the GNU GPLv3 (http://www.gnu.org/licenses/license-list.html#GNUGPLv3),
118 ;; or any future license endorsed by Mnemosyne LLC.
120 ;; A few files files carry an MIT/X11 license header.
123 (define-public libtorrent
130 "http://rtorrent.net/downloads/libtorrent-"
134 "012s1nwcvz5m5r4d2z9klgy2n34kpgn9kgwgzxm97zgdjs6a0f18"))))
135 (build-system gnu-build-system)
136 (inputs `(("openssl" ,openssl)
138 (native-inputs `(("pkg-config" ,pkg-config)
139 ("cppunit" ,cppunit)))
140 (synopsis "BitTorrent library of rtorrent")
142 "LibTorrent is a BitTorrent library used by and developed in parallel
143 with the BitTorrent client rtorrent. It is written in C++ with emphasis on
144 speed and efficiency.")
145 (home-page "https://github.com/rakshasa/libtorrent")
148 (define-public rtorrent
155 "http://rtorrent.net/downloads/rtorrent-"
159 "03jvzw9pi2mhcm913h8qg0qw9gwjqc6lhwynb1yz1y163x7w4s8y"))))
160 (build-system gnu-build-system)
161 (inputs `(("libtorrent" ,libtorrent)
164 ("cyrus-sasl" ,cyrus-sasl)
167 (native-inputs `(("pkg-config" ,pkg-config)
168 ("cppunit" ,cppunit)))
169 (synopsis "BitTorrent client with ncurses interface")
171 "rTorrent is a BitTorrent client with an ncurses interface. It supports
172 full encryption, DHT, PEX, and Magnet Links. It can also be controlled via
174 (home-page "https://github.com/rakshasa/rtorrent")
178 (let ((commit "401f2303c9b5a6e2e7b0808617d794576d4aa29e")
182 (version (string-append "0.9.0-" revision "." (string-take commit 7)))
187 (url "https://github.com/louipc/tremc.git")
191 "1h2720zn35iggmf9av65g119b0bhskwm1ng0zbkjryaf38nfzpin"))))
192 (build-system python-build-system)
194 `(#:tests? #f ; no test suite
196 (modify-phases %standard-phases
197 ;; The software is just a Python script that must be
198 ;; copied into place.
201 (lambda* (#:key outputs #:allow-other-keys)
202 (let* ((out (assoc-ref outputs "out"))
203 (bin (string-append out "/bin"))
204 (man (string-append out "/share/man/man1"))
205 ;; FIXME install zsh completions
206 (completions (string-append out "/etc/bash_completion.d")))
207 (install-file "tremc" bin)
208 (install-file "tremc.1" man)
212 "transmission-remote-cli-bash-completion.sh")
214 (synopsis "Console client for the Transmission BitTorrent daemon")
215 (description "Tremc is a console client, with a curses interface, for the
216 Transmission BitTorrent daemon.")
217 (home-page "https://github.com/louipc/tremc")
220 (define-public transmission-remote-cli
222 (name "transmission-remote-cli")
226 (uri (string-append "https://github.com/fagga/"
227 "transmission-remote-cli/archive/v"
229 (file-name (string-append name "-" version ".tar.gz"))
232 "1y0hkpcjf6jw9xig8yf484hbhy63nip0pkchx401yxj81m25l4z9"))))
233 (build-system python-build-system)
235 `(#:python ,python-2 ; only supports Python 2
236 #:tests? #f ; no test suite
237 #:phases (modify-phases %standard-phases
238 ;; The software is just a Python script that must be
239 ;; copied into place.
242 (lambda* (#:key outputs #:allow-other-keys)
243 (let* ((out (assoc-ref outputs "out"))
244 (bin (string-append out "/bin"))
245 (man (string-append out "/share/man/man1"))
246 ;; FIXME install zsh completions
247 (completions (string-append out "/etc/bash_completion.d")))
248 (install-file "transmission-remote-cli" bin)
249 (install-file "transmission-remote-cli.1" man)
253 "transmission-remote-cli-bash-completion.sh")
255 (synopsis "Console client for the Transmission BitTorrent daemon")
256 (description "Transmission-remote-cli is a console client, with a curses
257 interface, for the Transmission BitTorrent daemon. This package is no longer
258 maintained upstream.")
259 (home-page "https://github.com/fagga/transmission-remote-cli")
261 (properties `((superseded . ,tremc)))))
269 (uri (string-append "https://github.com/tatsuhiro-t/aria2/"
270 "releases/download/release-" version "/"
271 name "-" version ".tar.xz"))
274 "131zh75fqw9a1j0igl8gx3lwmhhbicdmp2p387r0cd5j928631bv"))))
275 (build-system gnu-build-system)
277 `(#:configure-flags (list "--enable-libaria2"
278 (string-append "--with-bashcompletiondir="
279 %output "/etc/bash_completion.d/"))
281 (modify-phases %standard-phases
282 (add-after 'unpack 'delete-socket-tests
284 (substitute* "test/LpdMessageDispatcherTest.cc"
285 (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageDispatcherTest\\);" text)
286 (string-append "// " text)))
287 (substitute* "test/LpdMessageReceiverTest.cc"
288 (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageReceiverTest\\);" text)
289 (string-append "// " text)))
292 `(("cppunit" ,cppunit) ; for the tests
293 ("pkg-config" ,pkg-config)))
303 (home-page "https://aria2.github.io/")
304 (synopsis "Utility for parallel downloading files")
306 "Aria2 is a lightweight, multi-protocol & multi-source command-line
307 download utility. It supports HTTP/HTTPS, FTP, SFTP, BitTorrent and Metalink.
308 Aria2 can be manipulated via built-in JSON-RPC and XML-RPC interfaces.")
317 (uri (string-append "mirror://sourceforge/urlget/"
318 "uget%20%28stable%29/" version "/uget-"
322 "0919cf7lfk1djdl003cahqjvafdliv7v2l8r5wg95n4isqggdk75"))))
323 (build-system gnu-build-system)
325 `(("intltool" ,intltool)))
331 ("gstreamer" ,gstreamer)
332 ("libgcrypt" ,libgcrypt)
333 ("libnotify" ,libnotify)
334 ("openssl" ,openssl)))
336 `(("intltool" ,intltool)
337 ("pkg-config" ,pkg-config)))
338 (home-page "http://ugetdm.com/")
339 (synopsis "Universal download manager with GTK+ interface")
341 "uGet is portable download manager with GTK+ interface supporting
342 HTTP, HTTPS, BitTorrent and Metalink, supporting multi-connection
343 downloads, download scheduling, download rate limiting.")
344 (license l:lgpl2.1+)))
346 (define-public mktorrent
352 (uri (string-append "mirror://sourceforge/mktorrent/mktorrent/"
353 version "/" name "-" version ".tar.gz"))
356 "17qi3nfky240pq6qcmf5qg324mxm83vk9r3nvsdhsvinyqm5d3kg"))))
357 (build-system gnu-build-system)
359 `(#:phases (modify-phases %standard-phases
360 (delete 'configure)) ; no configure script
361 #:make-flags (list "CC=gcc"
362 (string-append "PREFIX=" (assoc-ref %outputs "out"))
367 #:tests? #f)) ; no tests
368 (home-page "http://mktorrent.sourceforge.net/")
369 (synopsis "Utility to create BitTorrent metainfo files")
370 (description "mktorrent is a simple command-line utility to create
371 BitTorrent @dfn{metainfo} files, often known simply as @dfn{torrents}, from
372 both single files and whole directories. It can add multiple trackers and web
373 seed URLs, and set the @code{private} flag to disallow advertisement through
374 the distributed hash table (DHT) and Peer Exchange. Hashing is multi-threaded
375 and will take advantage of multiple processor cores where possible.")
376 (license (list l:public-domain ; sha1.*, used to build without OpenSSL
377 l:gpl2+)))) ; with permission to link with OpenSSL
379 (define-public libtorrent-rasterbar
381 (name "libtorrent-rasterbar")
387 "https://github.com/arvidn/libtorrent/releases/download/libtorrent-"
388 "1_0_10" "/libtorrent-rasterbar-" version ".tar.gz"))
391 "0gjcr892hzmcngvpw5bycjci4dk49v763lsnpvbwsjmim2ncwrd8"))))
392 (build-system gnu-build-system)
395 (list (string-append "--with-boost-libdir="
396 (assoc-ref %build-inputs "boost")
398 "--enable-python-binding"
401 (string-append "LDFLAGS=-Wl,-rpath="
402 (assoc-ref %outputs "out") "/lib"))))
403 (inputs `(("boost" ,boost)
404 ("openssl" ,openssl)))
405 (native-inputs `(("python" ,python-2)
406 ("pkg-config" ,pkg-config)))
407 (home-page "http://www.rasterbar.com/products/libtorrent/")
408 (synopsis "Feature complete BitTorrent implementation")
410 "libtorrent-rasterbar is a feature complete C++ BitTorrent implementation
411 focusing on efficiency and scalability. It runs on embedded devices as well as