mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-11-07 07:26:13 -05:00
gnu: ghostscript: Add "doc" output.
* gnu/packages/ghostscript.scm (ghostscript)[source](snippet): New field. [outputs]: New field. [arguments]: Add 'remove-doc-reference' phase.
This commit is contained in:
parent
4a6aeb670f
commit
9161ba818d
1 changed files with 16 additions and 1 deletions
|
@ -129,8 +129,15 @@ (define-public ghostscript
|
|||
(sha256
|
||||
(base32
|
||||
"0q4jj41p0qbr4mgcc9q78f5zs8cm1g57wgryhsm2yq4lfslm3ib1"))
|
||||
(patches (list (search-patch "ghostscript-runpath.patch")))))
|
||||
(patches (list (search-patch "ghostscript-runpath.patch")))
|
||||
(modules '((guix build utils)))
|
||||
(snippet
|
||||
;; Honor --docdir.
|
||||
'(substitute* "Makefile.in"
|
||||
(("^docdir=.*$") "docdir = @docdir@\n")
|
||||
(("^exdir=.*$") "exdir = $(docdir)/examples\n")))))
|
||||
(build-system gnu-build-system)
|
||||
(outputs '("out" "doc")) ;16 MiB of HTML/PS doc + examples
|
||||
(inputs `(("freetype" ,freetype)
|
||||
("lcms" ,lcms)
|
||||
("libjpeg-8" ,libjpeg-8)
|
||||
|
@ -152,6 +159,14 @@ (define-public ghostscript
|
|||
(("/bin/sh") (which "bash")))
|
||||
(substitute* "base/unixhead.mak"
|
||||
(("/bin/sh") (which "bash")))))
|
||||
(add-after 'configure 'remove-doc-reference
|
||||
(lambda _
|
||||
;; Don't retain a reference to the 'doc' output in 'gs'.
|
||||
;; The only use of this definition is in the output of
|
||||
;; 'gs --help', so this change is fine.
|
||||
(substitute* "base/gscdef.c"
|
||||
(("GS_DOCDIR")
|
||||
"\"~/.guix-profile/share/doc/ghostscript\""))))
|
||||
(add-after 'build 'build-so
|
||||
(lambda _
|
||||
(zero? (system* "make" "so"))))
|
||||
|
|
Loading…
Reference in a new issue