chore(docs) fix latex build

This commit is contained in:
Themba Dube
2021-05-07 12:31:39 -04:00
parent e44c19946c
commit 5a5d469e23
3 changed files with 5 additions and 4 deletions

View File

@@ -34,7 +34,7 @@ jobs:
!${{ env.pythonLocation }}/lib/python*/site-packages/setuptools* !${{ env.pythonLocation }}/lib/python*/site-packages/setuptools*
key: ${{ env.pythonLocation }} key: ${{ env.pythonLocation }}
- name: Install Doxygen and Latex dependencies - name: Install Doxygen and Latex dependencies
run: sudo apt-get install doxygen texlive-xetex run: sudo apt-get install doxygen texlive-xetex makeindex texlive-lang-english
- name: Install requirements - name: Install requirements
run: | run: |
pip install --upgrade --upgrade-strategy eager sphinx recommonmark commonmark breathe sphinx-rtd-theme sphinx-markdown-tables sphinx-sitemap pip install --upgrade --upgrade-strategy eager sphinx recommonmark commonmark breathe sphinx-rtd-theme sphinx-markdown-tables sphinx-sitemap

View File

@@ -60,9 +60,7 @@ cmd("cd ../scripts && doxygen Doxyfile")
cmd("sphinx-build -b latex . out_latex") cmd("sphinx-build -b latex . out_latex")
# Generate PDF # Generate PDF
cmd("cd out_latex && makeindex LVGL.idx") cmd("cd out_latex && latexmk -pdf 'LVGL.tex'")
cmd("cd out_latex && makeindex -s python.ist -o LVGL.ind LVGL.idx")
cmd("cd out_latex && xelatex -interaction=batchmode *.tex")
# Copy the result PDF to the main directory to make it avaiable for the HTML build # Copy the result PDF to the main directory to make it avaiable for the HTML build
cmd("cd out_latex && cp -f LVGL.pdf ../LVGL.pdf") cmd("cd out_latex && cp -f LVGL.pdf ../LVGL.pdf")

View File

@@ -146,6 +146,8 @@ html_last_updated_fmt = ''
# -- Options for LaTeX output --------------------------------------------- # -- Options for LaTeX output ---------------------------------------------
latex_engine = 'xelatex'
latex_use_xindy = False
latex_elements = { latex_elements = {
# The paper size ('letterpaper' or 'a4paper'). # The paper size ('letterpaper' or 'a4paper').
# #
@@ -166,6 +168,7 @@ latex_elements = {
'inputenc': '', 'inputenc': '',
'utf8extra': '', 'utf8extra': '',
'classoptions': ',openany,oneside', 'classoptions': ',openany,oneside',
'babel': '\\usepackage{babel}',
'preamble': r''' 'preamble': r'''
\usepackage{fontspec} \usepackage{fontspec}
\setmonofont{DejaVu Sans Mono} \setmonofont{DejaVu Sans Mono}