gnu: Add perl-xml-libxslt.
[jackhill/guix/guix.git] / gnu / packages / xml.scm
index b2f51bd..80534d6 100644 (file)
@@ -12,6 +12,8 @@
 ;;; Copyright © 2016 Ben Woodcroft <donttrustben@gmail.com>
 ;;; 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>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
 (define-public expat
   (package
     (name "expat")
-    (version "2.1.1")
+    (version "2.2.0")
     (source (origin
              (method url-fetch)
              (uri (string-append "mirror://sourceforge/expat/expat/"
                                  version "/expat-" version ".tar.bz2"))
-             (patches (search-patches "expat-CVE-2012-6702-and-CVE-2016-5300.patch"
-                                      "expat-CVE-2015-1283-refix.patch"
-                                      "expat-CVE-2016-0718.patch"))
+             (patches
+               (search-patches "expat-CVE-2016-0718-fix-regression.patch"))
              (sha256
               (base32
-               "0ryyjgvy7jq0qb7a9mhc1giy3bzn56aiwrs8dpydqngplbjq9xdg"))))
+               "1zq4lnwjlw8s9mmachwfvfjf2x3lk24jm41746ykhdcvs7r0zrfr"))))
     (build-system gnu-build-system)
     (home-page "http://www.libexpat.org/")
     (synopsis "Stream-oriented XML parser library written in C")
@@ -133,6 +134,7 @@ project (but it is usable outside of the Gnome platform).")
 (define-public libxslt
   (package
     (name "libxslt")
+    (replacement libxslt/fixed)
     (version "1.1.29")
     (source (origin
              (method url-fetch)
@@ -154,6 +156,14 @@ project (but it is usable outside of the Gnome platform).")
 based on libxml for XML parsing, tree manipulation and XPath support.")
     (license license:x11)))
 
+(define libxslt/fixed
+  (package
+    (inherit libxslt)
+    (name "libxslt")
+    (source (origin
+              (inherit (package-source libxslt))
+              (patches (search-patches "libxslt-CVE-2016-4738.patch"))))))
+
 (define-public perl-graph-readwrite
   (package
     (name "perl-graph-readwrite")
@@ -319,6 +329,29 @@ XML parser and the high performance DOM implementation.")
 @code{XML::LibXML}.")
     (license (package-license perl))))
 
+(define-public perl-xml-libxslt
+  (package
+    (name "perl-xml-libxslt")
+    (version "1.95")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "mirror://cpan/authors/id/S/SH/SHLOMIF/"
+                           "XML-LibXSLT-" version ".tar.gz"))
+       (sha256
+        (base32
+         "0dggycql18kfxzkb1kw3yc7gslxlrrgyyn2r2ygsylycb89j3jpi"))))
+    (build-system perl-build-system)
+    (inputs
+     `(("libxslt" ,libxslt)))
+    (propagated-inputs
+     `(("perl-xml-libxml" ,perl-xml-libxml)))
+    (home-page "http://search.cpan.org/dist/XML-LibXSLT")
+    (synopsis "Perl bindings to GNOME libxslt library")
+    (description "This Perl module is an interface to the GNOME project's
+libxslt library.")
+    (license (package-license perl))))
+
 (define-public perl-xml-namespacesupport
   (package
     (name "perl-xml-namespacesupport")
@@ -631,6 +664,45 @@ encoding of the message to be send into XML, sending the message to the
 server, collect the answer, and finally decoding the XML to Perl.")
     (license (package-license perl))))
 
+(define-public perl-xml-feed
+  (package
+    (name "perl-xml-feed")
+    (version "0.53")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://cpan/authors/id/D/DA/DAVECROSS/"
+                                  "XML-Feed-" version ".tar.gz"))
+              (sha256
+               (base32
+                "07b165g6wk8kqwpl49r3n0kag6p2nrkyp3ch0h8qyxb6nrnkkq7c"))))
+    (build-system perl-build-system)
+    (arguments
+     `(#:tests? #f)) ; Tests require internet connection
+    (native-inputs
+     `(("perl-module-build" ,perl-module-build)
+       ("perl-uri" ,perl-uri)
+       ("perl-class-data-inheritable" ,perl-class-data-inheritable)))
+    (inputs
+     `(("perl-class-errorhandler" ,perl-class-errorhandler)
+       ("perl-datetime" ,perl-datetime)
+       ("perl-datetime-format-mail" ,perl-datetime-format-mail)
+       ("perl-datetime-format-w3cdtf" ,perl-datetime-format-w3cdtf)
+       ("perl-feed-find" ,perl-feed-find)
+       ("perl-html-parser" ,perl-html-parser)
+       ("perl-libwww-perl" ,perl-libwww)
+       ("perl-module-pluggable" ,perl-module-pluggable)
+       ("perl-uri-fetch" ,perl-uri-fetch)
+       ("perl-xml-atom" ,perl-xml-atom)
+       ("perl-xml-libxml" ,perl-xml-libxml)
+       ("perl-xml-rss" ,perl-xml-rss)))
+    (home-page "http://search.cpan.org/dist/XML-Feed")
+    (synopsis "XML Syndication Feed Support")
+    (description "@code{XML::Feed} is a syndication feed parser for both RSS and
+Atom feeds.  It also implements feed auto-discovery for finding feeds, given a URI.
+@code{XML::Feed} supports the following syndication feed formats:
+RSS 0.91, RSS 1.0, RSS 2.0, Atom")
+    (license (package-license perl))))
+
 (define-public perl-xml-xpath
   (package
     (name "perl-xml-xpath")
@@ -689,6 +761,30 @@ different Unicode encodings which happen automatically during
 parsing/saving.")
     (license license:expat)))
 
+(define-public python-pyxb
+  (package
+    (name "python-pyxb")
+    (version "1.2.5")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "PyXB" version))
+              (sha256
+               (base32
+                "0rzzwibfqa28gxgcxx4cybx1qcg0g6fand06ykj3gz7z5kp653sf"))))
+    (build-system python-build-system)
+    (home-page "http://pyxb.sourceforge.net/")
+    (synopsis "Python XML Schema Bindings")
+    (description
+     "PyXB (\"pixbee\") is a pure Python package that generates Python source
+code for classes that correspond to data structures defined by XMLSchema.")
+    (license (list license:asl2.0    ; Most files.
+                   license:expat     ; pyxb/utils/six.py
+                   license:gpl2      ; bundled jquery in doc is dual MIT/GPL2
+                   license:psfl))))  ; pyxb/utils/activestate.py
+
+(define-public python2-pyxb
+  (package-with-python2 python-pyxb))
+
 (define-public xmlto
   (package
     (name "xmlto")
@@ -840,10 +936,31 @@ Cflags: -I${includedir}
                #t))))))
     (synopsis "Small XML parser for C++")
     (description "TinyXML is a small and simple XML parsing library for the
-C++ programming langauge.")
+C++ programming language.")
     (home-page "http://www.grinninglizard.com/tinyxml/index.html")
     (license license:zlib)))
 
+(define-public tinyxml2
+  (package
+    (name "tinyxml2")
+    (version "4.0.1")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/leethomason/tinyxml2/archive/"
+                           version ".tar.gz"))
+       (sha256
+       (base32
+        "083z4r4khcndxi9k840lcr48sqxvar4gpsnf749xfdn1bkr8xcql"))))
+    (build-system cmake-build-system)
+    (arguments
+     `(#:tests? #f))    ; no tests
+    (synopsis "Small XML parser for C++")
+    (description "TinyXML2 is a small and simple XML parsing library for the
+C++ programming language.")
+    (home-page "http://www.grinninglizard.com/tinyxml2/")
+    (license license:zlib)))
+
 (define-public xmlstarlet
  (package
    (name "xmlstarlet")