blob: 73c0d65f3153eb17af0607bee01ed811f573b10b [file] [log] [blame]
Directory structure
This is a tree of .rst files that represent the source of the NaCl
documentation. Some of the files and directories here are special:
* Sphinx configuration file
* images/: Images are stored here. Note that this isn't necessary - Sphinx
doesn't mind about interspersing images in .rst directories.
* _sphinxext/: Code of the Sphinx extension we use to generate HTML from .rst
* _static/: Static files, like CSS, for the documentation. This should be seen
as part of the infrastructure - the real CSS comes from the real doc
publishing server.
* doxygen/: Contains scripts for building doxygen docs.
* Makefile & README
All output is written to native_client_sdk/doc_generated/...
How to build
To build the docs you will need these debian/ubuntu packages:
* python-sphinx
* python-beautifulsoup
Note: Sphinx version 1.3.3 is required due to dependency on
SmartyPantsHTMLTranslator, which is unavailable in recent versions of Sphinx.
There are two primary make targets: ``chromesite`` and ``chromesite_rst``. The
``chromesite`` target will build all documentation, including the doxygen docs.
This usually takes about a minute. To build this config, run::
The ``chromesite_rst`` target will only build the ReST docs. This is usually
much faster. The default target is ``chromesite``. To build this config, run::
make chromesite_rst
Local HTTP server to view the docs
To view the HTML locally, build the docs with production mode turned off, and
make serve
This will start a webserver on the local machine, and allows the pages
to be viewed by in a browser by navigating to::
Serving through a server and not just file:/// because this way the <link>
relative paths to CSS actually work.
Checking outgoing links for integrity
We use the Sphinx-provided link checker (configured in and with some
monkey-patching in the extension) to check the outgoing links from the
documentation. To run the link checker::
make linkcheck
And look for "broken" in the output file.