summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicolas Goaziou <mail@nicolasgoaziou.fr>2022-01-28 13:10:04 +0100
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2022-01-28 13:10:04 +0100
commitdecd4c36798f0c89a5927c33b395e3a73f26ab52 (patch)
treedcf08a1b8c8d1628b7726174087f8994e39b6708
parentd024a21fbe5572474e2655ce945c69a9b587cbfc (diff)
downloadguix-decd4c36798f0c89a5927c33b395e3a73f26ab52.tar.gz
gnu: texlive-babel-french: Add missing files.
* gnu/packages/tex.scm (texlive-babel-french)[outputs]: Add "doc" output.
[arguments]<#:phases>: Install documentation and source files.
-rw-r--r--gnu/packages/tex.scm15
1 files changed, 13 insertions, 2 deletions
diff --git a/gnu/packages/tex.scm b/gnu/packages/tex.scm
index a7a0a8b3ab..63aeefc6cd 100644
--- a/gnu/packages/tex.scm
+++ b/gnu/packages/tex.scm
@@ -4059,16 +4059,27 @@ for Canadian and USA text.")
           (base32 "0cgn4dq5wnlfh9wddjzxsf7p56pk29lyndg56zg6558y7xf67cw8"))))
     (package
       (inherit template)
+      (outputs '("out" "doc"))
       (arguments
        (substitute-keyword-arguments (package-arguments template)
          ((#:tex-directory _ '())
           "generic/babel-french")
          ((#:build-targets _ '())
-          ''("frenchb.ins"))           ; TODO: use dtx and build documentation
+          ;; TODO: use dtx and build documentation.
+          '(list "frenchb.ins"))
          ((#:phases phases)
           `(modify-phases ,phases
              (add-after 'unpack 'chdir
-               (lambda _ (chdir "source/generic/babel-french")))))))
+               (lambda _ (chdir "source/generic/babel-french")))
+             (replace 'copy-files
+               (lambda* (#:key inputs outputs #:allow-other-keys)
+                 (let ((origin (assoc-ref inputs "source"))
+                       (source (string-append (assoc-ref outputs "out")
+                                              "/share/texmf-dist/source"))
+                       (doc (string-append (assoc-ref outputs "doc")
+                                           "/share/texmf-dist/doc")))
+                   (copy-recursively (string-append origin "/source") source)
+                   (copy-recursively (string-append origin "/doc") doc))))))))
       (home-page "https://ctan.org/macros/latex/contrib/babel-contrib/french")
       (synopsis "Babel contributed support for French")
       (description