1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014 John Darrington <jmd@gnu.org>
3 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
5 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
7 ;;; Copyright © 2016 Francesco Frassinelli <fraph24@gmail.com>
8 ;;; Copyright © 2016, 2017 ng0 <ng0@n0.is>
9 ;;; Copyright © 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
10 ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2017 Adonay Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@hyperbola.info>
12 ;;; Copyright © 2018 Jovany Leandro G.C <bit4bit@riseup.net>
13 ;;; Copyright © 2018 Tim Gesthuizen <tim.gesthuizen@yahoo.de>
14 ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
15 ;;; Copyright © 2019 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl>
16 ;;; Copyright © 2019 Ivan Vilata i Balaguer <ivan@selidor.net>
18 ;;; This file is part of GNU Guix.
20 ;;; GNU Guix is free software; you can redistribute it and/or modify it
21 ;;; under the terms of the GNU General Public License as published by
22 ;;; the Free Software Foundation; either version 3 of the License, or (at
23 ;;; your option) any later version.
25 ;;; GNU Guix is distributed in the hope that it will be useful, but
26 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
27 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28 ;;; GNU General Public License for more details.
30 ;;; You should have received a copy of the GNU General Public License
31 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
33 (define-module (gnu packages telephony)
34 #:use-module (gnu packages)
35 #:use-module (gnu packages aidc)
36 #:use-module (gnu packages autotools)
37 #:use-module (gnu packages avahi)
38 #:use-module (gnu packages audio)
39 #:use-module (gnu packages base)
40 #:use-module (gnu packages boost)
41 #:use-module (gnu packages check)
42 #:use-module (gnu packages compression)
43 #:use-module (gnu packages crypto)
44 #:use-module (gnu packages documentation)
45 #:use-module (gnu packages file)
46 #:use-module (gnu packages protobuf)
47 #:use-module (gnu packages gettext)
48 #:use-module (gnu packages gl)
49 #:use-module (gnu packages glib)
50 #:use-module (gnu packages gnome)
51 #:use-module (gnu packages gnupg)
52 #:use-module (gnu packages gtk)
53 #:use-module (gnu packages libcanberra)
54 #:use-module (gnu packages linux)
55 #:use-module (gnu packages multiprecision)
56 #:use-module (gnu packages ncurses)
57 #:use-module (gnu packages networking)
58 #:use-module (gnu packages pcre)
59 #:use-module (gnu packages perl)
60 #:use-module (gnu packages pkg-config)
61 #:use-module (gnu packages pulseaudio)
62 #:use-module (gnu packages python)
63 #:use-module (gnu packages qt)
64 #:use-module (gnu packages serialization)
65 #:use-module (gnu packages speech)
66 #:use-module (gnu packages tls)
67 #:use-module (gnu packages upnp)
68 #:use-module (gnu packages video)
69 #:use-module (gnu packages webkit)
70 #:use-module (gnu packages xiph)
71 #:use-module (gnu packages xorg)
72 #:use-module (gnu packages xml)
73 #:use-module (gnu packages readline)
74 #:use-module (gnu packages bison)
75 #:use-module (gnu packages flex)
76 #:use-module ((guix licenses) #:prefix license:)
77 #:use-module (guix packages)
78 #:use-module (guix download)
79 #:use-module (guix git-download)
80 #:use-module (guix build-system cmake)
81 #:use-module (guix build-system gnu)
82 #:use-module (guix build-system qt))
84 (define-public commoncpp
90 (uri (string-append "mirror://gnu/" name "/commoncpp2-"
93 "0kmgr5w3b1qwzxnsnw94q6rqs0hr8nbv9clf07ca2a2fyypx9kjk"))))
96 (modify-phases %standard-phases
97 (add-before 'configure 'pre-configure
99 (substitute* "src/applog.cpp"
100 (("^// TODO sc.*") "#include <sys/types.h>\n#include <sys/stat.h>\n"))
102 (build-system gnu-build-system)
103 (synopsis "(u)Common C++ framework for threaded applications")
104 (description "GNU Common C++ is an portable, optimized class framework for
105 threaded applications, supporting concurrent synchronization, inter-process
106 communications via sockets, and various methods for data handling, such as
107 serialization and XML parsing. It includes the uCommon C++ library, a smaller
109 (license license:gpl2+) ; plus runtime exception
110 (home-page "https://www.gnu.org/software/commoncpp/")))
112 (define-public ucommon
118 (uri (string-append "mirror://gnu/commoncpp/" name "-"
121 "1mv080rvrhyxyhgqiqr8r9jdqhg3xhfawjvfj5zgj47h59nggjba"))))
122 (build-system gnu-build-system)
123 (inputs `(("gnutls" ,gnutls)))
124 (synopsis "Common C++ framework for threaded applications")
125 (description "GNU uCommon C++ is meant as a very light-weight C++ library
126 to facilitate using C++ design patterns even for very deeply embedded
127 applications, such as for systems using uclibc along with posix threading
129 (license license:gpl3+)
130 (home-page "https://www.gnu.org/software/commoncpp/")
131 (properties '((ftp-directory . "/gnu/commoncpp")))))
139 (uri (string-append "mirror://gnu/ccrtp/ccrtp-"
142 "17ili8l7zqbbkzr1rcy4hlnazkf50mds41wg6n7bfdsx3c7cldgh"))))
143 (build-system gnu-build-system)
144 (inputs `(("ucommon" ,ucommon)
145 ("libgcrypt" ,libgcrypt)))
146 (native-inputs `(("pkg-config" ,pkg-config)))
147 (synopsis "Implementation of RTP (real-time transport protocol)")
148 (description "GNU ccRTP is an implementation of RTP, the real-time transport
149 protocol from the IETF. It is suitable both for high capacity servers and
150 personal client applications. It is flexible in its design, allowing it to
151 function as a framework for the framework, rather than just being a
152 packet-manipulation library.")
153 (license license:gpl2+) ; plus runtime exception
154 (home-page "https://www.gnu.org/software/ccrtp/")))
163 (uri (string-append "mirror://gnu/osip/libosip2-" version ".tar.gz"))
164 (patches (search-patches "osip-CVE-2017-7853.patch"))
167 "00yznbrm9q04wgd4b831km8iwlvwvsnwv87igf79g5vj9yakr88q"))))
168 (build-system gnu-build-system)
170 (synopsis "Library implementing SIP (RFC-3261)")
171 (description "GNU oSIP is an implementation of the SIP protocol. It is
172 used to provide multimedia and telecom software developers with an interface
173 to initiate and control SIP sessions.")
174 (license license:lgpl2.1+)
175 (home-page "https://www.gnu.org/software/osip/")))
178 (define-public exosip
184 (uri (string-append "mirror://savannah/exosip/libeXosip2-"
187 "17cna8kpc8nk1si419vgr6r42k2lda0rdk50vlxrw8rzg0xp2xrw"))))
188 (build-system gnu-build-system)
189 (inputs `(("osip" ,osip)))
190 (synopsis "Sip abstraction library")
191 (description "EXosip is a library that hides the complexity of using the
192 SIP protocol for multimedia session establishment. This protocol is mainly to
193 be used by VoIP telephony applications (endpoints or conference server) but
194 might be also useful for any application that wish to establish sessions like
196 (license license:gpl2+)
197 ;; (plus OpenSSL linking exception)
198 ;; http://git.savannah.gnu.org/cgit/exosip.git/plain/LICENSE.OpenSSL
199 (home-page "https://savannah.nongnu.org/projects/exosip")))
201 (define-public sipwitch
207 (uri (string-append "mirror://gnu/sipwitch/sipwitch-"
210 "10lli9c703d7qbarzc0lgmz963ppncvnrklwrnri0s1zcmmahyia"))))
211 (build-system gnu-build-system)
212 ;; The configure.ac uses pkg-config but in a kludgy way which breaks when
213 ;; cross-compiling. Among other issues there the program name "pkg-config"
214 ;; is hard coded instead of respecting the PKG_CONFIG environment variable.
215 ;; Fortunately we can avoid the use of pkg-config and set the dependency
217 (arguments `(#:configure-flags
218 `("--without-pkg-config"
219 ,(string-append "UCOMMON_CFLAGS=-I"
220 (assoc-ref %build-inputs "ucommon") "/include")
221 "UCOMMON_LIBS=-lusecure -lucommon -lrt -ldl -lpthread"
222 ,(string-append "LIBOSIP2_CFLAGS=-I"
223 (assoc-ref %build-inputs "osip") "/include")
224 "LIBOSIP2_LIBS=-losipparser2 -losip2"
225 ,(string-append "--sysconfdir=" (assoc-ref %outputs "out")
227 "EXOSIP2_LIBS=-leXosip2"
228 ,(string-append "EXOSIP2_CFLAGS=-I"
229 (assoc-ref %build-inputs "exosip")
231 (inputs `(("ucommon" ,ucommon)
234 (synopsis "Secure peer-to-peer VoIP server for the SIP protocol")
235 (description "GNU SIP Witch is a peer-to-peer Voice-over-IP server that
236 uses the SIP protocol. Calls can be made from behind NAT firewalls and
237 without the need for a service provider. Its peer-to-peer design ensures that
238 there is no central point for media intercept or capture and thus it can be
239 used to construct a secure telephone system that operates over the public
241 (license license:gpl3+)
242 (home-page "https://www.gnu.org/software/sipwitch/")))
244 (define-public libsrtp
251 (url "https://github.com/cisco/libsrtp")
252 (commit (string-append "v" version))))
253 (file-name (git-file-name name version))
256 "1ac7xs1djb03j131f1gmqyfmrplblid9qqyxahs0shdy707r5ll6"))))
258 `(("psmisc" ,psmisc) ;some tests require 'killall'
260 (build-system gnu-build-system)
262 '(#:test-target "runtest"))
263 (synopsis "Secure RTP (SRTP) Reference Implementation")
265 "This package provides an implementation of the Secure Real-time Transport
266 Protocol (@dfn{SRTP}), the Universal Security Transform (@dfn{UST}), and a
267 supporting cryptographic kernel.")
268 (home-page "https://github.com/cisco/libsrtp")
269 (license license:bsd-3)))
271 (define-public bctoolbox
277 (uri (string-append "mirror://savannah/linphone/bctoolbox/bctoolbox-"
281 "14ivv6bh6qywys6yyb34scy9w78d636xl1f7cyxm3gwx2qv71lx5"))))
282 (build-system gnu-build-system)
283 (arguments '(#:make-flags '("CFLAGS=-fPIC")))
287 `(("mbedtls" ,mbedtls-apache)))
288 (home-page "https://www.linphone.org")
289 (synopsis "Utilities library for linphone software")
290 (description "BCtoolbox is a utilities library used by Belledonne
291 Communications software like linphone.")
292 (license license:gpl2+)))
300 (uri (string-append "https://download.savannah.nongnu.org/"
301 "releases/linphone/ortp/sources/ortp-"
305 "1by0dqdqrj5avzcvjws30g8v5sa61wj12x00sxw0kn1smcrshqgb"))))
306 (build-system gnu-build-system)
308 `(("bctoolbox" ,bctoolbox)))
310 `(("pkg-config" ,pkg-config)))
311 (home-page "https://linphone.org/")
312 (synopsis "Implementation of the Real-time transport protocol")
313 (description "oRTP is a library implementing the Real-time transport
314 protocol (RFC 3550).")
315 (license license:lgpl2.1+)))
317 (define-public libiax2
318 (let ((commit "0e5980f1d78ce462e2d1ed6bc39ff35c8341f201"))
319 ;; This is the commit used by the Ring Project.
322 (version (string-append "0.0.0-1." (string-take commit 7)))
327 (url "https://gitlab.savoirfairelinux.com/sflphone/libiax2.git")
329 (file-name (git-file-name name version))
332 "0d269474kk1933c55hx4azw3sak5ycfrxkw6ida0sb2cm00kfich"))))
333 (build-system gnu-build-system)
335 `(("autoconf" ,autoconf)
336 ("automake" ,automake)
337 ("libtool" ,libtool)))
338 (home-page "https://gitlab.savoirfairelinux.com/sflphone/libiax2")
339 (synopsis "Inter-Asterisk-Protocol library")
340 (description "LibIAX2 implements the Inter-Asterisk-Protocol for relaying
341 Voice-over-IP (VoIP) communications.")
342 ;; The file 'src/md5.c' is released into the public domain by RSA Data
343 ;; Security. The files 'src/answer.h', 'src/miniphone.c',
344 ;; 'src/options.c', 'src/options.h', 'src/ring10.h', 'src/winiphone.c' are
345 ;; covered under the 'GPL'.
346 ;; The package as a whole is distributed under the LGPL 2.0.
347 (license (list license:lgpl2.0
348 license:public-domain
357 (uri (string-append "http://holdenc.altervista.org/"
358 "seren/downloads/seren-" version
362 "06mams6bng7ib7p2zpfq88kdr4ffril9svzc9lprkb0wjgmkglk9"))))
363 (build-system gnu-build-system)
364 (arguments '(#:tests? #f)) ; no "check" target
366 `(("alsa-lib" ,alsa-lib)
371 (synopsis "Simple VoIP program to create conferences from the terminal")
373 "Seren is a simple VoIP program based on the Opus codec that allows you
374 to create a voice conference from the terminal, with up to 10 participants,
375 without having to register accounts, exchange emails, or add people to contact
376 lists. All you need to join an existing conference is the host name or IP
377 address of one of the participants.")
378 (home-page "http://holdenc.altervista.org/seren/")
379 (license license:gpl3+)))
381 (define-public mumble
387 (uri (string-append "https://mumble.info/snapshot/"
388 name "-" version ".tar.gz"))
391 "03dqg5yf6d7ilc1wydpshnv1ndssppcbadqcq20jm5j4fdaf53cs"))
392 (modules '((guix build utils)))
395 ;; Remove bundled software. Keep arc4random, celt-0.7.0,
396 ;; celt-0.11.0, qqbonjour, rnnoise, smallft.
398 delete-file-recursively
399 '("3rdparty/GL" ; in mesa
400 "3rdparty/mach-override-build" ; for macx
401 "3rdparty/mach-override-src"
402 "3rdparty/minhook-build" ; for win32
403 "3rdparty/minhook-src"
404 "3rdparty/opus-build" ; in opus
406 "3rdparty/sbcelt-helper-build" ; not enabled
407 "3rdparty/sbcelt-lib-build"
408 "3rdparty/sbcelt-src"
409 "3rdparty/speex-build" ; in speex
411 "3rdparty/speexdsp-src" ; in speexdsp
412 "3rdparty/xinputcheck-build" ; for win32
413 "3rdparty/xinputcheck-src"))
415 (build-system qt-build-system)
417 `(#:tests? #f ; no "check" target
419 (modify-phases %standard-phases
421 (lambda* (#:key inputs outputs #:allow-other-keys)
422 (invoke "qmake" "main.pro" "QMAKE_LRELEASE=lrelease"
423 (string-append "MUMBLE_PYTHON="
424 (string-append (assoc-ref inputs "python")
426 (string-append "CONFIG+="
428 ;; Options used are listed in the same order
429 ;; as in the "INSTALL" file
430 ;; (plus the final "packaged" and "release").
431 (list "no-bundled-speex" ; in speex
432 "no-bundled-opus" ; in opus
433 "no-g15" ; not packaged
434 "no-jackaudio" ; use pulse
436 "no-alsa" ; use pulse
438 "no-embed-qt-translations"
439 "no-ice" ; not packaged
442 (string-append "DEFINES+="
444 (assoc-ref outputs "out")
446 (add-before 'configure 'fix-libspeechd-include
448 (substitute* "src/mumble/TextToSpeech_unix.cpp"
449 (("libspeechd.h") "speech-dispatcher/libspeechd.h"))
451 (add-before 'install 'disable-murmur-ice
453 (substitute* "scripts/murmur.ini.system"
456 (replace 'install ; install phase does not exist
457 (lambda* (#:key inputs outputs #:allow-other-keys)
458 (let* ((out (assoc-ref outputs "out"))
459 (etc (string-append out "/etc/murmur"))
460 (dbus (string-append out "/etc/dbus-1/system.d/"))
461 (bin (string-append out "/bin"))
462 (services (string-append out "/share/services"))
463 (applications (string-append out "/share/applications"))
464 (icons (string-append out "/share/icons/hicolor/scalable/apps"))
465 (man (string-append out "/share/man/man1"))
466 (lib (string-append out "/lib/mumble")))
467 (install-file "release/mumble" bin)
468 (install-file "scripts/mumble-overlay" bin)
469 (install-file "scripts/mumble.protocol" services)
470 (install-file "scripts/mumble.desktop" applications)
471 (install-file "icons/mumble.svg" icons)
472 (install-file "man/mumble-overlay.1" man)
473 (install-file "man/mumble.1" man)
474 (install-file "release/murmurd" bin)
475 (install-file "scripts/murmur.ini.system" etc)
476 (rename-file (string-append etc "/murmur.ini.system")
477 (string-append etc "/murmur.ini"))
478 (install-file "scripts/murmur.conf" dbus)
479 (install-file "man/murmurd.1" man)
480 (for-each (lambda (file) (install-file file lib))
481 (find-files "." "\\.so\\."))
482 (for-each (lambda (file) (install-file file lib))
483 (find-files "release/plugins" "\\.so$"))))))))
487 ("libsndfile" ,libsndfile)
489 ("mesa" ,mesa) ; avoid bundled
491 ("opus" ,opus) ; avoid bundled
492 ("protobuf" ,protobuf)
493 ("pulseaudio" ,pulseaudio)
496 ("speech-dispatcher" ,speech-dispatcher)
497 ("speex" ,speex) ; avoid bundled
498 ("speexdsp" ,speexdsp))) ; avoid bundled
500 `(("pkg-config" ,pkg-config)
502 ("qttools" ,qttools)))
503 (synopsis "Low-latency, high quality voice chat software")
505 "Mumble is an low-latency, high quality voice chat
506 software primarily intended for use while gaming.
507 Mumble consists of two applications for separate usage:
508 @code{mumble} for the client, and @code{murmur} for the server.")
509 (home-page "https://wiki.mumble.info/wiki/Main_Page")
510 (license (list license:bsd-3 ; mumble celt-0.7.0 qqbonjour rnnoise smallft
511 license:bsd-2 ; celt-0.11.0
512 license:isc)))) ; arc4random
514 (define-public twinkle
521 (url "https://github.com/LubosD/twinkle")
522 (commit (string-append "v" version))))
523 (file-name (git-file-name name version))
526 "0s0gi03xwvzp02ah4q6j33r9jx9nbayr6dxlg2ck9pwbay1nq1hx"))))
527 (build-system cmake-build-system)
529 `(#:tests? #f ; no test target
530 #:configure-flags '("-DWITH_SPEEX=On")
532 (modify-phases %standard-phases
533 (add-after 'install 'wrap-executable
534 (lambda* (#:key inputs outputs #:allow-other-keys)
535 (let ((out (assoc-ref outputs "out")))
536 (wrap-program (string-append out "/bin/twinkle")
537 `("QT_PLUGIN_PATH" ":" prefix
538 ,(map (lambda (label)
539 (string-append (assoc-ref inputs label)
541 '("qtbase" "qtdeclarative")))
542 `("QML2_IMPORT_PATH" ":" prefix
543 ,(map (lambda (label)
544 (string-append (assoc-ref inputs label)
546 '("qtdeclarative" "qtquickcontrols"))))
551 ("readline" ,readline)
557 ("speexdsp" ,speexdsp)
558 ("libsndfile" ,libsndfile)
559 ("alsa-lib" ,alsa-lib)
560 ("qttools" ,qttools)))
563 ("qtdeclarative" ,qtdeclarative)
564 ("qtquickcontrols" ,qtquickcontrols)))
565 (home-page "http://twinkle.dolezel.info/")
566 (synopsis "Softphone for voice over IP and instant messaging")
567 (description "Twinkle is a softphone for your voice over IP and instant
568 messaging communcations using the SIP protocol. You can use it for direct IP
569 phone to IP phone communication or in a network using a SIP proxy to route your
571 (license license:gpl2+)))
573 (define-public pjproject
581 (url "https://github.com/pjsip/pjproject.git")
582 (commit "5dfa75be7d69047387f9b0436dd9492bbbf03fe4")))
583 (modules '((guix build utils)))
586 (let ((third-party-directories
587 ;; Things we don't need:
588 ;; BaseClasses - contains libraries from Windows SDK
589 ;; we don't need it, at least not now.
590 (list "BaseClasses" "g7221" "ilbc" "milenage"
591 "speex" "threademulation" "yuv" "bdsound"
592 "gsm" "mp3" "resample" "srtp" "webrtc"
593 ;; Keep only resample, build and README.txt.
594 "build/baseclasses" "build/g7221" "build/gsm"
595 "build/ilbc" "build/milenage" "build/resample"
596 "build/samplerate" "build/speex" "build/srtp"
597 "build/webrtc" "build/yuv")))
598 ;; Keep only Makefiles related to resample.
599 (for-each (lambda (directory)
600 (delete-file-recursively
601 (string-append "third_party/" directory)))
602 third-party-directories)
604 (let ((third-party-dirs
605 (list "gsm" "ilbc" "speex" "g7221" "srtp"
606 "portaudio" "resample")))
609 (substitute* "third_party/build/os-linux.mak"
610 (((string-append "DIRS += " dirs)) "")))
612 (file-name (git-file-name name version))
615 "1ayj6n7zd5wvd1nzj2k9s57fb4ckc2fv92k5sjvhd87yg69k3393"))))
616 (build-system gnu-build-system)
618 `(("portaudio" ,portaudio)))
620 ;; These packages are referenced in the Libs field of the pkg-config
621 ;; file that will be installed by pjproject.
625 ("resample", resample)
626 ("util-linux" ,util-linux)))
628 `(("autoconf" ,autoconf)
629 ("automake" ,automake)
630 ("pkg-config" ,pkg-config)
631 ("libtool" ,libtool)))
633 `(;; FIXME make: No rule to make target
634 ;; 'pjlib-test-unknown-[something]-gnu'.
636 ;; #:test-target "selftest"
638 (modify-phases %standard-phases
639 (add-before 'build 'build-dep
640 (lambda _ (invoke "make" "dep")))
641 (add-before 'patch-source-shebangs 'autoconf
643 (invoke "autoconf" "-v" "-f" "-i" "-o"
644 "aconfigure" "aconfigure.ac")))
645 (add-before 'autoconf 'disable-some-tests
646 ;; Three of the six test programs fail due to missing network
649 (substitute* "Makefile"
650 (("selftest: pjlib-test pjlib-util-test pjnath-test pjmedia-test pjsip-test pjsua-test")
651 "selftest: pjlib-test pjlib-util-test pjmedia-test"))
653 (home-page "https://www.pjsip.org")
654 (synopsis "Session Initiation Protocol (SIP) stack")
655 (description "PJProject provides an implementation of the Session
656 Initiation Protocol (SIP) and a multimedia framework.")
657 (license license:gpl2+)))
659 (define %jami-version "20191101.3.67671e7")
661 (define* (jami-source #:key without-daemon)
664 (uri (string-append "https://dl.jami.net/ring-release/tarballs/ring_"
667 (modules '((guix build utils)))
671 (delete-file-recursively "daemon/contrib"))
675 "0kw172w2ccyz438kf5xqw14nhfm4xk6a2libnzib9j2wvhlpf4q0"))))
677 (define-public pjproject-jami
680 (name "pjproject-jami")
682 `(("savoir-faire-linux-patches" ,(jami-source))
683 ,@(package-native-inputs pjproject)))
686 ;; See ring-project/daemon/contrib/src/pjproject/rules.mak.
688 (list "--disable-oss"
692 "--disable-speex-aec"
693 "--disable-g711-codec"
694 "--disable-l16-codec"
695 "--disable-gsm-codec"
696 "--disable-g722-codec"
697 "--disable-g7221-codec"
698 "--disable-speex-codec"
699 "--disable-ilbc-codec"
700 "--disable-opencore-amr"
707 "--disable-libwebrtc"
709 "--with-external-srtp"
710 ;; We need -fPIC or else we get the following error when linking
711 ;; against pjproject-jami:
712 ;; relocation R_X86_64_32S against `.rodata' can not be used when
713 ;; making a shared object;
717 (modify-phases %standard-phases
718 (add-after 'unpack 'make-git-checkout-writable
720 (for-each make-file-writable (find-files "."))
722 (add-after 'unpack 'apply-patches
723 (lambda* (#:key inputs #:allow-other-keys)
724 (let ((savoir-faire-linux-patches-directory "Savoir-faire Linux patches")
726 ;; "ring-project/daemon/contrib/src/pjproject/rules.mak".
727 ;; WARNING: These amount for huge changes in pjproject.
728 (savoir-faire-linux-patches
729 '("fix_turn_alloc_failure"
735 "fix_ioqueue_ipv6_sendto"
740 "fix_first_packet_turn_tcp"
742 "ignore_ipv6_on_transport_check"
743 "fix_turn_connection_failure"
744 ;; "uwp_vs" ; for windows
745 "disable_local_resolution")))
746 (mkdir-p savoir-faire-linux-patches-directory)
747 (invoke "tar" "-xvf" (assoc-ref inputs "savoir-faire-linux-patches")
748 "-C" savoir-faire-linux-patches-directory
749 "--strip-components=5"
750 "ring-project/daemon/contrib/src/pjproject")
753 (invoke "patch" "--force" "-p1" "-i"
754 (string-append savoir-faire-linux-patches-directory "/"
756 savoir-faire-linux-patches))
758 ;; TODO: We could use substitute-keyword-arguments instead of
759 ;; repeating the phases from pjproject, but somehow it does
761 (add-before 'build 'build-dep
762 (lambda _ (invoke "make" "dep")))
763 (add-before 'patch-source-shebangs 'autoconf
765 (invoke "autoconf" "-v" "-f" "-i" "-o"
766 "aconfigure" "aconfigure.ac")))
767 (add-before 'autoconf 'disable-some-tests
768 ;; Three of the six test programs fail due to missing network
771 (substitute* "Makefile"
772 (("selftest: pjlib-test pjlib-util-test pjnath-test pjmedia-test pjsip-test pjsua-test")
773 "selftest: pjlib-test pjlib-util-test pjmedia-test"))
776 (define-public libring
779 (version %jami-version)
780 (source (jami-source #:without-daemon #t))
781 (build-system gnu-build-system)
783 ;; Missing (optional?) dep: libnatpmp.
784 `(("alsa-lib" ,alsa-lib)
786 ("dbus-c++" ,dbus-c++)
799 ("pulseaudio" ,pulseaudio)
800 ("libsamplerate" ,libsamplerate)
801 ("libsndfile" ,libsndfile)
803 ("speexdsp" ,speexdsp)
805 ("libvorbis" ,libvorbis)
807 ("libvdpau" ,libvdpau)
808 ("yaml-cpp" ,yaml-cpp)
811 ("libsecp256k1" ,libsecp256k1)
813 ("python-wrapper" ,python-wrapper)
814 ("restinio" ,restinio)
817 ;; TODO: Upstream seems to rely on a custom pjproject (a.k.a. pjsip) version.
818 ;; See https://git.jami.net/savoirfairelinux/ring-daemon/issues/24.
819 ("pjproject" ,pjproject-jami)))
821 `(("autoconf" ,autoconf)
822 ("automake" ,automake)
824 ("pkg-config" ,pkg-config)
827 ("perl" ,perl))) ; Needed for documentation.
829 `(#:tests? #f ; The tests fail to compile due to missing headers.
831 (modify-phases %standard-phases
832 (add-after 'unpack 'change-directory
836 (add-before 'build 'add-lib-dir
840 (synopsis "Distributed multimedia communications platform")
841 (description "Jami (formerly GNU Ring) is a secure and distributed voice,
842 video and chat communication platform that requires no centralized server and
843 leaves the power of privacy in the hands of the user. It supports the SIP and
844 IAX protocols, as well as decentralized calling using P2P-DHT.
846 This package provides a library and daemon implementing the Jami core
848 (home-page "https://jami.net/")
849 (license license:gpl3+)))
851 (define-public libringclient
854 (name "libringclient")
855 (build-system cmake-build-system)
857 `(("libring" ,libring) ; For 'dring'.
858 ("qtbase" ,qtbase) ; Qt is included in several installed headers.
859 ("qttools" ,qttools)))
861 `(#:tests? #f ; There is no testsuite.
863 (list (string-append "-DRING_BUILD_DIR="
864 (assoc-ref %build-inputs "libring") "/include"))
866 (modify-phases %standard-phases
867 (add-after 'unpack 'change-directory
871 (add-before 'configure 'fix-dbus-interfaces-path
872 (lambda* (#:key inputs #:allow-other-keys)
873 (substitute* "CMakeLists.txt"
874 (("\\$\\{CMAKE_INSTALL_PREFIX\\}(/share/dbus-1/interfaces)" _ dbus-interfaces-path-suffix)
875 (string-append (assoc-ref inputs "libring")
876 dbus-interfaces-path-suffix))))))))
877 (synopsis "Distributed multimedia communications platform")
878 (description "Jami (formerly GNU Ring) is a secure and distributed voice,
879 video and chat communication platform that requires no centralized server and
880 leaves the power of privacy in the hands of the user. It supports the SIP and
881 IAX protocols, as well as decentralized calling using P2P-DHT.
883 This package provides a library common to all Jami clients.")
884 (home-page "https://jami.net")
885 (license license:gpl3+)))
891 (build-system cmake-build-system)
893 `(("libringclient" ,libringclient)
895 ("qrencode" ,qrencode)
896 ("libnotify" ,libnotify)
898 ("clutter-gtk" ,clutter-gtk)
899 ("gettext" ,gnu-gettext)
900 ("libcanberra" ,libcanberra)
901 ("webkitgtk" ,webkitgtk)))
903 `(("pkg-config" ,pkg-config)
904 ("glib:bin" ,glib "bin")
905 ("doxygen" ,doxygen)))
907 `(("libring" ,libring) ; Contains `dring', the daemon, which is automatically by d-bus.
908 ("adwaita-icon-theme" ,adwaita-icon-theme)
909 ("evolution-data-server" ,evolution-data-server)))
911 `(#:tests? #f ; There is no testsuite.
913 (modify-phases %standard-phases
914 (add-after 'unpack 'change-directory
916 (chdir "client-gnome")
918 (synopsis "Distributed, privacy-respecting communication program")
919 (description "Jami (formerly GNU Ring) is a secure and distributed voice,
920 video and chat communication platform that requires no centralized server and
921 leaves the power of privacy in the hands of the user. It supports the SIP and
922 IAX protocols, as well as decentralized calling using P2P-DHT.
924 This package provides the Jami client for the GNOME desktop.")
925 (home-page "https://jami.net")
926 (license license:gpl3+)))
928 (define-public jami-client-gnome
929 (deprecated-package "jami-client-gnome" jami))