Commit | Line | Data |
---|---|---|
15c6e426 JW |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz> | |
3 | ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> | |
4 | ;;; Copyright © 2019, 2020 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl> | |
3d913c1e | 5 | ;;; Copyright © 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> |
15c6e426 JW |
6 | ;;; |
7 | ;;; This file is part of GNU Guix. | |
8 | ;;; | |
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. | |
13 | ;;; | |
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. | |
18 | ;;; | |
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/>. | |
21 | ||
22 | (define-module (gnu packages jami) | |
23 | #:use-module ((guix licenses) #:prefix license:) | |
24 | #:use-module (gnu packages aidc) | |
25 | #:use-module (gnu packages audio) | |
26 | #:use-module (gnu packages autotools) | |
1c15d305 | 27 | #:use-module (gnu packages backup) |
15c6e426 | 28 | #:use-module (gnu packages base) |
15c6e426 JW |
29 | #:use-module (gnu packages crypto) |
30 | #:use-module (gnu packages documentation) | |
2cfd4770 | 31 | #:use-module (gnu packages gcc) |
15c6e426 JW |
32 | #:use-module (gnu packages gettext) |
33 | #:use-module (gnu packages glib) | |
34 | #:use-module (gnu packages gnome) | |
35 | #:use-module (gnu packages gtk) | |
36 | #:use-module (gnu packages libcanberra) | |
37 | #:use-module (gnu packages linux) | |
15c6e426 | 38 | #:use-module (gnu packages networking) |
15c6e426 JW |
39 | #:use-module (gnu packages perl) |
40 | #:use-module (gnu packages pkg-config) | |
41 | #:use-module (gnu packages pulseaudio) | |
42 | #:use-module (gnu packages python) | |
43 | #:use-module (gnu packages qt) | |
44 | #:use-module (gnu packages serialization) | |
45 | #:use-module (gnu packages sqlite) | |
46 | #:use-module (gnu packages telephony) | |
47 | #:use-module (gnu packages tls) | |
48 | #:use-module (gnu packages upnp) | |
2cfd4770 | 49 | #:use-module (gnu packages version-control) |
15c6e426 JW |
50 | #:use-module (gnu packages video) |
51 | #:use-module (gnu packages webkit) | |
52 | #:use-module (gnu packages xiph) | |
53 | #:use-module (gnu packages xorg) | |
54 | #:use-module (gnu packages) | |
55 | #:use-module (guix build-system cmake) | |
56 | #:use-module (guix build-system gnu) | |
57 | #:use-module (guix download) | |
58 | #:use-module (guix git-download) | |
59 | #:use-module (guix packages) | |
2cfd4770 | 60 | #:use-module (guix utils)) |
15c6e426 | 61 | |
3d913c1e | 62 | (define %jami-version "20210326.1.cfba013") |
15c6e426 | 63 | |
0531ea98 MC |
64 | (define* (jami-source #:key keep-contrib-patches?) |
65 | "Return an origin object of the tarball release sources archive of Jami. | |
66 | When KEEP-CONTRIB-PATCHES? is #t, do not completely remove the contrib | |
67 | subdirectory, which contains patches to be applied to some of the dependencies | |
68 | of Jami." | |
15c6e426 JW |
69 | (origin |
70 | (method url-fetch) | |
aaa199ca | 71 | (uri (string-append "https://dl.jami.net/release/tarballs/jami_" |
15c6e426 JW |
72 | %jami-version |
73 | ".tar.gz")) | |
74 | (modules '((guix build utils))) | |
75 | (snippet | |
0531ea98 | 76 | `(begin |
3d913c1e | 77 | ;; Delete multiple MiBs of bundled tarballs. The contrib directory |
0531ea98 MC |
78 | ;; contains the custom patches for pjproject and other libraries used |
79 | ;; by Savoir-faire Linux. | |
80 | (if ,keep-contrib-patches? | |
81 | (delete-file-recursively "daemon/contrib/tarballs") | |
15c6e426 | 82 | (delete-file-recursively "daemon/contrib")) |
0531ea98 MC |
83 | ;; Remove code from unused Jami clients. |
84 | (for-each delete-file-recursively '("client-android" | |
3d913c1e MC |
85 | "client-electron" |
86 | "client-ios" | |
0531ea98 | 87 | "client-macosx" |
3d913c1e | 88 | "client-uwp")))) |
15c6e426 JW |
89 | (sha256 |
90 | (base32 | |
3d913c1e | 91 | "1h0avma8bdzyznkz39crjyv2888bii4f49md15jg7970dyp5pdyz")))) |
15c6e426 | 92 | |
0531ea98 MC |
93 | (define %sfl-patches (jami-source #:keep-contrib-patches? #t)) |
94 | ||
95 | (define %jami-sources (jami-source)) | |
96 | ||
3d913c1e MC |
97 | ;; Savoir-faire Linux maintains a set of patches for some key dependencies |
98 | ;; (currently pjproject and ffmpeg) of Jami that haven't yet been integrated | |
99 | ;; upstream. This procedure simplifies the process of applying these patches.x | |
f60699af JW |
100 | (define jami-apply-dependency-patches |
101 | '(lambda* (#:key inputs dep-name patches) | |
102 | (let ((patches-directory "sfl-patches")) | |
103 | (mkdir-p patches-directory) | |
104 | (invoke "tar" "-xvf" (assoc-ref inputs "sfl-patches") | |
105 | "-C" patches-directory | |
106 | "--strip-components=5" | |
107 | (string-append "ring-project/daemon/contrib/src/" | |
108 | dep-name)) | |
109 | (for-each | |
110 | (lambda (file) | |
3d913c1e | 111 | (invoke "patch" "--force" "--ignore-whitespace" "-p1" "-i" |
f60699af JW |
112 | (string-append patches-directory "/" |
113 | file ".patch"))) | |
114 | patches)))) | |
115 | ||
3d913c1e MC |
116 | ;;; Jami maintains pjproject patches that add the ability to do ICE over TCP, |
117 | ;;; among other things. The patches are currently based on pjproject 2.10. | |
15c6e426 JW |
118 | (define-public pjproject-jami |
119 | (package | |
120 | (inherit pjproject) | |
121 | (name "pjproject-jami") | |
3d913c1e MC |
122 | (version "2.10") |
123 | (source (origin | |
124 | (method git-fetch) | |
125 | (uri (git-reference | |
126 | (url "https://github.com/pjsip/pjproject") | |
127 | (commit version))) | |
128 | (file-name (git-file-name name version)) | |
129 | (sha256 | |
130 | (base32 | |
131 | "1aklicpgwc88578k03i5d5cm5h8mfm7hmx8vfprchbmaa2p8f4z0")) | |
132 | (patches (search-patches | |
133 | "pjproject-correct-the-cflags-field.patch" | |
134 | "pjproject-fix-pkg-config-ldflags.patch")))) | |
15c6e426 | 135 | (native-inputs |
0531ea98 | 136 | `(("sfl-patches" ,%sfl-patches) |
15c6e426 JW |
137 | ,@(package-native-inputs pjproject))) |
138 | (arguments | |
a5b44d99 MC |
139 | (substitute-keyword-arguments (package-arguments pjproject) |
140 | ((#:phases phases '%standard-phases) | |
141 | `(modify-phases ,phases | |
142 | (add-after 'make-source-files-writable 'apply-patches | |
143 | (lambda* (#:key inputs #:allow-other-keys) | |
144 | (,jami-apply-dependency-patches | |
f60699af JW |
145 | #:inputs inputs |
146 | #:dep-name "pjproject" | |
147 | #:patches | |
2ff4e549 JW |
148 | '("0001-rfc6544" |
149 | "0002-rfc2466" | |
150 | "0003-add-tcp-keep-alive" | |
151 | "0004-multiple_listeners" | |
152 | "0005-fix_ebusy_turn" | |
153 | "0006-ignore_ipv6_on_transport_check" | |
3d913c1e | 154 | "0007-upnp-srflx-nat-assisted-cand" |
2ff4e549 | 155 | "0008-fix_ioqueue_ipv6_sendto" |
1c15d305 | 156 | "0009-add-config-site" |
3d913c1e MC |
157 | ;; Already taken care of via the origin patches. |
158 | ;;"0010-fix-pkgconfig" | |
1c15d305 | 159 | "0011-fix-tcp-death-detection" |
3d913c1e MC |
160 | "0012-fix-turn-shutdown-crash" |
161 | "0013-Assign-unique-local-preferences-for-candidates-with-" | |
162 | "0014-Add-new-compile-time-setting-PJ_ICE_ST_USE_TURN_PERM" | |
163 | "0015-update-local-preference-for-peer-reflexive-candidate" | |
164 | "0016-use-addrinfo-instead-CFHOST" | |
165 | "0017-CVE-2020-15260" | |
166 | "0018-CVE-2021-21375")))))))))) | |
15c6e426 | 167 | |
da358e8c JW |
168 | ;; The following variables are configure flags used by ffmpeg-jami. They're |
169 | ;; from the ring-project/daemon/contrib/src/ffmpeg/rules.mak file. We try to | |
170 | ;; keep it as close to the official Jami package as possible, to provide all | |
171 | ;; the codecs and extra features that are expected. | |
172 | ;; | |
173 | ;; See: | |
174 | ;; https://review.jami.net/plugins/gitiles/ring-daemon/+/refs/heads/master/contrib/src/ffmpeg/rules.mak | |
175 | ||
176 | (define %ffmpeg-default-configure-flags | |
177 | '("--disable-everything" | |
178 | "--enable-zlib" | |
179 | "--enable-gpl" | |
180 | "--enable-swscale" | |
181 | "--enable-bsfs" | |
182 | "--disable-filters" | |
183 | "--disable-programs" | |
184 | "--disable-postproc" | |
185 | "--disable-protocols" | |
186 | "--enable-protocol=crypto" | |
187 | "--enable-protocol=file" | |
188 | "--enable-protocol=rtp" | |
189 | "--enable-protocol=srtp" | |
190 | "--enable-protocol=tcp" | |
191 | "--enable-protocol=udp" | |
192 | "--enable-protocol=unix" | |
193 | "--enable-protocol=pipe" | |
194 | ||
195 | ;; enable muxers/demuxers | |
196 | "--disable-demuxers" | |
197 | "--disable-muxers" | |
198 | "--enable-muxer=rtp" | |
199 | "--enable-muxer=g722" | |
200 | "--enable-muxer=h263" | |
201 | "--enable-muxer=h264" | |
202 | "--enable-muxer=hevc" | |
203 | "--enable-muxer=webm" | |
204 | "--enable-muxer=ogg" | |
205 | "--enable-muxer=pcm_s16be" | |
206 | "--enable-muxer=pcm_s16le" | |
207 | "--enable-demuxer=rtp" | |
208 | "--enable-demuxer=mjpeg" | |
209 | "--enable-demuxer=mjpeg_2000" | |
210 | "--enable-demuxer=mpegvideo" | |
211 | "--enable-demuxer=gif" | |
212 | "--enable-demuxer=image_jpeg_pipe" | |
213 | "--enable-demuxer=image_png_pipe" | |
214 | "--enable-demuxer=image_webp_pipe" | |
215 | "--enable-demuxer=matroska" | |
216 | "--enable-demuxer=m4v" | |
217 | "--enable-demuxer=mp3" | |
218 | "--enable-demuxer=ogg" | |
219 | "--enable-demuxer=flac" | |
220 | "--enable-demuxer=wav" | |
221 | "--enable-demuxer=ac3" | |
222 | "--enable-demuxer=g722" | |
223 | "--enable-demuxer=pcm_mulaw" | |
224 | "--enable-demuxer=pcm_alaw" | |
225 | "--enable-demuxer=pcm_s16be" | |
226 | "--enable-demuxer=pcm_s16le" | |
227 | "--enable-demuxer=h263" | |
228 | "--enable-demuxer=h264" | |
229 | "--enable-demuxer=hevc" | |
230 | ||
231 | ;; enable parsers | |
232 | "--enable-parser=h263" | |
233 | "--enable-parser=h264" | |
234 | "--enable-parser=hevc" | |
235 | "--enable-parser=mpeg4video" | |
236 | "--enable-parser=vp8" | |
237 | "--enable-parser=vp9" | |
238 | "--enable-parser=opus" | |
239 | ||
240 | ;; encoders/decoders | |
241 | "--enable-encoder=adpcm_g722" | |
242 | "--enable-decoder=adpcm_g722" | |
243 | "--enable-encoder=rawvideo" | |
244 | "--enable-decoder=rawvideo" | |
245 | "--enable-encoder=libx264" | |
246 | "--enable-decoder=h264" | |
247 | "--enable-encoder=pcm_alaw" | |
248 | "--enable-decoder=pcm_alaw" | |
249 | "--enable-encoder=pcm_mulaw" | |
250 | "--enable-decoder=pcm_mulaw" | |
251 | "--enable-encoder=mpeg4" | |
252 | "--enable-decoder=mpeg4" | |
253 | "--enable-encoder=libvpx_vp8" | |
254 | "--enable-decoder=vp8" | |
255 | "--enable-decoder=vp9" | |
256 | "--enable-encoder=h263" | |
257 | "--enable-encoder=h263p" | |
258 | "--enable-decoder=h263" | |
259 | "--enable-encoder=mjpeg" | |
260 | "--enable-decoder=mjpeg" | |
261 | "--enable-decoder=mjpegb" | |
262 | "--enable-libspeex" | |
263 | "--enable-libopus" | |
264 | "--enable-libvpx" | |
265 | "--enable-libx264" | |
266 | "--enable-encoder=libspeex" | |
267 | "--enable-decoder=libspeex" | |
268 | "--enable-encoder=libopus" | |
269 | "--enable-decoder=libopus" | |
270 | ||
271 | ;; decoders for ringtones and audio streaming | |
272 | "--enable-decoder=flac" | |
273 | "--enable-decoder=vorbis" | |
274 | "--enable-decoder=aac" | |
275 | "--enable-decoder=ac3" | |
276 | "--enable-decoder=eac3" | |
277 | "--enable-decoder=mp3" | |
278 | "--enable-decoder=pcm_u24be" | |
279 | "--enable-decoder=pcm_u24le" | |
280 | "--enable-decoder=pcm_u32be" | |
281 | "--enable-decoder=pcm_u32le" | |
282 | "--enable-decoder=pcm_u8" | |
283 | "--enable-decoder=pcm_f16le" | |
284 | "--enable-decoder=pcm_f24le" | |
285 | "--enable-decoder=pcm_f32be" | |
286 | "--enable-decoder=pcm_f32le" | |
287 | "--enable-decoder=pcm_f64be" | |
288 | "--enable-decoder=pcm_f64le" | |
289 | "--enable-decoder=pcm_s16be" | |
290 | "--enable-decoder=pcm_s16be_planar" | |
291 | "--enable-decoder=pcm_s16le" | |
292 | "--enable-decoder=pcm_s16le_planar" | |
293 | "--enable-decoder=pcm_s24be" | |
294 | "--enable-decoder=pcm_s24le" | |
295 | "--enable-decoder=pcm_s24le_planar" | |
296 | "--enable-decoder=pcm_s32be" | |
297 | "--enable-decoder=pcm_s32le" | |
298 | "--enable-decoder=pcm_s32le_planar" | |
299 | "--enable-decoder=pcm_s64be" | |
300 | "--enable-decoder=pcm_s64le" | |
301 | "--enable-decoder=pcm_s8" | |
302 | "--enable-decoder=pcm_s8_planar" | |
303 | "--enable-decoder=pcm_u16be" | |
304 | "--enable-decoder=pcm_u16le" | |
305 | ||
306 | ;; encoders/decoders for images | |
307 | "--enable-encoder=gif" | |
308 | "--enable-decoder=gif" | |
309 | "--enable-encoder=jpegls" | |
310 | "--enable-decoder=jpegls" | |
311 | "--enable-encoder=ljpeg" | |
312 | "--enable-decoder=jpeg2000" | |
313 | "--enable-encoder=png" | |
314 | "--enable-decoder=png" | |
315 | "--enable-encoder=bmp" | |
316 | "--enable-decoder=bmp" | |
317 | "--enable-encoder=tiff" | |
318 | "--enable-decoder=tiff" | |
319 | ||
320 | ;; filters | |
321 | "--enable-filter=scale" | |
322 | "--enable-filter=overlay" | |
323 | "--enable-filter=amix" | |
324 | "--enable-filter=amerge" | |
325 | "--enable-filter=aresample" | |
326 | "--enable-filter=format" | |
327 | "--enable-filter=aformat" | |
328 | "--enable-filter=fps" | |
329 | "--enable-filter=transpose" | |
330 | "--enable-filter=pad")) | |
331 | ||
332 | (define %ffmpeg-linux-configure-flags | |
333 | '("--enable-pic" | |
334 | "--extra-cxxflags=-fPIC" | |
335 | "--extra-cflags=-fPIC" | |
336 | "--target-os=linux" | |
337 | "--enable-indev=v4l2" | |
338 | "--enable-indev=xcbgrab" | |
339 | "--enable-vdpau" | |
340 | "--enable-hwaccel=h264_vdpau" | |
341 | "--enable-hwaccel=mpeg4_vdpau" | |
342 | "--enable-vaapi" | |
343 | "--enable-hwaccel=h264_vaapi" | |
344 | "--enable-hwaccel=mpeg4_vaapi" | |
345 | "--enable-hwaccel=h263_vaapi" | |
346 | "--enable-hwaccel=vp8_vaapi" | |
347 | "--enable-hwaccel=mjpeg_vaapi" | |
348 | "--enable-hwaccel=hevc_vaapi" | |
349 | "--enable-encoder=h264_vaapi" | |
350 | "--enable-encoder=vp8_vaapi" | |
351 | "--enable-encoder=mjpeg_vaapi" | |
352 | "--enable-encoder=hevc_vaapi")) | |
353 | ||
354 | ;; ffnvcodec is not supported on ARM then we enable it here for i386 and | |
355 | ;; x86_64 architectures. | |
356 | (define %ffmpeg-linux-x86-configure-flags | |
357 | '("--arch=x86" | |
358 | "--enable-cuvid" | |
359 | "--enable-ffnvcodec" | |
360 | "--enable-nvdec" | |
361 | "--enable-nvenc" | |
362 | "--enable-hwaccel=h264_nvdec" | |
363 | "--enable-hwaccel=hevc_nvdec" | |
364 | "--enable-hwaccel=vp8_nvdec" | |
365 | "--enable-hwaccel=mjpeg_nvdec" | |
366 | "--enable-encoder=h264_nvenc" | |
367 | "--enable-encoder=hevc_nvenc")) | |
368 | ||
369 | ;; This procedure composes the configure flags list for ffmpeg-jami. | |
370 | (define (ffmpeg-compose-configure-flags) | |
371 | (define (system=? s) | |
372 | (string-prefix? s (%current-system))) | |
373 | ||
374 | `(,@%ffmpeg-default-configure-flags | |
375 | ,@(if (string-contains (%current-system) "linux") | |
376 | (if (or (system=? "i686") | |
377 | (system=? "x86_64")) | |
378 | (append %ffmpeg-linux-configure-flags | |
379 | %ffmpeg-linux-x86-configure-flags) | |
380 | %ffmpeg-linux-configure-flags) | |
381 | '()))) | |
382 | ||
383 | (define-public ffmpeg-jami | |
1a265842 | 384 | (package/inherit ffmpeg |
da358e8c JW |
385 | (name "ffmpeg-jami") |
386 | (native-inputs | |
0531ea98 | 387 | `(("sfl-patches" ,%sfl-patches) |
da358e8c JW |
388 | ("libiconv" ,libiconv) |
389 | ,@(package-native-inputs ffmpeg))) | |
390 | (supported-systems '("x86_64-linux" "i686-linux" | |
391 | "aarch64-linux" "armhf-linux")) | |
392 | (arguments | |
393 | (append | |
394 | '(#:tests? #f) | |
395 | (substitute-keyword-arguments (package-arguments ffmpeg) | |
396 | ((#:configure-flags '()) | |
397 | (ffmpeg-compose-configure-flags)) | |
398 | ((#:phases phases) | |
399 | `(modify-phases ,phases | |
400 | (add-after 'unpack 'make-git-checkout-writable | |
401 | (lambda _ | |
3f742c77 | 402 | (for-each make-file-writable (find-files ".")))) |
da358e8c JW |
403 | (add-after 'unpack 'apply-patches |
404 | (lambda* (#:key inputs #:allow-other-keys) | |
405 | (let ((jami-apply-dependency-patches | |
406 | ,jami-apply-dependency-patches)) | |
407 | ;; These patches come from: | |
408 | ;; "ring-project/daemon/contrib/src/ffmpeg/rules.mak". | |
3f742c77 MC |
409 | (jami-apply-dependency-patches |
410 | #:inputs inputs | |
411 | #:dep-name "ffmpeg" | |
412 | #:patches | |
413 | '("remove-mjpeg-log" | |
414 | "change-RTCP-ratio" | |
415 | "rtp_ext_abs_send_time" | |
416 | "libopusdec-enable-FEC" | |
417 | "libopusenc-enable-FEC")))))))))))) | |
da358e8c | 418 | |
15c6e426 JW |
419 | (define-public libring |
420 | (package | |
421 | (name "libring") | |
422 | (version %jami-version) | |
0531ea98 | 423 | (source %jami-sources) |
15c6e426 JW |
424 | (build-system gnu-build-system) |
425 | (inputs | |
15c6e426 | 426 | `(("alsa-lib" ,alsa-lib) |
2cfd4770 | 427 | ("asio" ,asio) |
15c6e426 JW |
428 | ("dbus-c++" ,dbus-c++) |
429 | ("eudev" ,eudev) | |
da358e8c | 430 | ("ffmpeg" ,ffmpeg-jami) |
15c6e426 JW |
431 | ("jack" ,jack-1) |
432 | ("jsoncpp" ,jsoncpp) | |
1c15d305 | 433 | ("libarchive" ,libarchive) |
2cfd4770 | 434 | ("libgit2" ,libgit2) |
63e6f1cd | 435 | ("libnatpmp" ,libnatpmp) |
2cfd4770 MC |
436 | ("libsecp256k1" ,libsecp256k1) |
437 | ("libupnp" ,libupnp) | |
15c6e426 | 438 | ("opendht" ,opendht) |
2cfd4770 MC |
439 | ("openssl" ,openssl) |
440 | ("pjproject" ,pjproject-jami) | |
15c6e426 | 441 | ("pulseaudio" ,pulseaudio) |
15c6e426 JW |
442 | ("speex" ,speex) |
443 | ("speexdsp" ,speexdsp) | |
2cfd4770 MC |
444 | ("webrtc-audio-processing" ,webrtc-audio-processing) |
445 | ("yaml-cpp" ,yaml-cpp))) | |
15c6e426 JW |
446 | (native-inputs |
447 | `(("autoconf" ,autoconf) | |
448 | ("automake" ,automake) | |
2cfd4770 | 449 | ("gcc" ,gcc-8) ;charconv requires GCC 8.1+ |
15c6e426 | 450 | ("libtool" ,libtool) |
2cfd4770 | 451 | ("perl" ,perl) ;to generate manpages with pod2man |
15c6e426 | 452 | ("pkg-config" ,pkg-config) |
2cfd4770 | 453 | ("which" ,which))) |
15c6e426 JW |
454 | (arguments |
455 | `(#:tests? #f ; The tests fail to compile due to missing headers. | |
2cfd4770 | 456 | #:make-flags '("V=1") ;build verbosely |
15c6e426 JW |
457 | #:phases |
458 | (modify-phases %standard-phases | |
459 | (add-after 'unpack 'change-directory | |
460 | (lambda _ | |
2cfd4770 | 461 | (chdir "daemon"))) |
15c6e426 JW |
462 | (add-before 'build 'add-lib-dir |
463 | (lambda _ | |
2cfd4770 MC |
464 | (mkdir-p "src/lib")))))) |
465 | (synopsis "Jami core library and daemon") | |
466 | (description "This package provides a library and daemon implementing the | |
467 | Jami core functionality. Jami is a secure and distributed voice, video and | |
468 | chat communication platform that requires no centralized server and leaves the | |
469 | power of privacy in the hands of the user. It supports the SIP and IAX | |
470 | protocols, as well as decentralized calling using P2P-DHT.") | |
15c6e426 JW |
471 | (home-page "https://jami.net/") |
472 | (license license:gpl3+))) | |
473 | ||
474 | (define-public libringclient | |
475 | (package | |
476 | (inherit libring) | |
477 | (name "libringclient") | |
478 | (build-system cmake-build-system) | |
479 | (propagated-inputs | |
480 | `(("libring" ,libring) ; For 'dring'. | |
481 | ("qtbase" ,qtbase) ; Qt is included in several installed headers. | |
482 | ("qttools" ,qttools))) | |
483 | (arguments | |
484 | `(#:tests? #f ; There is no testsuite. | |
485 | #:configure-flags | |
486 | (list (string-append "-DRING_BUILD_DIR=" | |
487 | (assoc-ref %build-inputs "libring") "/include")) | |
488 | #:phases | |
489 | (modify-phases %standard-phases | |
490 | (add-after 'unpack 'change-directory | |
491 | (lambda _ | |
492 | (chdir "lrc") | |
493 | #t)) | |
494 | (add-before 'configure 'fix-dbus-interfaces-path | |
495 | (lambda* (#:key inputs #:allow-other-keys) | |
496 | (substitute* "CMakeLists.txt" | |
497 | (("\\$\\{CMAKE_INSTALL_PREFIX\\}(/share/dbus-1/interfaces)" _ dbus-interfaces-path-suffix) | |
498 | (string-append (assoc-ref inputs "libring") | |
499 | dbus-interfaces-path-suffix)))))))) | |
500 | (synopsis "Distributed multimedia communications platform") | |
501 | (description "Jami (formerly GNU Ring) is a secure and distributed voice, | |
502 | video and chat communication platform that requires no centralized server and | |
503 | leaves the power of privacy in the hands of the user. It supports the SIP and | |
504 | IAX protocols, as well as decentralized calling using P2P-DHT. | |
505 | ||
506 | This package provides a library common to all Jami clients.") | |
507 | (home-page "https://jami.net") | |
508 | (license license:gpl3+))) | |
509 | ||
510 | (define-public jami | |
511 | (package | |
512 | (inherit libring) | |
513 | (name "jami") | |
514 | (build-system cmake-build-system) | |
515 | (inputs | |
516 | `(("libringclient" ,libringclient) | |
517 | ("gtk+" ,gtk+) | |
518 | ("qrencode" ,qrencode) | |
519 | ("libnotify" ,libnotify) | |
520 | ("clutter" ,clutter) | |
521 | ("clutter-gtk" ,clutter-gtk) | |
15c6e426 JW |
522 | ("libcanberra" ,libcanberra) |
523 | ("webkitgtk" ,webkitgtk) | |
12bcfced | 524 | ("sqlite" ,sqlite))) |
15c6e426 JW |
525 | (native-inputs |
526 | `(("pkg-config" ,pkg-config) | |
f06eefa3 | 527 | ("gettext" ,gettext-minimal) |
15c6e426 JW |
528 | ("glib:bin" ,glib "bin") |
529 | ("doxygen" ,doxygen))) | |
530 | (propagated-inputs | |
531 | `(("libring" ,libring) ; Contains `dring', the daemon, which is automatically by d-bus. | |
532 | ("adwaita-icon-theme" ,adwaita-icon-theme) | |
533 | ("evolution-data-server" ,evolution-data-server))) | |
534 | (arguments | |
535 | `(#:tests? #f ; There is no testsuite. | |
536 | #:phases | |
537 | (modify-phases %standard-phases | |
538 | (add-after 'unpack 'change-directory | |
539 | (lambda _ | |
540 | (chdir "client-gnome") | |
15c6e426 JW |
541 | #t))))) |
542 | (synopsis "Distributed, privacy-respecting communication program") | |
543 | (description "Jami (formerly GNU Ring) is a secure and distributed voice, | |
544 | video and chat communication platform that requires no centralized server and | |
545 | leaves the power of privacy in the hands of the user. It supports the SIP and | |
546 | IAX protocols, as well as decentralized calling using P2P-DHT. | |
547 | ||
548 | This package provides the Jami client for the GNOME desktop.") | |
549 | (home-page "https://jami.net") | |
550 | (license license:gpl3+))) |