gnu: igt-gpu-tools: Don't use NAME in source URI.
[jackhill/guix/guix.git] / gnu / packages / docbook.scm
index ed1e60a..1e5379b 100644 (file)
@@ -2,6 +2,7 @@
 ;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org>
 ;;; Copyright © 2014 Eric Bavier <bavier@member.fsf.org>
 ;;; Copyright © 2016 Mathieu Lirzin <mthl@gnu.org>
+;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
                           (dtd    (string-append out "/xml/dtd/docbook")))
                      (mkdir-p dtd)
                      (with-directory-excursion dtd
-                       (system* unzip source))
+                       (invoke unzip source))
                      (substitute* (string-append out "/xml/dtd/docbook/catalog.xml")
                        (("uri=\"") 
                         (string-append 
-                         "uri=\"file://" dtd "/")))))
+                         "uri=\"file://" dtd "/")))
+                     #t))
                  #:modules ((guix build utils))))
     (native-inputs `(("unzip" ,unzip)))
     (home-page "http://docbook.org")
@@ -126,7 +128,7 @@ by no means limited to these applications.)  This package provides XML DTDs.")
                (dtd    (string-append (assoc-ref %outputs "out")
                                       "/xml/dtd/docbook")))
            (mkdir-p dtd)
-           (zero? (system* unzip source "-d" dtd))))))))
+           (invoke unzip source "-d" dtd)))))))
 
 (define-public docbook-xsl
   (package
@@ -136,11 +138,15 @@ by no means limited to these applications.)  This package provides XML DTDs.")
               (method url-fetch)
               (uri (string-append "mirror://sourceforge/docbook/docbook-xsl/"
                                   version "/docbook-xsl-" version ".tar.bz2"))
-              ;; Note: If removing all patches, the XZ dependency is no longer needed.
               (patches (search-patches "docbook-xsl-nonrecursive-string-subst.patch"))
               (sha256
                (base32
-                "0s59lihif2fr7rznckxr2kfyrvkirv76r1zvidp9b5mj28p4apvj"))))
+                "0s59lihif2fr7rznckxr2kfyrvkirv76r1zvidp9b5mj28p4apvj"))
+              (modules '((guix build utils)))
+              (snippet
+               '(begin
+                  (for-each delete-file (find-files "." "\\.jar$"))
+                  #t))))
     (build-system trivial-build-system)
     (arguments
      `(#:builder (let ((name-version (string-append ,name "-" ,version)))
@@ -153,7 +159,7 @@ by no means limited to these applications.)  This package provides XML DTDs.")
                           (out    (assoc-ref %outputs "out"))
                           (xsl    (string-append out "/xml/xsl")))
                      (setenv "PATH" (string-append bzip2 "/bin" ":" xz "/bin"))
-                     (system* (string-append tar "/bin/tar") "xvf" source)
+                     (invoke (string-append tar "/bin/tar") "xvf" source)
 
                      (mkdir-p xsl)
                      (copy-recursively name-version
@@ -162,10 +168,11 @@ by no means limited to these applications.)  This package provides XML DTDs.")
                      (substitute* (string-append xsl "/" name-version "/catalog.xml")
                        (("rewritePrefix=\"./")
                         (string-append "rewritePrefix=\"file://" xsl "/"
-                                       name-version "/")))))
-                 #:modules ((guix build utils))))
+                                       name-version "/")))
+                     #t))
+       #:modules ((guix build utils))))
     (native-inputs `(("bzip2" ,bzip2)
-                     ("xz" ,xz)
+                     ("xz" ,xz)         ;needed for repacked tarballs
                      ("tar" ,tar)))
     (home-page "http://docbook.org")
     (synopsis "DocBook XSL style sheets for document authoring")
@@ -176,7 +183,7 @@ by no means limited to these applications.)  This package provides XML DTDs.")
 (define-public dblatex
   (package
     (name "dblatex")
-    (version "0.3.9")
+    (version "0.3.10")
     (source (origin
               (method url-fetch)
               (uri (string-append "mirror://sourceforge/dblatex/dblatex/"
@@ -184,8 +191,7 @@ by no means limited to these applications.)  This package provides XML DTDs.")
                                   version ".tar.bz2"))
               (sha256
                (base32
-                "0pdizc5rjywwzxa1qqhdmba5zr35pbmdwbysalsid7xw87w3kq06"))
-              (patches (search-patches "dblatex-remove-multirow.patch"))))
+                "1yicd861rqz78i2khl35j7nvc0ccv4jx4hzqrbhll17082vrdmkg"))))
     (build-system python-build-system)
     ;; TODO: Add xfig/transfig for fig2dev utility
     (inputs
@@ -236,19 +242,19 @@ by no means limited to these applications.)  This package provides XML DTDs.")
        #:use-setuptools? #f
        #:tests? #f                      ;no 'test' command
        #:phases
-       (alist-cons-after
-        'wrap 'set-path
-        (lambda* (#:key inputs outputs #:allow-other-keys)
-          (let ((out (assoc-ref outputs "out")))
-            ;; dblatex executes helper programs at runtime.
-            (wrap-program (string-append out "/bin/dblatex")
-                          `("PATH" ":" prefix
-                            ,(map (lambda (input)
-                                    (string-append (assoc-ref inputs input)
-                                                   "/bin"))
-                                  '("libxslt" "texlive"
-                                    "imagemagick" "inkscape"))))))
-        %standard-phases)))
+       (modify-phases %standard-phases
+         (add-after 'wrap 'set-path
+           (lambda* (#:key inputs outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out")))
+               ;; dblatex executes helper programs at runtime.
+               (wrap-program (string-append out "/bin/dblatex")
+                 `("PATH" ":" prefix
+                   ,(map (lambda (input)
+                           (string-append (assoc-ref inputs input)
+                                          "/bin"))
+                         '("libxslt" "texlive"
+                           "imagemagick" "inkscape"))))
+               #t))))))
     (home-page "http://dblatex.sourceforge.net")
     (synopsis "DocBook to LaTeX Publishing")
     (description