d889e602edbf078bd10abbd90227823a9cad23d3
[jackhill/guix/guix.git] / gnu / packages / xml.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org>
5 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
6 ;;; Copyright © 2015, 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015, 2016, 2017 Mark H Weaver <mhw@netris.org>
8 ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2015 Raimon Grau <raimonster@gmail.com>
10 ;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org>
11 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
12 ;;; Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com>
13 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
14 ;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net>
15 ;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
16 ;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com>
17 ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com>
18 ;;; Copyright © 2017 Gregor Giesen <giesen@zaehlwerk.net>
19 ;;; Copyright © 2017 Alex Vong <alexvong1995@gmail.com>
20 ;;;
21 ;;; This file is part of GNU Guix.
22 ;;;
23 ;;; GNU Guix is free software; you can redistribute it and/or modify it
24 ;;; under the terms of the GNU General Public License as published by
25 ;;; the Free Software Foundation; either version 3 of the License, or (at
26 ;;; your option) any later version.
27 ;;;
28 ;;; GNU Guix is distributed in the hope that it will be useful, but
29 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
30 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
31 ;;; GNU General Public License for more details.
32 ;;;
33 ;;; You should have received a copy of the GNU General Public License
34 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
35
36 (define-module (gnu packages xml)
37 #:use-module (gnu packages)
38 #:use-module (gnu packages autotools)
39 #:use-module (gnu packages compression)
40 #:use-module (gnu packages gnupg)
41 #:use-module (gnu packages perl)
42 #:use-module (gnu packages python)
43 #:use-module (gnu packages tls)
44 #:use-module (gnu packages web)
45 #:use-module ((guix licenses) #:prefix license:)
46 #:use-module (guix packages)
47 #:use-module (guix download)
48 #:use-module (guix build-system ant)
49 #:use-module (guix build-system cmake)
50 #:use-module (guix build-system gnu)
51 #:use-module (guix build-system perl)
52 #:use-module (guix build-system python)
53 #:use-module (gnu packages linux)
54 #:use-module (gnu packages pkg-config))
55
56 (define-public expat
57 (package
58 (name "expat")
59 (version "2.2.1")
60 (replacement expat-2.2.2)
61 (source (origin
62 (method url-fetch)
63 (uri (string-append "mirror://sourceforge/expat/expat/"
64 version "/expat-" version ".tar.bz2"))
65 (sha256
66 (base32
67 "11c8jy1wvllvlk7xdc5cm8hdhg0hvs8j0aqy6s702an8wkdcls0q"))))
68 (build-system gnu-build-system)
69 (home-page "http://www.libexpat.org/")
70 (synopsis "Stream-oriented XML parser library written in C")
71 (description
72 "Expat is an XML parser library written in C. It is a
73 stream-oriented parser in which an application registers handlers for
74 things the parser might find in the XML document (like start tags).")
75 (license license:expat)))
76
77 (define expat-2.2.2 ; Fixes CVE-2017-9233, CVE-2016-9063 and other issues.
78 (package
79 (inherit expat)
80 (version "2.2.2")
81 (source (origin
82 (method url-fetch)
83 (uri (string-append "mirror://sourceforge/expat/expat/"
84 version "/expat-" version ".tar.bz2"))
85 (sha256
86 (base32
87 "0ik0r39ala9c6hj4kxrk933klgwkzlkbrfhvhaykx8l1rwgr2xj3"))))))
88
89 (define-public libebml
90 (package
91 (name "libebml")
92 (version "1.3.4")
93 (source
94 (origin
95 (method url-fetch)
96 (uri (string-append "https://dl.matroska.org/downloads/"
97 name "/" name "-" version ".tar.bz2"))
98 (sha256
99 (base32
100 "11zka6z9ncywyjr1gfm5cnii33ln7y3w6s86kiacchip2g7kw3f5"))))
101 (build-system gnu-build-system)
102 (home-page "https://www.matroska.org")
103 (synopsis "C++ libary to parse EBML files")
104 (description "libebml is a C++ library to read and write EBML (Extensible
105 Binary Meta Language) files. EBML was designed to be a simplified binary
106 extension of XML for the purpose of storing and manipulating data in a
107 hierarchical form with variable field lengths.")
108 (license license:lgpl2.1)))
109
110 (define-public libxml2
111 (package
112 (name "libxml2")
113 (version "2.9.4")
114 (replacement libxml2/fixed)
115 (source (origin
116 (method url-fetch)
117 (uri (string-append "ftp://xmlsoft.org/libxml2/libxml2-"
118 version ".tar.gz"))
119 (patches (search-patches "libxml2-CVE-2016-4658.patch"
120 "libxml2-CVE-2016-5131.patch"))
121 (sha256
122 (base32
123 "0g336cr0bw6dax1q48bblphmchgihx9p1pjmxdnrd6sh3qci3fgz"))))
124 (build-system gnu-build-system)
125 (home-page "http://www.xmlsoft.org/")
126 (synopsis "C parser for XML")
127 (propagated-inputs `(("zlib" ,zlib))) ; libxml2.la says '-lz'.
128 (native-inputs `(("perl" ,perl)))
129 ;; $XML_CATALOG_FILES lists 'catalog.xml' files found in under the 'xml'
130 ;; sub-directory of any given package.
131 (native-search-paths (list (search-path-specification
132 (variable "XML_CATALOG_FILES")
133 (separator " ")
134 (files '("xml"))
135 (file-pattern "^catalog\\.xml$")
136 (file-type 'regular))))
137 (search-paths native-search-paths)
138 (description
139 "Libxml2 is the XML C parser and toolkit developed for the Gnome
140 project (but it is usable outside of the Gnome platform).")
141 (license license:x11)))
142
143 (define libxml2/fixed
144 (package
145 (inherit libxml2)
146 (source
147 (origin
148 (inherit (package-source libxml2))
149 (patches
150 (append (origin-patches (package-source libxml2))
151 (search-patches "libxml2-CVE-2017-0663.patch"
152 "libxml2-CVE-2017-7375.patch"
153 "libxml2-CVE-2017-7376.patch"
154 "libxml2-CVE-2017-9047+CVE-2017-9048.patch"
155 "libxml2-CVE-2017-9049+CVE-2017-9050.patch")))))))
156
157 (define-public python-libxml2
158 (package (inherit libxml2)
159 (name "python-libxml2")
160 (build-system python-build-system)
161 (arguments
162 `(;; XXX: Tests are specified in 'Makefile.am', but not in 'setup.py'.
163 #:tests? #f
164 #:phases
165 (modify-phases %standard-phases
166 (add-before
167 'build 'configure
168 (lambda* (#:key inputs #:allow-other-keys)
169 (chdir "python")
170 (let ((glibc (assoc-ref inputs ,(if (%current-target-system)
171 "cross-libc" "libc")))
172 (libxml2 (assoc-ref inputs "libxml2")))
173 (substitute* "setup.py"
174 ;; For 'libxml2/libxml/tree.h'.
175 (("ROOT = r'/usr'")
176 (format #f "ROOT = r'~a'" libxml2))
177 ;; For 'iconv.h'.
178 (("/opt/include")
179 (string-append glibc "/include")))))))))
180 (inputs `(("libxml2" ,libxml2)))
181 (synopsis "Python bindings for the libxml2 library")))
182
183 (define-public python2-libxml2
184 (package-with-python2 python-libxml2))
185
186 (define-public libxslt
187 (package
188 (name "libxslt")
189 (version "1.1.29")
190 (source (origin
191 (method url-fetch)
192 (uri (string-append "ftp://xmlsoft.org/libxslt/libxslt-"
193 version ".tar.gz"))
194 (patches (search-patches "libxslt-CVE-2016-4738.patch"))
195 (sha256
196 (base32
197 "1klh81xbm9ppzgqk339097i39b7fnpmlj8lzn8bpczl3aww6x5xm"))
198 (patches (search-patches "libxslt-generated-ids.patch"))))
199 (build-system gnu-build-system)
200 (home-page "http://xmlsoft.org/XSLT/index.html")
201 (synopsis "C library for applying XSLT stylesheets to XML documents")
202 (inputs `(("libgcrypt" ,libgcrypt)
203 ("libxml2" ,libxml2)
204 ("python" ,python-minimal-wrapper)
205 ("zlib" ,zlib)))
206 (description
207 "Libxslt is an XSLT C library developed for the GNOME project. It is
208 based on libxml for XML parsing, tree manipulation and XPath support.")
209 (license license:x11)))
210
211 (define-public perl-graph-readwrite
212 (package
213 (name "perl-graph-readwrite")
214 (version "2.09")
215 (source
216 (origin
217 (method url-fetch)
218 (uri (string-append
219 "mirror://cpan/authors/id/N/NE/NEILB/Graph-ReadWrite-"
220 version
221 ".tar.gz"))
222 (sha256
223 (base32
224 "0jlsg64pmy6ka5q5gy851nnyfgjzvhyxc576bhns3vi2x5ng07mh"))))
225 (build-system perl-build-system)
226 (propagated-inputs
227 `(("perl-graph" ,perl-graph)
228 ("perl-parse-yapp" ,perl-parse-yapp)
229 ("perl-xml-parser" ,perl-xml-parser)
230 ("perl-xml-writer" ,perl-xml-writer)))
231 (home-page "http://search.cpan.org/dist/Graph-ReadWrite")
232 (synopsis "Modules for reading and writing directed graphs")
233 (description "This is a collection of perl classes for reading and writing
234 directed graphs in a variety of file formats. The graphs are represented in
235 Perl using Jarkko Hietaniemi's @code{Graph} classes.
236
237 There are two base classes. @code{Graph::Reader} is the base class for classes
238 which read a graph file and create an instance of the Graph class.
239 @code{Graph::Writer} is the base class for classes which take an instance of
240 the @code{Graph} class and write it out in a specific file format.")
241 (license license:perl-license)))
242
243 (define-public perl-xml-atom
244 (package
245 (name "perl-xml-atom")
246 (version "0.42")
247 (source (origin
248 (method url-fetch)
249 (uri (string-append "mirror://cpan/authors/id/M/MI/MIYAGAWA/"
250 "XML-Atom-" version ".tar.gz"))
251 (sha256
252 (base32
253 "1wa8kfy1w4mg7kzxim4whyprkn48a2il6fap0b947zywknw4c6y6"))))
254 (build-system perl-build-system)
255 (arguments
256 `(#:phases
257 (modify-phases %standard-phases
258 (add-before 'check 'set-perl-search-path
259 (lambda _
260 (setenv "PERL5LIB"
261 (string-append (getcwd) ":"
262 (getenv "PERL5LIB")))
263 #t)))))
264 (native-inputs
265 `(("perl-datetime" ,perl-datetime)
266 ;; TODO package: perl-datetime-format-atom
267 ("perl-html-tagset" ,perl-html-tagset)
268 ("perl-module-build-tiny" ,perl-module-build-tiny)
269 ("perl-module-install" ,perl-module-install)
270 ("perl-xml-xpath" ,perl-xml-xpath)))
271 (inputs
272 `(("perl-class-data-inheritable" ,perl-class-data-inheritable)
273 ("perl-datetime" ,perl-datetime)
274 ("perl-datetime-timezone" ,perl-datetime-timezone)
275 ("perl-digest-sha1" ,perl-digest-sha1)
276 ("perl-libwww" ,perl-libwww)
277 ("perl-uri" ,perl-uri)
278 ("perl-xml-libxml" ,perl-xml-libxml)
279 ("perl-xml-xpath" ,perl-xml-xpath)))
280 (home-page "http://search.cpan.org/dist/XML-Atom")
281 (synopsis "Atom feed and API implementation")
282 (description
283 "Atom is a syndication, API, and archiving format for weblogs and other data.
284 @code{XML::Atom} implements the feed format as well as a client for the API.")
285 (license license:perl-license)))
286
287 (define-public perl-xml-descent
288 (package
289 (name "perl-xml-descent")
290 (version "1.04")
291 (source (origin
292 (method url-fetch)
293 (uri (string-append "mirror://cpan/authors/id/A/AN/ANDYA/"
294 "XML-Descent-" version ".tar.gz"))
295 (sha256
296 (base32
297 "0l5xmw2hd95ypppz3lyvp4sn02ccsikzjwacli3ydxfdz1bbh4d7"))))
298 (build-system perl-build-system)
299 (native-inputs
300 `(("perl-module-build" ,perl-module-build)))
301 (propagated-inputs
302 `(("perl-test-differences" ,perl-test-differences)
303 ("perl-xml-tokeparser" ,perl-xml-tokeparser)))
304 (home-page "http://search.cpan.org/dist/XML-Descent")
305 (synopsis "Recursive descent XML parsing")
306 (description
307 "The conventional models for parsing XML are either @dfn{DOM}
308 (a data structure representing the entire document tree is created) or
309 @dfn{SAX} (callbacks are issued for each element in the XML).
310
311 XML grammar is recursive - so it's nice to be able to write recursive
312 parsers for it. @code{XML::Descent} allows such parsers to be created.")
313 (license license:perl-license)))
314
315 (define-public perl-xml-parser
316 (package
317 (name "perl-xml-parser")
318 (version "2.44")
319 (source (origin
320 (method url-fetch)
321 (uri (string-append
322 "mirror://cpan/authors/id/T/TO/TODDR/XML-Parser-"
323 version ".tar.gz"))
324 (sha256
325 (base32
326 "05ij0g6bfn27iaggxf8nl5rhlwx6f6p6xmdav6rjcly3x5zd1s8s"))))
327 (build-system perl-build-system)
328 (arguments `(#:make-maker-flags
329 (let ((expat (assoc-ref %build-inputs "expat")))
330 (list (string-append "EXPATLIBPATH=" expat "/lib")
331 (string-append "EXPATINCPATH=" expat "/include")))))
332 (inputs `(("expat" ,expat)))
333 (license license:perl-license)
334 (synopsis "Perl bindings to the Expat XML parsing library")
335 (description
336 "This module provides ways to parse XML documents. It is built on top of
337 XML::Parser::Expat, which is a lower level interface to James Clark's expat
338 library. Each call to one of the parsing methods creates a new instance of
339 XML::Parser::Expat which is then used to parse the document. Expat options
340 may be provided when the XML::Parser object is created. These options are
341 then passed on to the Expat object on each parse call. They can also be given
342 as extra arguments to the parse methods, in which case they override options
343 given at XML::Parser creation time.")
344 (home-page "http://search.cpan.org/dist/XML-Parser")))
345
346 (define-public perl-xml-tokeparser
347 (package
348 (name "perl-xml-tokeparser")
349 (version "0.05")
350 (source (origin
351 (method url-fetch)
352 (uri (string-append "mirror://cpan/authors/id/P/PO/PODMASTER/"
353 "XML-TokeParser-" version ".tar.gz"))
354 (sha256
355 (base32
356 "1hnpwb3lh6cbgwvjjgqzcp6jm4mp612qn6ili38adc9nhkwv8fc5"))))
357 (build-system perl-build-system)
358 (propagated-inputs `(("perl-xml-parser" ,perl-xml-parser)))
359 (home-page "http://search.cpan.org/dist/XML-TokeParser")
360 (synopsis "Simplified interface to XML::Parser")
361 (description
362 "@code{XML::TokeParser} provides a procedural (\"pull mode\") interface
363 to @code{XML::Parser} in much the same way that Gisle Aas'
364 @code{HTML::TokeParser} provides a procedural interface to @code{HTML::Parser}.
365 @code{XML::TokeParser} splits its XML input up into \"tokens\", each
366 corresponding to an @code{XML::Parser} event.")
367 (license license:perl-license)))
368
369 (define-public perl-libxml
370 (package
371 (name "perl-libxml")
372 (version "0.08")
373 (source (origin
374 (method url-fetch)
375 (uri (string-append
376 "mirror://cpan/authors/id/K/KM/KMACLEOD/libxml-perl-"
377 version ".tar.gz"))
378 (sha256
379 (base32
380 "1jy9af0ljyzj7wakqli0437zb2vrbplqj4xhab7bfj2xgfdhawa5"))))
381 (build-system perl-build-system)
382 (propagated-inputs
383 `(("perl-xml-parser" ,perl-xml-parser)))
384 (license license:perl-license)
385 (synopsis "Perl SAX parser using XML::Parser")
386 (description
387 "XML::Parser::PerlSAX is a PerlSAX parser using the XML::Parser
388 module.")
389 (home-page "http://search.cpan.org/~kmacleod/libxml-perl/lib/XML/Parser/PerlSAX.pm")))
390
391 (define-public perl-xml-libxml
392 (package
393 (name "perl-xml-libxml")
394 (version "2.0128")
395 (source
396 (origin
397 (method url-fetch)
398 (uri (string-append "mirror://cpan/authors/id/S/SH/SHLOMIF/"
399 "XML-LibXML-" version ".tar.gz"))
400 (sha256
401 (base32
402 "0awgd2gjzy7kn38bqblsigikzl81xsi561phkz9f9b9v3x2vmrr6"))))
403 (build-system perl-build-system)
404 (propagated-inputs
405 `(("perl-xml-namespacesupport" ,perl-xml-namespacesupport)
406 ("perl-xml-sax" ,perl-xml-sax)))
407 (inputs
408 `(("libxml2" ,libxml2)))
409 (home-page "http://search.cpan.org/dist/XML-LibXML")
410 (synopsis "Perl interface to libxml2")
411 (description "This module implements a Perl interface to the libxml2
412 library which provides interfaces for parsing and manipulating XML files. This
413 module allows Perl programmers to make use of the highly capable validating
414 XML parser and the high performance DOM implementation.")
415 (license license:perl-license)))
416
417 (define-public perl-xml-libxml-simple
418 (package
419 (name "perl-xml-libxml-simple")
420 (version "0.97")
421 (source (origin
422 (method url-fetch)
423 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
424 "XML-LibXML-Simple-" version ".tar.gz"))
425 (sha256
426 (base32
427 "1g8nlk3zdz2cclxf7azvsb3jfxmvy6ml8wmj774k4qjqcsqmzk0w"))))
428 (build-system perl-build-system)
429 (propagated-inputs
430 `(("perl-file-slurp-tiny" ,perl-file-slurp-tiny)
431 ("perl-xml-libxml" ,perl-xml-libxml)))
432 (home-page "http://search.cpan.org/dist/XML-LibXML-Simple")
433 (synopsis "XML::LibXML based XML::Simple clone")
434 (description
435 "This package provides the same API as @code{XML::Simple} but is based on
436 @code{XML::LibXML}.")
437 (license license:perl-license)))
438
439 (define-public perl-xml-libxslt
440 (package
441 (name "perl-xml-libxslt")
442 (version "1.95")
443 (source
444 (origin
445 (method url-fetch)
446 (uri (string-append "mirror://cpan/authors/id/S/SH/SHLOMIF/"
447 "XML-LibXSLT-" version ".tar.gz"))
448 (sha256
449 (base32
450 "0dggycql18kfxzkb1kw3yc7gslxlrrgyyn2r2ygsylycb89j3jpi"))))
451 (build-system perl-build-system)
452 (inputs
453 `(("libxslt" ,libxslt)))
454 (propagated-inputs
455 `(("perl-xml-libxml" ,perl-xml-libxml)))
456 (home-page "http://search.cpan.org/dist/XML-LibXSLT")
457 (synopsis "Perl bindings to GNOME libxslt library")
458 (description "This Perl module is an interface to the GNOME project's
459 libxslt library.")
460 (license license:perl-license)))
461
462 (define-public perl-xml-namespacesupport
463 (package
464 (name "perl-xml-namespacesupport")
465 (version "1.12")
466 (source
467 (origin
468 (method url-fetch)
469 (uri (string-append "mirror://cpan/authors/id/P/PE/PERIGRIN/"
470 "XML-NamespaceSupport-" version ".tar.gz"))
471 (sha256
472 (base32
473 "1vz5pbi4lm5fhq2slrs2hlp6bnk29863abgjlcx43l4dky2rbsa7"))))
474 (build-system perl-build-system)
475 (home-page "http://search.cpan.org/dist/XML-NamespaceSupport")
476 (synopsis "XML namespace support class")
477 (description "This module offers a simple to process namespaced XML
478 names (unames) from within any application that may need them. It also helps
479 maintain a prefix to namespace URI map, and provides a number of basic
480 checks.")
481 (license license:perl-license)))
482
483 (define-public perl-xml-rss
484 (package
485 (name "perl-xml-rss")
486 (version "1.59")
487 (source (origin
488 (method url-fetch)
489 (uri (string-append "mirror://cpan/authors/id/S/SH/SHLOMIF/"
490 "XML-RSS-" version ".tar.gz"))
491 (sha256
492 (base32
493 "0v6vfizn2psy6av057kp7fv3z3y73s6b3w56jm3zr6hlq48llsx2"))))
494 (build-system perl-build-system)
495 (native-inputs
496 `(("perl-module-build" ,perl-module-build)
497 ("perl-test-manifest" ,perl-test-manifest)
498 ("perl-test-differences" ,perl-test-differences)
499 ("perl-test-pod" ,perl-test-pod)
500 ("perl-test-pod-coverage" ,perl-test-pod-coverage)))
501 ;; XXX: The test which uses this modules does not run, even when it is included
502 ;; it is ignored. ("perl-test-trailingspace" ,perl-test-trailingspace)
503 (inputs
504 `(("perl-datetime" ,perl-datetime)
505 ("perl-datetime-format-mail" ,perl-datetime-format-mail)
506 ("perl-datetime-format-w3cdtf" ,perl-datetime-format-w3cdtf)
507 ("perl-html-parser" ,perl-html-parser)
508 ("perl-xml-parser" ,perl-xml-parser)))
509 (home-page "http://search.cpan.org/dist/XML-RSS")
510 (synopsis "Creates and updates RSS files")
511 (description
512 "This module provides a basic framework for creating and maintaining
513 RDF Site Summary (RSS) files. This distribution also contains many examples
514 that allow you to generate HTML from an RSS, convert between 0.9, 0.91, and
515 1.0 version, and more.")
516 (license license:perl-license)))
517
518 (define-public perl-xml-sax
519 (package
520 (name "perl-xml-sax")
521 (version "0.99")
522 (source
523 (origin
524 (method url-fetch)
525 (uri (string-append "mirror://cpan/authors/id/G/GR/GRANTM/"
526 "XML-SAX-" version ".tar.gz"))
527 (sha256
528 (base32
529 "115dypb50w1l94y3iwihv5nkixbsv1cxiqkd93y4rk5n6s74pc1j"))))
530 (build-system perl-build-system)
531 (propagated-inputs
532 `(("perl-xml-namespacesupport" ,perl-xml-namespacesupport)
533 ("perl-xml-sax-base" ,perl-xml-sax-base)))
534 (arguments
535 `(#:phases (modify-phases %standard-phases
536 (add-before
537 'install 'augment-path
538 ;; The install target tries to load the newly-installed
539 ;; XML::SAX module, but can't find it, so we need to tell
540 ;; perl where to look.
541 (lambda* (#:key outputs #:allow-other-keys)
542 (setenv "PERL5LIB"
543 (string-append (getenv "PERL5LIB") ":"
544 (assoc-ref outputs "out")
545 "/lib/perl5/site_perl")))))))
546 (home-page "http://search.cpan.org/dist/XML-SAX")
547 (synopsis "Perl API for XML")
548 (description "XML::SAX consists of several framework classes for using and
549 building Perl SAX2 XML parsers, filters, and drivers.")
550 (license license:perl-license)))
551
552 (define-public perl-xml-sax-base
553 (package
554 (name "perl-xml-sax-base")
555 (version "1.08")
556 (source
557 (origin
558 (method url-fetch)
559 (uri (string-append "mirror://cpan/authors/id/G/GR/GRANTM/"
560 "XML-SAX-Base-" version ".tar.gz"))
561 (sha256
562 (base32
563 "17i161rq1ngjlk0c8vdkrkkc56y1pf51k1g54y28py0micqp0qk6"))))
564 (build-system perl-build-system)
565 (home-page "http://search.cpan.org/dist/XML-SAX-Base")
566 (synopsis "Base class for SAX Drivers and Filters")
567 (description "This module has a very simple task - to be a base class for
568 PerlSAX drivers and filters. It's default behaviour is to pass the input
569 directly to the output unchanged. It can be useful to use this module as a
570 base class so you don't have to, for example, implement the characters()
571 callback.")
572 (license license:perl-license)))
573
574 (define-public perl-xml-simple
575 (package
576 (name "perl-xml-simple")
577 (version "2.22")
578 (source (origin
579 (method url-fetch)
580 (uri (string-append
581 "mirror://cpan/authors/id/G/GR/GRANTM/XML-Simple-"
582 version ".tar.gz"))
583 (sha256
584 (base32
585 "0jgbk30jizafpl7078jhw1di1yh08gf8d85dsvjllr595vr0widr"))))
586 (build-system perl-build-system)
587 (propagated-inputs
588 `(("perl-xml-parser" ,perl-xml-parser)
589 ("perl-xml-sax" ,perl-xml-sax)))
590 (license license:perl-license)
591 (synopsis "Perl module for easy reading/writing of XML files")
592 (description
593 "The XML::Simple module provides a simple API layer on top of an
594 underlying XML parsing module (either XML::Parser or one of the SAX2
595 parser modules).")
596 (home-page "http://search.cpan.org/dist/XML-Simple")))
597
598 (define-public perl-xml-regexp
599 (package
600 (name "perl-xml-regexp")
601 (version "0.04")
602 (source (origin
603 (method url-fetch)
604 (uri (string-append
605 "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-RegExp-"
606 version ".tar.gz"))
607 (sha256
608 (base32
609 "0m7wj00a2kik7wj0azhs1zagwazqh3hlz4255n75q21nc04r06fz"))))
610 (build-system perl-build-system)
611 (inputs
612 `(("perl-xml-parser" ,perl-xml-parser)))
613 (license license:perl-license)
614 (synopsis "Perl regular expressions for XML tokens")
615 (description
616 "XML::RegExp contains regular expressions for the following XML tokens:
617 BaseChar, Ideographic, Letter, Digit, Extender, CombiningChar, NameChar,
618 EntityRef, CharRef, Reference, Name, NmToken, and AttValue.")
619 (home-page "http://search.cpan.org/~tjmather/XML-RegExp/lib/XML/RegExp.pm")))
620
621 (define-public perl-xml-dom
622 (package
623 (name "perl-xml-dom")
624 (version "1.46")
625 (source (origin
626 (method url-fetch)
627 (uri (string-append
628 "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-DOM-"
629 version ".tar.gz"))
630 (sha256
631 (base32
632 "0phpkc4li43m2g44hdcvyxzy9pymqwlqhh5hwp2xc0cv8l5lp8lb"))))
633 (build-system perl-build-system)
634 (propagated-inputs
635 `(("perl-libwww" ,perl-libwww)
636 ("perl-libxml" ,perl-libxml)
637 ("perl-xml-parser" ,perl-xml-parser)
638 ("perl-xml-regexp" ,perl-xml-regexp)))
639 (license license:perl-license)
640 (synopsis
641 "Perl module for building DOM Level 1 compliant document structures")
642 (description
643 "This module extends the XML::Parser module by Clark Cooper. The
644 XML::Parser module is built on top of XML::Parser::Expat, which is a lower
645 level interface to James Clark's expat library. XML::DOM::Parser is derived
646 from XML::Parser. It parses XML strings or files and builds a data structure
647 that conforms to the API of the Document Object Model.")
648 (home-page "http://search.cpan.org/~tjmather/XML-DOM-1.44/lib/XML/DOM.pm")))
649
650 (define-public perl-xml-compile-tester
651 (package
652 (name "perl-xml-compile-tester")
653 (version "0.90")
654 (source (origin
655 (method url-fetch)
656 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
657 "XML-Compile-Tester-" version ".tar.gz"))
658 (sha256
659 (base32
660 "1bcl8x8cyacqv9yjp97aq9qq85sy8wv78kd8c16yd9yw3by4cpp1"))))
661 (build-system perl-build-system)
662 (propagated-inputs
663 `(("perl-log-report" ,perl-log-report)
664 ("perl-test-deep" ,perl-test-deep)))
665 (home-page "http://search.cpan.org/dist/XML-Compile-Tester")
666 (synopsis "XML::Compile related regression testing")
667 (description
668 "The @code{XML::Compile} module suite has extensive regression testing.
669 This module provide functions which simplify writing tests for
670 @code{XML::Compile} related distributions.")
671 (license license:perl-license)))
672
673 (define-public perl-xml-compile
674 (package
675 (name "perl-xml-compile")
676 (version "1.54")
677 (source (origin
678 (method url-fetch)
679 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
680 "XML-Compile-" version ".tar.gz"))
681 (sha256
682 (base32
683 "1hp41960bpqxvv1samv9hc0ghhmvs3i16r4rfl9yp54lp6jhsr2c"))))
684 (build-system perl-build-system)
685 (propagated-inputs
686 `(("perl-log-report" ,perl-log-report)
687 ("perl-xml-compile-tester" ,perl-xml-compile-tester)
688 ("perl-xml-libxml" ,perl-xml-libxml)
689 ("perl-test-deep" ,perl-test-deep)))
690 (home-page "http://search.cpan.org/dist/XML-Compile")
691 (synopsis "Compilation-based XML processing")
692 (description
693 "@code{XML::Compile} can be used to translate a Perl data-structure into
694 XML or XML into a Perl data-structure, both directions under rigid control by
695 a schema.")
696 (license license:perl-license)))
697
698 (define-public perl-xml-compile-cache
699 (package
700 (name "perl-xml-compile-cache")
701 (version "1.05")
702 (source (origin
703 (method url-fetch)
704 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
705 "XML-Compile-Cache-" version ".tar.gz"))
706 (sha256
707 (base32
708 "0xbwlszhi9hg8sxm5ylglm2qvnb689i595p913awrj2g4mp9yfsw"))))
709 (build-system perl-build-system)
710 (propagated-inputs
711 `(("perl-log-report" ,perl-log-report)
712 ("perl-xml-compile" ,perl-xml-compile)
713 ("perl-xml-compile-tester" ,perl-xml-compile-tester)
714 ("perl-xml-libxml-simple" ,perl-xml-libxml-simple)))
715 (home-page "http://search.cpan.org/dist/XML-Compile-Cache")
716 (synopsis "Cache compiled XML translators")
717 (description
718 "This package provides methods to cache compiled XML translators.")
719 (license license:perl-license)))
720
721 (define-public perl-xml-compile-soap
722 (package
723 (name "perl-xml-compile-soap")
724 (version "3.21")
725 (source (origin
726 (method url-fetch)
727 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
728 "XML-Compile-SOAP-" version ".tar.gz"))
729 (sha256
730 (base32
731 "0rxidh7kjyhnw2y789bqbwccnp8n0m3xskn524y9c752s64qpjcz"))))
732 (build-system perl-build-system)
733 (propagated-inputs
734 `(("perl-file-slurp-tiny" ,perl-file-slurp-tiny)
735 ("perl-libwww" ,perl-libwww)
736 ("perl-log-report" ,perl-log-report)
737 ("perl-xml-compile" ,perl-xml-compile)
738 ("perl-xml-compile-cache" ,perl-xml-compile-cache)
739 ("perl-xml-compile-tester" ,perl-xml-compile-tester)))
740 (home-page "http://search.cpan.org/dist/XML-Compile-SOAP")
741 (synopsis "Base-class for SOAP implementations")
742 (description
743 "This module provides a class to handle the SOAP protocol. The first
744 implementation is @url{SOAP1.1,
745 http://www.w3.org/TR/2000/NOTE-SOAP-20000508/}, which is still most often
746 used.")
747 (license license:perl-license)))
748
749 (define-public perl-xml-compile-wsdl11
750 (package
751 (name "perl-xml-compile-wsdl11")
752 (version "3.06")
753 (source (origin
754 (method url-fetch)
755 (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
756 "XML-Compile-WSDL11-" version ".tar.gz"))
757 (sha256
758 (base32
759 "0vbq05cpynm3jj81fw1k4nsb3wv4zngi6blvi1jhdarmh2rfg1x2"))))
760 (build-system perl-build-system)
761 (propagated-inputs
762 `(("perl-log-report" ,perl-log-report)
763 ("perl-xml-compile" ,perl-xml-compile)
764 ("perl-xml-compile-cache" ,perl-xml-compile-cache)
765 ("perl-xml-compile-soap" ,perl-xml-compile-soap)))
766 (home-page "http://search.cpan.org/dist/XML-Compile-WSDL11")
767 (synopsis "Create SOAP messages defined by WSDL 1.1")
768 (description
769 "This module understands WSDL version 1.1. A WSDL file defines a set of
770 messages to be send and received over SOAP connections. This involves
771 encoding of the message to be send into XML, sending the message to the
772 server, collect the answer, and finally decoding the XML to Perl.")
773 (license license:perl-license)))
774
775 (define-public perl-xml-feed
776 (package
777 (name "perl-xml-feed")
778 (version "0.53")
779 (source (origin
780 (method url-fetch)
781 (uri (string-append "mirror://cpan/authors/id/D/DA/DAVECROSS/"
782 "XML-Feed-" version ".tar.gz"))
783 (sha256
784 (base32
785 "07b165g6wk8kqwpl49r3n0kag6p2nrkyp3ch0h8qyxb6nrnkkq7c"))))
786 (build-system perl-build-system)
787 (arguments
788 `(#:tests? #f)) ; Tests require internet connection
789 (native-inputs
790 `(("perl-module-build" ,perl-module-build)
791 ("perl-uri" ,perl-uri)
792 ("perl-class-data-inheritable" ,perl-class-data-inheritable)))
793 (inputs
794 `(("perl-class-errorhandler" ,perl-class-errorhandler)
795 ("perl-datetime" ,perl-datetime)
796 ("perl-datetime-format-mail" ,perl-datetime-format-mail)
797 ("perl-datetime-format-w3cdtf" ,perl-datetime-format-w3cdtf)
798 ("perl-feed-find" ,perl-feed-find)
799 ("perl-html-parser" ,perl-html-parser)
800 ("perl-libwww-perl" ,perl-libwww)
801 ("perl-module-pluggable" ,perl-module-pluggable)
802 ("perl-uri-fetch" ,perl-uri-fetch)
803 ("perl-xml-atom" ,perl-xml-atom)
804 ("perl-xml-libxml" ,perl-xml-libxml)
805 ("perl-xml-rss" ,perl-xml-rss)))
806 (home-page "http://search.cpan.org/dist/XML-Feed")
807 (synopsis "XML Syndication Feed Support")
808 (description "@code{XML::Feed} is a syndication feed parser for both RSS and
809 Atom feeds. It also implements feed auto-discovery for finding feeds, given a URI.
810 @code{XML::Feed} supports the following syndication feed formats:
811 RSS 0.91, RSS 1.0, RSS 2.0, Atom")
812 (license license:perl-license)))
813
814 (define-public perl-xml-xpath
815 (package
816 (name "perl-xml-xpath")
817 (version "1.40")
818 (source (origin
819 (method url-fetch)
820 (uri (string-append "mirror://cpan/authors/id/M/MA/MANWAR/"
821 "XML-XPath-" version ".tar.gz"))
822 (sha256
823 (base32
824 "07pa0bl42jka8mj7jshjynx8vpfh8b4cdyiv4zlkqvkqz98nzxib"))))
825 (build-system perl-build-system)
826 (native-inputs
827 `(("perl-path-tiny" ,perl-path-tiny)))
828 (inputs
829 `(("perl-xml-parser" ,perl-xml-parser)))
830 (home-page "http://search.cpan.org/dist/XML-XPath")
831 (synopsis "Parse and evaluate XPath statements")
832 (description
833 "This module aims to comply exactly to the @url{XPath specification,
834 https://www.w3.org/TR/xpath} and yet allow extensions to be added in
835 the form of functions.")
836 (license license:perl-license)))
837
838 (define-public pugixml
839 (package
840 (name "pugixml")
841 (version "1.8.1")
842 (source
843 (origin
844 (method url-fetch)
845 (uri (string-append "https://github.com/zeux/pugixml/releases/download/v"
846 version "/pugixml-" version ".tar.gz"))
847 (sha256
848 (base32
849 "0fcgggry5x5bn0zhb09ij9hb0p45nb0sv0d9fw3cm1cf62hp9n80"))))
850 (build-system cmake-build-system)
851 (arguments
852 `(#:configure-flags '("-DCMAKE_CXX_FLAGS=-shared -fPIC"
853 "-DCMAKE_C_FLAGS=-shared -fPIC")
854 #:tests? #f)) ; no tests
855 (home-page "http://pugixml.org")
856 (synopsis "Light-weight, simple and fast XML parser for C++ with XPath support")
857 (description
858 "pugixml is a C++ XML processing library, which consists of a DOM-like
859 interface with rich traversal/modification capabilities, a fast XML parser
860 which constructs the DOM tree from an XML file/buffer, and an XPath 1.0
861 implementation for complex data-driven tree queries. Full Unicode support is
862 also available, with Unicode interface variants and conversions between
863 different Unicode encodings which happen automatically during
864 parsing/saving.")
865 (license license:expat)))
866
867 (define-public python-pyxb
868 (package
869 (name "python-pyxb")
870 (version "1.2.6")
871 (source (origin
872 (method url-fetch)
873 (uri (pypi-uri "PyXB" version))
874 (sha256
875 (base32
876 "1d17pyixbfvjyi2lb0cfp0ch8wwdf44mmg3r5pwqhyyqs66z601a"))))
877 (build-system python-build-system)
878 (home-page "http://pyxb.sourceforge.net/")
879 (synopsis "Python XML Schema Bindings")
880 (description
881 "PyXB (\"pixbee\") is a pure Python package that generates Python source
882 code for classes that correspond to data structures defined by XMLSchema.")
883 (license (list license:asl2.0 ; Most files.
884 license:expat ; pyxb/utils/six.py
885 license:gpl2 ; bundled jquery in doc is dual MIT/GPL2
886 license:psfl)))) ; pyxb/utils/activestate.py
887
888 (define-public python2-pyxb
889 (package-with-python2 python-pyxb))
890
891 (define-public xmlto
892 (package
893 (name "xmlto")
894 (version "0.0.28")
895 (source
896 (origin
897 (method url-fetch)
898 ;; The old source on fedorahosted.org is offline permanently:
899 ;; <https://bugs.gnu.org/25989>
900 (uri (string-append "mirror://debian/pool/main/x/xmlto/"
901 "xmlto_" version ".orig.tar.bz2"))
902 (file-name (string-append name "-" version ".tar.bz2"))
903 (sha256
904 (base32
905 "0xhj8b2pwp4vhl9y16v3dpxpsakkflfamr191mprzsspg4xdyc0i"))))
906 (build-system gnu-build-system)
907 (arguments
908 ;; Make sure the reference to util-linux's 'getopt' is kept in 'xmlto'.
909 '(#:configure-flags (list (string-append "GETOPT="
910 (assoc-ref %build-inputs
911 "util-linux")
912 "/bin/getopt"))))
913 (inputs
914 `(("util-linux" ,util-linux) ; for 'getopt'
915 ("libxml2" ,libxml2) ; for 'xmllint'
916 ("libxslt" ,libxslt))) ; for 'xsltproc'
917 (home-page "http://cyberelk.net/tim/software/xmlto/")
918 (synopsis "Front-end to an XSL toolchain")
919 (description
920 "Xmlto is a front-end to an XSL toolchain. It chooses an appropriate
921 stylesheet for the conversion you want and applies it using an external
922 XSL-T processor. It also performs any necessary post-processing.")
923 (license license:gpl2+)))
924
925 (define-public xmlsec
926 (package
927 (name "xmlsec")
928 (version "1.2.20")
929 (source (origin
930 (method url-fetch)
931 (uri (string-append "https://www.aleksey.com/xmlsec/download/"
932 name "1-" version ".tar.gz"))
933 (sha256
934 (base32
935 "01bkbv2y3x8d1sf4dcln1x3y2jyj391s3208d9a2ndhglly5j89j"))))
936 (build-system gnu-build-system)
937 (propagated-inputs ; according to xmlsec1.pc
938 `(("libxml2" ,libxml2)
939 ("libxslt" ,libxslt)))
940 (inputs
941 `(("gnutls" ,gnutls)
942 ("libgcrypt" ,libgcrypt)
943 ("libltdl" ,libltdl)))
944 (native-inputs
945 `(("pkg-config" ,pkg-config)))
946 (home-page "http://www.libexpat.org/")
947 (synopsis "XML Security Library")
948 (description
949 "The XML Security Library is a C library based on Libxml2. It
950 supports XML security standards such as XML Signature, XML Encryption,
951 Canonical XML (part of Libxml2) and Exclusive Canonical XML (part of
952 Libxml2).")
953 (license (license:x11-style "file://COPYING"
954 "See 'COPYING' in the distribution."))))
955
956 (define-public minixml
957 (package
958 (name "minixml")
959 (version "2.10")
960 (source (origin
961 (method url-fetch)
962 (uri (string-append "https://github.com/michaelrsweet/mxml/"
963 "releases/download/release-" version
964 "/mxml-" version ".tar.gz"))
965 (sha256
966 (base32
967 "14bqfq4lymhb31snz6wsvzhlavy0573v1nki1lbngiyxcj5zazr6"))))
968 (build-system gnu-build-system)
969 (arguments
970 `(#:tests? #f)) ;no "check" target
971 (home-page "https://michaelrsweet.github.io/mxml")
972 (synopsis "Small XML parsing library")
973 (description
974 "Mini-XML is a small C library to read and write XML files and strings in
975 UTF-8 and UTF-16 encoding.")
976 ;; LGPL 2.0+ with additional exceptions for static linking
977 (license license:lgpl2.0+)))
978
979 ;; TinyXML is an unmaintained piece of software, so the patches and build
980 ;; system massaging have no upstream potential.
981 (define-public tinyxml
982 (package
983 (name "tinyxml")
984 (version "2.6.2")
985 (source (origin
986 (method url-fetch)
987 (uri (string-append "mirror://sourceforge/tinyxml/tinyxml/"
988 version "/tinyxml_"
989 (string-join (string-split version #\.) "_")
990 ".tar.gz"))
991 (sha256
992 (base32
993 "14smciid19lvkxqznfig77jxn5s4iq3jpb47vh5a6zcaqp7gvg8m"))
994 (patches (search-patches "tinyxml-use-stl.patch"))))
995 (build-system gnu-build-system)
996 ;; This library is missing *a lot* of the steps to make it usable, so we
997 ;; have to add them here, like every other distro must do.
998 (arguments
999 `(#:phases
1000 (modify-phases %standard-phases
1001 (delete 'configure)
1002 (add-after 'build 'build-shared-library
1003 (lambda _
1004 (zero? (system* "g++" "-Wall" "-O2" "-shared" "-fpic"
1005 "tinyxml.cpp" "tinyxmlerror.cpp"
1006 "tinyxmlparser.cpp" "tinystr.cpp"
1007 "-o" "libtinyxml.so"))))
1008 (replace 'check
1009 (lambda _ (zero? (system "./xmltest"))))
1010 (replace 'install
1011 (lambda* (#:key outputs #:allow-other-keys)
1012 (let* ((out (assoc-ref outputs "out"))
1013 (include (string-append out "/include"))
1014 (lib (string-append out "/lib"))
1015 (pkgconfig (string-append out "/lib/pkgconfig"))
1016 (doc (string-append out "/share/doc")))
1017 ;; Install libs and headers.
1018 (install-file "libtinyxml.so" lib)
1019 (install-file "tinystr.h" include)
1020 (install-file "tinyxml.h" include)
1021 ;; Generate and install pkg-config file.
1022 (mkdir-p pkgconfig)
1023 ;; Software such as Kodi expect this file to be present, but
1024 ;; it's not provided in the source code.
1025 (call-with-output-file (string-append pkgconfig "/tinyxml.pc")
1026 (lambda (port)
1027 (format port "prefix=~a
1028 exec_prefix=${prefix}
1029 libdir=${exec_prefix}/lib
1030 includedir=${prefix}/include
1031
1032 Name: TinyXML
1033 Description: A simple, small, C++ XML parser
1034 Version: ~a
1035 Libs: -L${libdir} -ltinyxml
1036 Cflags: -I${includedir}
1037 "
1038 out ,version)))
1039 ;; Install docs.
1040 (mkdir-p doc)
1041 (copy-recursively "docs" (string-append doc "tinyxml"))
1042 #t))))))
1043 (synopsis "Small XML parser for C++")
1044 (description "TinyXML is a small and simple XML parsing library for the
1045 C++ programming language.")
1046 (home-page "http://www.grinninglizard.com/tinyxml/index.html")
1047 (license license:zlib)))
1048
1049 (define-public tinyxml2
1050 (package
1051 (name "tinyxml2")
1052 (version "4.0.1")
1053 (source
1054 (origin
1055 (method url-fetch)
1056 (uri (string-append "https://github.com/leethomason/tinyxml2/archive/"
1057 version ".tar.gz"))
1058 (sha256
1059 (base32
1060 "083z4r4khcndxi9k840lcr48sqxvar4gpsnf749xfdn1bkr8xcql"))))
1061 (build-system cmake-build-system)
1062 (arguments
1063 `(#:tests? #f)) ; no tests
1064 (synopsis "Small XML parser for C++")
1065 (description "TinyXML2 is a small and simple XML parsing library for the
1066 C++ programming language.")
1067 (home-page "http://www.grinninglizard.com/tinyxml2/")
1068 (license license:zlib)))
1069
1070 (define-public xmlstarlet
1071 (package
1072 (name "xmlstarlet")
1073 (version "1.6.1")
1074 (source
1075 (origin
1076 (method url-fetch)
1077 (uri (string-append "mirror://sourceforge/xmlstar/xmlstarlet/"
1078 version "/xmlstarlet-" version ".tar.gz"))
1079 (sha256
1080 (base32
1081 "1jp737nvfcf6wyb54fla868yrr39kcbijijmjpyk4lrpyg23in0m"))))
1082 (build-system gnu-build-system)
1083 (arguments
1084 '(#:phases
1085 (modify-phases %standard-phases
1086 (add-before 'check 'drop-failing-tests
1087 (lambda _
1088 ;; FIXME: Why are these tests failing.
1089 (substitute* "Makefile"
1090 (("^examples/schema1\\\\") "\\")
1091 (("^examples/valid1\\\\") "\\"))
1092 #t)))))
1093 (inputs
1094 `(("libxslt" ,libxslt)
1095 ("libxml2" ,libxml2)))
1096 (home-page "http://xmlstar.sourceforge.net/")
1097 (synopsis "Command line XML toolkit")
1098 (description "XMLStarlet is a set of command line utilities which can be
1099 used to transform, query, validate, and edit XML documents. XPath is used to
1100 match and extract data, and elements can be added, deleted or modified using
1101 XSLT and EXSLT.")
1102 (license license:x11)))
1103
1104 (define-public xlsx2csv
1105 (package
1106 (name "xlsx2csv")
1107 (version "0.7.2")
1108 (source (origin
1109 (method url-fetch)
1110 (uri (string-append
1111 "https://github.com/dilshod/"
1112 name "/archive/release/" version ".tar.gz"))
1113 (file-name (string-append name "-" version ".tar.gz"))
1114 (sha256
1115 (base32
1116 "1gpn6kaa7l1ai8c9zx2j3acf04bvxq79pni8jjfjrk01smjbyyql"))))
1117 (build-system python-build-system)
1118 (arguments
1119 `(#:python ,python-2 ; Use python-2 for the test script.
1120 #:phases
1121 (modify-phases %standard-phases
1122 (replace 'check
1123 (lambda _
1124 (substitute* "test/run"
1125 ;; Run tests with `python' only
1126 (("^(PYTHON_VERSIONS = ).*" all m) (string-append m "['']")))
1127 (zero? (system* "test/run")))))))
1128 (home-page "https://github.com/dilshod/xlsx2csv")
1129 (synopsis "XLSX to CSV converter")
1130 (description
1131 "Xlsx2csv is a program to convert Microsoft Excel 2007 XML (XLSX and
1132 XLSM) format spreadsheets into plaintext @dfn{comma separated values} (CSV)
1133 files. It is designed to be fast and to handle large input files.")
1134 (license license:gpl2+)))
1135
1136 (define-public python-defusedxml
1137 (package
1138 (name "python-defusedxml")
1139 (version "0.4.1")
1140 (source
1141 (origin
1142 (method url-fetch)
1143 (uri (pypi-uri "defusedxml" version))
1144 (sha256
1145 (base32
1146 "0y147zy3jqmk6ly7fbhqmzn1hf41xcb53f2vcc3m8x4ba5d1smfd"))))
1147 (build-system python-build-system)
1148 (home-page "https://bitbucket.org/tiran/defusedxml")
1149 (synopsis "XML bomb protection for Python stdlib modules")
1150 (description
1151 "Defusedxml provides XML bomb protection for Python stdlib modules.")
1152 (license license:psfl)))
1153
1154 (define-public python2-defusedxml
1155 (package-with-python2 python-defusedxml))
1156
1157 (define-public libxls
1158 (package
1159 (name "libxls")
1160 (version "1.4.0")
1161 (source (origin
1162 (method url-fetch)
1163 (uri (string-append "https://sourceforge.net/projects/"
1164 name "/files/" name "-"
1165 version ".zip"))
1166 (sha256
1167 (base32
1168 "1g8ds7wbhsa4hdcn77xc2c0l3vvz5bx2hx9ng9c9n7aii92ymfnk"))))
1169 (build-system gnu-build-system)
1170 (arguments
1171 `(#:phases
1172 (modify-phases %standard-phases
1173 ;; Bootstrapping is required in order to fix the test driver script.
1174 (add-after 'unpack 'bootstrap
1175 (lambda _
1176 (zero? (system* "bash" "bootstrap")))))))
1177 (native-inputs
1178 `(("unzip" ,unzip)
1179 ("autoconf" ,autoconf)
1180 ("automake" ,automake)
1181 ("libtool" ,libtool)))
1182 (home-page "http://libxls.sourceforge.net/")
1183 (synopsis "Read Excel files")
1184 (description
1185 "libxls is a C library which can read Excel (xls) files since Excel 97 (the BIFF8 format).
1186 libxls cannot write Excel files.")
1187 (license license:bsd-2)))
1188
1189 (define-public freexl
1190 (package
1191 (name "freexl")
1192 (version "1.0.4")
1193 (source (origin
1194 (method url-fetch)
1195 (uri (string-append "http://www.gaia-gis.it/gaia-sins/"
1196 name "-" version ".tar.gz"))
1197 (sha256
1198 (base32
1199 "09bwzqjc41cc8qw8qkw9wq58rg9nax8r3fg19iny5vmw1c0z23sh"))))
1200 (build-system gnu-build-system)
1201 (home-page "https://www.gaia-gis.it/fossil/freexl/index")
1202 (synopsis "Read Excel files")
1203 (description
1204 "FreeXL is a C library to extract valid data from within an Excel (.xls)
1205 spreadsheet.")
1206 ;; Any of these licenses may be picked.
1207 (license (list license:gpl2+
1208 license:lgpl2.1+
1209 license:mpl1.1))))
1210
1211 (define-public xerces-c
1212 (package
1213 (name "xerces-c")
1214 (version "3.1.4")
1215 (source (origin
1216 (method url-fetch)
1217 (uri (string-append "mirror://apache/xerces/c/3/sources/"
1218 "xerces-c-" version ".tar.xz"))
1219 (sha256
1220 (base32
1221 "0hb29c0smqlpxj0zdm09s983z5jx37szlliccnvgh0qq91wwqwwr"))))
1222 (build-system gnu-build-system)
1223 (arguments
1224 (let ((system (or (%current-target-system)
1225 (%current-system))))
1226 (if (string-prefix? "x86_64" system)
1227 '()
1228 '(#:configure-flags '("--disable-sse2")))))
1229 (native-inputs
1230 `(("perl" ,perl)))
1231 (home-page "http://xerces.apache.org/xerces-c/")
1232 (synopsis "Validating XML parser library for C++")
1233 (description "Xerces-C++ is a validating XML parser written in a portable
1234 subset of C++. Xerces-C++ makes it easy to give your application the ability
1235 to read and write XML data. A shared library is provided for parsing,
1236 generating, manipulating, and validating XML documents using the DOM, SAX, and
1237 SAX2 APIs.")
1238 (license license:asl2.0)))
1239
1240 (define-public java-simple-xml
1241 (package
1242 (name "java-simple-xml")
1243 (version "2.7.1")
1244 (source (origin
1245 (method url-fetch)
1246 (uri (string-append "mirror://sourceforge/simple/simple-xml-"
1247 version ".zip"))
1248 (sha256
1249 (base32
1250 "0w19k1awslmihpwsxwjbg89hv0vjhk4k3i0vrfchy3mqknd988y5"))))
1251 (build-system ant-build-system)
1252 (arguments
1253 `(#:build-target "build"
1254 #:test-target "test"
1255 #:phases
1256 (modify-phases %standard-phases
1257 (replace 'install (install-jars "jar")))))
1258 (native-inputs
1259 `(("unzip" ,unzip)))
1260 (home-page "http://simple.sourceforge.net/")
1261 (synopsis "XML serialization framework for Java")
1262 (description "Simple is a high performance XML serialization and
1263 configuration framework for Java. Its goal is to provide an XML framework
1264 that enables rapid development of XML configuration and communication systems.
1265 This framework aids the development of XML systems with minimal effort and
1266 reduced errors. It offers full object serialization and deserialization,
1267 maintaining each reference encountered.")
1268 (license license:asl2.0)))