gnu: Add texlive-xcolor.

* gnu/packages/tex.scm (texlive-latex-xcolor): Bind to deprecated package
pointing...
(texlive-color): ...to this variable; implement in terms of
simple-texlive-package.
[arguments]: Add phase "move-files" to install xcolor.pro to the expected
location.
This commit is contained in:
Ricardo Wurmus 2019-09-05 15:36:02 +02:00
parent f1a46c9025
commit 266e07421e
No known key found for this signature in database
GPG Key ID: 197A5888235FACAC
1 changed files with 33 additions and 18 deletions

View File

@ -2875,19 +2875,31 @@ documents. It comprises the packages color, graphics, graphicx, trig, epsfig,
keyval, and lscape.")
(license license:lppl1.3c+)))
(define-public texlive-latex-xcolor
(package
(name "texlive-latex-xcolor")
(version (number->string %texlive-revision))
(source (origin
(method svn-fetch)
(uri (texlive-ref "latex" "xcolor"))
(file-name (string-append name "-" version "-checkout"))
(sha256
(define-public texlive-xcolor
(let ((template (simple-texlive-package
"texlive-xcolor"
(list "/doc/latex/xcolor/"
"/source/latex/xcolor/")
(base32
"01n613s7bcrd2n4jfawm0k4nn2ny3aaifp2jjfif3lz4sbv31494"))))
(build-system texlive-build-system)
(arguments '(#:tex-directory "latex/xcolor"))
"12q6spmpxg30alhvarjmxzigmz7lazapbrb0mc4vhbn6n1sdz7pp"))))
(package
(inherit template)
(arguments
(substitute-keyword-arguments (package-arguments template)
((#:tex-directory _ #t)
"latex/xcolor")
((#:phases phases)
`(modify-phases ,phases
(add-after 'unpack 'chdir
(lambda _ (chdir "source/latex/xcolor") #t))
(add-after 'install 'move-files
(lambda* (#:key outputs #:allow-other-keys)
(let ((share (string-append (assoc-ref outputs "out")
"/share/texmf-dist")))
(mkdir-p (string-append share "/dvips/xcolor"))
(rename-file (string-append share "/tex/latex/xcolor/xcolor.pro")
(string-append share "/dvips/xcolor/xcolor.pro"))
#t)))))))
(home-page "https://www.ctan.org/pkg/xcolor")
(synopsis "Driver-independent color extensions for LaTeX and pdfLaTeX")
(description
@ -2898,7 +2910,10 @@ document-wide target color model and offers complete tools for conversion
between eight color models. Additionally, there is a command for alternating
row colors plus repeated non-aligned material (like horizontal lines) in
tables.")
(license license:lppl1.2+)))
(license license:lppl1.2+))))
(define-public texlive-latex-xcolor
(deprecated-package "texlive-latex-xcolor" texlive-xcolor))
(define-public texlive-latex-hyperref
(package