gnu: emacs-svg-icon: Fix grammar.
[jackhill/guix/guix.git] / gnu / packages / documentation.scm
CommitLineData
436d4d1f 1;;; GNU Guix --- Functional package management for GNU
189be331 2;;; Copyright © 2014, 2018 Ludovic Courtès <ludo@gnu.org>
7c853c02 3;;; Copyright © 2014, 2016 Andreas Enge <andreas@enge.fr>
b4e655e5 4;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
fa8af53e 5;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
603308ee 6;;; Copyright © 2016 Thomas Danckaert <post@thomasdanckaert.be>
3c8ba11a 7;;; Copyright © 2017 Kei Kebreau <kkebreau@posteo.net>
e951c9f2 8;;; Copyright © 2017, 2020 Efraim Flashner <efraim@flashner.co.il>
ccfe4aa1 9;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
21b0ed1f 10;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
013a0bc0 11;;; Copyright © 2020 Ricardo Wurmus <rekado@elephly.net>
b7a225e3 12;;; Copyright © 2020, 2021 Michael Rohleder <mike@rohleder.de>
436d4d1f
AE
13;;;
14;;; This file is part of GNU Guix.
15;;;
16;;; GNU Guix is free software; you can redistribute it and/or modify it
17;;; under the terms of the GNU General Public License as published by
18;;; the Free Software Foundation; either version 3 of the License, or (at
19;;; your option) any later version.
20;;;
21;;; GNU Guix is distributed in the hope that it will be useful, but
22;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24;;; GNU General Public License for more details.
25;;;
26;;; You should have received a copy of the GNU General Public License
27;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
0573a923
EB
29(define-module (gnu packages documentation)
30 #:use-module (guix licenses)
436d4d1f
AE
31 #:use-module (guix packages)
32 #:use-module (guix download)
013a0bc0 33 #:use-module (guix git-download)
0573a923 34 #:use-module (guix build-system gnu)
7c853c02 35 #:use-module (guix build-system cmake)
7d456e52 36 #:use-module (guix build-system qt)
436d4d1f 37 #:use-module (gnu packages)
ccfe4aa1 38 #:use-module (gnu packages autotools)
7d456e52 39 #:use-module (gnu packages backup)
21b0ed1f 40 #:use-module (gnu packages base)
603308ee 41 #:use-module (gnu packages bash)
0573a923 42 #:use-module (gnu packages python)
436d4d1f 43 #:use-module (gnu packages bison)
7d456e52 44 #:use-module (gnu packages kde-frameworks)
fa8af53e 45 #:use-module (gnu packages docbook)
436d4d1f 46 #:use-module (gnu packages flex)
9e57c1b5 47 #:use-module (gnu packages graphviz)
b4e655e5 48 #:use-module (gnu packages gettext)
fa8af53e 49 #:use-module (gnu packages glib)
436d4d1f 50 #:use-module (gnu packages perl)
7d456e52
MR
51 #:use-module (gnu packages pkg-config)
52 #:use-module (gnu packages qt)
53 #:use-module (gnu packages sqlite)
54 #:use-module (gnu packages xml)
55 #:use-module (gnu packages xorg))
0573a923 56
22e44094
RG
57(define-public latex2html
58 (package
59 (name "latex2html")
60 (version "2020.2")
61 (source
62 (origin
63 (method git-fetch)
64 (uri
65 (git-reference
8ed4c468 66 (url "https://github.com/latex2html/latex2html")
22e44094
RG
67 (commit (string-append "v" version))))
68 (file-name (git-file-name name version))
69 (sha256
70 (base32 "1icyl6kl60wh7cavprgbd8q6lpjwr7wn24m34kpiif7ahknhcbcm"))))
71 (build-system gnu-build-system)
72 (arguments
73 `(#:phases
74 (modify-phases %standard-phases
75 (add-after 'unpack 'patch-configure
76 (lambda* (#:key outputs #:allow-other-keys)
77 (substitute* "configure"
78 (("/usr/local")
79 (assoc-ref outputs "out"))
80 (("\\$\\{CONFIG_SHELL-/bin/sh\\}")
81 (which "bash")))
82 #t))
83 (replace 'configure
84 (lambda _
85 (invoke "./configure")
86 #t))
87 (add-after 'configure 'patch-cfgcache
88 (lambda* (#:key outputs #:allow-other-keys)
89 (substitute* "cfgcache.pm"
90 (("/usr/local")
91 (assoc-ref outputs "out")))
92 #t)))))
93 (inputs
94 `(("perl" ,perl)))
95 (synopsis "LaTeX documents to HTML")
96 (description "LaTeX2HTML is a utility that converts LaTeX documents to web
97pages in HTML.")
98 (home-page "https://www.latex2html.org/")
99 (license gpl2+)))
100
0573a923
EB
101(define-public asciidoc
102 (package
103 (name "asciidoc")
ccfe4aa1 104 (version "8.6.10")
0573a923 105 (source (origin
e951c9f2
EF
106 (method git-fetch)
107 (uri (git-reference
53c40b3c 108 (url "https://github.com/asciidoc-py/asciidoc-py2")
e951c9f2
EF
109 (commit version)))
110 (file-name (git-file-name name version))
0573a923
EB
111 (sha256
112 (base32
e951c9f2 113 "1hrqkgjmp1gq3f9rkbr8l0y62fzvwb9n8ys35s25bg2ld04y4g4y"))))
0573a923 114 (build-system gnu-build-system)
dd10ba63
115 (arguments
116 `(#:tests? #f ; no 'check' target
117 #:phases
118 (modify-phases %standard-phases
8a442e5d
MW
119 (replace 'bootstrap
120 (lambda _
121 (invoke "autoconf")))
9099a457
KK
122 ;; Some XML-related binaries are required for asciidoc's proper usage.
123 ;; Without these, asciidoc fails when parsing XML documents, either
124 ;; reporting a missing "xmllint" binary or, when passed the
125 ;; "--no-xmllint" option, a missing "xsltproc" binary.
126 ;; The following phase enables asciidoc to find some of them.
127 (add-before 'configure 'set-xml-binary-paths
128 (lambda* (#:key inputs #:allow-other-keys)
129 (let* ((libxml2 (assoc-ref inputs "libxml2"))
130 (xmllint (string-append libxml2 "/bin/xmllint"))
131 (libxslt (assoc-ref inputs "libxslt"))
132 (xsltproc (string-append libxslt "/bin/xsltproc")))
133 (substitute* "a2x.py"
134 (("XMLLINT = 'xmllint'")
135 (string-append "XMLLINT = '" xmllint "'"))
136 (("XSLTPROC = 'xsltproc'")
137 (string-append "XSLTPROC = '" xsltproc "'")))
138 #t)))
dd10ba63
139 ;; Make asciidoc use the local docbook-xsl package instead of fetching
140 ;; it from the internet at run-time.
141 (add-before 'install 'make-local-docbook-xsl
142 (lambda* (#:key inputs #:allow-other-keys)
143 (substitute* (find-files "docbook-xsl" ".*\\.xsl$")
144 (("xsl:import href=\"http://docbook.sourceforge.net/\
145release/xsl/current")
146 (string-append
147 "xsl:import href=\""
148 (string-append (assoc-ref inputs "docbook-xsl")
149 "/xml/xsl/docbook-xsl-"
150 ,(package-version docbook-xsl)))))
3078821d
KK
151 #t))
152 ;; Do the same for docbook-xml.
153 (add-before 'install 'make-local-docbook-xml
154 (lambda* (#:key inputs #:allow-other-keys)
155 (substitute* "docbook45.conf"
156 (("http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd")
157 (string-append (assoc-ref inputs "docbook-xml")
158 "/xml/dtd/docbook/docbookx.dtd")))
dd10ba63 159 #t)))))
ccfe4aa1
TGR
160 (native-inputs
161 `(("autoconf" ,autoconf)))
dd10ba63 162 (inputs `(("python" ,python-2)
3078821d 163 ("docbook-xml" ,docbook-xml)
9099a457
KK
164 ("docbook-xsl" ,docbook-xsl)
165 ("libxml2" ,libxml2)
166 ("libxslt" ,libxslt)))
42d11593 167 (home-page "https://asciidoc.org/")
0573a923
EB
168 (synopsis "Text-based document generation system")
169 (description
170 "AsciiDoc is a text document format for writing notes, documentation,
171articles, books, ebooks, slideshows, web pages, man pages and blogs.
172AsciiDoc files can be translated to many formats including HTML, PDF,
173EPUB, man page.
174
175AsciiDoc is highly configurable: both the AsciiDoc source file syntax and
176the backend output markups (which can be almost any type of SGML/XML
177markup) can be customized and extended by the user.")
178 (license gpl2+)))
436d4d1f 179
013a0bc0
RW
180(define-public asciidoc-py3
181 (package (inherit asciidoc)
182 (name "asciidoc-py3")
58670cee 183 (version "9.0.1")
013a0bc0
RW
184 (source (origin
185 (method git-fetch)
186 (uri (git-reference
187 (url "https://github.com/asciidoc/asciidoc-py3/")
188 (commit version)))
189 (file-name (git-file-name name version))
190 (sha256
191 (base32
58670cee 192 "1xpws5lgzaqwgbc7sq6bp8adjxy8qb4qb9nj4vvpxamjgx3pny54"))))
013a0bc0
RW
193 (build-system gnu-build-system)
194 (native-inputs
195 `(("autoconf" ,autoconf)))
196 (inputs
197 `(("python" ,python)
198 ("docbook-xml" ,docbook-xml)
199 ("docbook-xsl" ,docbook-xsl)
200 ("libxml2" ,libxml2)
201 ("libxslt" ,libxslt)))))
202
436d4d1f
AE
203(define-public doxygen
204 (package
205 (name "doxygen")
b34c1258 206 (version "1.8.17")
58c6a93d 207 (home-page "http://www.doxygen.nl/")
436d4d1f
AE
208 (source (origin
209 (method url-fetch)
58c6a93d
MB
210 (uri (list (string-append home-page "files/doxygen-"
211 version ".src.tar.gz")
212 (string-append "mirror://sourceforge/doxygen/rel-"
213 version "/doxygen-" version
214 ".src.tar.gz")))
436d4d1f
AE
215 (sha256
216 (base32
b34c1258
MB
217 "16dmv0gm1x8rvbm82fmjvi213q8fxqxinm75pcf595flya59ific"))
218 (patches (search-patches "doxygen-test.patch"
219 "doxygen-1.8.17-runtests.patch"))))
7c853c02 220 (build-system cmake-build-system)
436d4d1f
AE
221 (native-inputs
222 `(("bison" ,bison)
ff685049 223 ("flex" ,flex)
f826ac47
MB
224 ("libxml2" ,libxml2) ;provides xmllint for the tests
225 ("python" ,python))) ;for creating the documentation
603308ee 226 (inputs
fb76ef84 227 `(("bash" ,bash-minimal)))
436d4d1f 228 (arguments
21b0ed1f
MO
229 ;; Force cmake to use iconv header from cross-libc instead of the one
230 ;; from native libc.
231 `(,@(if (%current-target-system)
232 '(#:configure-flags
233 (list (string-append "-DICONV_INCLUDE_DIR="
234 (assoc-ref %build-inputs "cross-libc")
235 "/include")))
236 '())
237 #:test-target "tests"
603308ee
TD
238 #:phases (modify-phases %standard-phases
239 (add-before 'configure 'patch-sh
240 (lambda* (#:key inputs #:allow-other-keys)
241 (substitute* "src/portable.cpp"
242 (("/bin/sh")
243 (string-append
244 (assoc-ref inputs "bash") "/bin/sh")))
245 #t)))))
35b9e423 246 (synopsis "Generate documentation from annotated sources")
436d4d1f
AE
247 (description "Doxygen is the de facto standard tool for generating
248documentation from annotated C++ sources, but it also supports other popular
249programming languages such as C, Objective-C, C#, PHP, Java, Python,
250IDL (Corba, Microsoft, and UNO/OpenOffice flavors), Fortran, VHDL, Tcl,
251and to some extent D.")
252 (license gpl3+)))
b4e655e5
EB
253
254(define-public doc++
255 (package
256 (name "doc++")
257 (version "3.4.10")
258 (source (origin
259 (method url-fetch)
260 (uri (string-append "https://sourceforge.net/projects/docpp/"
261 "files/doc++-" version ".tar.gz"))
262 (sha256
263 (base32
264 "0i37zlxl8g352s4hzpdx0657k5x3czh3xcsfr27irc708gb277pn"))
265 (patches (search-patches "doc++-include-directives.patch"
266 "doc++-segfault-fix.patch"))))
267 (build-system gnu-build-system)
268 (native-inputs
269 `(("flex" ,flex)
b94a6ca0 270 ("gettext" ,gettext-minimal)))
b4e655e5
EB
271 (home-page "http://docpp.sourceforge.net/")
272 (synopsis "Documentation system for C, C++, IDL, and Java")
273 (description
274 "DOC++ is a documentation system for C, C++, IDL, and Java. It can
275generate both TeX output for high-quality hardcopies or HTML output for online
7230f6d5 276browsing. The documentation is extracted directly from the C/C++/IDL source
b4e655e5
EB
277or Java class files.")
278 (license gpl2+)))
fa8af53e
RJ
279
280(define-public scrollkeeper
281 (package
282 (name "scrollkeeper")
283 (version "0.3.14")
284 (source
285 (origin
286 (method url-fetch)
de67e922
LF
287 (uri (string-append "mirror://sourceforge/scrollkeeper/scrollkeeper/"
288 version "/scrollkeeper-" version ".tar.gz"))
fa8af53e
RJ
289 (sha256
290 (base32 "1bfxwxc1ngh11v36z899sz9qam366r050fhkyb5adv65lb1x62sa"))))
291 (build-system gnu-build-system)
292 (arguments
293 `(#:configure-flags
294 (list (string-append "--with-xml-catalog="
295 (assoc-ref %build-inputs "docbook-xml")
296 "/xml/dtd/docbook/catalog.xml"))))
297 (inputs
298 `(("perl" ,perl)
299 ("libxml2" ,libxml2)
300 ("libxslt" ,libxslt)
301 ;; The configure script checks for either version 4.2 or 4.1.2.
302 ("docbook-xml" ,docbook-xml-4.2)))
303 (native-inputs
304 `(("intltool" ,intltool)))
305 (home-page "http://scrollkeeper.sourceforge.net/")
306 (synopsis "Open Documentation Cataloging Project")
307 (description "ScrollKeeper is a cataloging system for documentation on open
308systems. It manages documentation metadata as specified by the Open Source
309Metadata Framework and provides a simple API to allow help browsers to find,
310sort, and search the document catalog. It will also be able to communicate
311with catalog servers on the Net to search for documents which are not on the
312local system.")
313 (license lgpl2.1+)))
7d456e52
MR
314
315(define-public zeal
b7a225e3
MR
316 (let ((commit "d3c5521c501d24050f578348ff1b9d68244b992c")
317 (revision "1"))
318 (package
319 (name "zeal")
320 (version (git-version "0.6.1" revision commit))
321 (source
322 (origin
323 (method git-fetch)
324 (uri (git-reference
325 (url "https://github.com/zealdocs/zeal")
326 (commit commit)))
327 (file-name (git-file-name name version))
328 (sha256
329 (base32 "1ky2qi2cmjckc51lm3i28815ixgqdm36j7smixxr16jxpmbqs6sl"))))
330 (build-system qt-build-system)
331 (arguments
332 `(#:tests? #f ;no tests
333 #:phases
334 (modify-phases %standard-phases
335 (add-after 'wrap 'wrap-qt-process-path
336 (lambda* (#:key inputs outputs #:allow-other-keys)
337 (let* ((out (assoc-ref outputs "out"))
338 (bin (string-append out "/bin/zeal"))
339 (qt-process-path (string-append
340 (assoc-ref inputs "qtwebengine")
341 "/lib/qt5/libexec/QtWebEngineProcess")))
342 (wrap-program bin
343 `("QTWEBENGINEPROCESS_PATH" = (,qt-process-path)))
344 #t))))))
345 (native-inputs
346 `(("extra-cmake-modules" ,extra-cmake-modules)
347 ("pkg-config" ,pkg-config)))
348 (inputs
349 `(("libarchive" ,libarchive)
350 ("sqlite" ,sqlite)
351 ("qtbase" ,qtbase)
352 ("qtdeclarative" ,qtdeclarative)
353 ("qtwebchannel" ,qtwebchannel)
354 ("qtwebengine" ,qtwebengine)
355 ("qtquickcontrols" ,qtquickcontrols)
356 ("qtx11extras" ,qtx11extras)
357 ("xcb-util-keyms" ,xcb-util-keysyms)))
358 (home-page "https://zealdocs.org/")
359 (synopsis "Offline documentation browser inspired by Dash")
360 (description "Zeal is a simple offline documentation browser
7d456e52 361inspired by Dash.")
b7a225e3 362 (license gpl3+))))