glfs/general/prog/python-modules/sphinx.xml
2023-07-28 12:11:37 -05:00

217 lines
7.0 KiB
XML

<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect2 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../../../general.ent">
%general-entities;
<!ENTITY sphinx-download-http "https://github.com/sphinx-doc/sphinx/archive/v&sphinx-version;/sphinx-&sphinx-version;.tar.gz">
<!ENTITY sphinx-download-ftp " ">
<!ENTITY sphinx-md5sum "cc1d0e40959f98ee63ec2cc90eb9156e">
<!ENTITY sphinx-size "6.6 MB">
<!ENTITY sphinx-buildsize "27 MB (add 40 MB for tests)">
<!ENTITY sphinx-time "less than 0.1 SBU (1.0 SBU for tests)">
]>
<sect2 id="sphinx" xreflabel="sphinx-&sphinx-version;">
<title>Sphinx-&sphinx-version;</title>
<indexterm zone="sphinx">
<primary sortas="a-sphinx">sphinx</primary>
</indexterm>
<sect3 role="package">
<title>Introduction to Sphinx Module</title>
<para>
The <application>Sphinx</application> package is a set of tools
for translating some structured text formats into pretty documentation
in various formats.
</para>
&lfs113_checked;
<bridgehead renderas="sect4">Package Information</bridgehead>
<itemizedlist spacing="compact">
<listitem>
<para>
Download (HTTP): <ulink url="&sphinx-download-http;"/>
</para>
</listitem>
<listitem>
<para>
Download (FTP): <ulink url="&sphinx-download-ftp;"/>
</para>
</listitem>
<listitem>
<para>
Download MD5 sum: &sphinx-md5sum;
</para>
</listitem>
<listitem>
<para>
Download size: &sphinx-size;
</para>
</listitem>
<listitem>
<para>
Estimated disk space required: &sphinx-buildsize;
</para>
</listitem>
<listitem>
<para>
Estimated build time: &sphinx-time;
</para>
</listitem>
</itemizedlist>
<bridgehead renderas="sect4">Sphinx Dependencies</bridgehead>
<bridgehead renderas="sect5">Required</bridgehead>
<para role="required">
<xref linkend="alabaster"/>,
<xref linkend="babel"/>,
<xref linkend="docutils"/>,
<xref linkend="imagesize"/>,
<xref linkend="packaging"/>,
<xref linkend="pygments"/>,
<xref linkend="requests"/>,
<xref linkend="snowballstemmer"/>,
<xref linkend="sc-applehelp"/>,
<xref linkend="sc-devhelp"/>,
<xref linkend="sc-htmlhelp"/>,
<xref linkend="sc-jsmath"/>,
<xref linkend="sc-qthelp"/>, and
<xref linkend="sc-serializinghtml"/>
</para>
<bridgehead renderas="sect5">Optional (for tests)</bridgehead>
<para role="optional">
<xref linkend="cython"/>,
<xref linkend="pytest"/>,
<xref linkend="texlive"/>,
<ulink url="https://pypi.org/project/filelock/">filelock</ulink>, and
<ulink url="https://pypi.org/project/html5lib/">html5lib</ulink>
</para>
</sect3>
<sect3 role="installation">
<title>Installation of Sphinx</title>
<para> Build the module: </para>
<screen><userinput>pip3 wheel -w dist --no-build-isolation --no-deps $PWD</userinput></screen>
<para>
Now, as the <systemitem class="username">root</systemitem> user:
</para>
<screen role="root"><userinput>pip3 install --no-index --find-links dist --no-cache-dir --no-user sphinx</userinput></screen>
<para>
Assuming <xref linkend="cython"/> and <xref linkend="pytest"/> are
installed, but the other optional dependency is not, the installation
can be tested with the following commands:
</para>
<screen remap="test"><userinput>python3 -m venv --system-site-packages testenv &amp;&amp;
source testenv/bin/activate &amp;&amp;
pip3 install html5lib filelock &amp;&amp;
python3 /usr/bin/pytest<!-- no && because of a possible error -->
deactivate</userinput></screen>
<!-- No failure in 7.0.1 [pierre]
7.1.0: 4 failed, 1896 passed, 10 skipped in 108.14s (0:01:48)
test_imgmath_png, test_imgmath_svg, test_imgmath_svg_embed, test_imgmath_numfig_html
-->
<para>
Four subtests in <command>tests/test_ext_math.py</command>
are known to fail.
</para>
</sect3>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
href="../../../xincludes/pip3-cmd-explain.xml"/>
<sect3 role="content">
<title>Contents</title>
<segmentedlist>
<segtitle>Installed Programs</segtitle>
<segtitle>Installed Libraries</segtitle>
<segtitle>Installed Directories</segtitle>
<seglistitem>
<seg>
sphinx-apidoc, sphinx-autogen, sphinx-build, and sphinx-quickstart
</seg>
<seg>None</seg>
<seg>
/usr/lib/python&python3-majorver;/site-packages/sphinx and
/usr/lib/python&python3-majorver;/site-packages/sphinx-&sphinx-version;.dist-info
</seg>
</seglistitem>
</segmentedlist>
<variablelist>
<bridgehead renderas="sect5">Short Descriptions</bridgehead>
<?dbfo list-presentation="list"?>
<?dbhtml list-presentation="table"?>
<varlistentry id="sphinx-apidoc">
<term><command>sphinx-apidoc</command></term>
<listitem>
<para>
creates an reST file from python modules and packages
</para>
<indexterm zone="sphinx sphinx-apidoc">
<primary sortas="b-sphinx-apidoc">sphinx-apidoc</primary>
</indexterm>
</listitem>
</varlistentry>
<varlistentry id="sphinx-autogen">
<term><command>sphinx-autogen</command></term>
<listitem>
<para>
generates ReStructuredText from special directives contained
in given input files
</para>
<indexterm zone="sphinx sphinx-autogen">
<primary sortas="b-sphinx-autogen">sphinx-autogen</primary>
</indexterm>
</listitem>
</varlistentry>
<varlistentry id="sphinx-build">
<term><command>sphinx-build</command></term>
<listitem>
<para>
generates documentation in various formats from ReStructuredText
source files
</para>
<indexterm zone="sphinx sphinx-build">
<primary sortas="b-sphinx-build">sphinx-build</primary>
</indexterm>
</listitem>
</varlistentry>
<varlistentry id="sphinx-quickstart">
<term><command>sphinx-quickstart</command></term>
<listitem>
<para>
generates required files for a sphinx project
</para>
<indexterm zone="sphinx sphinx-quickstart">
<primary sortas="b-sphinx-quickstart">sphinx-quickstart</primary>
</indexterm>
</listitem>
</varlistentry>
</variablelist>
</sect3>
</sect2>