gnu: python-unidecode: Fix typo in description.
[jackhill/guix/guix.git] / gnu / packages / gnunet.scm
CommitLineData
eb4b2ab6 1;;; GNU Guix --- Functional package management for GNU
8ca73fce 2;;; Copyright © 2013, 2014, 2015 Andreas Enge <andreas@enge.fr>
05e8a0b0 3;;; Copyright © 2014 Sree Harsha Totakura <sreeharsha@totakura.in>
e1ecc890 4;;; Copyright © 2015, 2017 Ludovic Courtès <ludo@gnu.org>
5f47e713 5;;; Copyright © 2015 Efraim Flashner <efraim@flashner.co.il>
3ccdd430 6;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
fd7fd3c1 7;;; Copyright © 2016 Mark H Weaver <mhw@netris.org>
28e12d6c 8;;; Copyright © 2016, 2017 ng0 <ng0@infotropique.org>
eb4b2ab6
AE
9;;;
10;;; This file is part of GNU Guix.
11;;;
12;;; GNU Guix is free software; you can redistribute it and/or modify it
13;;; under the terms of the GNU General Public License as published by
14;;; the Free Software Foundation; either version 3 of the License, or (at
15;;; your option) any later version.
16;;;
17;;; GNU Guix is distributed in the hope that it will be useful, but
18;;; WITHOUT ANY WARRANTY; without even the implied warranty of
19;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20;;; GNU General Public License for more details.
21;;;
22;;; You should have received a copy of the GNU General Public License
23;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
24
25(define-module (gnu packages gnunet)
266b39fc 26 #:use-module (gnu packages)
2fd22ec5 27 #:use-module (gnu packages file)
3ccdd430 28 #:use-module (gnu packages aidc)
eb4b2ab6
AE
29 #:use-module (gnu packages autotools)
30 #:use-module (gnu packages compression)
88065ec2 31 #:use-module (gnu packages curl)
1dba6407 32 #:use-module (gnu packages gettext)
eb4b2ab6 33 #:use-module (gnu packages glib)
3ccdd430 34 #:use-module (gnu packages gnome)
88065ec2 35 #:use-module (gnu packages gnupg)
6adda006 36 #:use-module (gnu packages gnuzilla)
a85cb486 37 #:use-module (gnu packages groff)
3ccdd430 38 #:use-module (gnu packages gtk)
59698c2c 39 #:use-module (gnu packages guile)
248c0645 40 #:use-module (gnu packages gstreamer)
a85cb486 41 #:use-module (gnu packages libidn)
6adda006 42 #:use-module (gnu packages linux)
e55354b8 43 #:use-module (gnu packages image)
266b39fc
SHT
44 #:use-module (gnu packages libunistring)
45 #:use-module (gnu packages maths)
6adda006 46 #:use-module (gnu packages multiprecision)
b0a2addd 47 #:use-module (gnu packages music)
6adda006 48 #:use-module (gnu packages ncurses)
b0a2addd 49 #:use-module (gnu packages package-management)
eb4b2ab6 50 #:use-module (gnu packages pkg-config)
a85cb486 51 #:use-module (gnu packages perl)
266b39fc 52 #:use-module (gnu packages pulseaudio)
a85cb486 53 #:use-module (gnu packages python)
5f96f303 54 #:use-module (gnu packages databases)
a7fd7b68 55 #:use-module (gnu packages tls)
248c0645 56 #:use-module (gnu packages video)
6adda006 57 #:use-module (gnu packages web)
54ff0b7d 58 #:use-module (gnu packages xiph)
cd372ca3 59 #:use-module (gnu packages backup)
b5b73a82 60 #:use-module ((guix licenses) #:prefix license:)
eb4b2ab6
AE
61 #:use-module (guix packages)
62 #:use-module (guix download)
59698c2c 63 #:use-module (guix git-download)
eb4b2ab6
AE
64 #:use-module (guix build-system gnu))
65
66(define-public libextractor
67 (package
68 (name "libextractor")
75cc8fe9 69 (version "1.4")
eb4b2ab6
AE
70 (source (origin
71 (method url-fetch)
72 (uri (string-append "mirror://gnu/libextractor/libextractor-"
73 version ".tar.gz"))
74 (sha256
75 (base32
75cc8fe9 76 "0v7ns5jhsyp1wzvbaydfgxnva5zd63gkzm9djhckmam9liq824l4"))))
eb4b2ab6
AE
77 (build-system gnu-build-system)
78 ;; WARNING: Checks require /dev/shm to be in the build chroot, especially
79 ;; not to be a symbolic link to /run/shm.
80 ;; FIXME:
81 ;; The following dependencies are all optional, but should be
82 ;; available for maximum coverage:
eb4b2ab6 83 ;; * libmagic (file)
b0a2addd 84 ;; * librpm (rpm) ; investigate failure
cd372ca3 85 ;; * libgif (giflib) ; investigate failure
eb4b2ab6 86 (inputs
2e838890 87 `(("exiv2" ,exiv2)
b0a2addd 88 ("bzip2" ,bzip2)
eb4b2ab6 89 ("flac" ,flac)
248c0645 90 ("ffmpeg" ,ffmpeg)
2fd22ec5 91 ("file" ,file) ;libmagic, for the MIME plug-in
eb4b2ab6 92 ("glib" ,glib)
248c0645
AE
93 ("gstreamer" ,gstreamer)
94 ("gst-plugins-base" ,gst-plugins-base)
cd372ca3 95 ("gtk+" ,gtk+)
96 ("libarchive" ,libarchive)
97 ("libgsf" ,libgsf)
eb4b2ab6 98 ("libjpeg" ,libjpeg)
cd372ca3 99 ("libltdl" ,libltdl)
100 ("libmpeg2" ,libmpeg2)
b0a2addd 101 ("libmp4v2" ,libmp4v2)
102 ("libsmf" ,libsmf)
103 ("tidy-html" ,tidy-html)
eb4b2ab6
AE
104 ("libogg" ,libogg)
105 ("libtiff" ,libtiff)
eb4b2ab6 106 ("libvorbis" ,libvorbis)
eb4b2ab6 107 ("zlib" ,zlib)))
c4c4cc05 108 (native-inputs
cd372ca3 109 `(("pkg-config" ,pkg-config)))
ff711960 110 (outputs '("out"
111 "static")) ; 396 KiB .a files
cd372ca3 112 (arguments
113 `(#:configure-flags
114 (list (string-append "--with-ltdl="
b0a2addd 115 (assoc-ref %build-inputs "libltdl"))
116 (string-append "--with-tidy="
117 (assoc-ref %build-inputs "tidy-html")))
ff711960 118 #:parallel-tests? #f
119 #:phases
120 (modify-phases %standard-phases
121 (add-after 'install 'move-static-libraries
122 (lambda* (#:key outputs #:allow-other-keys)
123 ;; Move static libraries to the "static" output.
124 (let* ((out (assoc-ref outputs "out"))
125 (lib (string-append out "/lib"))
126 (static (assoc-ref outputs "static"))
127 (slib (string-append static "/lib")))
128 (mkdir-p slib)
129 (for-each (lambda (file)
130 (install-file file slib)
131 (delete-file file))
132 (find-files lib "\\.a$"))
133 #t))))))
eb4b2ab6
AE
134 (synopsis "Library to extract meta-data from media files")
135 (description
79c311b8 136 "GNU libextractor is a library for extracting metadata from files. It
a22dc0c4
LC
137supports a very large number of file formats, including audio files, document
138files, and archive files. Each file format is implemented as a plugin, so
79c311b8 139new formats can be added easily. The package also contains a command-line
a22dc0c4 140tool to extract metadata from a file and print the results.")
eb4b2ab6 141 (license license:gpl3+)
6fd52309 142 (home-page "https://www.gnu.org/software/libextractor/")))
88065ec2
AE
143
144(define-public libmicrohttpd
145 (package
146 (name "libmicrohttpd")
e1ecc890 147 (version "0.9.55")
88065ec2
AE
148 (source (origin
149 (method url-fetch)
150 (uri (string-append "mirror://gnu/libmicrohttpd/libmicrohttpd-"
151 version ".tar.gz"))
152 (sha256
153 (base32
e1ecc890 154 "1y6h1slav5l6k8zyb01dpw65dscdgxxgfa3a0z9qnn7jr66sn70c"))))
88065ec2
AE
155 (build-system gnu-build-system)
156 (inputs
157 `(("curl" ,curl)
158 ("gnutls" ,gnutls)
159 ("libgcrypt" ,libgcrypt)
160 ("openssl" ,openssl)
161 ("zlib" ,zlib)))
dce17227 162 (arguments
e1ecc890
LC
163 `(#:parallel-tests? #f
164 #:phases (modify-phases %standard-phases
165 (add-before 'check 'add-missing-LDFLAGS
166 (lambda _
167 ;; The two test_upgrade* programs depend on GnuTLS
168 ;; directly but lack -lgnutls; add it.
169 (substitute* "src/microhttpd/Makefile"
170 (("^test_upgrade(.*)LDFLAGS = (.*)$" _ first rest)
171 (string-append "test_upgrade" first
172 "LDFLAGS = -lgnutls " rest)))
173 #t)))))
88065ec2
AE
174 (synopsis "C library implementing an HTTP 1.1 server")
175 (description
dce17227
AE
176 "GNU libmicrohttpd is a small, embeddable HTTP server implemented as a
177C library. It makes it easy to run an HTTP server as part of another
a22dc0c4 178application. The library is fully HTTP 1.1 compliant. It can listen on
dce17227
AE
179multiple ports, supports four different threading models, and supports
180IPv6. It
181also features security features such as basic and digest authentication
a22dc0c4 182and support for SSL3 and TLS.")
88065ec2 183 (license license:lgpl2.1+)
b02b9a52 184 (home-page "https://www.gnu.org/software/libmicrohttpd/")))
a85cb486
SHT
185
186(define-public gnurl
187 (package
188 (name "gnurl")
77a0354a 189 (version "7.55.1-3")
a85cb486
SHT
190 (source (origin
191 (method url-fetch)
b53e4cbd 192 (uri (string-append "https://gnunet.org/sites/default/files/"
193 name "-" version ".tar.bz2"))
a85cb486 194 (sha256
7012e2c7 195 (base32
77a0354a 196 "1p2qdh44hgsxjlzh4d3n51xr66cg2z517vpr818flvcrmpq2vxpq"))))
a85cb486 197 (build-system gnu-build-system)
50e9f81a 198 (outputs '("out"
199 "doc")) ; 1.5 MiB of man3 pages
a85cb486
SHT
200 (inputs `(("gnutls" ,gnutls)
201 ("libidn" ,libidn)
202 ("zlib" ,zlib)))
203 (native-inputs
a0e43c9f 204 `(("autoconf" ,autoconf)
205 ("automake" ,automake)
206 ("libtool" ,libtool)
207 ("groff" ,groff)
7af52bd5
SHT
208 ("perl" ,perl)
209 ("pkg-config" ,pkg-config)
a85cb486
SHT
210 ("python" ,python-2)))
211 (arguments
212 `(#:configure-flags '("--enable-ipv6" "--with-gnutls" "--without-libssh2"
213 "--without-libmetalink" "--without-winidn"
214 "--without-librtmp" "--without-nghttp2"
215 "--without-nss" "--without-cyassl"
216 "--without-polarssl" "--without-ssl"
217 "--without-winssl" "--without-darwinssl"
218 "--disable-sspi" "--disable-ntlm-wb"
219 "--disable-ldap" "--disable-rtsp" "--disable-dict"
220 "--disable-telnet" "--disable-tftp" "--disable-pop3"
221 "--disable-imap" "--disable-smtp" "--disable-gopher"
5f9d5905 222 "--disable-file" "--disable-ftp" "--disable-smb")
c543b4e1 223 #:test-target "test"
224 #:parallel-tests? #f
225 #:phases
226 ;; We have to patch runtests.pl in tests/ directory
b9fe72bf 227 (modify-phases %standard-phases
50e9f81a 228 (add-after 'install 'move-man3-pages
229 (lambda* (#:key outputs #:allow-other-keys)
230 ;; Move section 3 man pages to "doc".
231 (let ((out (assoc-ref outputs "out"))
232 (doc (assoc-ref outputs "doc")))
233 (mkdir-p (string-append doc "/share/man"))
234 (rename-file (string-append out "/share/man/man3")
235 (string-append doc "/share/man/man3"))
236 #t)))
d10092b8 237 (add-after 'unpack 'autoconf
a0e43c9f 238 ;; Clear artifacts left (shebangs) from release preparation.
239 (lambda _
d10092b8 240 (zero? (system* "sh" "buildconf"))))
4ec08b63 241 (replace 'check
a0e43c9f 242 (lambda _
243 ;; It is unclear why test1026 fails, however the content of it
244 ;; suggests that it is not vital for gnurl.
245 (delete-file "tests/data/test1026")
4ec08b63 246
b9fe72bf
EF
247 (substitute* "tests/runtests.pl"
248 (("/bin/sh") (which "sh")))
4ec08b63 249
250 ;; Make test output more verbose.
251 (zero? (system* "make" "-C" "tests" "test"))
b9fe72bf 252 #t)))))
a85cb486
SHT
253 (synopsis "Microfork of cURL with support for the HTTP/HTTPS/GnuTLS subset of cURL")
254 (description
255 "Gnurl is a microfork of cURL, a command line tool for transferring data
35b9e423 256with URL syntax. While cURL supports many crypto backends, libgnurl only
5f9d5905 257supports HTTP, HTTPS and GnuTLS.")
166191b3
LC
258 (license (license:non-copyleft "file://COPYING"
259 "See COPYING in the distribution."))
a85cb486 260 (home-page "https://gnunet.org/gnurl")))
266b39fc
SHT
261
262(define-public gnunet
263 (package
264 (name "gnunet")
f944fbf1 265 (version "0.10.1")
266b39fc
SHT
266 (source
267 (origin
268 (method url-fetch)
269 (uri (string-append "mirror://gnu/gnunet/gnunet-" version
270 ".tar.gz"))
6adda006 271 (sha256
272 (base32
273 "04wxzm3wkgqbn42b8ksr4cx6m5cckyig5cls1adh0nwdczwvnp7n"))))
266b39fc
SHT
274 (build-system gnu-build-system)
275 (inputs
05e8a0b0
AE
276 `(("glpk" ,glpk)
277 ("gnurl" ,gnurl)
1eb6bbd8
RW
278 ("gstreamer" ,gstreamer)
279 ("gst-plugins-base" ,gst-plugins-base)
05e8a0b0 280 ("gnutls" ,gnutls)
266b39fc
SHT
281 ("libextractor" ,libextractor)
282 ("libgcrypt" ,libgcrypt)
266b39fc 283 ("libidn" ,libidn)
6adda006 284 ("libmicrohttpd" ,libmicrohttpd) ; hostlist, pt, contrib, and more
3246cc91 285 ("libltdl" ,libltdl)
6adda006 286 ("libunistring" ,libunistring) ; fs and more
287 ("openssl" ,openssl) ; transport, certificate creation, contribs
288 ("opus" ,opus) ; gnunet-conversation
289 ("pulseaudio" ,pulseaudio) ; conversation
290 ("sqlite" ,sqlite) ; sqlite bindings, *store
291 ("zlib" ,zlib)
292 ("perl" ,perl) ; doxygen and more
293 ("jansson" ,jansson) ; identity, taler (external), gnunet-json, gns
294 ("nss" ,nss) ; gns
295 ("gmp" ,gmp) ; util
296 ("bluez" ,bluez) ; gnunet-transport
297 ("glib" ,glib)
298 ("libogg" ,libogg) ; gnunet-conversation
299 ("python-2" ,python-2))) ; tests, gnunet-qr
266b39fc 300 (native-inputs
6adda006 301 `(("pkg-config" ,pkg-config)))
266b39fc 302 (arguments
972f4e50
SB
303 '(#:configure-flags
304 (list (string-append "--with-nssdir=" %output "/lib"))
305 #:parallel-tests? #f
f944fbf1
AE
306 ;; test_gnunet_service_arm fails; reported upstream
307 #:tests? #f
308 #:phases
90d8ef6b 309 (modify-phases %standard-phases
05e8a0b0 310 ;; swap check and install phases and set paths to installed binaries
90d8ef6b
EF
311 (add-before 'check 'set-path-for-check
312 (lambda* (#:key outputs #:allow-other-keys)
313 (let ((out (assoc-ref outputs "out")))
314 (setenv "GNUNET_PREFIX" (string-append out "/lib"))
315 (setenv "PATH" (string-append (getenv "PATH") ":" out "/bin")))
316 #t))
317 (add-after 'install 'check
318 (assoc-ref %standard-phases 'check))
319 (delete 'check))))
574e86f9 320 (synopsis "Secure, decentralized, peer-to-peer networking framework")
266b39fc 321 (description
a3947cb1
LC
322 "GNUnet is a framework for secure peer-to-peer networking. The
323high-level goal is to provide a strong foundation of free software for a
324global, distributed network that provides security and privacy. GNUnet in
325that sense aims to replace the current internet protocol stack. Along with
326an application for secure publication of files, it has grown to include all
327kinds of basic applications for the foundation of a GNU internet.")
266b39fc
SHT
328 (license license:gpl3+)
329 (home-page "https://gnunet.org/")))
59698c2c
LC
330
331(define-public guile-gnunet ;GSoC 2015!
698bd297 332 (let ((commit "383eac2aab175d8d9ea5315c2f1c8a5055c76a52"))
59698c2c
LC
333 (package
334 (name "guile-gnunet")
698bd297 335 (version (string-append "0.0." (string-take commit 7)))
59698c2c
LC
336 (source (origin
337 (method git-fetch)
338 (uri (git-reference
5f13bf09 339 (url "https://git.savannah.gnu.org/git/guix/gnunet.git/")
59698c2c 340 (commit commit)))
821f4dc2 341 (file-name (string-append name "-" version "-checkout"))
59698c2c
LC
342 (sha256
343 (base32
344 "0k6mn28isjlxrnvbnblab3nh2xqx1b7san8k98kc35ap9lq0iz8w"))))
345 (build-system gnu-build-system)
346 (arguments
347 '(#:phases (modify-phases %standard-phases
d10092b8 348 (add-after 'unpack 'bootstrap
59698c2c
LC
349 (lambda _
350 (zero? (system* "autoreconf" "-vfi")))))))
351 (native-inputs `(("pkg-config" ,pkg-config)
352 ("autoconf" ,(autoconf-wrapper))
353 ("automake" ,automake)))
354 (inputs `(("guile" ,guile-2.0)
355 ("gnunet" ,gnunet)))
356 (synopsis "Guile bindings for GNUnet services")
357 (description
358 "This package provides Guile bindings to the client libraries of various
359GNUnet services, including the @dfn{identity} and @dfn{file sharing}
360services.")
cc04b099 361 (home-page "https://gnu.org/software/guix")
59698c2c 362 (license license:gpl3+))))
3ccdd430 363
364;; FIXME: "gnunet-setup" segfaults under certain conditions and "gnunet-gtk"
365;; does not seem to be fully functional. This has been reported upstream:
366;; http://lists.gnu.org/archive/html/gnunet-developers/2016-02/msg00004.html
367(define-public gnunet-gtk
368 (package (inherit gnunet)
369 (name "gnunet-gtk")
370 (version (package-version gnunet))
371 (source (origin
372 (method url-fetch)
373 (uri (string-append "mirror://gnu/gnunet/gnunet-gtk-"
374 version ".tar.gz"))
375 (sha256
376 (base32
377 "1p38k1s6a2fmcfc9a7cf1zrdycm9h06kqdyand4s3k500nj6mb4g"))))
378 (arguments
379 `(#:configure-flags
d8bc4729 380 (list "--with-libunique"
9b12bc70 381 "--with-qrencode"
382 (string-append "--with-gnunet="
383 (assoc-ref %build-inputs "gnunet")))))
3ccdd430 384 (inputs
385 `(("gnunet" ,gnunet)
386 ("libgcrypt" ,libgcrypt)
387 ("gtk+" ,gtk+)
388 ("libextractor" ,libextractor)
389 ("glade3" ,glade3)
d8bc4729 390 ("qrencode" ,qrencode)
391 ("libunique" ,libunique)))
3ccdd430 392 (native-inputs
393 `(("pkg-config" ,pkg-config)
394 ("libglade" ,libglade)))
395 (synopsis "Graphical front-end tools for GNUnet")))