Skip to content

Commit

Permalink
Docs: Fix PDF build on ReadTheDocs
Browse files Browse the repository at this point in the history
ReadTheDocs switched from calling pdflatex directly to using latexmk.
This change broke the previous workaround that only the last-built PDF
file was made available on RTD. Use a more explicit approach instead to
fix that.

Changed upstream in readthedocs/readthedocs.org#5437
  • Loading branch information
imphil committed Mar 28, 2020
1 parent c565ae8 commit 9ede71c
Showing 1 changed file with 20 additions and 15 deletions.
35 changes: 20 additions & 15 deletions src/conf.py
Expand Up @@ -149,21 +149,26 @@
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title,
# author, documentclass [howto, manual, or own class]).
latex_documents = [
('01_overview/index', 'osd-overview.tex', u'Open SoC Debug Overview',
u'The Open SoC Debug Contributors', 'manual'),

('02_spec/index', 'osd-spec.tex', u'Open SoC Debug Specification',
u'The Open SoC Debug Contributors', 'manual'),

('03_user/index', 'osd-userguide.tex', u'Open SoC Debug User Guides',
u'The Open SoC Debug Contributors', 'manual'),

('04_implementer/index', 'osd-implementerguide.tex',
u'Open SoC Debug Implementer Guides',
u'The Open SoC Debug Contributors', 'manual'),

# The last document is the one and only one made available by RTD
latex_documents = []
if not read_the_docs_build:
latex_documents += [
('01_overview/index', 'osd-overview.tex', u'Open SoC Debug Overview',
u'The Open SoC Debug Contributors', 'manual'),

('02_spec/index', 'osd-spec.tex', u'Open SoC Debug Specification',
u'The Open SoC Debug Contributors', 'manual'),

('03_user/index', 'osd-userguide.tex', u'Open SoC Debug User Guides',
u'The Open SoC Debug Contributors', 'manual'),

('04_implementer/index', 'osd-implementerguide.tex',
u'Open SoC Debug Implementer Guides',
u'The Open SoC Debug Contributors', 'manual'),
]

# ReadTheDocs only supports a single PDF document, make the combined doc
# available.
latex_documents += [
(master_doc, 'opensocdebug.tex',
u'Open SoC Debug Documentation Library',
u'The Open SoC Debug Contributors', 'manual'),
Expand Down

0 comments on commit 9ede71c

Please sign in to comment.