Commit | Line | Data |
---|---|---|
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> |
12bccb8e | 5 | ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2022 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> |
a24b83d7 | 11 | ;;; Copyright © 2018, 2021 Ricardo Wurmus <rekado@elephly.net> |
c15a2cd9 | 12 | ;;; Copyright © 2019, 2020 Brett Gilio <brettg@gnu.org> |
7e24e1e5 | 13 | ;;; Copyright © 2020 Hartmut Goebel <h.goebel@crazy-compilers.com> |
9cb35c02 | 14 | ;;; Copyright © 2021 Justin Veilleux <terramorpha@cock.li> |
b432cd11 | 15 | ;;; Copyright © 2021 Marius Bakke <marius@gnu.org> |
711f0e68 | 16 | ;;; Copyright © 2021 Josselin Poiret <josselin.poiret@protonmail.ch> |
1b13c71a | 17 | ;;; Copyright © 2022 Brice Waegeneire <brice@waegenei.re> |
3963a729 LC |
18 | ;;; |
19 | ;;; This file is part of GNU Guix. | |
20 | ;;; | |
21 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
22 | ;;; under the terms of the GNU General Public License as published by | |
23 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
24 | ;;; your option) any later version. | |
25 | ;;; | |
26 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
27 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
28 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
29 | ;;; GNU General Public License for more details. | |
30 | ;;; | |
31 | ;;; You should have received a copy of the GNU General Public License | |
32 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
33 | ||
34 | (define-module (gnu packages bittorrent) | |
35 | #:use-module (guix packages) | |
36 | #:use-module (guix download) | |
e906f4e1 | 37 | #:use-module (guix git-download) |
b432cd11 | 38 | #:use-module (guix build-system cmake) |
3963a729 | 39 | #:use-module (guix build-system gnu) |
feb767b2 | 40 | #:use-module (guix build-system python) |
4cdec09a | 41 | #:use-module (guix build-system glib-or-gtk) |
b5b73a82 | 42 | #:use-module ((guix licenses) #:prefix l:) |
dc64e7a1 | 43 | #:use-module (guix gexp) |
01d5eec9 | 44 | #:use-module (guix utils) |
3c569804 | 45 | #:use-module (gnu packages) |
f66842dc | 46 | #:use-module (gnu packages adns) |
9cb35c02 | 47 | #:use-module (gnu packages autotools) |
bb5f8a3b | 48 | #:use-module (gnu packages bash) |
4e58e9d0 | 49 | #:use-module (gnu packages boost) |
f66842dc | 50 | #:use-module (gnu packages check) |
b432cd11 | 51 | #:use-module (gnu packages cmake) |
f66842dc | 52 | #:use-module (gnu packages compression) |
4b67098d | 53 | #:use-module (gnu packages crypto) |
3963a729 | 54 | #:use-module (gnu packages curl) |
f66842dc | 55 | #:use-module (gnu packages cyrus-sasl) |
c2be790f | 56 | #:use-module (gnu packages freedesktop) |
9cb35c02 | 57 | #:use-module (gnu packages gettext) |
3963a729 | 58 | #:use-module (gnu packages glib) |
4b67098d TČ |
59 | #:use-module (gnu packages gnome) |
60 | #:use-module (gnu packages gnupg) | |
61 | #:use-module (gnu packages gstreamer) | |
df66fee7 | 62 | #:use-module (gnu packages gtk) |
f66842dc | 63 | #:use-module (gnu packages libevent) |
f66842dc EF |
64 | #:use-module (gnu packages multiprecision) |
65 | #:use-module (gnu packages nettle) | |
2d8dc79c | 66 | #:use-module (gnu packages ncurses) |
f66842dc | 67 | #:use-module (gnu packages pkg-config) |
feb767b2 | 68 | #:use-module (gnu packages python) |
dbcd2050 | 69 | #:use-module (gnu packages python-build) |
c2be790f | 70 | #:use-module (gnu packages python-crypto) |
01d5eec9 | 71 | #:use-module (gnu packages python-web) |
44d10b1f | 72 | #:use-module (gnu packages python-xyz) |
f8fbe376 | 73 | #:use-module (gnu packages qt) |
cd0322a3 | 74 | #:use-module (gnu packages sqlite) |
f66842dc EF |
75 | #:use-module (gnu packages ssh) |
76 | #:use-module (gnu packages tls) | |
77 | #:use-module (gnu packages xml)) | |
3963a729 LC |
78 | |
79 | (define-public transmission | |
80 | (package | |
81 | (name "transmission") | |
7233b19f | 82 | (version "3.00") |
3963a729 LC |
83 | (source (origin |
84 | (method url-fetch) | |
7233b19f LF |
85 | (uri (string-append "https://github.com/transmission/transmission" |
86 | "/releases/download/" version "/transmission-" | |
87 | version ".tar.xz")) | |
3963a729 LC |
88 | (sha256 |
89 | (base32 | |
1d634451 SS |
90 | "1wjmn96zrvmk8j1yz2ysmqd7a2x6ilvnwwapcvfzgxs2wwpnai4i")) |
91 | (patches (search-patches "transmission-honor-localedir.patch")))) | |
4cdec09a | 92 | (build-system glib-or-gtk-build-system) |
3963a729 LC |
93 | (outputs '("out" ; library and command-line interface |
94 | "gui")) ; graphical user interface | |
95 | (arguments | |
1d634451 SS |
96 | '(#:configure-flags |
97 | (list (string-append "--localedir=" | |
98 | (assoc-ref %outputs "gui") | |
99 | "/share/locale")) | |
c16341bb MO |
100 | ;; Some tests segfault when using libevent 2.12 without internet |
101 | ;; connection. This has been reported mainstream but not fixed yet: | |
102 | ;; https://github.com/transmission/transmission/issues/1437. | |
103 | #:tests? #f | |
1d634451 | 104 | #:glib-or-gtk-wrap-excluded-outputs '("out") |
dc1d3cde KK |
105 | #:phases |
106 | (modify-phases %standard-phases | |
107 | (add-after 'install 'move-gui | |
108 | (lambda* (#:key outputs #:allow-other-keys) | |
109 | ;; Move the GUI to its own output, so that "out" doesn't | |
110 | ;; depend on GTK+. | |
111 | (let ((out (assoc-ref outputs "out")) | |
112 | (gui (assoc-ref outputs "gui"))) | |
113 | (mkdir-p (string-append gui "/bin")) | |
114 | (rename-file (string-append out "/bin/transmission-gtk") | |
7233b19f | 115 | (string-append gui "/bin/transmission-gtk")) |
07366434 | 116 | |
bf155ce3 PN |
117 | (for-each |
118 | (lambda (dir) | |
119 | (rename-file (string-append out "/share/" dir) | |
120 | (string-append gui "/share/" dir))) | |
1d634451 | 121 | '("appdata" "applications" "icons" "pixmaps")) |
0305bc91 SS |
122 | |
123 | (mkdir-p (string-append gui "/share/man/man1")) | |
124 | (rename-file | |
125 | (string-append out "/share/man/man1/transmission-gtk.1") | |
126 | (string-append gui "/share/man/man1/transmission-gtk.1")) | |
127 | #t)))))) | |
3963a729 | 128 | (inputs |
8394619b | 129 | (list libevent curl openssl zlib gtk+)) |
3963a729 | 130 | (native-inputs |
8394619b | 131 | (list intltool pkg-config)) |
c4cfa9c6 | 132 | (home-page "https://transmissionbt.com/") |
3963a729 LC |
133 | (synopsis "Fast and easy BitTorrent client") |
134 | (description | |
135 | "Transmission is a BitTorrent client that comes with graphical, | |
136 | textual, and Web user interfaces. Transmission also has a daemon for | |
e881752c | 137 | unattended operations. It supports local peer discovery, full encryption, |
3963a729 LC |
138 | DHT, µTP, PEX and Magnet Links.") |
139 | ||
140 | ;; COPYING reads: | |
141 | ;; | |
142 | ;; Transmission can be redistributed and/or modified under the terms of | |
143 | ;; the GNU GPLv2 (http://www.gnu.org/licenses/license-list.html#GPLv2), | |
144 | ;; the GNU GPLv3 (http://www.gnu.org/licenses/license-list.html#GNUGPLv3), | |
145 | ;; or any future license endorsed by Mnemosyne LLC. | |
146 | ;; | |
147 | ;; A few files files carry an MIT/X11 license header. | |
559491ea | 148 | (license (list l:gpl2 l:gpl3)))) |
df66fee7 | 149 | |
9cb35c02 JV |
150 | (define-public transmission-remote-gtk |
151 | (package | |
152 | (name "transmission-remote-gtk") | |
eceecd8a | 153 | (version "1.4.2") |
9cb35c02 JV |
154 | (source |
155 | (origin | |
156 | (method url-fetch) | |
157 | (uri (string-append "https://github.com/transmission-remote-gtk/" | |
158 | "transmission-remote-gtk/releases/download/" | |
159 | version "/transmission-remote-gtk-" version | |
eceecd8a | 160 | ".tar.gz")) |
9cb35c02 | 161 | (sha256 |
eceecd8a | 162 | (base32 "0qz9wi70qc6vgnaymivc3xz6y86c9hglk6wjv3snnqxpxmp9saay")))) |
9cb35c02 JV |
163 | (build-system gnu-build-system) |
164 | (native-inputs | |
8394619b | 165 | (list gnu-gettext pkg-config)) |
9cb35c02 | 166 | (inputs |
8394619b | 167 | (list appstream-glib curl gtk+ json-glib)) |
9cb35c02 JV |
168 | (synopsis "Gtk frontend to the Transmission daemon") |
169 | (description "transmission-remote-gtk is a GTK client for remote management | |
170 | of the Transmission BitTorrent client, using its HTTP RPC protocol.") | |
171 | (home-page "https://github.com/transmission-remote-gtk/transmission-remote-gtk") | |
172 | (license l:gpl2+))) | |
173 | ||
df66fee7 LC |
174 | (define-public libtorrent |
175 | (package | |
176 | (name "libtorrent") | |
9e171634 | 177 | (version "0.13.8") |
df66fee7 LC |
178 | (source (origin |
179 | (method url-fetch) | |
180 | (uri (string-append | |
29b4c57b | 181 | "http://rtorrent.net/downloads/libtorrent-" |
df66fee7 LC |
182 | version ".tar.gz")) |
183 | (sha256 | |
184 | (base32 | |
9e171634 | 185 | "10z9i1rc41cmmi7nx8k7k1agsx6afv09g9cl7g9zr35fyhl5l4gd")))) |
df66fee7 | 186 | (build-system gnu-build-system) |
8394619b LC |
187 | (inputs (list openssl zlib)) |
188 | (native-inputs (list pkg-config cppunit)) | |
df66fee7 LC |
189 | (synopsis "BitTorrent library of rtorrent") |
190 | (description | |
191 | "LibTorrent is a BitTorrent library used by and developed in parallel | |
192 | with the BitTorrent client rtorrent. It is written in C++ with emphasis on | |
193 | speed and efficiency.") | |
9db04bf5 | 194 | (home-page "https://github.com/rakshasa/libtorrent") |
df66fee7 | 195 | (license l:gpl2+))) |
2d8dc79c TUBK |
196 | |
197 | (define-public rtorrent | |
198 | (package | |
199 | (name "rtorrent") | |
0cbec2aa | 200 | (version "0.9.8") |
2d8dc79c TUBK |
201 | (source (origin |
202 | (method url-fetch) | |
203 | (uri (string-append | |
9fbd458b | 204 | "http://rtorrent.net/downloads/rtorrent-" |
2d8dc79c TUBK |
205 | version ".tar.gz")) |
206 | (sha256 | |
207 | (base32 | |
0cbec2aa | 208 | "1bs2fnf4q7mlhkhzp3i1v052v9xn8qa7g845pk9ia8hlpw207pwy")))) |
2d8dc79c | 209 | (build-system gnu-build-system) |
8394619b LC |
210 | (inputs (list libtorrent |
211 | ncurses | |
212 | curl | |
213 | cyrus-sasl | |
214 | openssl | |
215 | zlib)) | |
216 | (native-inputs (list pkg-config cppunit)) | |
2d8dc79c TUBK |
217 | (synopsis "BitTorrent client with ncurses interface") |
218 | (description | |
219 | "rTorrent is a BitTorrent client with an ncurses interface. It supports | |
220 | full encryption, DHT, PEX, and Magnet Links. It can also be controlled via | |
221 | XML-RPC over SCGI.") | |
9db04bf5 | 222 | (home-page "https://github.com/rakshasa/rtorrent") |
2d8dc79c | 223 | (license l:gpl2+))) |
e906f4e1 LF |
224 | |
225 | (define-public tremc | |
9c77cbba LF |
226 | (package |
227 | (name "tremc") | |
228 | (version "0.9.2") | |
229 | (source | |
230 | (origin | |
231 | (method git-fetch) | |
232 | (uri (git-reference | |
233 | (url "https://github.com/tremc/tremc") | |
234 | (commit version))) | |
235 | (file-name (git-file-name name version)) | |
236 | (sha256 | |
237 | (base32 | |
b4263f12 TGR |
238 | "1fqspp2ckafplahgba54xmx0sjidx1pdzyjaqjhz0ivh98dkx2n5")) |
239 | (patches (search-patches "tremc-fix-decodestring.patch")))) | |
9c77cbba LF |
240 | (build-system gnu-build-system) |
241 | (arguments | |
242 | `(#:tests? #f ; no test suite | |
243 | #:make-flags | |
244 | (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) | |
245 | #:phases | |
246 | (modify-phases %standard-phases | |
247 | ;; The software is just a Python script that must be copied into place. | |
248 | (delete 'configure) | |
249 | (delete 'build)))) | |
250 | (inputs | |
8394619b | 251 | (list python)) |
9c77cbba LF |
252 | (synopsis "Console client for the Transmission BitTorrent daemon") |
253 | (description "Tremc is a console client, with a curses interface, for the | |
e906f4e1 | 254 | Transmission BitTorrent daemon.") |
9c77cbba LF |
255 | (home-page "https://github.com/tremc/tremc") |
256 | (license l:gpl3+))) | |
feb767b2 LF |
257 | |
258 | (define-public transmission-remote-cli | |
259 | (package | |
260 | (name "transmission-remote-cli") | |
261 | (version "1.7.1") | |
262 | (source (origin | |
8322ecb0 RW |
263 | (method git-fetch) |
264 | (uri (git-reference | |
b0e7b699 | 265 | (url "https://github.com/fagga/transmission-remote-cli") |
8322ecb0 RW |
266 | (commit (string-append "v" version)))) |
267 | (file-name (git-file-name name version)) | |
feb767b2 LF |
268 | (sha256 |
269 | (base32 | |
8322ecb0 | 270 | "09w9f8vrm61lapin8fmq4rgahr95y3c6wss10g0fgd0kl16f895v")))) |
feb767b2 LF |
271 | (build-system python-build-system) |
272 | (arguments | |
273 | `(#:python ,python-2 ; only supports Python 2 | |
274 | #:tests? #f ; no test suite | |
275 | #:phases (modify-phases %standard-phases | |
276 | ;; The software is just a Python script that must be | |
277 | ;; copied into place. | |
278 | (delete 'build) | |
279 | (replace 'install | |
280 | (lambda* (#:key outputs #:allow-other-keys) | |
281 | (let* ((out (assoc-ref outputs "out")) | |
282 | (bin (string-append out "/bin")) | |
283 | (man (string-append out "/share/man/man1")) | |
284 | ;; FIXME install zsh completions | |
285 | (completions (string-append out "/etc/bash_completion.d"))) | |
286 | (install-file "transmission-remote-cli" bin) | |
287 | (install-file "transmission-remote-cli.1" man) | |
288 | (install-file | |
289 | (string-append | |
290 | "completion/bash/" | |
291 | "transmission-remote-cli-bash-completion.sh") | |
292 | completions))))))) | |
293 | (synopsis "Console client for the Transmission BitTorrent daemon") | |
294 | (description "Transmission-remote-cli is a console client, with a curses | |
aaf111a2 LF |
295 | interface, for the Transmission BitTorrent daemon. This package is no longer |
296 | maintained upstream.") | |
feb767b2 | 297 | (home-page "https://github.com/fagga/transmission-remote-cli") |
aaf111a2 LF |
298 | (license l:gpl3+) |
299 | (properties `((superseded . ,tremc))))) | |
f66842dc EF |
300 | |
301 | (define-public aria2 | |
302 | (package | |
303 | (name "aria2") | |
161091f0 | 304 | (version "1.36.0") |
f66842dc EF |
305 | (source (origin |
306 | (method url-fetch) | |
7b6a8e23 EF |
307 | (uri (string-append "https://github.com/aria2/aria2/releases/" |
308 | "download/release-" version | |
309 | "/aria2-" version ".tar.xz")) | |
f66842dc EF |
310 | (sha256 |
311 | (base32 | |
161091f0 | 312 | "1987x4ywnnrhhfs9hi2h820c200d7nas9nd35414yh0jiihfglaq")))) |
f66842dc EF |
313 | (build-system gnu-build-system) |
314 | (arguments | |
dc64e7a1 EF |
315 | (list |
316 | #:configure-flags | |
317 | #~(list "--enable-libaria2" | |
318 | (string-append "--with-bashcompletiondir=" | |
319 | #$output "/etc/bash_completion.d/")) | |
f66842dc | 320 | #:phases |
dc64e7a1 EF |
321 | #~(modify-phases %standard-phases |
322 | (add-after 'unpack 'delete-socket-tests | |
323 | (lambda _ | |
324 | (substitute* "test/LpdMessageDispatcherTest.cc" | |
325 | (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageDispatcherTest\\);" text) | |
326 | (string-append "// " text))) | |
327 | (substitute* "test/LpdMessageReceiverTest.cc" | |
328 | (("CPPUNIT_TEST_SUITE_REGISTRATION\\(LpdMessageReceiverTest\\);" text) | |
329 | (string-append "// " text)))))))) | |
f66842dc | 330 | (native-inputs |
8394619b LC |
331 | (list cppunit ; for the tests |
332 | pkg-config)) | |
f66842dc | 333 | (inputs |
8394619b LC |
334 | (list c-ares |
335 | gnutls | |
336 | gmp | |
337 | libssh2 | |
338 | libxml2 | |
339 | nettle | |
340 | sqlite | |
341 | zlib)) | |
5bed95ef | 342 | (home-page "https://aria2.github.io/") |
f66842dc EF |
343 | (synopsis "Utility for parallel downloading files") |
344 | (description | |
345 | "Aria2 is a lightweight, multi-protocol & multi-source command-line | |
346 | download utility. It supports HTTP/HTTPS, FTP, SFTP, BitTorrent and Metalink. | |
347 | Aria2 can be manipulated via built-in JSON-RPC and XML-RPC interfaces.") | |
12bccb8e EF |
348 | (properties |
349 | '((release-monitoring-url . "https://github.com/aria2/aria2/releases"))) | |
f66842dc | 350 | (license l:gpl2+))) |
4b67098d | 351 | |
4b67098d TČ |
352 | (define-public uget |
353 | (package | |
354 | (name "uget") | |
5a3d6ad1 | 355 | (version "2.2.1") |
b2d35dd9 NG |
356 | (source |
357 | (origin | |
358 | (method url-fetch) | |
359 | (uri (string-append "mirror://sourceforge/urlget/" | |
360 | "uget%20%28stable%29/" version "/uget-" | |
361 | version ".tar.gz")) | |
362 | (sha256 | |
5a3d6ad1 | 363 | (base32 "0dlrjhnm1pg2vwmp7nl2xv1aia5hyirb3021rl46x859k63zap24")))) |
4b67098d | 364 | (build-system gnu-build-system) |
a24b83d7 RW |
365 | (arguments |
366 | `(#:configure-flags '("CFLAGS=-fcommon"))) | |
4b67098d | 367 | (inputs |
8394619b LC |
368 | (list curl |
369 | gtk+ | |
370 | glib | |
371 | gnutls | |
372 | gstreamer | |
373 | libgcrypt | |
374 | libnotify | |
375 | openssl)) | |
4b67098d | 376 | (native-inputs |
8394619b | 377 | (list intltool pkg-config)) |
950f1697 | 378 | (home-page "https://ugetdm.com/") |
4b67098d TČ |
379 | (synopsis "Universal download manager with GTK+ interface") |
380 | (description | |
381 | "uGet is portable download manager with GTK+ interface supporting | |
382 | HTTP, HTTPS, BitTorrent and Metalink, supporting multi-connection | |
383 | downloads, download scheduling, download rate limiting.") | |
384 | (license l:lgpl2.1+))) | |
8975d00c TGR |
385 | |
386 | (define-public mktorrent | |
387 | (package | |
388 | (name "mktorrent") | |
fd90e396 | 389 | (version "1.1") |
8975d00c | 390 | (source (origin |
4342a046 RW |
391 | (method git-fetch) |
392 | (uri (git-reference | |
b0e7b699 | 393 | (url "https://github.com/Rudde/mktorrent") |
4342a046 RW |
394 | (commit (string-append "v" version)))) |
395 | (file-name (git-file-name name version)) | |
8975d00c TGR |
396 | (sha256 |
397 | (base32 | |
4342a046 | 398 | "17pdc5mandl739f8q26n5is8ga56s83aqcrwhlnnplbxwx2inidr")))) |
8975d00c TGR |
399 | (build-system gnu-build-system) |
400 | (arguments | |
401 | `(#:phases (modify-phases %standard-phases | |
402 | (delete 'configure)) ; no configure script | |
a6b64691 | 403 | #:make-flags (list (string-append "CC=" ,(cc-for-target)) |
8975d00c TGR |
404 | (string-append "PREFIX=" (assoc-ref %outputs "out")) |
405 | "NO_HASH_CHECK=1" | |
406 | "USE_LARGE_FILES=1" | |
407 | "USE_LONG_OPTIONS=1" | |
408 | "USE_PTHREADS=1") | |
409 | #:tests? #f)) ; no tests | |
fd90e396 | 410 | (home-page "https://github.com/Rudde/mktorrent") |
8975d00c | 411 | (synopsis "Utility to create BitTorrent metainfo files") |
897bd0b5 TGR |
412 | (description |
413 | "mktorrent is a simple command-line utility to create BitTorrent | |
414 | @dfn{metainfo} files, often known simply as @dfn{torrents}, from both single | |
415 | files and whole directories. It can add multiple trackers and web seed URLs, | |
416 | and set the @code{private} flag to disallow advertisement through the | |
417 | distributed hash table (@dfn{DHT}) and Peer Exchange. Hashing is multi-threaded | |
8975d00c TGR |
418 | and will take advantage of multiple processor cores where possible.") |
419 | (license (list l:public-domain ; sha1.*, used to build without OpenSSL | |
420 | l:gpl2+)))) ; with permission to link with OpenSSL | |
4e58e9d0 JL |
421 | |
422 | (define-public libtorrent-rasterbar | |
423 | (package | |
424 | (name "libtorrent-rasterbar") | |
b432cd11 | 425 | (version "1.2.14") |
2d25c635 TGR |
426 | (source |
427 | (origin | |
428 | (method url-fetch) | |
429 | (uri | |
430 | (string-append "https://github.com/arvidn/libtorrent/" | |
b432cd11 | 431 | "releases/download/v" version "/" |
2d25c635 TGR |
432 | "libtorrent-rasterbar-" version ".tar.gz")) |
433 | (sha256 | |
b432cd11 MB |
434 | (base32 "0gwm4w7337ykh5lfnspapnnz6a35g7yay3wnj126s8s5kcsvy9wy")))) |
435 | (build-system cmake-build-system) | |
4e58e9d0 | 436 | (arguments |
a59abcb3 | 437 | `(#:configure-flags '("-Dpython-bindings=ON" |
b432cd11 MB |
438 | "-Dbuild_tests=ON") |
439 | #:phases | |
440 | (modify-phases %standard-phases | |
441 | (replace 'check | |
442 | (lambda* (#:key tests? parallel-tests? #:allow-other-keys) | |
443 | (let ((disabled-tests | |
444 | ;; test_upnp requires a non-localhost IPv4 interface. | |
445 | '("test_upnp"))) | |
446 | (when tests? | |
447 | ;; test_ssl relies on bundled TLS certificates with a fixed | |
448 | ;; expiry date. To ensure succesful builds in the future, | |
449 | ;; fake the time to be roughly that of the release. | |
450 | (setenv "FAKETIME_ONLY_CMDS" "test_ssl") | |
451 | (invoke "faketime" "2021-06-01" | |
452 | "ctest" | |
453 | "--exclude-regex" (string-join disabled-tests "|") | |
454 | "-j" (if parallel-tests? | |
455 | (number->string (parallel-job-count)) | |
456 | "1"))))))))) | |
8394619b | 457 | (inputs (list boost openssl)) |
b432cd11 MB |
458 | (native-inputs `(("libfaketime" ,libfaketime) |
459 | ("python" ,python-wrapper) | |
4e58e9d0 | 460 | ("pkg-config" ,pkg-config))) |
9270b2fb | 461 | (home-page "https://www.libtorrent.org/") |
a7e3aec0 | 462 | (synopsis "Feature-complete BitTorrent implementation") |
4e58e9d0 | 463 | (description |
a7e3aec0 | 464 | "libtorrent-rasterbar is a feature-complete C++ BitTorrent implementation |
4e58e9d0 JL |
465 | focusing on efficiency and scalability. It runs on embedded devices as well as |
466 | desktops.") | |
467 | (license l:bsd-2))) | |
468 | ||
f8fbe376 FT |
469 | (define-public qbittorrent |
470 | (package | |
471 | (name "qbittorrent") | |
dce70d0e | 472 | (version "4.2.5") |
0748a7b2 TGR |
473 | (source |
474 | (origin | |
475 | (method git-fetch) | |
476 | (uri (git-reference | |
b0e7b699 | 477 | (url "https://github.com/qbittorrent/qBittorrent") |
0748a7b2 TGR |
478 | (commit (string-append "release-" version)))) |
479 | (file-name (git-file-name name version)) | |
480 | (sha256 | |
dce70d0e | 481 | (base32 "1n613ylg6i9gisgk0dbr2kpfasyizrkdjff1r8smd4vri2qrdksn")))) |
f8fbe376 FT |
482 | (build-system gnu-build-system) |
483 | (arguments | |
484 | `(#:configure-flags | |
485 | (list (string-append "--with-boost-libdir=" | |
486 | (assoc-ref %build-inputs "boost") | |
487 | "/lib") | |
488 | "--enable-debug" | |
aaa88937 GLV |
489 | "QMAKE_LRELEASE=lrelease") |
490 | #:modules ((guix build gnu-build-system) | |
491 | (guix build qt-utils) | |
492 | (guix build utils)) | |
493 | #:imported-modules (,@%gnu-build-system-modules | |
494 | (guix build qt-utils)) | |
495 | #:phases | |
496 | (modify-phases %standard-phases | |
497 | (add-after 'install 'wrap-qt | |
7e24e1e5 HG |
498 | (lambda* (#:key outputs inputs #:allow-other-keys) |
499 | (let ((out (assoc-ref outputs "out"))) | |
500 | (wrap-qt-program "qbittorrent" #:output out #:inputs inputs)) | |
aaa88937 | 501 | #t))))) |
f8fbe376 | 502 | (native-inputs |
8394619b | 503 | (list pkg-config qttools)) |
f8fbe376 FT |
504 | (inputs |
505 | `(("boost" ,boost) | |
506 | ("libtorrent-rasterbar" ,libtorrent-rasterbar) | |
507 | ("openssl" ,openssl) | |
ea236462 | 508 | ("python" ,python-wrapper) |
ea0a5107 | 509 | ("qtbase" ,qtbase-5) |
f8fbe376 FT |
510 | ("qtsvg" ,qtsvg) |
511 | ("zlib" ,zlib))) | |
512 | (home-page "https://www.qbittorrent.org/") | |
513 | (synopsis "Graphical BitTorrent client") | |
514 | (description | |
515 | "qBittorrent is a BitTorrent client programmed in C++/Qt that uses | |
516 | libtorrent (sometimes called libtorrent-rasterbar) by Arvid Norberg. | |
4e58e9d0 | 517 | |
f8fbe376 FT |
518 | It aims to be a good alternative to all other BitTorrent clients out there. |
519 | qBittorrent is fast, stable and provides unicode support as well as many | |
520 | features.") | |
521 | (license l:gpl2+))) | |
c2be790f NN |
522 | |
523 | (define-public deluge | |
524 | (package | |
525 | (name "deluge") | |
1b13c71a | 526 | (version "2.0.5") |
c2be790f NN |
527 | (source |
528 | (origin | |
529 | (method url-fetch) | |
530 | (uri (string-append | |
01d5eec9 KK |
531 | "https://ftp.osuosl.org/pub/deluge/source/" |
532 | (version-major+minor version) "/deluge-" version ".tar.xz")) | |
c2be790f NN |
533 | (sha256 |
534 | (base32 | |
1b13c71a | 535 | "1n15dzfnz1gvb4cf046yhi404i3gs933qgz0ichna6r1znmh9gf4")))) |
c2be790f | 536 | (build-system python-build-system) |
bb5f8a3b | 537 | (inputs (list bash-minimal)) |
01d5eec9 | 538 | (propagated-inputs |
bb5f8a3b BW |
539 | (list gtk+ |
540 | libtorrent-rasterbar | |
541 | python-pycairo | |
542 | python-chardet | |
543 | python-dbus | |
544 | python-mako | |
545 | python-pygobject | |
546 | python-pillow | |
547 | python-pyopenssl | |
548 | python-pyxdg | |
549 | python-rencode | |
550 | python-service-identity | |
551 | python-setproctitle | |
552 | python-six | |
553 | python-twisted | |
554 | python-zope-interface)) | |
c2be790f | 555 | (native-inputs |
711f0e68 JP |
556 | (list intltool python-wheel |
557 | (if (string-prefix? "x86_64-" (%current-system)) | |
558 | librsvg-bootstrap | |
559 | librsvg-2.40))) | |
01d5eec9 KK |
560 | ;; TODO: Enable tests. |
561 | ;; After "pytest-twisted" is packaged, HOME is set, and an X server is | |
562 | ;; started, some of the tests still fail. There are likely some tests | |
563 | ;; that require a network connection. | |
c2be790f | 564 | (arguments |
01d5eec9 KK |
565 | `(#:tests? #f |
566 | #:phases | |
567 | (modify-phases %standard-phases | |
01d5eec9 | 568 | (add-after 'install 'wrap |
1471219a | 569 | (lambda* (#:key native-inputs inputs outputs #:allow-other-keys) |
01d5eec9 | 570 | (let ((out (assoc-ref outputs "out")) |
31577d87 BW |
571 | ;; "librsvg" input is only needed at build time and it |
572 | ;; conflit with the "librsvg" propageted by "gtk+", so we | |
573 | ;; make sure there is no reference to it in the wrapper. | |
1471219a JP |
574 | (gi-typelib-path |
575 | (string-join (filter | |
576 | (lambda (x) (not (string-prefix? | |
577 | (assoc-ref | |
578 | (or native-inputs inputs) | |
579 | "librsvg") | |
580 | x))) | |
581 | (string-split | |
582 | (getenv "GI_TYPELIB_PATH") | |
583 | #\:)) | |
584 | ":"))) | |
01d5eec9 KK |
585 | (for-each |
586 | (lambda (program) | |
587 | (wrap-program program | |
588 | `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))) | |
589 | (map (lambda (name) | |
590 | (string-append out "/bin/" name)) | |
591 | '("deluge" "deluge-gtk")))) | |
592 | #t))))) | |
c2be790f NN |
593 | (home-page "https://www.deluge-torrent.org/") |
594 | (synopsis "Fully-featured cross-platform BitTorrent client") | |
595 | (description | |
596 | "Deluge contains the common features to BitTorrent clients such as | |
597 | Protocol Encryption, DHT, Local Peer Discovery (LSD), Peer Exchange | |
598 | (PEX), UPnP, NAT-PMP, Proxy support, Web seeds, global and per-torrent | |
599 | speed limits. Deluge heavily utilises the libtorrent library. It is | |
600 | designed to run as both a normal standalone desktop application and as a | |
601 | client-server.") | |
602 | (license l:gpl3+))) |