summaryrefslogtreecommitdiff
path: root/docs/admin/buildhosts.rst
blob: 5260da0331781823b203b7c5f929eee43666e33a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
.. _buildhosts:

==========
Buildhosts
==========

.. sidebar:: This article needs some work

   If you have any contribution send us your :pull:`PR <../pulls>`, see
   :ref:`how to contribute`.

To get best results from build, its recommend to install additional packages
on build hosts.

.. _docs build:

Build docs
==========

.. _Graphviz: https://graphviz.gitlab.io
.. _ImageMagick: https://www.imagemagick.org
.. _XeTeX: https://tug.org/xetex/
.. _dvisvgm: https://dvisvgm.de/

.. sidebar:: Sphinx build needs

   - ImageMagick_
   - Graphviz_
   - XeTeX_
   - dvisvgm_

Most of the sphinx requirements are installed from :origin:`setup.py` and the
docs can be build from scratch with ``make docs``.  For better math and image
processing additional packages are needed.  The XeTeX_ needed not only for PDF
creation, its also needed for :ref:`math` when HTML output is build.

To be able to do :ref:`sphinx:math-support` without CDNs, the math are rendered
as images (``sphinx.ext.imgmath`` extension).  If your docs build (``make
docs``) shows warnings like this::

   WARNING: dot(1) not found, for better output quality install \
            graphviz from http://www.graphviz.org
   ..
   WARNING: LaTeX command 'latex' cannot be run (needed for math \
            display), check the imgmath_latex setting

you need to install additional packages on your build host, to get better HTML
output.

.. _system requirements:

.. tabs::

   .. group-tab:: Ubuntu / debian

      .. code-block:: sh

         $ sudo apt install graphviz imagemagick texlive-xetex librsvg2-bin

   .. group-tab:: Arch Linux

      .. code-block:: sh

         $ sudo pacman -S graphviz imagemagick texlive-bin extra/librsvg

   .. group-tab::  Fedora / RHEL

      .. code-block:: sh

         $ sudo dnf install graphviz graphviz-gd texlive-xetex-bin librsvg2-tools


For PDF output you also need:

.. tabs::

   .. group-tab:: Ubuntu / debian

      .. code:: sh

         $ sudo apt texlive-latex-recommended texlive-extra-utils ttf-dejavu

   .. group-tab:: Arch Linux

      .. code:: sh

      	 $ sudo pacman -S texlive-core texlive-latexextra ttf-dejavu

   .. group-tab::  Fedora / RHEL

      .. code:: sh

      	 $ sudo dnf install \
	        texlive-collection-fontsrecommended texlive-collection-latex \
		dejavu-sans-fonts dejavu-serif-fonts dejavu-sans-mono-fonts

.. _system requirements END:

.. literalinclude:: ../conf.py
   :language: python
   :start-after: # sphinx.ext.imgmath setup
   :end-before: # sphinx.ext.imgmath setup END