Commit | Line | Data |
---|---|---|
d0414883 | 1 | ;;; GNU Guix --- Functional package management for GNU |
493e9a5a | 2 | ;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> |
0899144f | 3 | ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr> |
b715dbac | 4 | ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org> |
10ac0f9f | 5 | ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> |
e4aab734 | 6 | ;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net> |
3ebba94d | 7 | ;;; Copyright © 2015, 2016 Mark H Weaver <mhw@netris.org> |
e831256f | 8 | ;;; Copyright © 2015, 2016 Efraim Flashner <efraim@flashner.co.il> |
fe9451c5 | 9 | ;;; Copyright © 2015 Raimon Grau <raimonster@gmail.com> |
119b8398 | 10 | ;;; Copyright © 2016 Leo Famulari <leo@famulari.name> |
d0414883 LC |
11 | ;;; |
12 | ;;; This file is part of GNU Guix. | |
13 | ;;; | |
14 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
15 | ;;; under the terms of the GNU General Public License as published by | |
16 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
17 | ;;; your option) any later version. | |
18 | ;;; | |
19 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
20 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
21 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
22 | ;;; GNU General Public License for more details. | |
23 | ;;; | |
24 | ;;; You should have received a copy of the GNU General Public License | |
25 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
26 | ||
1ffa7090 | 27 | (define-module (gnu packages xml) |
f0444eaf | 28 | #:use-module (gnu packages) |
0899144f | 29 | #:use-module (gnu packages autotools) |
322cbda7 | 30 | #:use-module (gnu packages compression) |
58cc3b38 | 31 | #:use-module (gnu packages gnupg) |
f0444eaf AE |
32 | #:use-module (gnu packages perl) |
33 | #:use-module (gnu packages python) | |
a7fd7b68 | 34 | #:use-module (gnu packages tls) |
ad871fc6 | 35 | #:use-module (gnu packages web) |
b5b73a82 | 36 | #:use-module ((guix licenses) #:prefix license:) |
d0414883 LC |
37 | #:use-module (guix packages) |
38 | #:use-module (guix download) | |
6ce212b8 | 39 | #:use-module (guix build-system cmake) |
2a1e82bb | 40 | #:use-module (guix build-system gnu) |
37f9ff63 | 41 | #:use-module (guix build-system perl) |
7ce32242 | 42 | #:use-module (guix build-system python) |
e4aab734 RW |
43 | #:use-module (gnu packages linux) |
44 | #:use-module (gnu packages pkg-config)) | |
d0414883 LC |
45 | |
46 | (define-public expat | |
47 | (package | |
48 | (name "expat") | |
119b8398 | 49 | (replacement expat/fixed) |
d0414883 LC |
50 | (version "2.1.0") |
51 | (source (origin | |
52 | (method url-fetch) | |
53 | (uri (string-append "mirror://sourceforge/expat/expat/" | |
54 | version "/expat-" version ".tar.gz")) | |
55 | (sha256 | |
56 | (base32 | |
99e29da1 | 57 | "11pblz61zyxh68s5pdcbhc30ha1b2vfjd83aiwfg4vc15x3hadw2")) |
fc1adab1 | 58 | (patches (search-patches "expat-CVE-2015-1283.patch")))) |
d0414883 LC |
59 | (build-system gnu-build-system) |
60 | (home-page "http://www.libexpat.org/") | |
9e771e3b | 61 | (synopsis "Stream-oriented XML parser library written in C") |
d0414883 LC |
62 | (description |
63 | "Expat is an XML parser library written in C. It is a | |
64 | stream-oriented parser in which an application registers handlers for | |
65 | things the parser might find in the XML document (like start tags).") | |
66 | (license license:expat))) | |
f0444eaf | 67 | |
119b8398 LF |
68 | (define expat/fixed |
69 | (package | |
70 | (inherit expat) | |
71 | (source (origin | |
72 | (inherit (package-source expat)) | |
436dd046 LF |
73 | (patches (search-patches "expat-CVE-2012-6702-and-CVE-2016-5300.patch" |
74 | "expat-CVE-2015-1283.patch" | |
119b8398 LF |
75 | "expat-CVE-2015-1283-refix.patch" |
76 | "expat-CVE-2016-0718.patch")))))) | |
77 | ||
f0444eaf AE |
78 | (define-public libxml2 |
79 | (package | |
80 | (name "libxml2") | |
821060f3 | 81 | (version "2.9.3") |
493e9a5a | 82 | (replacement libxml2/fixed) ;multiple CVEs |
f0444eaf AE |
83 | (source (origin |
84 | (method url-fetch) | |
85 | (uri (string-append "ftp://xmlsoft.org/libxml2/libxml2-" | |
86 | version ".tar.gz")) | |
87 | (sha256 | |
88 | (base32 | |
821060f3 | 89 | "0bd17g6znn2r98gzpjppsqjg33iraky4px923j3k8kdl8qgy7sad")))) |
f0444eaf AE |
90 | (build-system gnu-build-system) |
91 | (home-page "http://www.xmlsoft.org/") | |
35b9e423 | 92 | (synopsis "C parser for XML") |
c1944c92 | 93 | (propagated-inputs `(("zlib" ,zlib))) ; libxml2.la says '-lz'. |
7ce32242 | 94 | (native-inputs `(("perl" ,perl))) |
2a8d4401 LC |
95 | ;; $XML_CATALOG_FILES lists 'catalog.xml' files found in under the 'xml' |
96 | ;; sub-directory of any given package. | |
74528069 LC |
97 | (native-search-paths (list (search-path-specification |
98 | (variable "XML_CATALOG_FILES") | |
99 | (separator " ") | |
100 | (files '("xml")) | |
101 | (file-pattern "^catalog\\.xml$") | |
102 | (file-type 'regular)))) | |
2a8d4401 | 103 | (search-paths native-search-paths) |
f0444eaf | 104 | (description |
7c125ce0 AK |
105 | "Libxml2 is the XML C parser and toolkit developed for the Gnome |
106 | project (but it is usable outside of the Gnome platform).") | |
f0444eaf | 107 | (license license:x11))) |
58cc3b38 | 108 | |
493e9a5a LC |
109 | (define libxml2/fixed |
110 | (package | |
111 | (inherit libxml2) | |
df2dd07b LF |
112 | (source |
113 | (let ((name "libxml2") | |
114 | (version "2.9.4")) | |
115 | (origin | |
116 | (method url-fetch) | |
117 | (uri (string-append "ftp://xmlsoft.org/libxml2/libxml2-" | |
118 | version ".tar.gz")) | |
119 | (sha256 | |
120 | (base32 | |
993b400a | 121 | "0g336cr0bw6dax1q48bblphmchgihx9p1pjmxdnrd6sh3qci3fgz"))))))) |
493e9a5a | 122 | |
7ce32242 SB |
123 | (define-public python-libxml2 |
124 | (package (inherit libxml2) | |
125 | (name "python-libxml2") | |
92a7e46d | 126 | (replacement #f) |
7ce32242 SB |
127 | (build-system python-build-system) |
128 | (arguments | |
129 | `(;; XXX: Tests are specified in 'Makefile.am', but not in 'setup.py'. | |
130 | #:tests? #f | |
131 | #:phases | |
132 | (modify-phases %standard-phases | |
133 | (add-before | |
134 | 'build 'configure | |
135 | (lambda* (#:key inputs #:allow-other-keys) | |
136 | (chdir "python") | |
137 | (let ((glibc (assoc-ref inputs ,(if (%current-target-system) | |
138 | "cross-libc" "libc"))) | |
139 | (libxml2 (assoc-ref inputs "libxml2"))) | |
140 | (substitute* "setup.py" | |
141 | ;; For 'libxml2/libxml/tree.h'. | |
142 | (("ROOT = r'/usr'") | |
143 | (format #f "ROOT = r'~a'" libxml2)) | |
144 | ;; For 'iconv.h'. | |
145 | (("/opt/include") | |
146 | (string-append glibc "/include"))))))))) | |
147 | (inputs `(("libxml2" ,libxml2))) | |
148 | (synopsis "Python bindings for the libxml2 library"))) | |
149 | ||
150 | (define-public python2-libxml2 | |
151 | (package-with-python2 python-libxml2)) | |
152 | ||
58cc3b38 AE |
153 | (define-public libxslt |
154 | (package | |
155 | (name "libxslt") | |
156 | (version "1.1.28") | |
3ebba94d | 157 | (replacement libxslt/fixed) ; CVE-2016-1683 and CVE-2016-1684 |
58cc3b38 AE |
158 | (source (origin |
159 | (method url-fetch) | |
160 | (uri (string-append "ftp://xmlsoft.org/libxslt/libxslt-" | |
161 | version ".tar.gz")) | |
162 | (sha256 | |
163 | (base32 | |
b4a88dc2 | 164 | "13029baw9kkyjgr7q3jccw2mz38amq7mmpr5p3bh775qawd1bisz")) |
fc1adab1 | 165 | (patches (search-patches "libxslt-CVE-2015-7995.patch")))) |
58cc3b38 AE |
166 | (build-system gnu-build-system) |
167 | (home-page "http://xmlsoft.org/XSLT/index.html") | |
35b9e423 | 168 | (synopsis "C library for applying XSLT stylesheets to XML documents") |
58cc3b38 AE |
169 | (inputs `(("libgcrypt" ,libgcrypt) |
170 | ("libxml2" ,libxml2) | |
95288fcc | 171 | ("python" ,python-minimal-wrapper) |
11e3f107 | 172 | ("zlib" ,zlib))) |
58cc3b38 | 173 | (description |
35b9e423 | 174 | "Libxslt is an XSLT C library developed for the GNOME project. It is |
58cc3b38 AE |
175 | based on libxml for XML parsing, tree manipulation and XPath support.") |
176 | (license license:x11))) | |
2a1e82bb | 177 | |
3ebba94d MW |
178 | (define-public libxslt/fixed |
179 | (package | |
180 | (inherit libxslt) | |
181 | (source | |
182 | (let ((version "1.1.29")) | |
183 | (origin | |
184 | (method url-fetch) | |
185 | (uri (string-append "ftp://xmlsoft.org/libxslt/libxslt-" | |
186 | version ".tar.gz")) | |
187 | (sha256 | |
188 | (base32 | |
189 | "1klh81xbm9ppzgqk339097i39b7fnpmlj8lzn8bpczl3aww6x5xm"))))))) | |
190 | ||
2a1e82bb LC |
191 | (define-public perl-xml-parser |
192 | (package | |
193 | (name "perl-xml-parser") | |
d495634b | 194 | (version "2.44") |
2a1e82bb LC |
195 | (source (origin |
196 | (method url-fetch) | |
197 | (uri (string-append | |
2b8c5f54 | 198 | "mirror://cpan/authors/id/T/TO/TODDR/XML-Parser-" |
2a1e82bb LC |
199 | version ".tar.gz")) |
200 | (sha256 | |
201 | (base32 | |
d495634b | 202 | "05ij0g6bfn27iaggxf8nl5rhlwx6f6p6xmdav6rjcly3x5zd1s8s")))) |
2a1e82bb LC |
203 | (build-system perl-build-system) |
204 | (arguments `(#:make-maker-flags | |
205 | (let ((expat (assoc-ref %build-inputs "expat"))) | |
206 | (list (string-append "EXPATLIBPATH=" expat "/lib") | |
207 | (string-append "EXPATINCPATH=" expat "/include"))))) | |
208 | (inputs `(("expat" ,expat))) | |
209 | (license (package-license perl)) | |
210 | (synopsis "Perl bindings to the Expat XML parsing library") | |
211 | (description | |
212 | "This module provides ways to parse XML documents. It is built on top of | |
213 | XML::Parser::Expat, which is a lower level interface to James Clark's expat | |
214 | library. Each call to one of the parsing methods creates a new instance of | |
215 | XML::Parser::Expat which is then used to parse the document. Expat options | |
216 | may be provided when the XML::Parser object is created. These options are | |
217 | then passed on to the Expat object on each parse call. They can also be given | |
218 | as extra arguments to the parse methods, in which case they override options | |
219 | given at XML::Parser creation time.") | |
d495634b | 220 | (home-page "http://search.cpan.org/dist/XML-Parser"))) |
37f9ff63 | 221 | |
7339fbe2 | 222 | (define-public perl-libxml |
1385ba4f | 223 | (package |
7339fbe2 | 224 | (name "perl-libxml") |
1385ba4f AE |
225 | (version "0.08") |
226 | (source (origin | |
227 | (method url-fetch) | |
228 | (uri (string-append | |
229 | "mirror://cpan/authors/id/K/KM/KMACLEOD/libxml-perl-" | |
230 | version ".tar.gz")) | |
231 | (sha256 | |
232 | (base32 | |
233 | "1jy9af0ljyzj7wakqli0437zb2vrbplqj4xhab7bfj2xgfdhawa5")))) | |
234 | (build-system perl-build-system) | |
7b81406a | 235 | (propagated-inputs |
1385ba4f AE |
236 | `(("perl-xml-parser" ,perl-xml-parser))) |
237 | (license (package-license perl)) | |
238 | (synopsis "Perl SAX parser using XML::Parser") | |
239 | (description | |
240 | "XML::Parser::PerlSAX is a PerlSAX parser using the XML::Parser | |
241 | module.") | |
242 | (home-page "http://search.cpan.org/~kmacleod/libxml-perl/lib/XML/Parser/PerlSAX.pm"))) | |
243 | ||
3dd6bee1 EB |
244 | (define-public perl-xml-libxml |
245 | (package | |
246 | (name "perl-xml-libxml") | |
54c3c140 | 247 | (version "2.0125") |
3dd6bee1 EB |
248 | (source |
249 | (origin | |
250 | (method url-fetch) | |
251 | (uri (string-append "mirror://cpan/authors/id/S/SH/SHLOMIF/" | |
252 | "XML-LibXML-" version ".tar.gz")) | |
253 | (sha256 | |
254 | (base32 | |
54c3c140 | 255 | "1mvbv1pwpdqni9ia9b6brg8brnnvfxr8j5x872qsngc92gipyh01")))) |
3dd6bee1 EB |
256 | (build-system perl-build-system) |
257 | (propagated-inputs | |
258 | `(("perl-xml-namespacesupport" ,perl-xml-namespacesupport) | |
259 | ("perl-xml-sax" ,perl-xml-sax))) | |
260 | (inputs | |
261 | `(("libxml2" ,libxml2))) | |
262 | (home-page "http://search.cpan.org/dist/XML-LibXML") | |
263 | (synopsis "Perl interface to libxml2") | |
264 | (description "This module implements a Perl interface to the libxml2 | |
54c3c140 | 265 | library which provides interfaces for parsing and manipulating XML files. This |
3dd6bee1 EB |
266 | module allows Perl programmers to make use of the highly capable validating |
267 | XML parser and the high performance DOM implementation.") | |
268 | (license (package-license perl)))) | |
269 | ||
f7c4dc2f RW |
270 | (define-public perl-xml-libxml-simple |
271 | (package | |
272 | (name "perl-xml-libxml-simple") | |
273 | (version "0.95") | |
274 | (source (origin | |
275 | (method url-fetch) | |
276 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
277 | "XML-LibXML-Simple-" version ".tar.gz")) | |
278 | (sha256 | |
279 | (base32 | |
280 | "0qqfqj5bgqmh1j4iv8dwl3g00nsmcvf2b7w1d09k9d77rrb249xi")))) | |
281 | (build-system perl-build-system) | |
282 | (propagated-inputs | |
283 | `(("perl-file-slurp-tiny" ,perl-file-slurp-tiny) | |
284 | ("perl-xml-libxml" ,perl-xml-libxml))) | |
285 | (home-page "http://search.cpan.org/dist/XML-LibXML-Simple") | |
286 | (synopsis "XML::LibXML based XML::Simple clone") | |
287 | (description | |
288 | "This package provides the same API as @code{XML::Simple} but is based on | |
289 | @code{XML::LibXML}.") | |
290 | (license (package-license perl)))) | |
291 | ||
b715dbac EB |
292 | (define-public perl-xml-namespacesupport |
293 | (package | |
294 | (name "perl-xml-namespacesupport") | |
295 | (version "1.11") | |
296 | (source | |
297 | (origin | |
298 | (method url-fetch) | |
299 | (uri (string-append "mirror://cpan/authors/id/P/PE/PERIGRIN/" | |
300 | "XML-NamespaceSupport-" version ".tar.gz")) | |
301 | (sha256 | |
302 | (base32 | |
303 | "1sklgcldl3w6gn706vx1cgz6pm4y5lfgsjxnfqyk20pilgq530bd")))) | |
304 | (build-system perl-build-system) | |
305 | (home-page "http://search.cpan.org/dist/XML-NamespaceSupport") | |
306 | (synopsis "XML namespace support class") | |
307 | (description "This module offers a simple to process namespaced XML | |
308 | names (unames) from within any application that may need them. It also helps | |
309 | maintain a prefix to namespace URI map, and provides a number of basic | |
310 | checks.") | |
311 | (license (package-license perl)))) | |
312 | ||
18b8bbb3 EB |
313 | (define-public perl-xml-sax |
314 | (package | |
315 | (name "perl-xml-sax") | |
316 | (version "0.99") | |
317 | (source | |
318 | (origin | |
319 | (method url-fetch) | |
320 | (uri (string-append "mirror://cpan/authors/id/G/GR/GRANTM/" | |
321 | "XML-SAX-" version ".tar.gz")) | |
322 | (sha256 | |
323 | (base32 | |
324 | "115dypb50w1l94y3iwihv5nkixbsv1cxiqkd93y4rk5n6s74pc1j")))) | |
325 | (build-system perl-build-system) | |
326 | (propagated-inputs | |
327 | `(("perl-xml-namespacesupport" ,perl-xml-namespacesupport) | |
328 | ("perl-xml-sax-base" ,perl-xml-sax-base))) | |
329 | (arguments | |
330 | `(#:phases (modify-phases %standard-phases | |
331 | (add-before | |
40b084a3 | 332 | 'install 'augment-path |
18b8bbb3 EB |
333 | ;; The install target tries to load the newly-installed |
334 | ;; XML::SAX module, but can't find it, so we need to tell | |
335 | ;; perl where to look. | |
336 | (lambda* (#:key outputs #:allow-other-keys) | |
337 | (setenv "PERL5LIB" | |
338 | (string-append (getenv "PERL5LIB") ":" | |
339 | (assoc-ref outputs "out") | |
340 | "/lib/perl5/site_perl"))))))) | |
341 | (home-page "http://search.cpan.org/dist/XML-SAX") | |
342 | (synopsis "Perl API for XML") | |
343 | (description "XML::SAX consists of several framework classes for using and | |
344 | building Perl SAX2 XML parsers, filters, and drivers.") | |
345 | (license (package-license perl)))) | |
346 | ||
1ed6d5bc EB |
347 | (define-public perl-xml-sax-base |
348 | (package | |
349 | (name "perl-xml-sax-base") | |
350 | (version "1.08") | |
351 | (source | |
352 | (origin | |
353 | (method url-fetch) | |
354 | (uri (string-append "mirror://cpan/authors/id/G/GR/GRANTM/" | |
355 | "XML-SAX-Base-" version ".tar.gz")) | |
356 | (sha256 | |
357 | (base32 | |
358 | "17i161rq1ngjlk0c8vdkrkkc56y1pf51k1g54y28py0micqp0qk6")))) | |
359 | (build-system perl-build-system) | |
360 | (home-page "http://search.cpan.org/dist/XML-SAX-Base") | |
361 | (synopsis "Base class for SAX Drivers and Filters") | |
362 | (description "This module has a very simple task - to be a base class for | |
363 | PerlSAX drivers and filters. It's default behaviour is to pass the input | |
364 | directly to the output unchanged. It can be useful to use this module as a | |
365 | base class so you don't have to, for example, implement the characters() | |
366 | callback.") | |
367 | (license (package-license perl)))) | |
368 | ||
535dc6cf AE |
369 | (define-public perl-xml-simple |
370 | (package | |
371 | (name "perl-xml-simple") | |
e831256f | 372 | (version "2.22") |
535dc6cf AE |
373 | (source (origin |
374 | (method url-fetch) | |
375 | (uri (string-append | |
376 | "mirror://cpan/authors/id/G/GR/GRANTM/XML-Simple-" | |
377 | version ".tar.gz")) | |
378 | (sha256 | |
379 | (base32 | |
e831256f | 380 | "0jgbk30jizafpl7078jhw1di1yh08gf8d85dsvjllr595vr0widr")))) |
535dc6cf | 381 | (build-system perl-build-system) |
27ef7f45 | 382 | (propagated-inputs |
e831256f EF |
383 | `(("perl-xml-parser" ,perl-xml-parser) |
384 | ("perl-xml-sax" ,perl-xml-sax))) | |
535dc6cf AE |
385 | (license (package-license perl)) |
386 | (synopsis "Perl module for easy reading/writing of XML files") | |
387 | (description | |
388 | "The XML::Simple module provides a simple API layer on top of an | |
389 | underlying XML parsing module (either XML::Parser or one of the SAX2 | |
390 | parser modules).") | |
e831256f | 391 | (home-page "http://search.cpan.org/dist/XML-Simple"))) |
535dc6cf | 392 | |
a2e520af AE |
393 | (define-public perl-xml-regexp |
394 | (package | |
395 | (name "perl-xml-regexp") | |
396 | (version "0.04") | |
397 | (source (origin | |
398 | (method url-fetch) | |
399 | (uri (string-append | |
400 | "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-RegExp-" | |
401 | version ".tar.gz")) | |
402 | (sha256 | |
403 | (base32 | |
404 | "0m7wj00a2kik7wj0azhs1zagwazqh3hlz4255n75q21nc04r06fz")))) | |
405 | (build-system perl-build-system) | |
406 | (inputs | |
407 | `(("perl-xml-parser" ,perl-xml-parser))) | |
408 | (license (package-license perl)) | |
409 | (synopsis "Perl regular expressions for XML tokens") | |
410 | (description | |
411 | "XML::RegExp contains regular expressions for the following XML tokens: | |
412 | BaseChar, Ideographic, Letter, Digit, Extender, CombiningChar, NameChar, | |
413 | EntityRef, CharRef, Reference, Name, NmToken, and AttValue.") | |
414 | (home-page "http://search.cpan.org/~tjmather/XML-RegExp/lib/XML/RegExp.pm"))) | |
415 | ||
ad871fc6 AE |
416 | (define-public perl-xml-dom |
417 | (package | |
418 | (name "perl-xml-dom") | |
419 | (version "1.44") | |
420 | (source (origin | |
421 | (method url-fetch) | |
422 | (uri (string-append | |
423 | "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-DOM-" | |
424 | version ".tar.gz")) | |
425 | (sha256 | |
426 | (base32 | |
427 | "1r0ampc88ni3sjpzr583k86076qg399arfm9xirv3cw49k3k5bzn")))) | |
428 | (build-system perl-build-system) | |
f7faff88 AE |
429 | (propagated-inputs |
430 | `(("perl-libwww" ,perl-libwww) | |
ad871fc6 | 431 | ("perl-libxml" ,perl-libxml) |
ad871fc6 AE |
432 | ("perl-xml-regexp" ,perl-xml-regexp))) |
433 | (license (package-license perl)) | |
434 | (synopsis | |
435 | "Perl module for building DOM Level 1 compliant document structures") | |
436 | (description | |
437 | "This module extends the XML::Parser module by Clark Cooper. The | |
438 | XML::Parser module is built on top of XML::Parser::Expat, which is a lower | |
439 | level interface to James Clark's expat library. XML::DOM::Parser is derived | |
440 | from XML::Parser. It parses XML strings or files and builds a data structure | |
441 | that conforms to the API of the Document Object Model.") | |
442 | (home-page "http://search.cpan.org/~tjmather/XML-DOM-1.44/lib/XML/DOM.pm"))) | |
443 | ||
649e1676 RW |
444 | (define-public perl-xml-compile-tester |
445 | (package | |
446 | (name "perl-xml-compile-tester") | |
447 | (version "0.90") | |
448 | (source (origin | |
449 | (method url-fetch) | |
450 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
451 | "XML-Compile-Tester-" version ".tar.gz")) | |
452 | (sha256 | |
453 | (base32 | |
454 | "1bcl8x8cyacqv9yjp97aq9qq85sy8wv78kd8c16yd9yw3by4cpp1")))) | |
455 | (build-system perl-build-system) | |
456 | (propagated-inputs | |
457 | `(("perl-log-report" ,perl-log-report) | |
458 | ("perl-test-deep" ,perl-test-deep))) | |
459 | (home-page "http://search.cpan.org/dist/XML-Compile-Tester") | |
460 | (synopsis "XML::Compile related regression testing") | |
461 | (description | |
462 | "The @code{XML::Compile} module suite has extensive regression testing. | |
463 | This module provide functions which simplify writing tests for | |
464 | @code{XML::Compile} related distributions.") | |
465 | (license (package-license perl)))) | |
466 | ||
b494a5f1 RW |
467 | (define-public perl-xml-compile |
468 | (package | |
469 | (name "perl-xml-compile") | |
470 | (version "1.51") | |
471 | (source (origin | |
472 | (method url-fetch) | |
473 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
474 | "XML-Compile-" version ".tar.gz")) | |
475 | (sha256 | |
476 | (base32 | |
477 | "06fj4zf0yh4kf3kx4bhwrmrjr6al40nasasbgfhn8f1zxwkmm8f2")))) | |
478 | (build-system perl-build-system) | |
479 | (propagated-inputs | |
480 | `(("perl-log-report" ,perl-log-report) | |
481 | ("perl-xml-compile-tester" ,perl-xml-compile-tester) | |
482 | ("perl-xml-libxml" ,perl-xml-libxml) | |
483 | ("perl-test-deep" ,perl-test-deep))) | |
484 | (home-page "http://search.cpan.org/dist/XML-Compile") | |
485 | (synopsis "Compilation-based XML processing") | |
486 | (description | |
487 | "@code{XML::Compile} can be used to translate a Perl data-structure into | |
488 | XML or XML into a Perl data-structure, both directions under rigid control by | |
489 | a schema.") | |
490 | (license (package-license perl)))) | |
491 | ||
c1d41b5d RW |
492 | (define-public perl-xml-compile-cache |
493 | (package | |
494 | (name "perl-xml-compile-cache") | |
495 | (version "1.04") | |
496 | (source (origin | |
497 | (method url-fetch) | |
498 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
499 | "XML-Compile-Cache-" version ".tar.gz")) | |
500 | (sha256 | |
501 | (base32 | |
502 | "1689dm54n7wb0n0cl9n77vk0kvg0mcckn2hz9ahigjhvazah8740")))) | |
503 | (build-system perl-build-system) | |
504 | (propagated-inputs | |
505 | `(("perl-log-report" ,perl-log-report) | |
506 | ("perl-xml-compile" ,perl-xml-compile) | |
507 | ("perl-xml-compile-tester" ,perl-xml-compile-tester) | |
508 | ("perl-xml-libxml-simple" ,perl-xml-libxml-simple))) | |
509 | (home-page "http://search.cpan.org/dist/XML-Compile-Cache") | |
510 | (synopsis "Cache compiled XML translators") | |
511 | (description | |
512 | "This package provides methods to cache compiled XML translators.") | |
513 | (license (package-license perl)))) | |
514 | ||
baeab9b8 RW |
515 | (define-public perl-xml-compile-soap |
516 | (package | |
517 | (name "perl-xml-compile-soap") | |
518 | (version "3.13") | |
519 | (source (origin | |
520 | (method url-fetch) | |
521 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
522 | "XML-Compile-SOAP-" version ".tar.gz")) | |
523 | (sha256 | |
524 | (base32 | |
525 | "08qw63l78040nh37xzapbqp43g6s5l67bvskf3dyyizlarjx5mi4")))) | |
526 | (build-system perl-build-system) | |
527 | (propagated-inputs | |
528 | `(("perl-file-slurp-tiny" ,perl-file-slurp-tiny) | |
529 | ("perl-libwww" ,perl-libwww) | |
530 | ("perl-log-report" ,perl-log-report) | |
531 | ("perl-xml-compile" ,perl-xml-compile) | |
532 | ("perl-xml-compile-cache" ,perl-xml-compile-cache) | |
533 | ("perl-xml-compile-tester" ,perl-xml-compile-tester))) | |
534 | (home-page "http://search.cpan.org/dist/XML-Compile-SOAP") | |
535 | (synopsis "Base-class for SOAP implementations") | |
536 | (description | |
537 | "This module provides a class to handle the SOAP protocol. The first | |
538 | implementation is @url{SOAP1.1, | |
539 | http://www.w3.org/TR/2000/NOTE-SOAP-20000508/}, which is still most often | |
540 | used.") | |
541 | (license (package-license perl)))) | |
542 | ||
6a914948 RW |
543 | (define-public perl-xml-compile-wsdl11 |
544 | (package | |
545 | (name "perl-xml-compile-wsdl11") | |
546 | (version "3.04") | |
547 | (source (origin | |
548 | (method url-fetch) | |
549 | (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/" | |
550 | "XML-Compile-WSDL11-" version ".tar.gz")) | |
551 | (sha256 | |
552 | (base32 | |
553 | "0pyikwnfwpangvnkf5dbdagy4z93ag9824f1ax5qaibc3ghca8kv")))) | |
554 | (build-system perl-build-system) | |
555 | (propagated-inputs | |
556 | `(("perl-log-report" ,perl-log-report) | |
557 | ("perl-xml-compile" ,perl-xml-compile) | |
558 | ("perl-xml-compile-cache" ,perl-xml-compile-cache) | |
559 | ("perl-xml-compile-soap" ,perl-xml-compile-soap))) | |
560 | (home-page "http://search.cpan.org/dist/XML-Compile-WSDL11") | |
561 | (synopsis "Create SOAP messages defined by WSDL 1.1") | |
562 | (description | |
563 | "This module understands WSDL version 1.1. A WSDL file defines a set of | |
564 | messages to be send and received over SOAP connections. This involves | |
565 | encoding of the message to be send into XML, sending the message to the | |
566 | server, collect the answer, and finally decoding the XML to Perl.") | |
567 | (license (package-license perl)))) | |
568 | ||
6ce212b8 RW |
569 | (define-public pugixml |
570 | (package | |
571 | (name "pugixml") | |
572 | (version "1.6") | |
573 | (source | |
574 | (origin | |
575 | (method url-fetch) | |
576 | (uri (string-append "https://github.com/zeux/pugixml/archive/v" | |
577 | version ".tar.gz")) | |
578 | (file-name (string-append name "-" version ".tar.gz")) | |
579 | (sha256 | |
580 | (base32 | |
581 | "0czbcv9aqf2rw3s9cljz2wb1f4zbhd07wnj7ykklklccl0ipfnwi")))) | |
582 | (build-system cmake-build-system) | |
583 | (arguments | |
584 | `(#:tests? #f | |
585 | #:out-of-source? #f | |
586 | #:phases (modify-phases %standard-phases | |
587 | (add-before | |
588 | 'configure 'chdir | |
589 | (lambda _ | |
590 | (chdir "scripts") | |
591 | #t))))) | |
592 | (home-page "http://pugixml.org") | |
593 | (synopsis "Light-weight, simple and fast XML parser for C++ with XPath support") | |
594 | (description | |
595 | "pugixml is a C++ XML processing library, which consists of a DOM-like | |
596 | interface with rich traversal/modification capabilities, a fast XML parser | |
597 | which constructs the DOM tree from an XML file/buffer, and an XPath 1.0 | |
598 | implementation for complex data-driven tree queries. Full Unicode support is | |
599 | also available, with Unicode interface variants and conversions between | |
600 | different Unicode encodings which happen automatically during | |
601 | parsing/saving.") | |
602 | (license license:expat))) | |
603 | ||
37f9ff63 AE |
604 | (define-public xmlto |
605 | (package | |
606 | (name "xmlto") | |
877a6466 | 607 | (version "0.0.28") |
37f9ff63 AE |
608 | (source |
609 | (origin | |
610 | (method url-fetch) | |
611 | (uri (string-append | |
612 | "https://fedorahosted.org/releases/x/m/xmlto/xmlto-" | |
613 | version ".tar.bz2")) | |
614 | (sha256 | |
615 | (base32 | |
877a6466 | 616 | "0xhj8b2pwp4vhl9y16v3dpxpsakkflfamr191mprzsspg4xdyc0i")))) |
37f9ff63 | 617 | (build-system gnu-build-system) |
ae0c1202 LC |
618 | (arguments |
619 | ;; Make sure the reference to util-linux's 'getopt' is kept in 'xmlto'. | |
620 | '(#:configure-flags (list (string-append "GETOPT=" | |
621 | (assoc-ref %build-inputs | |
622 | "util-linux") | |
623 | "/bin/getopt")))) | |
37f9ff63 | 624 | (inputs |
ae0c1202 LC |
625 | `(("util-linux" ,util-linux) ; for 'getopt' |
626 | ("libxml2" ,libxml2) ; for 'xmllint' | |
627 | ("libxslt" ,libxslt))) ; for 'xsltproc' | |
37f9ff63 AE |
628 | (home-page "http://cyberelk.net/tim/software/xmlto/") |
629 | (synopsis "Front-end to an XSL toolchain") | |
630 | (description | |
631 | "Xmlto is a front-end to an XSL toolchain. It chooses an appropriate | |
632 | stylesheet for the conversion you want and applies it using an external | |
633 | XSL-T processor. It also performs any necessary post-processing.") | |
634 | (license license:gpl2+))) | |
0899144f AE |
635 | |
636 | (define-public xmlsec | |
637 | (package | |
638 | (name "xmlsec") | |
639 | (version "1.2.20") | |
640 | (source (origin | |
641 | (method url-fetch) | |
642 | (uri (string-append "https://www.aleksey.com/xmlsec/download/" | |
643 | name "1-" version ".tar.gz")) | |
644 | (sha256 | |
645 | (base32 | |
646 | "01bkbv2y3x8d1sf4dcln1x3y2jyj391s3208d9a2ndhglly5j89j")))) | |
647 | (build-system gnu-build-system) | |
648 | (propagated-inputs ; according to xmlsec1.pc | |
649 | `(("libxml2" ,libxml2) | |
650 | ("libxslt" ,libxslt))) | |
651 | (inputs | |
652 | `(("gnutls" ,gnutls) | |
653 | ("libgcrypt" ,libgcrypt) | |
654 | ("libltdl" ,libltdl))) | |
e4aab734 RW |
655 | (native-inputs |
656 | `(("pkg-config" ,pkg-config))) | |
0899144f AE |
657 | (home-page "http://www.libexpat.org/") |
658 | (synopsis "XML Security Library") | |
659 | (description | |
660 | "The XML Security Library is a C library based on Libxml2. It | |
661 | supports XML security standards such as XML Signature, XML Encryption, | |
662 | Canonical XML (part of Libxml2) and Exclusive Canonical XML (part of | |
663 | Libxml2).") | |
664 | (license (license:x11-style "file://COPYING" | |
665 | "See 'COPYING' in the distribution.")))) | |
96f8d991 RW |
666 | |
667 | (define-public minixml | |
668 | (package | |
669 | (name "minixml") | |
670 | (version "2.9") | |
671 | (source (origin | |
672 | (method url-fetch) | |
673 | (uri (string-append "http://www.msweet.org/files/project3/mxml-" | |
674 | version ".tar.gz")) | |
675 | (sha256 | |
676 | (base32 | |
677 | "14pzhlfidj5v1qbxy7a59yn4jz9pnjrs2zwalz228jsq7ijm9vfd")))) | |
678 | (build-system gnu-build-system) | |
679 | (arguments | |
680 | `(#:tests? #f)) ;no "check" target | |
681 | (home-page "http://www.minixml.org/") | |
682 | (synopsis "Small XML parsing library") | |
683 | (description | |
684 | "Mini-XML is a small C library to read and write XML files and strings in | |
685 | UTF-8 and UTF-16 encoding.") | |
686 | ;; LGPL 2.0+ with additional exceptions for static linking | |
687 | (license license:lgpl2.0+))) | |
33ae9107 DT |
688 | |
689 | ;; TinyXML is an unmaintained piece of software, so the patches and build | |
690 | ;; system massaging have no upstream potential. | |
691 | (define-public tinyxml | |
692 | (package | |
693 | (name "tinyxml") | |
694 | (version "2.6.2") | |
695 | (source (origin | |
696 | (method url-fetch) | |
697 | (uri (string-append "mirror://sourceforge/tinyxml/tinyxml_" | |
698 | (string-join (string-split version #\.) "_") | |
699 | ".tar.gz")) | |
700 | (sha256 | |
701 | (base32 | |
702 | "14smciid19lvkxqznfig77jxn5s4iq3jpb47vh5a6zcaqp7gvg8m")) | |
fc1adab1 | 703 | (patches (search-patches "tinyxml-use-stl.patch")))) |
33ae9107 DT |
704 | (build-system gnu-build-system) |
705 | ;; This library is missing *a lot* of the steps to make it usable, so we | |
706 | ;; have to add them here, like every other distro must do. | |
707 | (arguments | |
708 | `(#:phases | |
709 | (modify-phases %standard-phases | |
710 | (delete 'configure) | |
711 | (add-after 'build 'build-shared-library | |
712 | (lambda _ | |
713 | (zero? (system* "g++" "-Wall" "-O2" "-shared" "-fpic" | |
714 | "tinyxml.cpp" "tinyxmlerror.cpp" | |
715 | "tinyxmlparser.cpp" "tinystr.cpp" | |
716 | "-o" "libtinyxml.so")))) | |
717 | (replace 'check | |
718 | (lambda _ (zero? (system "./xmltest")))) | |
719 | (replace 'install | |
720 | (lambda* (#:key outputs #:allow-other-keys) | |
721 | (let* ((out (assoc-ref outputs "out")) | |
722 | (include (string-append out "/include")) | |
723 | (lib (string-append out "/lib")) | |
724 | (pkgconfig (string-append out "/lib/pkgconfig")) | |
725 | (doc (string-append out "/share/doc"))) | |
726 | ;; Install libs and headers. | |
727 | (install-file "libtinyxml.so" lib) | |
728 | (install-file "tinystr.h" include) | |
729 | (install-file "tinyxml.h" include) | |
730 | ;; Generate and install pkg-config file. | |
731 | (mkdir-p pkgconfig) | |
732 | ;; Software such as Kodi expect this file to be present, but | |
733 | ;; it's not provided in the source code. | |
734 | (call-with-output-file (string-append pkgconfig "/tinyxml.pc") | |
735 | (lambda (port) | |
736 | (format port "prefix=~a | |
737 | exec_prefix=${prefix} | |
738 | libdir=${exec_prefix}/lib | |
739 | includedir=${prefix}/include | |
740 | ||
741 | Name: TinyXML | |
742 | Description: A simple, small, C++ XML parser | |
743 | Version: ~a | |
744 | Libs: -L${libdir} -ltinyxml | |
745 | Cflags: -I${includedir} | |
746 | " | |
747 | out ,version))) | |
748 | ;; Install docs. | |
749 | (mkdir-p doc) | |
750 | (copy-recursively "docs" (string-append doc "tinyxml")) | |
751 | #t)))))) | |
752 | (synopsis "Small XML parser for C++") | |
753 | (description "TinyXML is a small and simple XML parsing library for the | |
754 | C++ programming langauge.") | |
755 | (home-page "http://www.grinninglizard.com/tinyxml/index.html") | |
756 | (license license:zlib))) | |
fe9451c5 RG |
757 | |
758 | (define-public xmlstarlet | |
759 | (package | |
760 | (name "xmlstarlet") | |
761 | (version "1.6.1") | |
762 | (source | |
763 | (origin | |
764 | (method url-fetch) | |
765 | (uri (string-append "mirror://sourceforge/xmlstar/xmlstarlet/" | |
766 | version "/xmlstarlet-" version ".tar.gz")) | |
767 | (sha256 | |
768 | (base32 | |
769 | "1jp737nvfcf6wyb54fla868yrr39kcbijijmjpyk4lrpyg23in0m")))) | |
770 | (build-system gnu-build-system) | |
771 | (inputs | |
772 | `(("libxslt" ,libxslt) | |
773 | ("libxml2" ,libxml2))) | |
774 | (home-page "http://xmlstar.sourceforge.net/") | |
775 | (synopsis "Command line XML toolkit") | |
776 | (description "XMLStarlet is a set of command line utilities which can be | |
777 | used to transform, query, validate, and edit XML documents. XPath is used to | |
778 | match and extract data, and elements can be added, deleted or modified using | |
779 | XSLT and EXSLT.") | |
780 | (license license:x11))) |