summaryrefslogtreecommitdiff
path: root/gnu/packages/texinfo.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/texinfo.scm')
-rw-r--r--gnu/packages/texinfo.scm35
1 files changed, 35 insertions, 0 deletions
diff --git a/gnu/packages/texinfo.scm b/gnu/packages/texinfo.scm
index 5c1204ed2e9..8f5913ac89f 100644
--- a/gnu/packages/texinfo.scm
+++ b/gnu/packages/texinfo.scm
@@ -101,6 +101,41 @@ is on expressing the content semantically, avoiding physical markup commands.")
101 (native-inputs '()) 101 (native-inputs '())
102 (inputs `(("ncurses" ,ncurses) ("xz" ,xz))))) 102 (inputs `(("ncurses" ,ncurses) ("xz" ,xz)))))
103 103
104(define-public info-reader
105 ;; The idea of this package is to have the standalone Info reader without
106 ;; the dependency on Perl that 'makeinfo' drags.
107 (package
108 (inherit texinfo-6.1)
109 (name "info-reader")
110 (arguments
111 `(#:disallowed-references ,(assoc-ref (package-inputs texinfo-6.1)
112 "perl")
113
114 #:modules ((ice-9 ftw) (srfi srfi-1)
115 ,@%gnu-build-system-modules)
116
117 #:phases (modify-phases %standard-phases
118 (add-after 'install 'keep-only-info-reader
119 (lambda* (#:key outputs #:allow-other-keys)
120 ;; Remove everything but 'bin/info' and associated
121 ;; files.
122 (define (files)
123 (scandir "." (lambda (file)
124 (not (member file '("." ".."))))))
125
126 (let ((out (assoc-ref outputs "out")))
127 (with-directory-excursion out
128 (for-each delete-file-recursively
129 (fold delete (files) '("bin" "share"))))
130 (with-directory-excursion (string-append out "/bin")
131 (for-each delete-file (delete "info" (files))))
132 (with-directory-excursion (string-append out "/share")
133 (for-each delete-file-recursively
134 (fold delete (files)
135 '("info" "locale"))))
136 #t))))))
137 (synopsis "Standalone Info documentation reader")))
138
104(define-public texi2html 139(define-public texi2html
105 (package 140 (package
106 (name "texi2html") 141 (name "texi2html")