gnu: Remove ".git" from "https://github/…/….git".
[jackhill/guix/guix.git] / gnu / packages / messaging.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
3 ;;; Copyright © 2014, 2017 Julien Lepiller <julien@lepiller.eu>
4 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.com>
5 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
6 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
8 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
9 ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
10 ;;; Copyright © 2016, 2017, 2018, 2019 Clément Lassieur <clement@lassieur.org>
11 ;;; Copyright © 2017 Mekeor Melire <mekeor.melire@gmail.com>
12 ;;; Copyright © 2017, 2018, 2020 Arun Isaac <arunisaac@systemreboot.net>
13 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
14 ;;; Copyright © 2017 Theodoros Foradis <theodoros@foradis.org>
15 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
16 ;;; Copyright © 2018 Leo Famulari <leo@famulari.name>
17 ;;; Copyright © 2018 Pierre-Antoine Rouby <contact@parouby.fr>
18 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
19 ;;; Copyright © 2019, 2020 Brett Gilio <brettg@gnu.org>
20 ;;; Copyright © 2019, 2020 Timotej Lazar <timotej.lazar@araneo.si>
21 ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz>
22 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
23 ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
24 ;;; Copyright © 2020 Reza Alizadeh Majd <r.majd@pantherx.org>
25 ;;; Copyright © 2020 Jonathan Brielmaier <jonathan.brielmaier@web.de>
26 ;;;
27 ;;; This file is part of GNU Guix.
28 ;;;
29 ;;; GNU Guix is free software; you can redistribute it and/or modify it
30 ;;; under the terms of the GNU General Public License as published by
31 ;;; the Free Software Foundation; either version 3 of the License, or (at
32 ;;; your option) any later version.
33 ;;;
34 ;;; GNU Guix is distributed in the hope that it will be useful, but
35 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
36 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37 ;;; GNU General Public License for more details.
38 ;;;
39 ;;; You should have received a copy of the GNU General Public License
40 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
41
42 (define-module (gnu packages messaging)
43 #:use-module (gnu packages)
44 #:use-module (gnu packages admin)
45 #:use-module (gnu packages aidc)
46 #:use-module (gnu packages aspell)
47 #:use-module (gnu packages audio)
48 #:use-module (gnu packages autotools)
49 #:use-module (gnu packages avahi)
50 #:use-module (gnu packages base)
51 #:use-module (gnu packages bash)
52 #:use-module (gnu packages bison)
53 #:use-module (gnu packages boost)
54 #:use-module (gnu packages check)
55 #:use-module (gnu packages compression)
56 #:use-module (gnu packages cpp)
57 #:use-module (gnu packages crypto)
58 #:use-module (gnu packages curl)
59 #:use-module (gnu packages cyrus-sasl)
60 #:use-module (gnu packages databases)
61 #:use-module (gnu packages documentation)
62 #:use-module (gnu packages enchant)
63 #:use-module (gnu packages fontutils)
64 #:use-module (gnu packages freedesktop)
65 #:use-module (gnu packages gettext)
66 #:use-module (gnu packages glib)
67 #:use-module (gnu packages gnome)
68 #:use-module (gnu packages gnupg)
69 #:use-module (gnu packages gperf)
70 #:use-module (gnu packages gtk)
71 #:use-module (gnu packages guile)
72 #:use-module (gnu packages icu4c)
73 #:use-module (gnu packages image)
74 #:use-module (gnu packages less)
75 #:use-module (gnu packages libcanberra)
76 #:use-module (gnu packages libidn)
77 #:use-module (gnu packages linux)
78 #:use-module (gnu packages logging)
79 #:use-module (gnu packages lua)
80 #:use-module (gnu packages man)
81 #:use-module (gnu packages markup)
82 #:use-module (gnu packages ncurses)
83 #:use-module (gnu packages networking)
84 #:use-module (gnu packages pcre)
85 #:use-module (gnu packages perl)
86 #:use-module (gnu packages photo)
87 #:use-module (gnu packages php)
88 #:use-module (gnu packages pkg-config)
89 #:use-module (gnu packages protobuf)
90 #:use-module (gnu packages python)
91 #:use-module (gnu packages python-crypto)
92 #:use-module (gnu packages python-web)
93 #:use-module (gnu packages python-xyz)
94 #:use-module (gnu packages qt)
95 #:use-module (gnu packages readline)
96 #:use-module (gnu packages sqlite)
97 #:use-module (gnu packages tcl)
98 #:use-module (gnu packages texinfo)
99 #:use-module (gnu packages textutils)
100 #:use-module (gnu packages tls)
101 #:use-module (gnu packages video)
102 #:use-module (gnu packages web)
103 #:use-module (gnu packages xdisorg)
104 #:use-module (gnu packages xiph)
105 #:use-module (gnu packages xml)
106 #:use-module (gnu packages xorg)
107 #:use-module (guix build-system cmake)
108 #:use-module (guix build-system glib-or-gtk)
109 #:use-module (guix build-system gnu)
110 #:use-module (guix build-system meson)
111 #:use-module (guix build-system perl)
112 #:use-module (guix build-system python)
113 #:use-module (guix build-system qt)
114 #:use-module (guix build-system trivial)
115 #:use-module (guix download)
116 #:use-module (guix git-download)
117 #:use-module (guix hg-download)
118 #:use-module ((guix licenses) #:prefix license:)
119 #:use-module (guix packages)
120 #:use-module (guix utils))
121
122 (define-public libotr
123 (package
124 (name "libotr")
125 (version "4.1.1")
126 (source (origin
127 (method url-fetch)
128 (uri (string-append "https://otr.cypherpunks.ca/libotr-"
129 version ".tar.gz"))
130 (sha256
131 (base32
132 "1x8rliydhbibmzwdbyr7pd7n87m2jmxnqkpvaalnf4154hj1hfwb"))
133 (patches (search-patches "libotr-test-auth-fix.patch"))))
134 (build-system gnu-build-system)
135 (propagated-inputs
136 `(("libgcrypt" ,libgcrypt))) ; libotr headers include gcrypt.h
137 (inputs `(("libgpg-error" ,libgpg-error)))
138 (native-inputs `(("perl" ,perl))) ; for the test suite
139 (synopsis "Off-the-Record (OTR) Messaging Library and Toolkit")
140 (description
141 "OTR allows you to have private conversations over instant messaging by
142 providing: (1) Encryption: No one else can read your instant messages. (2)
143 Authentication: You are assured the correspondent is who you think it is. (3)
144 Deniability: The messages you send do not have digital signatures that are
145 checkable by a third party. Anyone can forge messages after a conversation to
146 make them look like they came from you. However, during a conversation, your
147 correspondent is assured the messages he sees are authentic and
148 unmodified. (4) Perfect forward secrecy: If you lose control of your private
149 keys, no previous conversation is compromised.")
150 (home-page "https://otr.cypherpunks.ca/")
151 (license (list license:lgpl2.1 license:gpl2))))
152
153 (define-public libsignal-protocol-c
154 (package
155 (name "libsignal-protocol-c")
156 (version "2.3.2")
157 (source (origin
158 (method git-fetch)
159 (uri (git-reference
160 (url "https://github.com/WhisperSystems/libsignal-protocol-c")
161 (commit (string-append "v" version))))
162 (file-name (git-file-name name version))
163 (sha256
164 (base32
165 "1qj2w4csy6j9jg1jy66n1qwysx7hgjywk4n35hlqcnh1kpa14k3p"))))
166 (arguments
167 `(;; Required for proper linking and for tests to run.
168 #:configure-flags '("-DBUILD_SHARED_LIBS=on" "-DBUILD_TESTING=1")))
169 (build-system cmake-build-system)
170 (inputs `( ;; Required for tests:
171 ("check" ,check)
172 ("openssl" ,openssl)))
173 (native-inputs `(("pkg-config" ,pkg-config)))
174 (home-page "https://github.com/WhisperSystems/libsignal-protocol-c")
175 (synopsis "Implementation of a ratcheting forward secrecy protocol")
176 (description "libsignal-protocol-c is an implementation of a ratcheting
177 forward secrecy protocol that works in synchronous and asynchronous
178 messaging environments. It can be used with messaging software to provide
179 end-to-end encryption.")
180 (license license:gpl3+)))
181
182 (define-public bitlbee
183 (package
184 (name "bitlbee")
185 (version "3.6")
186 (source (origin
187 (method url-fetch)
188 (uri (string-append "https://get.bitlbee.org/src/bitlbee-"
189 version ".tar.gz"))
190 (sha256
191 (base32 "0zhhcbcr59sx9h4maf8zamzv2waya7sbsl7w74gbyilvy93dw5cz"))))
192 (build-system gnu-build-system)
193 (native-inputs `(("pkg-config" ,pkg-config)
194 ;; Note: Change to 'check' for versions > 3.6.
195 ("check" ,check-0.12)))
196 (inputs `(("glib" ,glib)
197 ("libotr" ,libotr)
198 ("gnutls" ,gnutls)
199 ("python" ,python)
200 ("perl" ,perl)))
201 (arguments
202 `(#:phases
203 (modify-phases %standard-phases
204 (add-before 'configure 'set-python
205 (lambda _ (setenv "PYTHON" (which "python3")) #t))
206 (add-after 'install 'install-etc
207 (lambda* (#:key (make-flags '()) #:allow-other-keys)
208 (apply invoke "make" "install-etc" make-flags)))
209 (add-after 'install-etc 'install-lib
210 (lambda* (#:key (make-flags '()) #:allow-other-keys)
211 (apply invoke "make" "install-dev" make-flags)))
212 (replace 'configure
213 ;; bitlbee's configure script does not tolerate many of the
214 ;; variable settings that Guix would pass to it.
215 (lambda* (#:key outputs #:allow-other-keys)
216 (invoke "./configure"
217 (string-append "--prefix="
218 (assoc-ref outputs "out"))
219 "--otr=1"))))))
220 (synopsis "IRC to instant messaging gateway")
221 (description "BitlBee brings IM (instant messaging) to IRC clients, for
222 people who have an IRC client running all the time and don't want to run an
223 additional IM client. BitlBee currently supports XMPP/Jabber (including
224 Google Talk), MSN Messenger, Yahoo! Messenger, AIM and ICQ, and the Twitter
225 microblogging network (plus all other Twitter API compatible services like
226 identi.ca and status.net).")
227 (home-page "https://www.bitlbee.org/")
228 (license (list license:gpl2+ license:bsd-2))))
229
230 (define-public bitlbee-discord
231 (package
232 (name "bitlbee-discord")
233 (version "0.4.2")
234 (source
235 (origin
236 (method git-fetch)
237 (uri (git-reference
238 (url "https://github.com/sm00th/bitlbee-discord")
239 (commit version)))
240 (file-name (git-file-name name version))
241 (sha256
242 (base32 "02pigk2vbz0jdz11f96sygdvp1j762yjn62h124fkcsc070g7a2f"))))
243 (build-system gnu-build-system)
244 (arguments
245 `(#:phases
246 (modify-phases %standard-phases
247 (add-after 'unpack 'patch-autogen
248 (lambda _
249 (let ((sh (which "sh")))
250 (substitute* "autogen.sh" (("/bin/sh") sh))
251 (setenv "CONFIG_SHELL" sh))
252 #t))
253 (replace 'configure
254 (lambda* (#:key inputs outputs #:allow-other-keys)
255 (invoke "./configure"
256 (string-append "--with-plugindir="
257 (assoc-ref outputs "out")
258 "/lib/bitlbee/")))))))
259 (inputs `(("glib" ,glib)))
260 (native-inputs `(("pkg-config" ,pkg-config)
261 ("autoconf" ,autoconf)
262 ("automake" ,automake)
263 ("texinfo" ,texinfo)
264 ("libtool" ,libtool)
265 ("bitlbee" ,bitlbee) ; needs bitlbee headers
266 ("bash" ,bash)))
267 (synopsis "Discord plugin for Bitlbee")
268 (description "Bitlbee-discord is a plugin for Bitlbee witch provides
269 access to servers running the Discord protocol.")
270 (home-page "https://github.com/sm00th/bitlbee-discord/")
271 (license license:gpl2+)))
272
273 (define-public purple-mattermost
274 (package
275 (name "purple-mattermost")
276 (version "1.2")
277 (home-page "https://github.com/EionRobb/purple-mattermost")
278 (source (origin
279 (method git-fetch)
280 (uri (git-reference (url home-page)
281 (commit (string-append "v" version))))
282 (file-name (git-file-name name version))
283 (sha256
284 (base32
285 "0fm49iv58l09qpy8vkca3am642fxiwcrrh6ykimyc2mas210b5g2"))))
286 (build-system gnu-build-system)
287 (arguments
288 `(#:phases (modify-phases %standard-phases
289 (replace 'configure
290 (lambda* (#:key inputs outputs #:allow-other-keys)
291 ;; Adjust the makefile to install files in the right
292 ;; place.
293 (let ((out (assoc-ref outputs "out")))
294 (substitute* "Makefile"
295 (("MATTERMOST_DEST = .*")
296 (string-append "MATTERMOST_DEST = " out
297 "/lib/purple-2\n")) ;XXX: hardcoded
298 (("MATTERMOST_ICONS_DEST = .*")
299 (string-append "MATTERMOST_ICONS_DEST = "
300 out
301 "/share/pixmaps/pidgin/protocols\n")))
302 #t))))
303 #:make-flags (list "CC=gcc"
304 ,(string-append "PLUGIN_VERSION=" version))
305 #:tests? #f))
306 (inputs `(("glib" ,glib)
307 ("json-glib" ,json-glib)
308 ("discount" ,discount)
309 ("pidgin" ,pidgin)))
310 (native-inputs `(("pkg-config" ,pkg-config)))
311 (synopsis "Purple plug-in to access Mattermost instant messaging")
312 (description
313 "Purple-Mattermost is a plug-in for Purple, the instant messaging library
314 used by Pidgin and Bitlbee, among others, to access
315 @uref{https://mattermost.com/, Mattermost} servers.")
316 (license license:gpl3+)))
317
318 (define-public hexchat
319 (package
320 (name "hexchat")
321 (version "2.14.3")
322 (source (origin
323 (method url-fetch)
324 (uri (string-append "https://dl.hexchat.net/hexchat/hexchat-"
325 version ".tar.xz"))
326 (sha256
327 (base32
328 "10p829jm1r6kidkgf5lhqhyqc5mxdcq96q3zhadsckasvc9rs6lh"))))
329 (build-system meson-build-system)
330 (native-inputs `(("gettext" ,gettext-minimal)
331 ("glib:bin" ,glib "bin") ;need glib-genmarshal
332 ("perl" ,perl)
333 ("pkg-config" ,pkg-config)))
334 (inputs `(("dbus-glib" ,dbus-glib)
335 ("dbus" ,dbus)
336 ("enchant" ,enchant)
337 ("gtk" ,gtk+-2)
338 ("libcanberra" ,libcanberra)
339 ("libnotify" ,libnotify)
340 ("libproxy" ,libproxy)
341 ("openssl" ,openssl)
342
343 ;; Bindings for add-on scripts.
344 ("luajit" ,luajit)
345 ("perl-xml-parser" ,perl-xml-parser)
346 ("python-2" ,python-2)))
347 (arguments
348 `(#:phases
349 (modify-phases %standard-phases
350 (add-after 'unpack 'skip-desktop-database-updates
351 (lambda _
352 ;; The build scripts update icon and desktop file databases when
353 ;; DESTDIR is not set. We can't update these databases from
354 ;; within the build chroot, but we also don't set DESTDIR. So, we
355 ;; just skip this code.
356 (substitute* "meson_post_install.py"
357 (("if 'DESTDIR' not in os.environ:")
358 "if False:"))
359 #t)))))
360 (synopsis "Graphical IRC client")
361 (description
362 "HexChat lets you connect to multiple IRC networks at once. The main
363 window shows the list of currently connected networks and their channels, the
364 current conversation and the list of users. It uses colors to differentiate
365 between users and to highlight messages. It checks spelling using available
366 dictionaries. HexChat can be extended with multiple addons.")
367 (home-page "https://hexchat.net/")
368 (license license:gpl2+)))
369
370 (define-public ngircd
371 (package
372 (name "ngircd")
373 (version "26")
374 (source (origin
375 (method url-fetch)
376 (uri (string-append "https://arthur.barton.de/pub/ngircd/ngircd-"
377 version ".tar.xz"))
378 (sha256
379 (base32
380 "1ijmv18fa648y7apxb9vp4j9iq6fxq850kz5v36rysaq614cdp2n"))
381 (patches (search-patches "ngircd-handle-zombies.patch"))))
382 (build-system gnu-build-system)
383 ;; Needed for the test suite.
384 (native-inputs `(("procps" ,procps)
385 ("expect" ,expect)
386 ("inetutils" ,inetutils)
387 ("openssl" ,openssl)))
388 ;; XXX Add libident.
389 (inputs `(("zlib" ,zlib)
390 ("libwrap" ,tcp-wrappers)
391 ("gnutls" ,gnutls)
392 ,@(if (string-suffix? "-linux"
393 (or (%current-target-system)
394 (%current-system)))
395 `(("linux-pam" ,linux-pam))
396 '())))
397 (arguments
398 `(#:configure-flags
399 '("--with-gnutls" "--with-iconv" "--enable-ipv6" "--with-tcp-wrappers"
400 ,@(if (string-suffix? "-linux"
401 (or (%current-target-system)
402 (%current-system)))
403 '("--with-pam")
404 '()))
405 #:phases
406 (modify-phases %standard-phases
407 ;; Necessary for the test suite.
408 (add-after 'configure 'post-configure
409 (lambda _
410 (substitute* "src/ngircd/Makefile"
411 (("/bin/sh") (which "sh")))
412 ;; The default getpid.sh does a sloppy grep over 'ps -ax' output,
413 ;; which fails arbitrarily.
414 (with-output-to-file "src/testsuite/getpid.sh"
415 (lambda ()
416 (display
417 (string-append
418 "#!" (which "sh") "\n"
419 "ps -C \"$1\" -o pid=\n"))))
420 ;; Our variant of getpid.sh does not match interpreter names
421 ;; when the script's shebang is invoked directly as "./foo".
422 ;; Patch cases where the test suite relies on this.
423 (substitute* "src/testsuite/start-server.sh"
424 ;; It runs 'getpid.sh sh' to test if it works at all. Run it on
425 ;; 'make' instead.
426 (("getpid.sh sh") "getpid.sh make")))))))
427 (home-page "https://ngircd.barton.de/")
428 (synopsis "Lightweight Internet Relay Chat server for small networks")
429 (description
430 "ngIRCd is a lightweight @dfn{Internet Relay Chat} (IRC) server for small
431 or private networks. It is easy to configure, can cope with dynamic IP
432 addresses, and supports IPv6, SSL-protected connections, as well as PAM for
433 authentication.")
434 (license license:gpl2+)))
435
436 (define-public pidgin
437 (package
438 (name "pidgin")
439 (version "2.13.0")
440 (source
441 (origin
442 (method url-fetch)
443 (uri (string-append "mirror://sourceforge/pidgin/Pidgin/"
444 version "/pidgin-" version ".tar.bz2"))
445 (sha256
446 (base32 "13vdqj70315p9rzgnbxjp9c51mdzf1l4jg1kvnylc4bidw61air7"))
447 (patches (search-patches "pidgin-add-search-path.patch"
448 ;; Remove the snippet and bootstrapping
449 ;; native-inputs together with this patch.
450 "pidgin-libnm.patch"))
451 (modules '((guix build utils)))
452 (snippet
453 '(begin
454 ;; Remove stale generated file after applying pidgin-libnm.patch.
455 (delete-file "configure")
456 #t))))
457 (build-system glib-or-gtk-build-system)
458 (native-inputs
459 `(("pkg-config" ,pkg-config)
460 ("check" ,check)
461 ("intltool" ,intltool)
462 ("gconf" ,gconf)
463 ("python" ,python-2)
464 ("doxygen" ,doxygen)
465
466 ;; For bootstrapping after applying pidgin-libnm.patch.
467 ("autoconf" ,autoconf)
468 ("automake" ,automake)
469 ("libtool" ,libtool)))
470 (inputs
471 `(("gtk+" ,gtk+-2)
472 ("libgcrypt" ,libgcrypt)
473 ("gnutls" ,gnutls)
474 ("cyrus-sasl" ,cyrus-sasl)
475 ("dbus" ,dbus)
476 ("dbus-glib" ,dbus-glib)
477 ("python2-dbus" ,python2-dbus)
478 ("libidn" ,libidn)
479 ("libltdl" ,libltdl)
480 ("libxml2" ,libxml2)
481 ;; TODO: gstreamer: patches needed to support gstreamer-1.0 or later
482 ;; TODO: farstream
483 ;; TODO: meanwhile
484 ;; TODO: gtkspell
485 ;; TODO: libxephyr
486 ;; TODO: libgadu
487 ("libxslt" ,libxslt)
488 ("avahi" ,avahi)
489 ("ncurses" ,ncurses)
490 ("network-manager" ,network-manager)
491 ("sqlite" ,sqlite)
492 ("libice" ,libice)
493 ("libsm" ,libsm)
494 ("libxscrnsaver" ,libxscrnsaver)
495 ("startup-notification" ,startup-notification)))
496 (arguments
497 `(#:configure-flags
498 (list "--disable-gtkspell"
499 "--disable-tcl"
500 "--disable-meanwhile"
501 "--disable-vv" ; XXX remove when we have farstream and gstreamer
502 "--disable-gstreamer" ; XXX patches needed to support gstreamer-1.0
503 "--enable-cyrus-sasl"
504 (string-append "--with-ncurses-headers="
505 (assoc-ref %build-inputs "ncurses")
506 "/include"))))
507 (native-search-paths
508 (list (search-path-specification
509 (variable "PURPLE_PLUGIN_PATH")
510 (files (list (string-append "lib/purple-"
511 (version-major version))
512 "lib/pidgin")))))
513 (home-page "https://www.pidgin.im/")
514 (synopsis "Graphical multi-protocol instant messaging client")
515 (description
516 "Pidgin is a modular instant messaging client that supports many popular
517 chat protocols.")
518 (license
519 (list
520 license:gpl2+ ; Most of the code
521 license:lgpl2.1 ; GG protocol plugin (libpurple/protocols/gg/lib)
522 license:lgpl2.0+ ; OSCAR protocol plugin (libpurple/protocols/oscar)
523 ;; The following licenses cover the zephyr protocol plugin:
524 (license:non-copyleft
525 "file://libpurple/protocols/zephyr/mit-copyright.h"
526 "See libpurple/protocols/zephyr/mit-copyright.h in the distribution.")
527 (license:non-copyleft
528 "file://libpurple/protocols/zephyr/mit-sipb-copyright.h"
529 "See libpurple/protocols/zephyr/mit-sipb-copyright.h in the distribution.")))))
530
531 (define-public pidgin-otr
532 (package
533 (name "pidgin-otr")
534 (version "4.0.2")
535 (source (origin
536 (method url-fetch)
537 (uri (string-append "https://otr.cypherpunks.ca/"
538 name "-" version ".tar.gz"))
539 (sha256
540 (base32
541 "1i5s9rrgbyss9rszq6c6y53hwqyw1k86s40cpsfx5ccl9bprxdgl"))))
542 (build-system gnu-build-system)
543 (native-inputs
544 `(("pkg-config" ,pkg-config)
545 ("intltool" ,intltool)))
546 (inputs
547 `(("pidgin" ,pidgin)
548 ("libotr" ,libotr)
549 ("libgpg-error" ,libgpg-error)
550 ("libgcrypt" ,libgcrypt)
551 ("glib" ,glib)
552 ("gtk+" ,gtk+-2)))
553 (home-page "https://otr.cypherpunks.ca/")
554 (synopsis "Off-the-Record Messaging plugin for Pidgin")
555 (description
556 "Pidgin-OTR is a plugin that adds support for OTR to the Pidgin instant
557 messaging client. OTR (Off-the-Record) Messaging allows you to have private
558 conversations over instant messaging by providing: (1) Encryption: No one else
559 can read your instant messages. (2) Authentication: You are assured the
560 correspondent is who you think it is. (3) Deniability: The messages you send
561 do not have digital signatures that are checkable by a third party. Anyone
562 can forge messages after a conversation to make them look like they came from
563 you. However, during a conversation, your correspondent is assured the
564 messages he sees are authentic and unmodified. (4) Perfect forward secrecy:
565 If you lose control of your private keys, no previous conversation is
566 compromised.")
567 (license license:gpl2)))
568
569 (define-public znc
570 (package
571 (name "znc")
572 (version "1.8.1")
573 (source (origin
574 (method url-fetch)
575 (uri (string-append "https://znc.in/releases/archive/znc-"
576 version ".tar.gz"))
577 (sha256
578 (base32
579 "0hb1v167aa6gv5bcwz352l6b8gnd74ymjw92y4x882l099hzg59i"))))
580 (build-system cmake-build-system)
581 (arguments
582 `(#:configure-flags
583 (list "-DWANT_CYRUS=ON"
584 "-DWANT_I18N=ON"
585 "-DWANT_PERL=ON"
586 "-DWANT_PYTHON=ON")
587 #:phases
588 (modify-phases %standard-phases
589 (add-after 'unpack 'unpack-googletest
590 ;; Copy the googletest sources to where the CMake build expects them.
591 (lambda* (#:key inputs #:allow-other-keys)
592 (let ((source (assoc-ref inputs "googletest-source"))
593 (target "third_party/googletest"))
594 (mkdir-p target)
595 (copy-recursively source target)
596 #t))))))
597 (native-inputs
598 `(("boost" ,boost)
599 ("gettext" ,gettext-minimal)
600 ("googletest-source" ,(package-source googletest))
601 ("pkg-config" ,pkg-config)))
602 (inputs
603 `(("cyrus-sasl" ,cyrus-sasl)
604 ("icu4c" ,icu4c)
605 ("openssl" ,openssl)
606 ("perl" ,perl)
607 ("python" ,python)
608 ("zlib" ,zlib)))
609 (home-page "https://wiki.znc.in/ZNC")
610 (synopsis "IRC network bouncer")
611 (description "ZNC is an @dfn{IRC network bouncer} or @dfn{BNC}. It can
612 detach the client from the actual IRC server, and also from selected channels.
613 Multiple clients from different locations can connect to a single ZNC account
614 simultaneously and therefore appear under the same nickname on IRC.")
615 (license license:asl2.0)))
616
617 (define-public python-nbxmpp
618 (package
619 (name "python-nbxmpp")
620 (version "0.6.10")
621 (source
622 (origin
623 (method url-fetch)
624 (uri (pypi-uri "nbxmpp" version))
625 (sha256
626 (base32
627 "1vq89nhamciblyi5579bppnm4sb0zk5cg5hdipfpz174fxvl2wyd"))))
628 (build-system python-build-system)
629 (arguments
630 `(#:tests? #f)) ; no tests
631 (home-page "https://dev.gajim.org/gajim/python-nbxmpp")
632 (synopsis "Non-blocking Jabber/XMPP module")
633 (description
634 "The goal of this python library is to provide a way for Python
635 applications to use Jabber/XMPP networks in a non-blocking way. This library
636 was initially a fork of xmpppy, but uses non-blocking sockets.")
637 (license license:gpl3+)))
638
639 (define-public python2-nbxmpp
640 (package-with-python2 python-nbxmpp))
641
642 (define-public gajim
643 (package
644 (name "gajim")
645 (version "1.1.3")
646 (source (origin
647 (method url-fetch)
648 (uri (string-append "https://gajim.org/downloads/"
649 (version-major+minor version)
650 "/gajim-" version ".tar.bz2"))
651 (sha256
652 (base32
653 "0bzxwcpdd4ydh6d6mzpr0gxwhcb0x9ympk55fpvm1hcw9d28a716"))))
654 (build-system python-build-system)
655 (arguments
656 `(#:phases
657 (modify-phases %standard-phases
658 (add-after 'unpack 'add-plugin-dirs
659 (lambda _
660 (substitute* "gajim/common/configpaths.py"
661 (("_paths\\['PLUGINS_USER'\\]\\]")
662 "_paths['PLUGINS_USER']] + \
663 ([os.getenv('GAJIM_PLUGIN_PATH')] \
664 if os.getenv('GAJIM_PLUGIN_PATH') \
665 and Path(os.getenv('GAJIM_PLUGIN_PATH')).is_dir() \
666 else [])"))
667 #t))
668 (replace 'check
669 (lambda _
670 (invoke "python" "./setup.py" "test" "-s" "test.no_gui")))
671 (add-after 'install 'wrap-gi-typelib-path
672 (lambda* (#:key outputs #:allow-other-keys)
673 (let ((out (assoc-ref outputs "out")))
674 (for-each
675 (lambda (name)
676 (let ((file (string-append out "/bin/" name))
677 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
678 (wrap-program file
679 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))
680 ;; For translations
681 `("XDG_DATA_DIRS" ":" prefix
682 (,(string-append (assoc-ref outputs "out") "/share"))))))
683 '("gajim" "gajim-remote" "gajim-history-manager")))
684 #t))
685 (add-after 'install 'install-icons
686 (lambda* (#:key inputs outputs #:allow-other-keys)
687 (let* ((out (assoc-ref outputs "out"))
688 (adwaita (string-append
689 (assoc-ref inputs "adwaita-icon-theme")
690 "/share/icons/Adwaita"))
691 (hicolor (string-append
692 (assoc-ref inputs "hicolor-icon-theme")
693 "/share/icons/hicolor"))
694 (icons (string-append
695 out "/lib/python"
696 ,(version-major+minor (package-version python))
697 "/site-packages/gajim/data/icons")))
698 (with-directory-excursion icons
699 (symlink adwaita "Adwaita")
700 (copy-recursively hicolor "hicolor")))
701 #t))
702 (add-after 'install-icons 'wrap-gsettings-schema-dir
703 (lambda* (#:key inputs outputs #:allow-other-keys)
704 (wrap-program (string-append (assoc-ref outputs "out")
705 "/bin/gajim")
706 ;; For GtkFileChooserDialog.
707 `("GSETTINGS_SCHEMA_DIR" =
708 (,(string-append (assoc-ref inputs "gtk+")
709 "/share/glib-2.0/schemas"))))
710 #t)))))
711 (native-search-paths
712 (list (search-path-specification
713 (variable "GAJIM_PLUGIN_PATH")
714 (separator #f) ;single entry
715 (files '("share/gajim/plugins")))
716 ;; Gajim needs to use the propagated inputs of its plugins.
717 (search-path-specification
718 (variable "PYTHONPATH")
719 (files (list (string-append
720 "lib/python"
721
722 ;; FIXME: Cannot use this expression as it would
723 ;; introduce a circular dependency at the top level.
724 ;; (version-major+minor (package-version python))
725 "3.8"
726
727 "/site-packages"))))))
728 (native-inputs
729 `(("intltool" ,intltool)
730 ("python-docutils" ,python-docutils)
731 ("xorg-server" ,xorg-server-for-tests)))
732 (inputs
733 `(("adwaita-icon-theme" ,adwaita-icon-theme)
734 ("gnome-keyring" ,gnome-keyring)
735 ("gtk+" ,gtk+)
736 ("gtkspell3" ,gtkspell3)
737 ("hicolor-icon-theme" ,hicolor-icon-theme)
738 ("libsecret" ,libsecret)
739 ("python-cssutils" ,python-cssutils)
740 ("python-dbus" ,python-dbus)
741 ("python-gnupg" ,python-gnupg)
742 ("python-keyring" ,python-keyring)
743 ("python-nbxmpp" ,python-nbxmpp)
744 ("python-pillow" ,python-pillow)
745 ("python-precis-i18n" ,python-precis-i18n)
746 ("python-pycairo" ,python-pycairo)
747 ("python-pygobject" ,python-pygobject)
748 ("python-pyopenssl" ,python-pyopenssl)
749 ("python-qrcode" ,python-qrcode)))
750 (home-page "https://gajim.org/")
751 (synopsis "Jabber (XMPP) client")
752 (description "Gajim is a feature-rich and easy to use Jabber/XMPP client.
753 Among its features are: a tabbed chat window and single window modes; support
754 for group chat (with Multi-User Chat protocol), invitation, chat to group chat
755 transformation; audio and video conferences; file transfer; TLS, GPG and
756 end-to-end encryption support; XML console.")
757 (license license:gpl3)))
758
759 (define-public gajim-omemo
760 (package
761 (name "gajim-omemo")
762 (version "2.7.4")
763 (source (origin
764 (method url-fetch/zipbomb)
765 (uri (string-append
766 "https://ftp.gajim.org/plugins_releases/omemo_"
767 version ".zip"))
768 (sha256
769 (base32
770 "00zrj57n86c2m99n0swmmaws4f8zccbgbi8fknv6f9b1vif9jc8p"))))
771 (build-system trivial-build-system)
772 (arguments
773 `(#:modules ((guix build utils))
774 #:builder
775 (begin
776 (use-modules (guix build utils))
777 (let* ((out (assoc-ref %outputs "out"))
778 (share (in-vicinity out "share/gajim/plugins"))
779 (source (assoc-ref %build-inputs "source")))
780 (mkdir-p share)
781 (copy-recursively source share)
782 #t))))
783 (propagated-inputs
784 `(("python-axolotl" ,python-axolotl)))
785 (home-page
786 "https://dev.gajim.org/gajim/gajim-plugins/-/wikis/OmemoGajimPlugin")
787 (synopsis "Gajim OMEMO plugin")
788 (description
789 "This package provides the Gajim OMEMO plugin. OMEMO is an XMPP
790 Extension Protocol (XEP) for secure multi-client end-to-end encryption based
791 on Axolotl and PEP.")
792 (license license:gpl3+)))
793
794 (define-public dino
795 (package
796 (name "dino")
797 (version "0.1.0")
798 (source
799 (origin
800 (method url-fetch)
801 (uri (string-append "https://github.com/dino/dino/releases/download/v"
802 version "/dino-" version ".tar.gz"))
803 (sha256
804 (base32
805 "0dcq2jhpywgxrp9x1qqmrl2z50hazspqj547b9zz70apy3y4418h"))))
806 (build-system cmake-build-system)
807 (arguments
808 `(#:tests? #f
809 #:parallel-build? #f ; not supported
810 #:modules ((guix build cmake-build-system)
811 ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:)
812 (guix build utils))
813 #:imported-modules (,@%gnu-build-system-modules
814 (guix build cmake-build-system)
815 (guix build glib-or-gtk-build-system))
816 #:phases
817 (modify-phases %standard-phases
818 (add-after 'install 'glib-or-gtk-wrap
819 (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap)))))
820 (inputs
821 `(("libgee" ,libgee)
822 ("libsignal-protocol-c" ,libsignal-protocol-c)
823 ("libgcrypt" ,libgcrypt)
824 ("libsoup" ,libsoup)
825 ("qrencode" ,qrencode)
826 ("sqlite" ,sqlite)
827 ("gpgme" ,gpgme)
828 ("gtk+" ,gtk+)
829 ("glib-networking" ,glib-networking)
830 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)))
831 (native-inputs
832 `(("pkg-config" ,pkg-config)
833 ("glib" ,glib "bin")
834 ("vala" ,vala)
835 ("gettext" ,gettext-minimal)))
836 (home-page "https://dino.im")
837 (synopsis "Graphical Jabber (XMPP) client")
838 (description "Dino is a Jabber (XMPP) client which aims to fit well into
839 a graphical desktop environment like GNOME.")
840 (license license:gpl3+)))
841
842 (define-public prosody
843 (package
844 (name "prosody")
845 (version "0.11.3")
846 (source (origin
847 (method url-fetch)
848 (uri (string-append "https://prosody.im/downloads/source/"
849 "prosody-" version ".tar.gz"))
850 (sha256
851 (base32
852 "11xz4milv2962qf75vrdwsvd8sy2332nf69202rmvz5989pvvnng"))))
853 (build-system gnu-build-system)
854 (arguments
855 `(#:tests? #f ;tests require "busted"
856 #:configure-flags (list "--no-example-certs")
857 #:modules ((ice-9 match)
858 (srfi srfi-1)
859 (guix build gnu-build-system)
860 (guix build utils))
861 #:phases
862 (modify-phases %standard-phases
863 (add-after 'unpack 'fix-configure-script
864 (lambda _
865 ;; The configure script aborts when it encounters unexpected
866 ;; arguments. Make it more tolerant.
867 (substitute* "configure"
868 (("exit 1") ""))
869 #t))
870 (add-after 'unpack 'fix-makefile
871 (lambda _
872 (substitute* "GNUmakefile"
873 ;; prosodyctl needs to read the configuration file.
874 (("^INSTALLEDCONFIG =.*") "INSTALLEDCONFIG = /etc/prosody\n")
875 ;; prosodyctl needs a place to put auto-generated certificates.
876 (("^INSTALLEDDATA =.*") "INSTALLEDDATA = /var/lib/prosody\n"))
877 #t))
878 (add-after 'install 'wrap-programs
879 (lambda* (#:key inputs outputs #:allow-other-keys)
880 ;; Make sure all executables in "bin" find the required Lua
881 ;; modules at runtime.
882 (let* ((out (assoc-ref outputs "out"))
883 (bin (string-append out "/bin/"))
884 (deps (delete #f (map (match-lambda
885 ((label . directory)
886 (if (string-prefix? "lua" label)
887 directory #f)))
888 inputs)))
889 (lua-path (string-join
890 (map (lambda (path)
891 (string-append
892 path "/share/lua/5.2/?.lua;"
893 path "/share/lua/5.2/?/?.lua"))
894 (cons out deps))
895 ";"))
896 (lua-cpath (string-join
897 (map (lambda (path)
898 (string-append
899 path "/lib/lua/5.2/?.so;"
900 path "/lib/lua/5.2/?/?.so"))
901 (cons out deps))
902 ";"))
903 (openssl (assoc-ref inputs "openssl"))
904 (coreutils (assoc-ref inputs "coreutils"))
905 (path (map (lambda (dir)
906 (string-append dir "/bin"))
907 (list openssl coreutils))))
908 (for-each (lambda (file)
909 (wrap-program file
910 `("LUA_PATH" ";" = (,lua-path))
911 `("LUA_CPATH" ";" = (,lua-cpath))
912 `("PATH" ":" prefix ,path)))
913 (find-files bin ".*"))
914 #t))))))
915 (inputs
916 `(("libidn" ,libidn)
917 ("openssl" ,openssl)
918 ("lua" ,lua-5.2)
919 ("lua5.2-bitop" ,lua5.2-bitop)
920 ("lua5.2-expat" ,lua5.2-expat)
921 ("lua5.2-socket" ,lua5.2-socket)
922 ("lua5.2-filesystem" ,lua5.2-filesystem)
923 ("lua5.2-sec" ,lua5.2-sec)))
924 (home-page "https://prosody.im/")
925 (synopsis "Jabber (XMPP) server")
926 (description "Prosody is a modern XMPP communication server. It aims to
927 be easy to set up and configure, and efficient with system resources.
928 Additionally, for developers it aims to be easy to extend and give a flexible
929 system on which to rapidly develop added functionality, or prototype new
930 protocols.")
931 (license license:x11)))
932
933 (define-public prosody-http-upload
934 (let ((changeset "765735bb590b")
935 (revision "1"))
936 (package
937 (name "prosody-http-upload")
938 (version (string-append "0-" revision "." (string-take changeset 7)))
939 (source (origin
940 (method hg-fetch)
941 (uri (hg-reference
942 (url "https://hg.prosody.im/prosody-modules/")
943 (changeset changeset)))
944 (file-name (string-append name "-" version "-checkout"))
945 (sha256
946 (base32
947 "142wrcism70nf8ffahhd961cqg2pi1h7ic8adfs3zwh0j3pnf41f"))))
948 (build-system trivial-build-system)
949 (arguments
950 '(#:modules ((guix build utils))
951 #:builder
952 (begin
953 (use-modules (guix build utils))
954 (let ((out (assoc-ref %outputs "out"))
955 (source (assoc-ref %build-inputs "source")))
956 (with-directory-excursion (in-vicinity source "mod_http_upload")
957 (install-file "mod_http_upload.lua" out))
958 #t))))
959 (home-page "https://modules.prosody.im/mod_http_upload.html")
960 (synopsis "XEP-0363: Allow clients to upload files over HTTP")
961 (description "This module implements XEP-0363: it allows clients to
962 upload files over HTTP.")
963 (license (package-license prosody)))))
964
965 (define-public prosody-smacks
966 (let ((changeset "67f1d1f22625")
967 (revision "1"))
968 (package
969 (name "prosody-smacks")
970 (version (string-append "0-" revision "." (string-take changeset 7)))
971 (source (origin
972 (method hg-fetch)
973 (uri (hg-reference
974 (url "https://hg.prosody.im/prosody-modules/")
975 (changeset changeset)))
976 (file-name (string-append name "-" version "-checkout"))
977 (sha256
978 (base32
979 "020ngpax30fgarah98yvlj0ni8rcdwq60if03a9hqdw8mic0nxxs"))))
980 (build-system trivial-build-system)
981 (arguments
982 '(#:modules ((guix build utils))
983 #:builder
984 (begin
985 (use-modules (guix build utils))
986 (let ((out (assoc-ref %outputs "out"))
987 (source (assoc-ref %build-inputs "source")))
988 (with-directory-excursion (in-vicinity source "mod_smacks")
989 (install-file "mod_smacks.lua" out))
990 #t))))
991 (home-page "https://modules.prosody.im/mod_smacks.html")
992 (synopsis "XEP-0198: Reliability and fast reconnects for XMPP")
993 (description "This module implements XEP-0198: when supported by both
994 the client and server, it can allow clients to resume a disconnected session,
995 and prevent message loss.")
996 (license (package-license prosody)))))
997
998 (define-public libtoxcore
999 (let ((revision "2")
1000 (commit "bf69b54f64003d160d759068f4816b2d9b2e1e21"))
1001 (package
1002 (name "libtoxcore")
1003 (version (string-append "0.0.0" "-"
1004 revision "."(string-take commit 7)))
1005 (source (origin
1006 (method git-fetch)
1007 (uri (git-reference
1008 (url "https://github.com/irungentoo/toxcore")
1009 (commit commit)))
1010 (file-name (string-append name "-" version "-checkout"))
1011 (sha256
1012 (base32
1013 "11lqra4yd7v293cp286ynff5lqz1pprzg8vn3wq6vryj08g88zqb"))))
1014 (build-system gnu-build-system)
1015 (arguments `(#:tests? #f)) ; FIXME: tests hang, some fail.
1016 (native-inputs
1017 `(("autoconf" ,autoconf)
1018 ("automake" ,automake)
1019 ("libtool" ,libtool)
1020 ("check" ,check)
1021 ("pkg-config" ,pkg-config)))
1022 (inputs
1023 `(("libsodium" ,libsodium)
1024 ("opus" ,opus)
1025 ("libvpx" ,libvpx)))
1026 (synopsis "Library for the Tox encrypted messenger protocol")
1027 (description
1028 "C library implementation of the Tox encrypted messenger protocol.")
1029 (license license:gpl3+)
1030 (home-page "https://tox.chat"))))
1031
1032 ;; Some tox clients move to c-toxcore, which seems to be where all the
1033 ;; recent development happens. It is run by the same developers as toxcore,
1034 ;; forked into a group namespace.
1035 (define-public c-toxcore
1036 (package
1037 (name "c-toxcore")
1038 (version "0.2.12")
1039 (source
1040 (origin
1041 (method git-fetch)
1042 (uri (git-reference
1043 (url "https://github.com/TokTok/c-toxcore")
1044 (commit (string-append "v" version))))
1045 (file-name (git-file-name name version))
1046 (sha256
1047 (base32
1048 "0a6sqpm00d2rn0nviqfz4gh9ck1wzci6rxgmqmcyryl5ca19ffvp"))))
1049 (arguments
1050 `(#:tests? #f)) ; FIXME: Testsuite seems to stay stuck on test 3. Disable
1051 ; for now.
1052 (build-system cmake-build-system)
1053 (native-inputs
1054 `(("pkg-config" ,pkg-config)))
1055 (propagated-inputs
1056 `(("libsodium" ,libsodium)
1057 ("opus" ,opus)
1058 ("libvpx" ,libvpx)))
1059 (home-page "https://tox.chat")
1060 (synopsis "Library for the Tox encrypted messenger protocol")
1061 (description
1062 "Official fork of the C library implementation of the Tox encrypted
1063 messenger protocol.")
1064 (license license:gpl3+)))
1065
1066 (define-public utox
1067 (package
1068 (name "utox")
1069 (version "0.17.1")
1070 (source
1071 (origin
1072 (method git-fetch)
1073 (uri (git-reference
1074 (url "https://github.com/uTox/uTox")
1075 (commit (string-append "v" version))
1076 (recursive? #t))) ;; Needed for 'minini' git submodule.
1077 (file-name (string-append name "-" version "-checkout"))
1078 (sha256
1079 (base32
1080 "17kwqw24iqljp2icih9k6ikx12gzr8zzqr8y5h35bg8m5s8pasq5"))))
1081 (build-system cmake-build-system)
1082 (arguments
1083 `(#:configure-flags '("-DENABLE_TESTS=on")
1084 #:phases
1085 (modify-phases %standard-phases
1086 (add-before 'build 'patch-absolute-filename-libgtk-3
1087 (lambda* (#:key inputs outputs #:allow-other-keys)
1088 (substitute* "../source/src/xlib/gtk.c"
1089 (("libgtk-3.so")
1090 (string-append (assoc-ref inputs "gtk+")
1091 "/lib/libgtk-3.so")))))
1092 (add-after 'install 'wrap-program
1093 (lambda* (#:key inputs outputs #:allow-other-keys)
1094 (wrap-program (string-append (assoc-ref outputs "out")
1095 "/bin/utox")
1096 ;; For GtkFileChooserDialog.
1097 `("GSETTINGS_SCHEMA_DIR" =
1098 (,(string-append (assoc-ref inputs "gtk+")
1099 "/share/glib-2.0/schemas")))))))))
1100 (inputs
1101 `(("dbus" ,dbus)
1102 ("filteraudio" ,filteraudio)
1103 ("fontconfig" ,fontconfig)
1104 ("freetype" ,freetype)
1105 ("libsodium" ,libsodium)
1106 ("c-toxcore" ,c-toxcore)
1107 ("gtk+" ,gtk+)
1108 ("libvpx" ,libvpx)
1109 ("libx11" ,libx11)
1110 ("libxext" ,libxext)
1111 ("libxrender" ,libxrender)
1112 ("openal" ,openal)
1113 ("v4l-utils" ,v4l-utils)))
1114 (native-inputs
1115 `(("check" ,check)
1116 ("pkg-config" ,pkg-config)))
1117 (synopsis "Lightweight Tox client")
1118 (description
1119 "Utox is a lightweight Tox client. Tox is a distributed and secure
1120 instant messenger with audio and video chat capabilities.")
1121 (home-page "http://utox.org/")
1122 (license license:gpl3)))
1123
1124 (define-public qtox
1125 (package
1126 (name "qtox")
1127 (version "1.17.2")
1128 (source (origin
1129 (method url-fetch/tarbomb)
1130 (uri (string-append "https://github.com/qTox/qTox/releases"
1131 "/download/v" version
1132 "/v" version ".tar.gz"))
1133 (sha256
1134 (base32
1135 "0fmr3a0apil3rl32247qv2pqslp3knpbj5vhprdq0ixsvifrlhmh"))
1136 (file-name (string-append name "-" version ".tar.gz"))))
1137 (build-system cmake-build-system)
1138 (arguments
1139 '(#:phases
1140 (modify-phases %standard-phases
1141 (add-after 'unpack 'fix-reproducibility-issues
1142 (lambda _
1143 (substitute* "src/main.cpp"
1144 (("__DATE__") "\"\"")
1145 (("__TIME__") "\"\"")
1146 (("TIMESTAMP") "\"\""))
1147 #t))
1148 (add-after 'unpack 'disable-network-tests
1149 (lambda _
1150 ;; These tests require network access.
1151 (substitute* "cmake/Testing.cmake"
1152 (("auto_test\\(core core\\)") "# auto_test(core core)")
1153 (("auto_test\\(net bsu\\)") "# auto_test(net bsu)"))
1154 #t))
1155 ;; Ensure that icons are found at runtime.
1156 (add-after 'install 'wrap-executable
1157 (lambda* (#:key inputs outputs #:allow-other-keys)
1158 (let ((out (assoc-ref outputs "out")))
1159 (wrap-program (string-append out "/bin/qtox")
1160 `("QT_PLUGIN_PATH" prefix
1161 ,(list (string-append (assoc-ref inputs "qtsvg")
1162 "/lib/qt5/plugins/"))))))))))
1163 (inputs
1164 `(("ffmpeg" ,ffmpeg)
1165 ("filteraudio" ,filteraudio)
1166 ("glib" ,glib)
1167 ("gtk+" ,gtk+-2)
1168 ("libsodium" ,libsodium)
1169 ("c-toxcore" ,c-toxcore)
1170 ("libvpx" ,libvpx)
1171 ("libxscrnsaver" ,libxscrnsaver)
1172 ("libx11" ,libx11)
1173 ("libexif" ,libexif)
1174 ("sqlite" ,sqlite)
1175 ("openal" ,openal)
1176 ("qrencode" ,qrencode)
1177 ("qtbase" ,qtbase)
1178 ("qtsvg" ,qtsvg)
1179 ("sqlcipher" ,sqlcipher)))
1180 (native-inputs
1181 `(("pkg-config" ,pkg-config)
1182 ("qmake" ,qttools)))
1183 (home-page "https://qtox.github.io/")
1184 (synopsis "Tox chat client using Qt")
1185 (description "qTox is a Tox client that follows the Tox design
1186 guidelines. It provides an easy to use application that allows you to
1187 connect with friends and family without anyone else listening in.")
1188 (license license:gpl3+)))
1189
1190 (define-public pybitmessage
1191 (package
1192 (name "pybitmessage")
1193 (version "0.6.3.2")
1194 (source
1195 (origin
1196 (method git-fetch)
1197 (uri (git-reference
1198 (url "https://github.com/Bitmessage/PyBitmessage")
1199 (commit version)))
1200 (file-name (string-append name "-" version "-checkout"))
1201 (sha256
1202 (base32
1203 "1lmhbpwsqh1v93krlqqhafw2pc3y0qp8zby186yllbph6s8kdp35"))))
1204 (propagated-inputs
1205 ;; TODO:
1206 ;; Package "pyopencl", required in addition to numpy for OpenCL support.
1207 ;; Package "gst123", required in addition to alsa-utils and
1208 ;; mpg123 for sound support.
1209 `(("python2-msgpack" ,python2-msgpack)
1210 ("python2-pythondialog" ,python2-pythondialog)
1211 ("python2-pyqt-4" ,python2-pyqt-4)
1212 ("python2-sip" ,python2-sip)
1213 ("python2-pysqlite" ,python2-pysqlite)
1214 ("python2-pyopenssl" ,python2-pyopenssl)))
1215 (native-inputs
1216 `(("openssl" ,openssl)))
1217 (build-system python-build-system)
1218 (arguments
1219 `(#:modules ((guix build python-build-system)
1220 (guix build utils))
1221 #:tests? #f ;no test target
1222 #:python ,python-2
1223 #:phases
1224 (modify-phases %standard-phases
1225 (add-after 'unpack 'fix-unmatched-python-shebangs
1226 (lambda* (#:key inputs #:allow-other-keys)
1227 (substitute* "src/bitmessagemain.py"
1228 (("#!/usr/bin/env python2.7")
1229 (string-append "#!" (which "python"))))
1230 (substitute* "src/bitmessagecli.py"
1231 (("#!/usr/bin/env python2.7.x")
1232 (string-append "#!" (which "python"))))
1233 #t))
1234 (add-after 'unpack 'fix-depends
1235 (lambda* (#:key inputs #:allow-other-keys)
1236 (substitute* "src/depends.py"
1237 (("libcrypto.so")
1238 (string-append (assoc-ref inputs "openssl")
1239 "/lib/libcrypto.so")))
1240 #t))
1241 (add-after 'unpack 'fix-local-files-in-paths
1242 (lambda* (#:key outputs #:allow-other-keys)
1243 (substitute* "src/proofofwork.py"
1244 (("bitmsghash.so")
1245 (string-append (assoc-ref outputs "out")
1246 "/lib/bitmsghash.so")))
1247 #t))
1248 (add-after 'unpack 'fix-pyelliptic
1249 (lambda* (#:key inputs #:allow-other-keys)
1250 (substitute* "src/pyelliptic/openssl.py"
1251 (("libcrypto.so")
1252 (string-append (assoc-ref inputs "openssl")
1253 "/lib/libcrypto.so"))
1254 (("libssl.so")
1255 (string-append (assoc-ref inputs "openssl")
1256 "/lib/libssl.so")))
1257 #t))
1258 (add-after 'unpack 'noninteractive-build
1259 ;; This applies upstream commit 4c597d3f7cf9f83a763472aa165a1a4292019f20
1260 (lambda _
1261 (substitute* "setup.py"
1262 (("except NameError")
1263 "except EOFError, NameError"))
1264 #t))
1265 ;; XXX: python setup.py does not build and install bitmsghash,
1266 ;; without it PyBitmessage tries to compile it at first run
1267 ;; in the store, which due to obvious reasons fails. Do it
1268 ;; and place it in /lib.
1269 (add-after 'unpack 'build-and-install-bitmsghash
1270 (lambda* (#:key outputs #:allow-other-keys)
1271 (with-directory-excursion "src/bitmsghash"
1272 (system* "make")
1273 (install-file "bitmsghash.so"
1274 (string-append (assoc-ref outputs "out") "/lib")))
1275 #t)))))
1276 (license license:expat)
1277 (description
1278 "Distributed and trustless peer-to-peer communications protocol
1279 for sending encrypted messages to one person or many subscribers.")
1280 (synopsis "Distributed peer-to-peer communication")
1281 (home-page "https://bitmessage.org/")))
1282
1283 (define-public ytalk
1284 (package
1285 (name "ytalk")
1286 (version "3.3.0")
1287 (source
1288 (origin
1289 (method url-fetch)
1290 (uri (string-append "ftp://ftp.ourproject.org/pub/ytalk/ytalk-"
1291 version ".tar.gz"))
1292 (sha256
1293 (base32
1294 "1d3jhnj8rgzxyxjwfa22vh45qwzjvxw1qh8fz6b7nfkj3zvk9jvf"))))
1295 (build-system gnu-build-system)
1296 (inputs
1297 `(("ncurses" ,ncurses)))
1298 (home-page "https://ytalk.ourproject.org")
1299 (synopsis "Multi-user chat program")
1300 (description "Ytalk is a replacement for the BSD talk program. Its main
1301 advantage is the ability to communicate with any arbitrary number of users at
1302 once. It supports both talk protocols (\"talk\" and \"ntalk\") and can communicate
1303 with several different talk daemons at the same time.")
1304 (license license:gpl2+)))
1305
1306 (define-public gloox
1307 (package
1308 (name "gloox")
1309 (version "1.0.23")
1310 (source
1311 (origin
1312 (method url-fetch)
1313 (uri (string-append "https://camaya.net/download/gloox-"
1314 version ".tar.bz2"))
1315 (sha256
1316 (base32 "12jz8glg9zmyk0iyv1ywf5i0hq93dfq8lvn6lyjgy8730w66mjwp"))))
1317 (build-system gnu-build-system)
1318 (inputs
1319 `(("libidn" ,libidn)
1320 ("gnutls" ,gnutls)
1321 ("zlib" ,zlib)))
1322 (native-inputs
1323 `(("pkg-config" ,pkg-config)))
1324 (synopsis "Portable high-level Jabber/XMPP library for C++")
1325 (description
1326 "gloox is a full-featured Jabber/XMPP client library,
1327 written in ANSI C++. It makes writing spec-compliant clients easy
1328 and allows for hassle-free integration of Jabber/XMPP functionality
1329 into existing applications.")
1330 (home-page "https://camaya.net/gloox")
1331 (license license:gpl3)))
1332
1333 (define-public perl-net-psyc
1334 (package
1335 (name "perl-net-psyc")
1336 (version "1.3")
1337 (source
1338 (origin
1339 (method url-fetch)
1340 (uri (string-append "https://perl.psyc.eu/"
1341 "perlpsyc-" version ".zip"))
1342 (file-name (string-append name "-" version ".zip"))
1343 (sha256
1344 (base32
1345 "0vsjclglkwgbyd9m5ad642fyysxw2x725nhq4r2m9pvqaq6s5yf2"))))
1346 (build-system perl-build-system)
1347 (native-inputs
1348 `(("unzip" ,unzip)))
1349 (inputs
1350 `(("perl-curses" ,perl-curses)
1351 ("perl-io-socket-ssl" ,perl-io-socket-ssl)))
1352 (arguments
1353 `(#:phases
1354 (modify-phases %standard-phases
1355 (delete 'configure) ; No configure script
1356 ;; There is a Makefile, but it does not install everything
1357 ;; (leaves out psycion) and says
1358 ;; "# Just to give you a rough idea". XXX: Fix it upstream.
1359 (replace 'build
1360 (lambda _ (invoke "make" "manuals")))
1361 (replace 'install
1362 (lambda* (#:key outputs #:allow-other-keys)
1363 (let* ((out (assoc-ref outputs "out"))
1364 (doc (string-append out "/share/doc/perl-net-psyc"))
1365 (man1 (string-append out "/share/man/man1"))
1366 (man3 (string-append out "/share/man/man3"))
1367 (bin (string-append out "/bin"))
1368 (libpsyc (string-append out "/lib/psyc/ion"))
1369 (libperl (string-append out "/lib/perl5/site_perl/"
1370 ,(package-version perl))))
1371
1372 (copy-recursively "lib/perl5" libperl)
1373 (copy-recursively "lib/psycion" libpsyc)
1374 (copy-recursively "bin" bin)
1375 (install-file "cgi/psycpager" (string-append doc "/cgi"))
1376 (copy-recursively "contrib" (string-append doc "/contrib"))
1377 (copy-recursively "hooks" (string-append doc "/hooks"))
1378 (copy-recursively "sdj" (string-append doc "/sdj"))
1379 (install-file "README.txt" doc)
1380 (install-file "TODO.txt" doc)
1381 (copy-recursively "share/man/man1" man1)
1382 (copy-recursively "share/man/man3" man3)
1383 #t)))
1384 (add-after 'install 'wrap-programs
1385 (lambda* (#:key outputs #:allow-other-keys)
1386 ;; Make sure all executables in "bin" find the Perl modules
1387 ;; provided by this package at runtime.
1388 (let* ((out (assoc-ref outputs "out"))
1389 (bin (string-append out "/bin/"))
1390 (path (getenv "PERL5LIB")))
1391 (for-each (lambda (file)
1392 (wrap-program file
1393 `("PERL5LIB" ":" prefix (,path))))
1394 (find-files bin "\\.*$"))
1395 #t))))))
1396 (description
1397 "@code{Net::PSYC} with support for TCP, UDP, Event.pm, @code{IO::Select} and
1398 Gtk2 event loops. This package includes 12 applications and additional scripts:
1399 psycion (a @uref{https://about.psyc.eu,PSYC} chat client), remotor (a control console
1400 for @uref{https://torproject.org,tor} router) and many more.")
1401 (synopsis "Perl implementation of PSYC protocol")
1402 (home-page "https://perl.psyc.eu")
1403 (license (list license:gpl2
1404 license:perl-license
1405 ;; contrib/irssi-psyc.pl:
1406 license:public-domain
1407 ;; bin/psycplay states AGPL with no version:
1408 license:agpl3+))))
1409
1410 (define-public libpsyc
1411 (package
1412 (name "libpsyc")
1413 (version "20160913")
1414 (source (origin
1415 (method url-fetch)
1416 (uri (string-append "http://www.psyced.org/files/"
1417 name "-" version ".tar.xz"))
1418 (sha256
1419 (base32
1420 "14q89fxap05ajkfn20rnhc6b1h4i3i2adyr7y6hs5zqwb2lcmc1p"))))
1421 (build-system gnu-build-system)
1422 (native-inputs
1423 `(("perl" ,perl)
1424 ("netcat" ,netcat)
1425 ("procps" ,procps)))
1426 (arguments
1427 `(#:make-flags
1428 (list "CC=gcc"
1429 (string-append "PREFIX=" (assoc-ref %outputs "out")))
1430 #:phases
1431 (modify-phases %standard-phases
1432 ;; The rust bindings are the only ones in use, the lpc bindings
1433 ;; are in psyclpc. The other bindings are not used by anything,
1434 ;; the chances are high that the bindings do not even work,
1435 ;; therefore we do not include them.
1436 ;; TODO: Get a cargo build system in Guix.
1437 (delete 'configure)))) ; no configure script
1438 (home-page "https://about.psyc.eu/libpsyc")
1439 (description
1440 "@code{libpsyc} is a PSYC library in C which implements
1441 core aspects of PSYC, useful for all kinds of clients and servers
1442 including psyced.")
1443 (synopsis "PSYC library in C")
1444 (license license:agpl3+)))
1445
1446 ;; This commit removes the historic bundled pcre and makes psyclpc reproducible.
1447 (define-public psyclpc
1448 (let* ((commit "61cf9aa81297085e5c40170fd01221c752f8deba")
1449 (revision "2"))
1450 (package
1451 (name "psyclpc")
1452 (version (string-append "20160821-" revision "." (string-take commit 7)))
1453 (source (origin
1454 (method git-fetch)
1455 (uri (git-reference
1456 (url "git://git.psyced.org/git/psyclpc")
1457 (commit commit)))
1458 (file-name (string-append name "-" version "-checkout"))
1459 (sha256
1460 (base32
1461 "1viwqymbhn3cwvx0zl58rlzl5gw47zxn0ldg2nbi55ghm5zxl1z5"))))
1462 (build-system gnu-build-system)
1463 (arguments
1464 `(#:tests? #f ; There are no tests/checks.
1465 #:configure-flags
1466 ;; If you have questions about this part, look at
1467 ;; "src/settings/psyced" and the ebuild.
1468 (list
1469 "--enable-use-tls=yes"
1470 "--enable-use-mccp" ; Mud Client Compression Protocol, leave this enabled.
1471 (string-append "--prefix="
1472 (assoc-ref %outputs "out"))
1473 ;; src/Makefile: Set MUD_LIB to the directory which contains
1474 ;; the mud data. defaults to MUD_LIB = @libdir@
1475 (string-append "--libdir="
1476 (assoc-ref %outputs "out")
1477 "/opt/psyced/world")
1478 (string-append "--bindir="
1479 (assoc-ref %outputs "out")
1480 "/opt/psyced/bin")
1481 ;; src/Makefile: Set ERQ_DIR to directory which contains the
1482 ;; stuff which ERQ can execute (hopefully) savely. Was formerly
1483 ;; defined in config.h. defaults to ERQ_DIR= @libexecdir@
1484 (string-append "--libexecdir="
1485 (assoc-ref %outputs "out")
1486 "/opt/psyced/run"))
1487 #:phases
1488 (modify-phases %standard-phases
1489 (add-before 'configure 'chdir-to-src
1490 ;; We need to pass this as env variables
1491 ;; and manually change the directory.
1492 (lambda _
1493 (chdir "src")
1494 (setenv "CONFIG_SHELL" (which "sh"))
1495 (setenv "SHELL" (which "sh"))
1496 #t)))
1497 #:make-flags (list "install-all")))
1498 (inputs
1499 `(("zlib" ,zlib)
1500 ("openssl" ,openssl-1.0)
1501 ("pcre" ,pcre)))
1502 (native-inputs
1503 `(("pkg-config" ,pkg-config)
1504 ("bison" ,bison)
1505 ("gettext" ,gettext-minimal)
1506 ("help2man" ,help2man)
1507 ("autoconf" ,autoconf)
1508 ("automake" ,automake)))
1509 (home-page "http://lpc.psyc.eu/")
1510 (synopsis "psycLPC is a multi-user network server programming language")
1511 (description
1512 "LPC is a bytecode language, invented to specifically implement
1513 multi user virtual environments on the internet. This technology is used for
1514 MUDs and also the psyced implementation of the Protocol for SYnchronous
1515 Conferencing (PSYC). psycLPC is a fork of LDMud with some new features and
1516 many bug fixes.")
1517 (license license:gpl2))))
1518
1519 (define-public loudmouth
1520 (package
1521 (name "loudmouth")
1522 (version "1.5.3")
1523 (source
1524 (origin
1525 (method url-fetch)
1526 (uri (string-append "https://mcabber.com/files/loudmouth/"
1527 name "-" version ".tar.bz2"))
1528 (sha256
1529 (base32
1530 "0b6kd5gpndl9nzis3n6hcl0ldz74bnbiypqgqa1vgb0vrcar8cjl"))))
1531 (build-system gnu-build-system)
1532 (inputs
1533 `(("glib" ,glib)
1534 ("gnutls" ,gnutls)
1535 ("libidn" ,libidn)))
1536 (native-inputs
1537 `(("pkg-config" ,pkg-config)
1538 ("check" ,check)
1539 ("glib" ,glib "bin") ; gtester
1540 ("gtk-doc" ,gtk-doc)))
1541 (home-page "https://mcabber.com/")
1542 (description
1543 "Loudmouth is a lightweight and easy-to-use C library for programming
1544 with the XMPP (formerly known as Jabber) protocol. It is designed to be
1545 easy to get started with and yet extensible to let you do anything the XMPP
1546 protocol allows.")
1547 (synopsis "Asynchronous XMPP library")
1548 ;; The files have LGPL2.0+ headers, but COPYING specifies LGPL2.1.
1549 (license license:lgpl2.0+)))
1550
1551 (define-public mcabber
1552 (package
1553 (name "mcabber")
1554 (version "1.1.0")
1555 (source
1556 (origin
1557 (method url-fetch)
1558 (uri (string-append "https://mcabber.com/files/"
1559 name "-" version ".tar.bz2"))
1560 (sha256
1561 (base32
1562 "1ggh865p1rf10ffsnf4g6qv9i8bls36dxdb1nzs5r9vdqci2rz04"))))
1563 (build-system gnu-build-system)
1564 (arguments
1565 '(#:configure-flags (list "--enable-otr"
1566 "--enable-aspell")))
1567 (inputs
1568 `(("gpgme" ,gpgme)
1569 ("libotr" ,libotr)
1570 ("aspell" ,aspell)
1571 ("libidn" ,libidn)
1572 ("glib" ,glib)
1573 ("ncurses" ,ncurses)
1574 ("loudmouth" ,loudmouth)))
1575 (native-inputs
1576 `(("pkg-config" ,pkg-config)))
1577 (home-page "https://mcabber.com")
1578 (description
1579 "Mcabber is a small XMPP (Jabber) console client, which includes features
1580 such as SASL and TLS support, @dfn{Multi-User Chat} (MUC) support, logging,
1581 command-completion, OpenPGP encryption, @dfn{Off-the-Record Messaging} (OTR)
1582 support, and more.")
1583 (synopsis "Small XMPP console client")
1584 (license license:gpl2+)))
1585
1586 (define-public freetalk
1587 (package
1588 (name "freetalk")
1589 (version "4.1")
1590 (source (origin
1591 (method url-fetch)
1592 (uri (string-append "mirror://gnu/freetalk/freetalk-"
1593 version ".tar.gz"))
1594 (sha256
1595 (base32
1596 "1rmrn7a1bb7vm26yaklrvx008a9qhwc32s57dwrlf40lv9gffwny"))))
1597 (build-system gnu-build-system)
1598 (arguments
1599 `(#:phases
1600 (modify-phases %standard-phases
1601 ;; For 'system' commands in Scheme code.
1602 (add-after 'install 'wrap-program
1603 (lambda* (#:key inputs outputs #:allow-other-keys)
1604 (let* ((out (assoc-ref outputs "out"))
1605 (bash (assoc-ref inputs "bash"))
1606 (coreutils (assoc-ref inputs "coreutils"))
1607 (less (assoc-ref inputs "less")))
1608 (wrap-program (string-append out "/bin/freetalk")
1609 `("PATH" ":" prefix
1610 ,(map (lambda (dir)
1611 (string-append dir "/bin"))
1612 (list bash coreutils less))))
1613 #t))))))
1614 (native-inputs
1615 `(("autoconf" ,autoconf)
1616 ("automake" ,automake)
1617 ("pkg-config" ,pkg-config)
1618 ("texinfo" ,texinfo)))
1619 (inputs
1620 `(("bash" ,bash)
1621 ("glib" ,glib)
1622 ("guile" ,guile-2.0)
1623 ("less" ,less)
1624 ("loudmouth" ,loudmouth)
1625 ("readline" ,readline)))
1626 (synopsis "Extensible console-based Jabber client")
1627 (description
1628 "GNU Freetalk is a command-line Jabber/XMPP chat client. It notably uses
1629 the Readline library to handle input, so it features convenient navigation of
1630 text as well as tab-completion of buddy names, commands and English words. It
1631 is also scriptable and extensible via Guile.")
1632 (home-page "https://www.gnu.org/software/freetalk/")
1633 (license license:gpl3+)))
1634
1635 (define-public libmesode
1636 (package
1637 (name "libmesode")
1638 (version "0.9.3")
1639 (source (origin
1640 (method git-fetch)
1641 (uri (git-reference
1642 (url "https://github.com/boothj5/libmesode")
1643 (commit version)))
1644 (file-name (git-file-name name version))
1645 (sha256
1646 (base32
1647 "0xzfg1xx88cn36352nnjlb1p7xyw32yqkhjzq10px88iaaqz1vv0"))))
1648 (build-system gnu-build-system)
1649 (inputs
1650 `(("expat" ,expat)
1651 ("openssl" ,openssl)))
1652 (native-inputs
1653 `(("autoconf" ,autoconf)
1654 ("automake" ,automake)
1655 ("libtool" ,libtool)
1656 ("pkg-config" ,pkg-config)))
1657 (synopsis "C library for writing XMPP clients")
1658 (description "Libmesode is a fork of libstrophe for use with Profanity
1659 XMPP Client. In particular, libmesode provides extra TLS functionality such as
1660 manual SSL certificate verification.")
1661 (home-page "https://github.com/boothj5/libmesode")
1662 ;; Dual-licensed.
1663 (license (list license:gpl3+ license:x11))))
1664
1665 (define-public libstrophe
1666 (package
1667 (name "libstrophe")
1668 (version "0.9.3")
1669 (source
1670 (origin
1671 (method git-fetch)
1672 (uri (git-reference
1673 (url "https://github.com/strophe/libstrophe")
1674 (commit version)))
1675 (file-name (git-file-name name version))
1676 (sha256
1677 (base32 "1g1l0w9z9hdy5ncdvd9097gi7k7783did6py5h9camlpb2fnk5mk"))))
1678 (build-system gnu-build-system)
1679 (inputs
1680 `(("expat" ,expat)
1681 ("openssl" ,openssl)))
1682 (native-inputs
1683 `(("autoconf" ,autoconf)
1684 ("automake" ,automake)
1685 ("libtool" ,libtool)
1686 ("pkg-config" ,pkg-config)))
1687 (synopsis "C library for writing XMPP clients")
1688 (description "Libstrophe is a minimal XMPP library written in C. It has
1689 almost no external dependencies, only an XML parsing library (expat or libxml
1690 are both supported).")
1691 (home-page "http://strophe.im/libstrophe")
1692 ;; Dual-licensed.
1693 (license (list license:gpl3+ license:x11))))
1694
1695 (define-public profanity
1696 (package
1697 (name "profanity")
1698 (version "0.9.5")
1699 (source (origin
1700 (method url-fetch)
1701 (uri (string-append "https://profanity-im.github.io/profanity-"
1702 version ".tar.gz"))
1703 (sha256
1704 (base32
1705 "00j9l9v62rz9hprgiy1vrz8v3v59ph18h8kskqxr31fgqvjv5xr3"))))
1706 (build-system gnu-build-system)
1707 (arguments
1708 '(#:configure-flags
1709 (list "--enable-c-plugins"
1710 "--enable-otr"
1711 "--enable-omemo"
1712 "--enable-pgp"
1713 "--enable-icons"
1714 "--enable-notifications")))
1715 (inputs
1716 `(("curl" ,curl)
1717 ("expat" ,expat)
1718 ("glib" ,glib)
1719 ("gpgme" ,gpgme)
1720 ("libmesode" ,libmesode)
1721 ("libotr" ,libotr)
1722 ("ncurses" ,ncurses)
1723 ("openssl" ,openssl)
1724 ("readline" ,readline)
1725 ("sqlite" ,sqlite)))
1726 (native-inputs
1727 `(("autoconf" ,autoconf)
1728 ("autoconf-archive" ,autoconf-archive)
1729 ("automake" ,automake)
1730 ("cmocka" ,cmocka)
1731 ("gtk+" ,gtk+-2)
1732 ("libnotify" ,libnotify)
1733 ("libtool" ,libtool)
1734 ("libsignal-protocol-c" ,libsignal-protocol-c)
1735 ("pkg-config" ,pkg-config)))
1736 (synopsis "Console-based XMPP client")
1737 (description "Profanity is a console based XMPP client written in C
1738 using ncurses and libmesode, inspired by Irssi.")
1739 (home-page "https://profanity-im.github.io")
1740 (license license:gpl3+)))
1741
1742 (define-public libircclient
1743 (package
1744 (name "libircclient")
1745 (version "1.10")
1746 (source
1747 (origin
1748 (method url-fetch)
1749 (uri (string-append "mirror://sourceforge/libircclient/libircclient/"
1750 version "/libircclient-" version ".tar.gz"))
1751 (sha256
1752 (base32
1753 "0b9wa0h3xc31wpqlvgxgnvqp5wgx3kwsf5s9432m5cj8ycx6zcmv"))))
1754 (build-system gnu-build-system)
1755 (inputs
1756 `(("openssl" ,openssl)))
1757 (arguments
1758 `(#:configure-flags
1759 (list (string-append "--libdir="
1760 (assoc-ref %outputs "out") "/lib")
1761 "--enable-shared"
1762 "--enable-ipv6"
1763 "--enable-openssl")
1764 #:tests? #f)) ; no test suite
1765 (home-page "https://www.ulduzsoft.com/libircclient/")
1766 (synopsis "Library implementing the client IRC protocol")
1767 (description "Libircclient is a library which implements the client IRC
1768 protocol. It is designed to be small, fast, portable and compatible with the
1769 RFC standards as well as non-standard but popular features. It can be used for
1770 building the IRC clients and bots.")
1771 (license license:lgpl3+)))
1772
1773 (define-public toxic
1774 (package
1775 (name "toxic")
1776 (version "0.8.3")
1777 (source
1778 (origin
1779 (method git-fetch)
1780 (uri (git-reference
1781 (url "https://github.com/JFreegman/toxic")
1782 (commit (string-append "v" version))))
1783 (sha256
1784 (base32 "09l2j3lwvrq7bf3051vjsnml9w63790ly3iylgf26gkrmld6k31w"))
1785 (file-name (git-file-name name version))))
1786 (build-system gnu-build-system)
1787 (arguments
1788 `(#:tests? #f ; no tests
1789 #:make-flags
1790 (list
1791 "CC=gcc"
1792 (string-append "PREFIX="
1793 (assoc-ref %outputs "out")))
1794 #:phases
1795 (modify-phases %standard-phases
1796 (delete 'configure)
1797 (add-before 'build 'enable-python-scripting
1798 (lambda _
1799 ;; XXX: For compatibility with Python 3.8, adjust python3-config
1800 ;; invokation to include --embed; see
1801 ;; <https://github.com/JFreegman/toxic/issues/533>.
1802 (substitute* "cfg/checks/python.mk"
1803 (("python3-config --ldflags")
1804 "python3-config --ldflags --embed"))
1805 (setenv "ENABLE_PYTHON" "1")
1806 #t)))))
1807 (inputs
1808 `(("c-toxcore" ,c-toxcore)
1809 ("curl" ,curl)
1810 ("freealut" ,freealut)
1811 ("gdk-pixbuf" ,gdk-pixbuf) ; for libnotify.pc
1812 ("libconfig" ,libconfig)
1813 ("libnotify" ,libnotify)
1814 ("libpng" ,libpng)
1815 ("libvpx" ,libvpx)
1816 ("libx11" ,libx11)
1817 ("ncurses" ,ncurses)
1818 ("openal" ,openal)
1819 ("python" ,python)
1820 ("qrencode" ,qrencode)))
1821 (native-inputs
1822 `(("pkg-config" ,pkg-config)))
1823 (home-page "https://github.com/JFreegman/toxic")
1824 (synopsis "Tox chat client using ncurses")
1825 (description "Toxic is a console-based instant messaging client, using
1826 c-toxcore and ncurses. It provides audio calls, sound and desktop
1827 notifications, and Python scripting support.")
1828 (license license:gpl3+)))
1829
1830 (define-public libqmatrixclient
1831 (package
1832 (name "libqmatrixclient")
1833 (version "0.5.3.2")
1834 (source
1835 (origin
1836 (method git-fetch)
1837 (uri (git-reference
1838 (url "https://github.com/quotient-im/libQuotient")
1839 (commit version)))
1840 (file-name (git-file-name name version))
1841 (sha256
1842 (base32 "0gkwr3yw6k2m0j8cc085b5p2q788rf5nhp1p5hc5d55pc7mci2qs"))))
1843 (build-system cmake-build-system)
1844 (inputs
1845 `(("qtbase" ,qtbase)
1846 ("qtmultimedia" ,qtmultimedia)))
1847 (arguments
1848 `(#:configure-flags (list "-DBUILD_SHARED_LIBS=ON")
1849 #:tests? #f)) ; no tests
1850 (home-page "https://matrix.org/docs/projects/sdk/libqmatrixclient.html")
1851 (synopsis "Qt5 client library for the Matrix instant messaging protocol")
1852 (description "libqmatrixclient is a Qt5 library to write clients for the
1853 Matrix instant messaging protocol. Quaternion is the reference client
1854 implementation. Quaternion and libqmatrixclient together form the
1855 QMatrixClient project.")
1856 (license license:lgpl2.1+)))
1857
1858 (define-public mtxclient
1859 (package
1860 (name "mtxclient")
1861 (version "0.3.1")
1862 (source
1863 (origin
1864 (method git-fetch)
1865 (uri (git-reference
1866 (url "https://github.com/Nheko-Reborn/mtxclient")
1867 (commit (string-append "v" version))))
1868 (file-name (git-file-name name version))
1869 (sha256
1870 (base32 "1dg4dq20g0ah62j5s3gpsxqq4ny7lxkxdxa9q6g54hdwkrb9ms7x"))))
1871 (arguments
1872 `(#:configure-flags
1873 (list
1874 ;; Disable example binaries (not installed)
1875 "-DBUILD_LIB_EXAMPLES=OFF")
1876 #:phases
1877 (modify-phases %standard-phases
1878 (add-before 'configure 'disable-network-tests
1879 (lambda _
1880 (substitute* "CMakeLists.txt"
1881 (("add_test\\((BasicConnectivity|ClientAPI|MediaAPI|Encryption|Pushrules)")
1882 "# add_test"))
1883 #t))
1884 (add-before 'configure 'set-home
1885 (lambda _
1886 ;; Tries to create package registry file
1887 ;; So, set HOME.
1888 (setenv "HOME" "/tmp")
1889 #t)))))
1890 (build-system cmake-build-system)
1891 (inputs
1892 `(("boost" ,boost)
1893 ("json-modern-cxx" ,json-modern-cxx)
1894 ("libolm" ,libolm)
1895 ("libsodium" ,libsodium)
1896 ("openssl" ,openssl)
1897 ("spdlog" ,spdlog)
1898 ("zlib" ,zlib)))
1899 (native-inputs
1900 `(("googletest" ,googletest)
1901 ("pkg-config" ,pkg-config)))
1902 (home-page "https://github.com/Nheko-Reborn/mtxclient")
1903 (synopsis "Client API library for the Matrix protocol")
1904 (description "@code{mtxclient} is a C++ library that implements client API
1905 for the Matrix protocol. It is built on to of @code{Boost.Asio}.")
1906 (license license:expat)))
1907
1908 (define-public nheko
1909 (package
1910 (name "nheko")
1911 (version "0.7.2")
1912 (source
1913 (origin
1914 (method git-fetch)
1915 (uri (git-reference
1916 (url "https://github.com/Nheko-Reborn/nheko")
1917 (commit (string-append "v" version))))
1918 (file-name (git-file-name name version))
1919 (sha256
1920 (base32 "1cbhgaf9klgxdirrxj571fqwspm0byl75c1xc40l727a6qswvp7s"))))
1921 (arguments
1922 `(#:tests? #f ;no test target
1923 #:configure-flags
1924 (list
1925 "-DCMAKE_BUILD_TYPE=Release"
1926 "-DCMAKE_CXX_FLAGS=-fpermissive")
1927 #:phases
1928 (modify-phases %standard-phases
1929 (add-after 'unpack 'remove-Werror
1930 (lambda _
1931 (substitute* "CMakeLists.txt"
1932 (("-Werror") ""))
1933 #t))
1934 (add-after 'unpack 'fix-determinism
1935 (lambda _
1936 ;; Make Qt deterministic.
1937 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
1938 #t)))))
1939 (build-system qt-build-system)
1940 (inputs
1941 `(("boost" ,boost)
1942 ("cmark" ,cmark)
1943 ("json-modern-cxx" ,json-modern-cxx)
1944 ("libolm" ,libolm)
1945 ("lmdb" ,lmdb)
1946 ("lmdbxx" ,lmdbxx)
1947 ("mtxclient" ,mtxclient)
1948 ("openssl" ,openssl)
1949 ("qtbase" ,qtbase)
1950 ("qtdeclarative" ,qtdeclarative)
1951 ("qtgraphicaleffects" ,qtgraphicaleffects)
1952 ("qtmultimedia" ,qtmultimedia)
1953 ("qtquickcontrols2" ,qtquickcontrols2)
1954 ("qtsvg" ,qtsvg)
1955 ("spdlog" ,spdlog)
1956 ("tweeny" ,tweeny)
1957 ("zlib" ,zlib)))
1958 (native-inputs
1959 `(("pkg-config" ,pkg-config)
1960 ("qtlinguist" ,qttools)))
1961 (home-page "https://github.com/Nheko-Reborn/nheko")
1962 (synopsis "Desktop client for Matrix using Qt and C++14")
1963 (description "@code{Nheko} want to provide a native desktop app for the
1964 Matrix protocol that feels more like a mainstream chat app and less like an IRC
1965 client.
1966
1967 There is support for:
1968 @itemize
1969 @item E2E encryption (text messages only: attachments are currently sent unencrypted).
1970 @item User registration.
1971 @item Creating, joining & leaving rooms.
1972 @item Sending & receiving invites.
1973 @item Sending & receiving files and emoji.
1974 @item Typing notifications.
1975 @item Username auto-completion.
1976 @item Message & mention notifications.
1977 @item Redacting messages.
1978 @item Read receipts.
1979 @item Basic communities support.
1980 @item Room switcher (@key{ctrl-K}).
1981 @item Light, Dark & System themes.
1982 @end itemize")
1983 (license license:gpl3+)))
1984
1985 (define-public quaternion
1986 (package
1987 (name "quaternion")
1988 (version "0.0.9.4e")
1989 (source
1990 (origin
1991 (method git-fetch)
1992 (uri (git-reference
1993 (url "https://github.com/quotient-im/Quaternion")
1994 (commit version)))
1995 (file-name (git-file-name name version))
1996 (sha256
1997 (base32 "0hqhg7l6wpkdbzrdjvrbqymmahziri07ba0hvbii7dd2p0h248fv"))))
1998 (build-system qt-build-system)
1999 (inputs
2000 `(("libqmatrixclient" ,libqmatrixclient)
2001 ("qtbase" ,qtbase)
2002 ("qtdeclarative" ,qtdeclarative)
2003 ("qtmultimedia" ,qtmultimedia)
2004 ("qtquickcontrols" ,qtquickcontrols)
2005 ("qtquickcontrols2" ,qtquickcontrols2)
2006 ("qtsvg" ,qtsvg)
2007 ("qttools" ,qttools)))
2008 (arguments
2009 `(#:tests? #f)) ; no tests
2010 (home-page "https://matrix.org/docs/projects/client/quaternion.html")
2011 (synopsis "Graphical client for the Matrix instant messaging protocol")
2012 (description "Quaternion is a Qt5 desktop client for the Matrix instant
2013 messaging protocol. It uses libqmatrixclient and is its reference client
2014 implementation. Quaternion and libqmatrixclient together form the
2015 QMatrixClient project.")
2016 (license (list license:gpl3+ ; all source code
2017 license:lgpl3+)))) ; icons/breeze
2018
2019 (define-public hangups
2020 (package
2021 (name "hangups")
2022 (version "0.4.10")
2023 (source
2024 (origin
2025 (method url-fetch)
2026 (uri (pypi-uri "hangups" version))
2027 (sha256
2028 (base32 "0ww9z9kcb02pwnr8q1ll31wkzspc1fci1ly8ifrwzxysp4rxy3j5"))))
2029 (build-system python-build-system)
2030 (arguments
2031 `(#:phases
2032 (modify-phases %standard-phases
2033 (add-before 'build 'relax-dependencies
2034 ;; Relax overly strict package version specifications.
2035 (lambda _
2036 (substitute* "setup.py"
2037 (("==") ">="))
2038 #t)))))
2039 (propagated-inputs
2040 `(("python-aiohttp" ,python-aiohttp)
2041 ("python-appdirs" ,python-appdirs)
2042 ("python-async-timeout" ,python-async-timeout)
2043 ("python-configargparse" ,python-configargparse)
2044 ("python-mechanicalsoup" ,python-mechanicalsoup)
2045 ("python-protobuf" ,python-protobuf-3.6)
2046 ("python-readlike" ,python-readlike)
2047 ("python-reparser" ,python-reparser)
2048 ("python-requests" ,python-requests)
2049 ("python-urwid" ,python-urwid)))
2050 (native-inputs
2051 `(("python-httpretty" ,python-httpretty)
2052 ("python-pytest" ,python-pytest)))
2053 (home-page "https://hangups.readthedocs.io/")
2054 (synopsis "Instant messaging client for Google Hangouts")
2055 (description
2056 "Hangups is an instant messaging client for Google Hangouts. It includes
2057 both a Python library and a reference client with a text-based user interface.
2058
2059 Hangups is implements a reverse-engineered version of Hangouts' proprietary,
2060 non-interoperable protocol, which allows it to support features like group
2061 messaging that aren’t available to clients that connect over XMPP.")
2062 (license license:expat)))
2063
2064 (define-public telegram-purple
2065 (package
2066 (name "telegram-purple")
2067 (version "1.4.2")
2068 (home-page "https://github.com/majn/telegram-purple")
2069 (source (origin
2070 (method git-fetch)
2071 (uri (git-reference
2072 (url home-page)
2073 (commit (string-append "v" version))
2074 (recursive? #t)))
2075 (sha256
2076 (base32
2077 "0imbzhhq9qbj6gvkckrnjhls2vvmmy8db7l6gsd7lng2pbfcn522"))
2078 (modules '((guix build utils)))
2079 (snippet
2080 '(begin
2081 (substitute* "Makefile.in"
2082 ;; By default these two directories point to Pidgin's own
2083 ;; prefix.
2084 (("^PLUGIN_DIR_PURPLE=.*")
2085 (string-append
2086 "exec_prefix := @exec_prefix@\n"
2087 "PLUGIN_DIR_PURPLE := @libdir@/purple-2\n"))
2088 (("^DATA_ROOT_DIR_PURPLE=.*")
2089 "DATA_ROOT_DIR_PURPLE := @datarootdir@\n")
2090
2091 ;; Honor sysconfdir instead of trying to write to /etc.
2092 (("DESTDIR\\)/etc/telegram-purple")
2093 "DESTDIR)@sysconfdir@/telegram-purple"))
2094 #t))
2095 (patches (search-patches "telegram-purple-adjust-test.patch"))
2096 (file-name (git-file-name name version))))
2097 (build-system gnu-build-system)
2098 (native-inputs
2099 `(("pkg-config" ,pkg-config)
2100 ("gettext" ,gettext-minimal)
2101 ("which" ,which)))
2102 (inputs
2103 `(("pidgin" ,pidgin)
2104 ("libgcrypt" ,libgcrypt)
2105 ("libwebp" ,libwebp)
2106 ("glib" ,glib)
2107 ("gtk+" ,gtk+-2)
2108 ("zlib" ,zlib)))
2109 (arguments
2110 `(#:phases
2111 (modify-phases %standard-phases
2112 ;; We're using release tag for repository checkout - let's prepare
2113 ;; header defining GIT_COMMIT manually instead of running git to
2114 ;; identify version which is being compiled. Git repository
2115 ;; is removed anyway and only source code is kept.
2116 (add-after 'unpack 'prepare-commit.h
2117 (lambda _
2118 (with-output-to-file "./commit.h"
2119 (lambda ()
2120 (display
2121 (string-append "//generated by guix, use version instead of "
2122 "commit\n"
2123 "#ifndef GIT_COMMIT\n"
2124 "# define GIT_COMMIT \"v"
2125 ,version "\"\n"
2126 "#endif\n"))))
2127 #t))
2128 (add-before 'configure 'set-SHELL-variables
2129 ;; Set these environment variables so that 'tgl/configure' uses the
2130 ;; right shell and not /bin/sh.
2131 (lambda _
2132 (let ((bash (which "bash")))
2133 (setenv "SHELL" bash)
2134 (setenv "CONFIG_SHELL" bash)
2135 #t))))))
2136 (synopsis "Telegram messaging support for Pidgin")
2137 (description
2138 "Telegram-purple is a plugin for Libpurple, the communication library
2139 used by the Pidgin instant messaging client, that adds support for the
2140 Telegram messenger.")
2141
2142 ;; Code under tgl/ (the Telegram library) is LGPLv2.1+, but the plugin
2143 ;; itself is GPLv2+.
2144 (license license:gpl2+)))
2145
2146 (define-public tdlib
2147 (let ((commit "278c7acdec83c5ac17d8e1ed0bb2cacbcea62460")
2148 (revision "0")
2149 (version "1.6.0"))
2150 (package
2151 (name "tdlib")
2152 (version (git-version version revision commit))
2153 (source (origin
2154 (method git-fetch)
2155 (uri (git-reference
2156 (url "https://github.com/tdlib/td")
2157 (commit commit)))
2158 (sha256
2159 (base32
2160 "0zlzpl6fgszg18kwycyyyrnkm255dvc6fkq0b0y32m5wvwwl36cv"))
2161 (file-name (git-file-name name version))))
2162 (build-system cmake-build-system)
2163 (arguments
2164 `(#:tests? #t
2165 #:configure-flags
2166 (list "-DCMAKE_BUILD_TYPE=Release"
2167 "-DTD_ENABLE_LTO=OFF") ; FIXME: Get LTO to work.
2168 #:phases
2169 (modify-phases %standard-phases
2170 (add-after 'unpack 'remove-failing-tests
2171 (lambda _
2172 (substitute* "test/CMakeLists.txt"
2173 ;; The test cases are compiled into a distinct binary
2174 ;; which uses mtproto.cpp to attempt to connect to
2175 ;; a remote server. Removing this file from the sources
2176 ;; list disables those specific test cases.
2177 (("\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}/mtproto.cpp") ""))
2178 #t)))))
2179 (native-inputs
2180 `(("gperf" ,gperf)
2181 ("openssl" ,openssl)
2182 ("zlib" ,zlib)
2183 ("php" ,php)
2184 ("doxygen" ,doxygen)))
2185 (synopsis "Cross-platform library for building Telegram clients")
2186 (description "Tdlib is a cross-platform library for creating custom
2187 Telegram clients following the official Telegram API. It can be easily used
2188 from almost any programming language with a C-FFI and features first-class
2189 support for high performance Telegram Bot creation.")
2190 (home-page "https://core.telegram.org/tdlib")
2191 (license license:boost1.0))))
2192
2193 (define-public purple-mm-sms
2194 (package
2195 (name "purple-mm-sms")
2196 (version "0.1.4")
2197 (source (origin
2198 (method git-fetch)
2199 (uri (git-reference
2200 (url "https://source.puri.sm/Librem5/purple-mm-sms.git")
2201 (commit (string-append "v" version))))
2202 (file-name (git-file-name name version))
2203 (sha256
2204 (base32
2205 "1daf7zl8bhhm1szkgxflpqql69f2w9i9nlgf1n4p1nynxifz1bim"))))
2206 (build-system gnu-build-system)
2207 (arguments
2208 `(#:make-flags
2209 (let ((out (assoc-ref %outputs "out")))
2210 ;; Fix hardcoded paths
2211 (list (string-append "PREFIX=" out)
2212 (string-append "PLUGIN_DIR_PURPLE=" out "/lib/purple-2")
2213 (string-append "DATA_ROOT_DIR_PURPLE=" out "/share")))
2214 #:tests? #f ; no tests
2215 #:phases
2216 (modify-phases %standard-phases
2217 (delete 'configure))))
2218 (native-inputs
2219 `(("glib:bin" ,glib "bin")
2220 ("pkg-config" ,pkg-config)))
2221 (inputs
2222 `(("modem-manager" ,modem-manager)
2223 ("pidgin" ,pidgin)))
2224 (synopsis "Libpurple plugin for SMS via ModemManager")
2225 (description "Plugin for libpurple to allow sending SMS using ModemManager.")
2226 (home-page "https://source.puri.sm/Librem5/purple-mm-sms")
2227 (license license:gpl2+)))
2228
2229 (define-public chatty
2230 (package
2231 (name "chatty")
2232 (version "0.1.10")
2233 (source (origin
2234 (method git-fetch)
2235 (uri (git-reference
2236 (url "https://source.puri.sm/Librem5/chatty.git")
2237 (commit (string-append "v" version))))
2238 (file-name (git-file-name name version))
2239 (sha256
2240 (base32
2241 "0czvqwjzsb0rvmgrmbh97m1b35rnwl41j7q32z4fcqb7bschibql"))))
2242 (build-system meson-build-system)
2243 (arguments
2244 '(#:phases
2245 (modify-phases %standard-phases
2246 (add-after 'unpack 'skip-updating-desktop-database
2247 (lambda _
2248 (substitute* "meson.build"
2249 (("meson.add_install_script.*") ""))
2250 #t)))))
2251 (native-inputs
2252 `(("gettext" ,gettext-minimal)
2253 ("glib:bin" ,glib "bin")
2254 ("pkg-config" ,pkg-config)))
2255 (inputs
2256 `(("feedbackd" ,feedbackd)
2257 ("folks" ,folks)
2258 ("libgcrypt" ,libgcrypt)
2259 ("libgee" ,libgee)
2260 ("libhandy" ,libhandy)
2261 ("pidgin" ,pidgin)
2262 ("purple-mm-sms" ,purple-mm-sms)
2263 ("sqlite" ,sqlite)))
2264 (propagated-inputs
2265 `(("adwaita-icon-theme" ,adwaita-icon-theme)
2266 ("evolution-data-server" ,evolution-data-server)))
2267 (synopsis "Mobile client for XMPP and SMS messaging")
2268 (description "Chatty is a chat program for XMPP and SMS. It works on mobile
2269 as well as on desktop platforms. It's based on libpurple and ModemManager.")
2270 (home-page "https://source.puri.sm/Librem5/chatty")
2271 (license license:gpl3+)))
2272
2273 ;;; messaging.scm ends here