gnu: python-pandas: Fix build on 32-bit.
[jackhill/guix/guix.git] / gnu / packages / xml.scm
index 1d63889..66eb63a 100644 (file)
@@ -13,7 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
-;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
+;;; Copyright © 2016, 2017 Marius Bakke <mbakke@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -74,6 +74,7 @@ things the parser might find in the XML document (like start tags).")
 (define-public libxml2
   (package
     (name "libxml2")
+    (replacement libxml2/fixed)
     (version "2.9.4")
     (source (origin
              (method url-fetch)
@@ -101,6 +102,15 @@ things the parser might find in the XML document (like start tags).")
 project (but it is usable outside of the Gnome platform).")
     (license license:x11)))
 
+(define libxml2/fixed
+  (package
+    (inherit libxml2)
+    (source
+      (origin
+        (inherit (package-source libxml2))
+        (patches (search-patches "libxml2-CVE-2016-4658.patch"
+                                 "libxml2-CVE-2016-5131.patch"))))))
+
 (define-public python-libxml2
   (package (inherit libxml2)
     (name "python-libxml2")
@@ -228,6 +238,34 @@ the @code{Graph} class and write it out in a specific file format.")
 @code{XML::Atom} implements the feed format as well as a client for the API.")
     (license (package-license perl))))
 
+(define-public perl-xml-descent
+  (package
+    (name "perl-xml-descent")
+    (version "1.04")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://cpan/authors/id/A/AN/ANDYA/"
+                                  "XML-Descent-" version ".tar.gz"))
+              (sha256
+               (base32
+                "0l5xmw2hd95ypppz3lyvp4sn02ccsikzjwacli3ydxfdz1bbh4d7"))))
+    (build-system perl-build-system)
+    (native-inputs
+     `(("perl-module-build" ,perl-module-build)))
+    (propagated-inputs
+     `(("perl-test-differences" ,perl-test-differences)
+       ("perl-xml-tokeparser" ,perl-xml-tokeparser)))
+    (home-page "http://search.cpan.org/dist/XML-Descent")
+    (synopsis "Recursive descent XML parsing")
+    (description
+     "The conventional models for parsing XML are either @dfn{DOM}
+(a data structure representing the entire document tree is created) or
+@dfn{SAX} (callbacks are issued for each element in the XML).
+
+XML grammar is recursive - so it's nice to be able to write recursive
+parsers for it.  @code{XML::Descent} allows such parsers to be created.")
+    (license (package-license perl))))
+
 (define-public perl-xml-parser
   (package
     (name "perl-xml-parser")
@@ -259,6 +297,29 @@ as extra arguments to the parse methods, in which case they override options
 given at XML::Parser creation time.")
     (home-page "http://search.cpan.org/dist/XML-Parser")))
 
+(define-public perl-xml-tokeparser
+  (package
+    (name "perl-xml-tokeparser")
+    (version "0.05")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://cpan/authors/id/P/PO/PODMASTER/"
+                                  "XML-TokeParser-" version ".tar.gz"))
+              (sha256
+               (base32
+                "1hnpwb3lh6cbgwvjjgqzcp6jm4mp612qn6ili38adc9nhkwv8fc5"))))
+    (build-system perl-build-system)
+    (propagated-inputs `(("perl-xml-parser" ,perl-xml-parser)))
+    (home-page "http://search.cpan.org/dist/XML-TokeParser")
+    (synopsis "Simplified interface to XML::Parser")
+    (description
+     "@code{XML::TokeParser} provides a procedural (\"pull mode\") interface
+to @code{XML::Parser} in much the same way that Gisle Aas'
+@code{HTML::TokeParser} provides a procedural interface to @code{HTML::Parser}.
+@code{XML::TokeParser} splits its XML input up into \"tokens\", each
+corresponding to an @code{XML::Parser} event.")
+    (license (package-license perl))))
+
 (define-public perl-libxml
   (package
     (name "perl-libxml")
@@ -591,14 +652,14 @@ a schema.")
 (define-public perl-xml-compile-cache
   (package
     (name "perl-xml-compile-cache")
-    (version "1.04")
+    (version "1.05")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
                                   "XML-Compile-Cache-" version ".tar.gz"))
               (sha256
                (base32
-                "1689dm54n7wb0n0cl9n77vk0kvg0mcckn2hz9ahigjhvazah8740"))))
+                "0xbwlszhi9hg8sxm5ylglm2qvnb689i595p913awrj2g4mp9yfsw"))))
     (build-system perl-build-system)
     (propagated-inputs
      `(("perl-log-report" ,perl-log-report)
@@ -614,14 +675,14 @@ a schema.")
 (define-public perl-xml-compile-soap
   (package
     (name "perl-xml-compile-soap")
-    (version "3.13")
+    (version "3.21")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
                                   "XML-Compile-SOAP-" version ".tar.gz"))
               (sha256
                (base32
-                "08qw63l78040nh37xzapbqp43g6s5l67bvskf3dyyizlarjx5mi4"))))
+                "0rxidh7kjyhnw2y789bqbwccnp8n0m3xskn524y9c752s64qpjcz"))))
     (build-system perl-build-system)
     (propagated-inputs
      `(("perl-file-slurp-tiny" ,perl-file-slurp-tiny)
@@ -642,14 +703,14 @@ used.")
 (define-public perl-xml-compile-wsdl11
   (package
     (name "perl-xml-compile-wsdl11")
-    (version "3.04")
+    (version "3.06")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://cpan/authors/id/M/MA/MARKOV/"
                                   "XML-Compile-WSDL11-" version ".tar.gz"))
               (sha256
                (base32
-                "0pyikwnfwpangvnkf5dbdagy4z93ag9824f1ax5qaibc3ghca8kv"))))
+                "0vbq05cpynm3jj81fw1k4nsb3wv4zngi6blvi1jhdarmh2rfg1x2"))))
     (build-system perl-build-system)
     (propagated-inputs
      `(("perl-log-report" ,perl-log-report)
@@ -707,14 +768,14 @@ RSS 0.91, RSS 1.0, RSS 2.0, Atom")
 (define-public perl-xml-xpath
   (package
     (name "perl-xml-xpath")
-    (version "1.37")
+    (version "1.40")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://cpan/authors/id/M/MA/MANWAR/"
                                   "XML-XPath-" version ".tar.gz"))
               (sha256
                (base32
-                "0997l8vjgq8p7d1irvp6amqyrv24x7f8hybjm4l4ayag32b13bmq"))))
+                "07pa0bl42jka8mj7jshjynx8vpfh8b4cdyiv4zlkqvkqz98nzxib"))))
     (build-system perl-build-system)
     (native-inputs
      `(("perl-path-tiny" ,perl-path-tiny)))
@@ -731,7 +792,7 @@ the form of functions.")
 (define-public pugixml
   (package
     (name "pugixml")
-    (version "1.7")
+    (version "1.8.1")
     (source
      (origin
       (method url-fetch)
@@ -739,17 +800,12 @@ the form of functions.")
                           version "/pugixml-" version ".tar.gz"))
       (sha256
        (base32
-        "1jpml475kbhs1aqwa48g2cbfxlrb9qp115m2j9yryxhxyr30vqgv"))))
+        "0fcgggry5x5bn0zhb09ij9hb0p45nb0sv0d9fw3cm1cf62hp9n80"))))
     (build-system cmake-build-system)
     (arguments
-     `(#:tests? #f
-       #:out-of-source? #f
-       #:phases (modify-phases %standard-phases
-                  (add-before
-                   'configure 'chdir
-                   (lambda _
-                     (chdir "scripts")
-                     #t)))))
+     `(#:configure-flags '("-DCMAKE_CXX_FLAGS=-shared -fPIC"
+                           "-DCMAKE_C_FLAGS=-shared -fPIC")
+       #:tests? #f))                    ; no tests
     (home-page "http://pugixml.org")
     (synopsis "Light-weight, simple and fast XML parser for C++ with XPath support")
     (description
@@ -793,9 +849,11 @@ code for classes that correspond to data structures defined by XMLSchema.")
     (source
      (origin
       (method url-fetch)
-      (uri (string-append
-            "https://fedorahosted.org/releases/x/m/xmlto/xmlto-"
-            version ".tar.bz2"))
+      ;; The old source on fedorahosted.org is offline permanently:
+      ;; <https://bugs.gnu.org/25989>
+      (uri (string-append "mirror://debian/pool/main/x/xmlto/"
+                          "xmlto_" version ".orig.tar.bz2"))
+      (file-name (string-append name "-" version ".tar.bz2"))
       (sha256
        (base32
         "0xhj8b2pwp4vhl9y16v3dpxpsakkflfamr191mprzsspg4xdyc0i"))))