gnu: Synchronize GNU package descriptions with upstream.
[jackhill/guix/guix.git] / gnu / packages / xml.scm
CommitLineData
d0414883
LC
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2013 Ludovic Courtès <ludo@gnu.org>
f0444eaf 3;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
d0414883
LC
4;;;
5;;; This file is part of GNU Guix.
6;;;
7;;; GNU Guix is free software; you can redistribute it and/or modify it
8;;; under the terms of the GNU General Public License as published by
9;;; the Free Software Foundation; either version 3 of the License, or (at
10;;; your option) any later version.
11;;;
12;;; GNU Guix is distributed in the hope that it will be useful, but
13;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15;;; GNU General Public License for more details.
16;;;
17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
1ffa7090 20(define-module (gnu packages xml)
f0444eaf 21 #:use-module (gnu packages)
322cbda7 22 #:use-module (gnu packages compression)
58cc3b38 23 #:use-module (gnu packages gnupg)
f0444eaf
AE
24 #:use-module (gnu packages perl)
25 #:use-module (gnu packages python)
ad871fc6 26 #:use-module (gnu packages web)
d0414883
LC
27 #:use-module ((guix licenses)
28 #:renamer (symbol-prefix-proc 'license:))
29 #:use-module (guix packages)
30 #:use-module (guix download)
2a1e82bb 31 #:use-module (guix build-system gnu)
37f9ff63
AE
32 #:use-module (guix build-system perl)
33 #:use-module (gnu packages linux))
d0414883
LC
34
35(define-public expat
36 (package
37 (name "expat")
38 (version "2.1.0")
39 (source (origin
40 (method url-fetch)
41 (uri (string-append "mirror://sourceforge/expat/expat/"
42 version "/expat-" version ".tar.gz"))
43 (sha256
44 (base32
45 "11pblz61zyxh68s5pdcbhc30ha1b2vfjd83aiwfg4vc15x3hadw2"))))
46 (build-system gnu-build-system)
47 (home-page "http://www.libexpat.org/")
48 (synopsis "A stream-oriented XML parser library written in C")
49 (description
50 "Expat is an XML parser library written in C. It is a
51stream-oriented parser in which an application registers handlers for
52things the parser might find in the XML document (like start tags).")
53 (license license:expat)))
f0444eaf
AE
54
55(define-public libxml2
56 (package
57 (name "libxml2")
58 (version "2.9.0")
59 (source (origin
60 (method url-fetch)
61 (uri (string-append "ftp://xmlsoft.org/libxml2/libxml2-"
62 version ".tar.gz"))
63 (sha256
64 (base32
65 "10ib8bpar2pl68aqksfinvfmqknwnk7i35ibq6yjl8dpb0cxj9dd"))))
66 (build-system gnu-build-system)
67 (home-page "http://www.xmlsoft.org/")
68 (synopsis "libxml2, a C parser for XML")
c4c4cc05
JD
69 (inputs `(("zlib" ,zlib)))
70 (native-inputs `(("perl" ,perl)
71 ("python" ,python-2))) ; incompatible with Python 3 (print syntax)
322cbda7
AE
72 (arguments
73 `(#:phases
74 (alist-replace
75 'install
76 (lambda* (#:key inputs outputs #:allow-other-keys #:rest args)
77 (let ((install (assoc-ref %standard-phases 'install))
5839958a
JD
78 (glibc (assoc-ref inputs ,(if (%current-target-system)
79 "cross-libc" "libc")))
322cbda7
AE
80 (out (assoc-ref outputs "out")))
81 (apply install args)
82 (chdir "python")
5839958a
JD
83 (substitute* "setup.py"
84 (("/opt/include")
85 (string-append glibc "/include")))
86 (system* "python" "setup.py" "install"
87 (string-append "--prefix=" out))))
322cbda7 88 %standard-phases)))
f0444eaf
AE
89 (description
90 "Libxml2 is the XML C parser and toolkit developed for the Gnome project
91(but it is usable outside of the Gnome platform).")
92 (license license:x11)))
58cc3b38
AE
93
94(define-public libxslt
95 (package
96 (name "libxslt")
97 (version "1.1.28")
98 (source (origin
99 (method url-fetch)
100 (uri (string-append "ftp://xmlsoft.org/libxslt/libxslt-"
101 version ".tar.gz"))
102 (sha256
103 (base32
104 "13029baw9kkyjgr7q3jccw2mz38amq7mmpr5p3bh775qawd1bisz"))))
105 (build-system gnu-build-system)
106 (home-page "http://xmlsoft.org/XSLT/index.html")
107 (synopsis "libxslt, a C library for applying XSLT stylesheets to XML documents")
108 (inputs `(("libgcrypt" ,libgcrypt)
109 ("libxml2" ,libxml2)
ee3e314b 110 ("python" ,python-wrapper)
11e3f107 111 ("zlib" ,zlib)))
58cc3b38
AE
112 (description
113 "Libxslt is an XSLT C library developed for the GNOME project. It is
114based on libxml for XML parsing, tree manipulation and XPath support.")
115 (license license:x11)))
2a1e82bb
LC
116
117(define-public perl-xml-parser
118 (package
119 (name "perl-xml-parser")
120 (version "2.41")
121 (source (origin
122 (method url-fetch)
123 (uri (string-append
2b8c5f54 124 "mirror://cpan/authors/id/T/TO/TODDR/XML-Parser-"
2a1e82bb
LC
125 version ".tar.gz"))
126 (sha256
127 (base32
128 "1sadi505g5qmxr36lgcbrcrqh3a5gcdg32b405gnr8k54b6rg0dl"))))
129 (build-system perl-build-system)
130 (arguments `(#:make-maker-flags
131 (let ((expat (assoc-ref %build-inputs "expat")))
132 (list (string-append "EXPATLIBPATH=" expat "/lib")
133 (string-append "EXPATINCPATH=" expat "/include")))))
134 (inputs `(("expat" ,expat)))
135 (license (package-license perl))
136 (synopsis "Perl bindings to the Expat XML parsing library")
137 (description
138 "This module provides ways to parse XML documents. It is built on top of
139XML::Parser::Expat, which is a lower level interface to James Clark's expat
140library. Each call to one of the parsing methods creates a new instance of
141XML::Parser::Expat which is then used to parse the document. Expat options
142may be provided when the XML::Parser object is created. These options are
143then passed on to the Expat object on each parse call. They can also be given
144as extra arguments to the parse methods, in which case they override options
145given at XML::Parser creation time.")
146 (home-page "http://search.cpan.org/~toddr/XML-Parser-2.41/Parser.pm")))
37f9ff63 147
7339fbe2 148(define-public perl-libxml
1385ba4f 149 (package
7339fbe2 150 (name "perl-libxml")
1385ba4f
AE
151 (version "0.08")
152 (source (origin
153 (method url-fetch)
154 (uri (string-append
155 "mirror://cpan/authors/id/K/KM/KMACLEOD/libxml-perl-"
156 version ".tar.gz"))
157 (sha256
158 (base32
159 "1jy9af0ljyzj7wakqli0437zb2vrbplqj4xhab7bfj2xgfdhawa5"))))
160 (build-system perl-build-system)
7b81406a 161 (propagated-inputs
1385ba4f
AE
162 `(("perl-xml-parser" ,perl-xml-parser)))
163 (license (package-license perl))
164 (synopsis "Perl SAX parser using XML::Parser")
165 (description
166 "XML::Parser::PerlSAX is a PerlSAX parser using the XML::Parser
167module.")
168 (home-page "http://search.cpan.org/~kmacleod/libxml-perl/lib/XML/Parser/PerlSAX.pm")))
169
535dc6cf
AE
170(define-public perl-xml-simple
171 (package
172 (name "perl-xml-simple")
173 (version "2.20")
174 (source (origin
175 (method url-fetch)
176 (uri (string-append
177 "mirror://cpan/authors/id/G/GR/GRANTM/XML-Simple-"
178 version ".tar.gz"))
179 (sha256
180 (base32
181 "0jj3jiray1l4pi9wkjcpxjc3v431whdwx5aqnhgdm4i7h3817zsw"))))
182 (build-system perl-build-system)
183 (inputs
184 `(("perl-xml-parser" ,perl-xml-parser)))
185 (license (package-license perl))
186 (synopsis "Perl module for easy reading/writing of XML files")
187 (description
188 "The XML::Simple module provides a simple API layer on top of an
189underlying XML parsing module (either XML::Parser or one of the SAX2
190parser modules).")
191 (home-page "http://search.cpan.org/~grantm/XML-Simple-2.20/lib/XML/Simple.pm")))
192
a2e520af
AE
193(define-public perl-xml-regexp
194 (package
195 (name "perl-xml-regexp")
196 (version "0.04")
197 (source (origin
198 (method url-fetch)
199 (uri (string-append
200 "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-RegExp-"
201 version ".tar.gz"))
202 (sha256
203 (base32
204 "0m7wj00a2kik7wj0azhs1zagwazqh3hlz4255n75q21nc04r06fz"))))
205 (build-system perl-build-system)
206 (inputs
207 `(("perl-xml-parser" ,perl-xml-parser)))
208 (license (package-license perl))
209 (synopsis "Perl regular expressions for XML tokens")
210 (description
211 "XML::RegExp contains regular expressions for the following XML tokens:
212BaseChar, Ideographic, Letter, Digit, Extender, CombiningChar, NameChar,
213EntityRef, CharRef, Reference, Name, NmToken, and AttValue.")
214 (home-page "http://search.cpan.org/~tjmather/XML-RegExp/lib/XML/RegExp.pm")))
215
ad871fc6
AE
216(define-public perl-xml-dom
217 (package
218 (name "perl-xml-dom")
219 (version "1.44")
220 (source (origin
221 (method url-fetch)
222 (uri (string-append
223 "mirror://cpan/authors/id/T/TJ/TJMATHER/XML-DOM-"
224 version ".tar.gz"))
225 (sha256
226 (base32
227 "1r0ampc88ni3sjpzr583k86076qg399arfm9xirv3cw49k3k5bzn"))))
228 (build-system perl-build-system)
f7faff88
AE
229 (propagated-inputs
230 `(("perl-libwww" ,perl-libwww)
ad871fc6 231 ("perl-libxml" ,perl-libxml)
ad871fc6
AE
232 ("perl-xml-regexp" ,perl-xml-regexp)))
233 (license (package-license perl))
234 (synopsis
235 "Perl module for building DOM Level 1 compliant document structures")
236 (description
237 "This module extends the XML::Parser module by Clark Cooper. The
238XML::Parser module is built on top of XML::Parser::Expat, which is a lower
239level interface to James Clark's expat library. XML::DOM::Parser is derived
240from XML::Parser. It parses XML strings or files and builds a data structure
241that conforms to the API of the Document Object Model.")
242 (home-page "http://search.cpan.org/~tjmather/XML-DOM-1.44/lib/XML/DOM.pm")))
243
37f9ff63
AE
244(define-public xmlto
245 (package
246 (name "xmlto")
247 (version "0.0.25")
248 (source
249 (origin
250 (method url-fetch)
251 (uri (string-append
252 "https://fedorahosted.org/releases/x/m/xmlto/xmlto-"
253 version ".tar.bz2"))
254 (sha256
255 (base32
256 "0dp5nxq491gymq806za0dk4hngfmq65ysrqbn0ypajqbbl6vf71n"))))
257 (build-system gnu-build-system)
ae0c1202
LC
258 (arguments
259 ;; Make sure the reference to util-linux's 'getopt' is kept in 'xmlto'.
260 '(#:configure-flags (list (string-append "GETOPT="
261 (assoc-ref %build-inputs
262 "util-linux")
263 "/bin/getopt"))))
37f9ff63 264 (inputs
ae0c1202
LC
265 `(("util-linux" ,util-linux) ; for 'getopt'
266 ("libxml2" ,libxml2) ; for 'xmllint'
267 ("libxslt" ,libxslt))) ; for 'xsltproc'
37f9ff63
AE
268 (home-page "http://cyberelk.net/tim/software/xmlto/")
269 (synopsis "Front-end to an XSL toolchain")
270 (description
271 "Xmlto is a front-end to an XSL toolchain. It chooses an appropriate
272stylesheet for the conversion you want and applies it using an external
273XSL-T processor. It also performs any necessary post-processing.")
274 (license license:gpl2+)))