1 ;;; GNU Guix --- Functional package management for GNU
3 ;;; Copyright © 2020, 2021 Raghav Gururajan <raghavgururajan@disroot.org>
4 ;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
5 ;;; Copyright © 2020 Tobias Geerinckx-Rice <me@tobias.gr>
7 ;;; This file is part of GNU Guix.
9 ;;; GNU Guix is free software; you can redistribute it and/or modify it
10 ;;; under the terms of the GNU General Public License as published by
11 ;;; the Free Software Foundation; either version 3 of the License, or (at
12 ;;; your option) any later version.
14 ;;; GNU Guix is distributed in the hope that it will be useful, but
15 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
16 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 ;;; GNU General Public License for more details.
19 ;;; You should have received a copy of the GNU General Public License
20 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
22 (define-module (gnu packages linphone)
23 #:use-module (gnu packages)
24 #:use-module (gnu packages admin)
25 #:use-module (gnu packages audio)
26 #:use-module (gnu packages avahi)
27 #:use-module (gnu packages base)
28 #:use-module (gnu packages cpp)
29 #:use-module (gnu packages compression)
30 #:use-module (gnu packages crypto)
31 #:use-module (gnu packages databases)
32 #:use-module (gnu packages documentation)
33 #:use-module (gnu packages gettext)
34 #:use-module (gnu packages gl)
35 #:use-module (gnu packages glib)
36 #:use-module (gnu packages gnome)
37 #:use-module (gnu packages gnome-xyz)
38 #:use-module (gnu packages graphviz)
39 #:use-module (gnu packages gtk)
40 #:use-module (gnu packages image)
41 #:use-module (gnu packages linux)
42 #:use-module (gnu packages ncurses)
43 #:use-module (gnu packages openldap)
44 #:use-module (gnu packages perl)
45 #:use-module (gnu packages pkg-config)
46 #:use-module (gnu packages pulseaudio)
47 #:use-module (gnu packages python)
48 #:use-module (gnu packages python-xyz)
49 #:use-module (gnu packages qt)
50 #:use-module (gnu packages java)
51 #:use-module (gnu packages sqlite)
52 #:use-module (gnu packages telephony)
53 #:use-module (gnu packages tls)
54 #:use-module (gnu packages video)
55 #:use-module (gnu packages xiph)
56 #:use-module (gnu packages xml)
57 #:use-module (gnu packages xorg)
58 #:use-module ((guix licenses) #:prefix license:)
59 #:use-module (guix packages)
60 #:use-module (guix download)
61 #:use-module (guix git-download)
62 #:use-module (guix build-system cmake)
63 #:use-module (guix build-system qt)
64 #:use-module (guix build-system glib-or-gtk)
65 #:use-module (guix build-system gnu))
68 (let ((commit "74021cc7cb20a4e177748dd2948173e1f9c270ae")
72 (version (git-version "3.0.2" revision commit))
77 (url "git://git.linphone.org/bcunit")
79 (file-name (git-file-name name version))
81 (base32 "0npdwvanjkfg9vrqs5yi8vh6wliv50ycdli8pzavir84nb31nq1b"))))
82 (build-system cmake-build-system)
83 (outputs '("out" "doc"))
85 `(#:configure-flags (list "-DENABLE_STATIC=NO"
88 "-DENABLE_EXAMPLES=ON"
90 "-DENABLE_MEMTRACE=ON")
92 (modify-phases %standard-phases
93 (add-after 'unpack 'patch-source
95 ;; Include BCunit headers for examples.
96 (substitute* "Examples/CMakeLists.txt"
97 (("\\$\\{CMAKE_CURRENT_SOURCE_DIR\\}")
98 (string-append "${CMAKE_CURRENT_SOURCE_DIR} "
99 "${PROJECT_SOURCE_DIR}/BCUnit/Headers "
100 "${CMAKE_BINARY_DIR}/BCUnit/Headers")))
101 ;; Link bcunit and bcunit_tests libraries.
102 (substitute* "BCUnit/Sources/CMakeLists.txt"
103 (("target_include_directories\\(bcunit_test PUBLIC Test\\)")
105 "target_include_directories(bcunit_test PUBLIC Test)\n"
106 "target_link_libraries(bcunit_test bcunit)")))))
109 (with-directory-excursion "BCUnit/Sources/Test"
110 (invoke "./test_bcunit"))))
111 (add-after 'install 'move-doc
112 (lambda* (#:key outputs #:allow-other-keys)
113 (let ((out (assoc-ref outputs "out"))
114 (doc (assoc-ref outputs "doc")))
116 `(,(string-append doc "/share/doc")
117 ,(string-append doc "/share/BCUnit")))
119 (string-append out "/share/doc/BCUnit")
120 (string-append doc "/share/doc/BCUnit"))
122 (string-append out "/share/BCUnit/Examples")
123 (string-append doc "/share/BCUnit/Examples"))))))))
125 `(("ncurses" ,ncurses)))
126 (synopsis "Belledonne Communications Unit Testing Framework")
127 (description "BCUnit is a fork of the defunct project CUnit, with
128 several fixes and patches applied. It is a unit testing framework for
129 writing, administering, and running unit tests in C.")
130 (home-page "https://gitlab.linphone.org/BC/public/bcunit")
131 (license license:lgpl2.0+))))
133 (define-public bctoolbox
141 (url "https://gitlab.linphone.org/BC/public/bctoolbox.git")
143 (file-name (git-file-name name version))
145 (base32 "0bfswwvvdshaahg4jd2j10f0sci8809s4khajd0m6b059zwc7y25"))))
146 (build-system cmake-build-system)
147 (outputs '("out" "debug"))
149 `(#:configure-flags '("-DENABLE_STATIC=OFF")
151 (modify-phases %standard-phases
152 (add-after 'unpack 'patch-cmake
153 (lambda* (#:key inputs #:allow-other-keys)
154 ;; Fix decaf dependency (see:
155 ;; https://gitlab.linphone.org/BC/public/bctoolbox/-/issues/3).
156 (let* ((decaf (assoc-ref inputs "decaf")))
157 (substitute* (find-files "." "CMakeLists.txt")
158 (("find_package\\(Decaf CONFIG\\)")
159 "set(DECAF_FOUND 1)")
160 (("\\$\\{DECAF_INCLUDE_DIRS\\}")
161 (string-append decaf "/include/decaf"))
162 (("\\$\\{DECAF_TARGETNAME\\}")
164 (add-after 'unpack 'skip-problematic-tests
166 ;; The following test relies on networking; disable it.
167 (substitute* "tester/port.c"
168 (("[ \t]*TEST_NO_TAG.*bctbx_addrinfo_sort_test\\)")
170 (add-after 'unpack 'fix-installed-resource-directory-detection
172 ;; There's some broken logic in tester.c that checks if CWD, or
173 ;; if its parent exist, and if so, sets the prefix where the test
174 ;; resources are looked up to; disable it (see:
175 ;; https://gitlab.linphone.org/BC/public/bctoolbox/-/issues/4).
176 (substitute* "src/tester.c"
177 (("if \\(file_exists\\(\".\"\\)\\)")
179 (("if \\(file_exists\\(\"..\"\\)\\)")
183 (with-directory-excursion "tester"
184 (invoke "./bctoolbox_tester")))))))
188 ("mbedtls" ,mbedtls-apache)))
189 (synopsis "Belledonne Communications Tool Box")
190 (description "BcToolBox is an utilities library used by Belledonne
191 Communications software like belle-sip, mediastreamer2 and linphone.")
192 (home-page "https://gitlab.linphone.org/BC/public/bctoolbox")
193 (license license:gpl3+)))
203 (url "https://gitlab.linphone.org/BC/public/belr.git")
205 (file-name (git-file-name name version))
207 (base32 "0w2canwwm0qb99whnangvaybvjzq8xg6vksqxykgr8fbx7clw03h"))))
208 (build-system cmake-build-system)
209 (outputs '("out" "debug" "tester"))
211 `(#:configure-flags '("-DENABLE_STATIC=OFF")
213 (modify-phases %standard-phases
214 (delete 'check) ;moved after the install phase
215 (add-after 'install 'check
216 (lambda* (#:key outputs #:allow-other-keys)
217 (let* ((tester (assoc-ref outputs "tester"))
218 (belr_tester (string-append tester "/bin/belr_tester"))
219 (tester-share (string-append tester "/share/belr_tester")))
220 (invoke belr_tester))))
221 (add-after 'install 'move-tester
222 (lambda* (#:key outputs #:allow-other-keys)
223 (let* ((out (assoc-ref outputs "out"))
224 (tester (assoc-ref outputs "tester")))
226 (list (string-append tester "/bin")
227 (string-append tester "/share")))
229 (string-append out "/bin/belr_tester")
230 (string-append tester "/bin/belr_tester"))
232 (string-append out "/share/belr-tester")
233 ;; The detect_res_prefix procedure in bctoolbox's tester.c
234 ;; resolves the resource path based on the executable path and
235 ;; name, so have it match.
236 (string-append tester "/share/belr_tester"))))))))
238 `(("bctoolbox" ,bctoolbox)))
239 (synopsis "Belledonne Communications Language Recognition Library")
240 (description "Belr is Belledonne Communications' language recognition
241 library, written in C++11. It parses text inputs formatted according to a
242 language defined by an ABNF grammar, such as the protocols standardized at
244 (home-page "https://gitlab.linphone.org/BC/public/belr")
245 (license license:gpl3+)))
247 (define-public belcard
255 (url "https://gitlab.linphone.org/BC/public/belcard.git")
257 (file-name (git-file-name name version))
259 (base32 "16x2xp8d0a115132zhy1kpxkyj86ia7vrsnpjdg78fnbvmvysc8m"))))
260 (build-system cmake-build-system)
261 (outputs '("out" "debug" "tester"))
264 #:configure-flags '("-DENABLE_STATIC=OFF")
266 (modify-phases %standard-phases
267 (add-after 'unpack 'patch-vcard-grammar-location
268 (lambda* (#:key outputs #:allow-other-keys)
269 (let* ((out (assoc-ref outputs "out"))
271 (string-append out "/share/belr/grammars/vcard_grammar")))
272 (substitute* "include/belcard/vcard_grammar.hpp"
273 (("define VCARD_GRAMMAR \"vcard_grammar\"")
274 (format #f "define VCARD_GRAMMAR ~s" vcard-grammar))))))
275 (add-after 'install 'install-tester
276 (lambda* (#:key inputs outputs #:allow-other-keys)
277 (let ((out (assoc-ref outputs "out"))
278 (tester (assoc-ref outputs "tester"))
279 (test-name (string-append ,name "_tester")))
281 (list (string-append tester "/bin")
282 (string-append tester "/share")))
283 (rename-file (string-append out "/bin/" test-name)
284 (string-append tester "/bin/" test-name))
285 (rename-file (string-append out "/share/" test-name)
286 (string-append tester "/share/" test-name)))))
288 (add-after 'install-tester 'check
289 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
291 (let* ((tester (assoc-ref outputs "tester"))
292 (belcard_tester (string-append tester
293 "/bin/belcard_tester")))
294 (invoke belcard_tester))))))))
296 `(("bctoolbox" ,bctoolbox)
298 (synopsis "Belledonne Communications VCard Library")
299 (description "Belcard is a C++ library to manipulate VCard standard
301 (home-page "https://gitlab.linphone.org/BC/public/belcard")
302 (license license:gpl3+)))
304 (define-public bcmatroska2
312 (url "https://gitlab.linphone.org/BC/public/bcmatroska2.git")
314 (file-name (git-file-name name version))
316 (base32 "1avl9w18kh4dxm3g8j0bkw39bksd7bz3nfxvyibqqnz63ds8vfi2"))))
317 (build-system cmake-build-system)
319 `(#:tests? #f ; No test target
320 #:configure-flags (list "-DENABLE_STATIC=NO"))) ; Not required
321 (synopsis "Belledonne Communications Media Container")
322 (description "BcMatroska is a free and open standard multi-media container
323 format. It can hold an unlimited number of video, audio, picture, or subtitle
324 tracks in one file. This project provides a convenient distribution of the
325 Matroska multimedia container format.")
326 (home-page "https://gitlab.linphone.org/BC/public/bcmatroska2")
327 (license (list license:gpl2+ ;for this package (build system files)
328 license:bsd-4 ;for Core C and LibEBML2
329 license:lgpl2.1+)))) ;for LibMatroska2
331 (define-public bcg729
339 (url "git://git.linphone.org/bcg729")
341 (file-name (git-file-name name version))
343 (base32 "1hal6b3w6f8y5r1wa0xzj8sj2jjndypaxyw62q50p63garp2h739"))))
344 (build-system cmake-build-system)
346 `(#:configure-flags (list "-DENABLE_STATIC=NO"
347 "-DENABLE_TESTS=YES")
349 (modify-phases %standard-phases
350 (add-before 'check 'copy-inputs
351 (lambda* (#:key inputs #:allow-other-keys)
352 (let ((test-patterns (assoc-ref inputs "test-patterns"))
353 (dest (string-append "test/bcg729-patterns.zip")))
354 (copy-recursively test-patterns dest))))
357 (with-directory-excursion "test"
358 (invoke "unzip" "bcg729-patterns.zip")
361 (invoke "./testCampaign" "-s" test-name))
362 (list "fixedCodebookSearch"
364 "adaptativeCodebookSearch"
366 "computeAdaptativeCodebookGain"
374 "decodeFixedCodeVector"
376 ;; "LP2LSPConversion"
378 "findOpenLoopPitchDelay"
380 "computeWeightedSpeech"
381 "interpolateqLSPAndConvert2LP"
382 "decodeAdaptativeCodeVector"))))))))
388 (uri (string-append "http://www.belledonne-communications.com/"
389 "bc-downloads/bcg729-patterns.zip"))
391 (base32 "1kivarhh3izrl9sg0szs6x6pbq2ap0y6xsraw0gbgspi4gnfihrh"))))
393 (synopsis "Belledonne Communications G729 Codec")
394 (description "BcG729 is an implementation of both encoder and decoder of
395 the ITU G729 speech codec. The library written in C 99 is fully portable and
396 can be executed on many platforms including both ARM and x86 processors. It
397 supports concurrent channels encoding and decoding for multi call application
398 such as conferencing.")
399 (home-page "https://linphone.org/technical-corner/bcg729")
400 (license license:gpl3+)))
410 (url "https://gitlab.linphone.org/BC/public/ortp.git")
412 (file-name (git-file-name name version))
414 (base32 "1r1kvjzyfvkf66in4p51wi87balzg3sw3aq6r4xr609mz86spi5m"))))
415 (build-system cmake-build-system)
416 (outputs '("out""tester"
417 "doc")) ;1.5 MiB of HTML doc
419 `(#:tests? #f ;requires networking
420 #:configure-flags (list "-DENABLE_STATIC=NO"
421 "-DENABLE_TESTS=YES")
423 (modify-phases %standard-phases
424 (add-after 'unpack 'fix-version-strings
425 ;; See: https://gitlab.linphone.org/BC/public/ortp/-/issues/5.
427 (substitute* "CMakeLists.txt"
428 (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+")
429 (string-append "VERSION " ,version))
430 (("\\$\\{ORTP_DOC_VERSION\\}")
432 (add-after 'install 'separate-outputs
433 (lambda* (#:key outputs #:allow-other-keys)
434 (let* ((out (assoc-ref outputs "out"))
435 (doc (assoc-ref outputs "doc"))
436 (doc-src (string-append out "/share/doc/ortp-" ,version))
437 (doc-dest (string-append doc "/share/doc/ortp-" ,version))
438 (tester (assoc-ref outputs "tester")))
439 (for-each mkdir-p (list (string-append doc "/share/doc")
440 (string-append tester "/bin")))
441 (rename-file doc-src doc-dest)
442 (rename-file (string-append out "/bin")
443 (string-append tester "/bin"))))))))
446 ("doxygen" ,doxygen)))
448 `(("bctoolbox" ,bctoolbox)))
449 (synopsis "Belledonne Communications RTP Library")
450 (description "oRTP is a C library implementing the RTP protocol. It
451 implements the RFC 3550 standard.")
452 (home-page "https://linphone.org/technical-corner/ortp")
453 (license license:gpl3+)))
463 (url "https://gitlab.linphone.org/BC/public/bzrtp")
465 (file-name (git-file-name name version))
467 (base32 "1yjmsbqmymzl4r7sba6w4a2yld8m6hzafr6jf7sj0syhwpnc3zv6"))))
468 (build-system cmake-build-system)
473 "-DENABLE_TESTS=YES")))
475 `(("bctoolbox" ,bctoolbox)
478 (synopsis "Belledonne Communications ZRTP Library")
479 (description "BZRTP is an implementation of ZRTP keys exchange protocol,
480 written in C. It is fully portable and can be executed on many platforms
481 including both ARM and x86.")
482 (home-page "https://gitlab.linphone.org/BC/public/bzrtp")
483 (license license:gpl3+)))
485 (define-public belle-sip
493 (url "https://gitlab.linphone.org/BC/public/belle-sip.git")
495 (file-name (git-file-name name version))
497 (base32 "1kknnlczq7dpqaj1dwxvy092dzrqjy11ndkv90rqwmdryigkjk6z"))))
498 (build-system cmake-build-system)
499 (outputs '("out" "tester"))
501 `(#:configure-flags (list "-DENABLE_STATIC=NO"
504 (modify-phases %standard-phases
505 (add-after 'unpack 'patch
506 (lambda* (#:key inputs #:allow-other-keys)
507 ;; Fix mDNS dependency.
508 (let* ((avahi (assoc-ref inputs "avahi")))
509 (substitute* (find-files "." "CMakeLists.txt")
510 (("find_package\\(DNSSD REQUIRED\\)")
511 "set(DNSSD_FOUND 1)")
512 (("\\$\\{DNSSD_INCLUDE_DIRS\\}")
513 (string-append avahi "/include/avahi-compat-libdns_sd"))
514 (("\\$\\{DNSSD_LIBRARIES\\}")
516 (substitute* "src/CMakeLists.txt"
517 ;; ANTLR would use multithreaded DFA generation otherwise,
518 ;; which would not be reproducible.
519 (("-Xmultithreaded ") ""))))
520 (delete 'check) ;move after install
521 (add-after 'install 'separate-outputs
522 (lambda* (#:key outputs #:allow-other-keys)
523 (let* ((out (assoc-ref outputs "out"))
524 (tester (assoc-ref outputs "tester"))
525 (tester-name "belle_sip_tester"))
526 (for-each mkdir-p (list (string-append tester "/bin")
527 (string-append tester "/share")))
528 (rename-file (string-append out "/bin")
529 (string-append tester "/bin"))
530 (rename-file (string-append out "/share/" tester-name)
531 (string-append tester "/share/" tester-name)))))
532 (add-after 'separate-outputs 'check
533 (lambda* (#:key outputs #:allow-other-keys)
534 (let ((tester (string-append (assoc-ref outputs "tester")
535 "/bin/belle_sip_tester")))
536 (for-each (lambda (suite-name)
537 (invoke tester "--suite" suite-name))
538 (list "Object inheritance"
548 "Authentication helper"
556 ("bctoolbox" ,bctoolbox)
558 (synopsis "Belledonne Communications SIP Library")
559 (description "Belle-sip is a modern library implementing SIP transport,
560 transaction and dialog layers. It is written in C, with an object-oriented
561 API. It also comprises a simple HTTP/HTTPS client implementation.")
562 (home-page "https://linphone.org/technical-corner/belle-sip")
563 (license license:gpl3+)))
565 (define-public mediastreamer2
567 (name "mediastreamer2")
573 (url "https://gitlab.linphone.org/BC/public/mediastreamer2.git")
575 (file-name (git-file-name name version))
577 (base32 "0989h3d0h7qrx4kjx8gg09j8c5hvvi3h8qi1iq1dqbppwbaxbz8c"))))
578 (outputs '("out" "doc" "tester"))
579 (build-system cmake-build-system)
581 `(#:configure-flags (list "-DENABLE_STATIC=NO"
583 ;; Do not fail on compile warnings.
585 "-DENABLE_PORTAUDIO=YES"
586 "-DENABLE_G729B_CNG=YES")
588 (modify-phases %standard-phases
589 (add-after 'unpack 'fix-version
591 (substitute* "CMakeLists.txt"
592 (("VERSION [0-9]+\\.[0-9]+\\.[0-9]+")
593 (string-append "VERSION " ,version)))))
594 (add-after 'unpack 'patch-source
596 (substitute* "src/otherfilters/mspcapfileplayer.c"
597 (("O_BINARY") "L_INCR"))))
598 (add-before 'check 'pre-check
600 ;; Tests require a running X server.
601 (system "Xvfb :1 +extension GLX &")
602 (setenv "DISPLAY" ":1")
603 ;; Tests write to $HOME.
604 (setenv "HOME" (getenv "TEMP"))))
605 (delete 'check) ;move after install
606 (add-after 'install 'separate-outputs
607 (lambda* (#:key outputs #:allow-other-keys)
608 (let* ((out (assoc-ref outputs "out"))
609 (tester (assoc-ref outputs "tester"))
610 (tester-name (string-append ,name "_tester"))
611 (doc (assoc-ref outputs "doc"))
612 (doc-name (string-append ,name "-" ,version)))
614 (list (string-append tester "/bin")
615 (string-append tester "/share")
616 (string-append doc "/share/doc")))
617 ;; Move the tester executable.
618 (rename-file (string-append out "/bin/" tester-name)
619 (string-append tester "/bin/" tester-name))
620 ;; Move the tester data files.
621 (rename-file (string-append out "/share/" tester-name)
622 (string-append tester "/share/" tester-name))
623 ;; Move the HTML documentation.
624 (rename-file (string-append out "/share/doc/" doc-name)
625 (string-append doc "/share/doc/" doc-name)))))
626 (add-after 'separate-outputs 'check
627 (lambda* (#:key outputs #:allow-other-keys)
628 (let ((tester (string-append (assoc-ref outputs "tester")
629 "/bin/mediastreamer2_tester")))
630 (for-each (lambda (suite-name)
631 (invoke tester "--suite" suite-name))
632 ;; Some tests fail, due to requiring access to the
633 ;; sound card or the network.
636 ;; "AdaptiveAlgorithm"
646 ("python" ,python-wrapper)
647 ("xorg-server" ,xorg-server-for-tests)))
651 ("bcmatroska2" ,bcmatroska2)
652 ("bctoolbox" ,bctoolbox)
662 ("portaudio" ,portaudio)
663 ("pulseaudio" ,pulseaudio)
666 ("speexdsp" ,speexdsp)
668 ("theora" ,libtheora)
669 ("turbojpeg" ,libjpeg-turbo)
675 (synopsis "Belledonne Communications Streaming Engine")
676 (description "Mediastreamer2 is a powerful and lightweight streaming engine
677 for telephony applications. This media processing and streaming toolkit is
678 responsible for receiving and sending all multimedia streams in Linphone,
679 including media capture, encoding and decoding, and rendering.")
680 (home-page "https://linphone.org/technical-corner/mediastreamer2")
681 (license license:gpl3+)))
691 (url "https://gitlab.linphone.org/BC/public/lime.git")
693 (file-name (git-file-name name version))
695 (base32 "14jg1zisjbzflw3scfqdbwy48wq3cp93l867vigb8l40lkc6n26z"))))
696 (build-system cmake-build-system)
697 (outputs '("out" "doc"))
699 `(#:configure-flags (list "-DENABLE_STATIC=NO"
700 "-DENABLE_C_INTERFACE=YES")
702 (modify-phases %standard-phases
703 (add-after 'unpack 'patch-source
705 ;; Disable tests that require networking.
706 (substitute* "tester/CMakeLists.txt"
707 (("add_test\\(?.*\"Hello World\"\\)") "")
708 (("add_test\\(?.*\"lime\"\\)") "")
709 (("add_test\\(?.*\"FFI\"\\)") ""))))
710 (add-after 'build 'build-doc
712 (invoke "make" "doc")))
713 (add-after 'install 'install-doc
714 (lambda* (#:key outputs #:allow-other-keys)
715 (let* ((doc (assoc-ref outputs "doc"))
716 (dir (string-append doc "/share/doc"))
717 (dest (string-append dir "/" ,name "-" ,version)))
719 (copy-recursively "doc" dest)))))))
722 ("doxygen" ,doxygen)))
724 `(("bctoolbox" ,bctoolbox)
725 ("belle-sip" ,belle-sip)
727 (synopsis "Belledonne Communications Encryption Library")
728 (description "LIME is an encryption library for one-to-one and group
729 instant messaging, allowing users to exchange messages privately and
730 asynchronously. It supports multiple devices per user and multiple users per
732 (home-page "https://linphone.org/technical-corner/lime")
733 (license license:gpl3+)))
735 (define-public liblinphone
743 (url "https://gitlab.linphone.org/BC/public/liblinphone.git")
745 (file-name (git-file-name name version))
747 (base32 "1lwabr93jw24y04pdqnw9dgg8jb3lzfplyx19f83jgp9dj8kmfq9"))))
748 (outputs '("out" "tester"))
749 (build-system cmake-build-system)
751 `(#:tests? #f ; Tests require networking
752 #:configure-flags (list "-DENABLE_STATIC=NO"
753 "-DENABLE_DOC=NO" ;requires unpackaged javasphinx
756 (modify-phases %standard-phases
757 (add-after 'install 'separate-outputs
758 (lambda* (#:key outputs #:allow-other-keys)
759 (let* ((out (assoc-ref outputs "out"))
760 (tester (assoc-ref outputs "tester"))
761 (tester-name (string-append ,name "_tester")))
763 (list (string-append tester "/bin")
764 (string-append tester "/share")))
765 (rename-file (string-append out "/bin/" tester-name)
766 (string-append tester "/bin/" tester-name))
767 (rename-file (string-append out "/bin/groupchat_benchmark")
768 (string-append tester "/bin/groupchat_benchmark"))
769 (rename-file (string-append out "/share/" tester-name)
770 (string-append tester "/share/" tester-name))))))))
774 ("gettext" ,gettext-minimal)
776 ("python" ,python-wrapper)
777 ("pystache" ,python-pystache)
781 `(("bctoolbox" ,bctoolbox)
783 ("bellesip" ,belle-sip)
790 ("mediastreamer2" ,mediastreamer2)
791 ("notify" ,libnotify)
797 (synopsis "Belledonne Communications Softphone Library")
798 (description "Liblinphone is a high-level SIP library integrating
799 all calling and instant messaging features into an unified
800 easy-to-use API. It is the cross-platform VoIP library on which the
801 Linphone application is based on, and that anyone can use to add audio
802 and video calls or instant messaging capabilities to an application.")
803 (home-page "https://linphone.org/technical-corner/liblinphone")
804 (license license:gpl3+)))
806 (define-public linphone-desktop
808 (name "linphone-desktop")
814 (url "https://gitlab.linphone.org/BC/public/linphone-desktop")
816 (file-name (git-file-name name version))
818 (base32 "1gq4l9p21rbrcksa7fbkzn9fzbbynqmn6ni6lhnvzk359sb1xvbz"))
819 (patches (search-patches "linphone-desktop-without-sdk.patch"))))
820 (build-system qt-build-system)
821 (outputs '("out" "debug"))
823 `(#:tests? #f ; No test target
824 #:configure-flags (list "-DENABLE_UPDATE_CHECK=NO"
825 "-DENABLE_DAEMON=YES"
826 "-DENABLE_CONSOLE_UI=YES")
828 (modify-phases %standard-phases
829 (add-after 'unpack 'pre-configure
831 (make-file-writable "linphone-app/linphoneqt_version.cmake")
832 (substitute* "linphone-app/linphoneqt_version.cmake"
833 (("\\$\\{GUIX-SET-VERSION\\}") ,version))))
834 (add-after 'install 'post-install
835 (lambda* (#:key inputs outputs #:allow-other-keys)
836 (let* ((out (assoc-ref outputs "out"))
837 (liblinphone (assoc-ref inputs "liblinphone"))
838 (grammar-dest (string-append out "/share/belr/grammars")))
839 ;; Remove unnecessary Qt configuration file.
840 (delete-file (string-append out "/bin/qt.conf"))
841 ;; Not using the FHS exposes an issue where the client
842 ;; refers to its own directories, which lacks files
843 ;; installed by the dependencies.
844 (symlink (string-append liblinphone "/lib")
845 (string-append out "/lib"))
846 (symlink (string-append liblinphone "/share/sounds")
847 (string-append out "/share/sounds"))
848 (symlink (string-append liblinphone "/share/linphone/rootca.pem")
849 (string-append out "/share/linphone/rootca.pem"))
850 (mkdir-p (dirname grammar-dest))
851 (symlink (string-append liblinphone "/share/belr/grammars")
854 `(("pkg-config" ,pkg-config)
855 ("qttools" ,qttools)))
857 `(("bctoolbox" ,bctoolbox)
860 ("liblinphone" ,liblinphone)
861 ("mediastreamer2" ,mediastreamer2)
864 ("qtdeclarative" ,qtdeclarative)
865 ("qtgraphicaleffects" ,qtgraphicaleffects)
866 ("qtquickcontrols" ,qtquickcontrols)
867 ("qtquickcontrols2" ,qtquickcontrols2)
869 (synopsis "Desktop client for the Linphone SIP softphone")
870 (description "Linphone is a SIP softphone for voice and video over IP calling
871 (VoIP) and instant messaging. Amongst its features are:
873 @item High Definition (HD) audio and video calls
874 @item Multiple call management (pause and resume)
876 @item Audio conferencing (merge calls into a conference call)
877 @item Call recording and replay (audio only)
878 @item Instant Messaging with message delivery status (IMDN)
879 @item Picture and file sharing
880 @item Echo cancellation
881 @item Secure user authentication using TLS client certificates
882 @item SRTP, zRTP and SRTP-DTLS voice and video encryption
883 @item Telephone tone (DTMF) support using SIP INFO or RFC 4733
884 @item Audio codecs: opus, speex, g711, g729, gsm, iLBC, g722, SILK, etc.
885 @item Video codecs: VP8, H.264 and H.265 with resolutions up to 1080P, MPEG4
887 (home-page "https://linphone.org/technical-corner/linphone")
888 (license license:gpl3+)))
890 (define-public linphoneqt
891 (deprecated-package "linphoneqt" linphone-desktop))
893 (define-public msopenh264
894 (let ((commit "88697cc95140017760d6da408cb0efdc5e86e40a")
898 (version (git-version "1.2.1" revision commit))
903 (url "https://gitlab.linphone.org/BC/public/msopenh264.git")
905 (file-name (git-file-name name version))
907 (base32 "10y3b6s934f2wbsf60b3p0g6hffizjqrj5in8l4sida2fjdxlwwy"))))
908 (build-system cmake-build-system)
910 `(#:tests? #f ; No test target
912 (list "-DENABLE_STATIC=NO"))) ; Not required
914 `(("bctoolbox" ,bctoolbox)
915 ("mediastreamer2" ,mediastreamer2)
916 ("openh264" ,openh264)
918 (synopsis "Media Streamer H.264 Codec")
919 (description "MsOpenH264 is an H.264 encoder/decoder plugin for
920 mediastreamer2 based on the openh264 library.")
921 (home-page "https://gitlab.linphone.org/BC/public/msopenh264")
922 (license license:gpl2+))))
924 (define-public mssilk
925 (let ((commit "dd0f31ee795faa7ea89e601b072dae4cd1df7e3f")
929 (version (git-version "1.1.1" revision commit))
934 (url "https://gitlab.linphone.org/BC/public/mssilk.git")
936 (file-name (git-file-name name version))
938 (base32 "1dann5fnzqp6wjlwc6bl2k9b6rvn6bznqb3qsi1kgv9dnq44cbr0"))))
939 (build-system cmake-build-system)
941 `(#:tests? #f ; No test target
943 (list "-DENABLE_STATIC=NO"))) ; Not required
945 `(("bctoolbox" ,bctoolbox)
946 ("mediastreamer2" ,mediastreamer2)
948 (synopsis "Media Streamer SILK Codec")
949 (description "MSSILK is a plugin of MediaStreamer, adding support for AMR
950 codec. It is based on the Skype's SILK implementation.")
951 (home-page "https://gitlab.linphone.org/BC/public/mssilk")
952 (license license:gpl2+))))
954 (define-public mswebrtc
955 (let ((commit "946ca706733f36a6b4923f04e569531125462d1d")
959 (version (git-version "1.1.1" revision commit))
964 (url "https://gitlab.linphone.org/BC/public/mswebrtc")
966 (file-name (git-file-name name version))
968 (base32 "1pfg9m6bpbv0f53nx72rdxhlyriax9pg4yj0gpwq8ha6lqnpwg1x"))))
969 (build-system cmake-build-system)
971 `(#:tests? #f ; No test target
974 "-DENABLE_STATIC=NO")
976 (modify-phases %standard-phases
977 (add-after 'unpack 'copy-inputs
978 (lambda* (#:key inputs outputs #:allow-other-keys)
979 (let* ((webrtc-from (assoc-ref inputs "webrtc"))
980 (webrtc-to (string-append (getcwd) "/webrtc")))
981 (copy-recursively webrtc-from webrtc-to))
989 (url "https://gitlab.linphone.org/BC/public/external/webrtc")
990 (commit "583acd27665cfadef8ab03eb85a768d308bd29dd")))
992 (git-file-name "webrtc-for-mswebrtc" version))
995 "1maqychrgwy0z4zypa03qp726l2finw64z6cymdzhd58ql3p1lvm"))))
996 ("python" ,python-wrapper)))
998 `(("bctoolbox" ,bctoolbox)
999 ("mediastreamer2" ,mediastreamer2)
1001 (synopsis "Media Streamer WebRTC Codec")
1002 (description "MSWebRTC is a plugin of MediaStreamer, adding support for
1003 WebRTC codec. It includes features from WebRTC, such as, iSAC and AECM.")
1004 (home-page "https://gitlab.linphone.org/BC/public/mswebrtc")
1005 (license license:gpl2+))))
1007 (define-public msamr
1008 (let ((commit "5ab5c098299107048dfcbfc741f7392faef167bd")
1012 (version (git-version "1.1.3" revision commit))
1017 (url "https://gitlab.linphone.org/BC/public/msamr")
1019 (file-name (git-file-name name version))
1021 (base32 "1g79lw1qi1mlw3v1b0cixmqiwjql81gz9naakb15n8pvaag9aaqm"))))
1022 (build-system cmake-build-system)
1024 `(#:tests? #f ; No test target
1026 (list "-DENABLE_STATIC=NO" ; Not required
1027 "-DENABLE_WIDEBAND=YES")))
1029 `(("bctoolbox" ,bctoolbox)
1030 ("mediastreamer2" ,mediastreamer2)
1031 ("opencoreamr" ,opencore-amr)
1033 ("voamrwbenc" ,vo-amrwbenc)))
1034 (synopsis "Media Streamer AMR Codec")
1035 (description "MSAMR is a plugin of MediaStreamer, adding support for AMR
1036 codec. It is based on the opencore-amr implementation.")
1037 (home-page "https://gitlab.linphone.org/BC/public/msamr")
1038 (license license:gpl3+))))