summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2016-05-21 13:20:15 +0200
committerBen Gamari <ben@smart-cactus.org>2016-05-21 19:09:55 +0200
commit528fb332de50b5719f4e83470cbb3887cd535f1c (patch)
treed616d7bfceb0d018b797782021e1176778b131b5
parent043832183538e7c0bdecaae2309a673427740ce5 (diff)
downloadhaskell-528fb332de50b5719f4e83470cbb3887cd535f1c.tar.gz
users-guide: Fix index in PDF output
The madness that is latex never ceases to amaze.
-rw-r--r--docs/users_guide/conf.py1
-rw-r--r--rules/sphinx.mk4
2 files changed, 5 insertions, 0 deletions
diff --git a/docs/users_guide/conf.py b/docs/users_guide/conf.py
index f9c326ef83..b2311c4994 100644
--- a/docs/users_guide/conf.py
+++ b/docs/users_guide/conf.py
@@ -66,6 +66,7 @@ latex_elements = {
'utf8extra': '',
'preamble': '''
\usepackage{fontspec}
+\usepackage{makeidx}
\setsansfont{DejaVu Sans}
\setromanfont{DejaVu Serif}
\setmonofont{DejaVu Sans Mono}
diff --git a/rules/sphinx.mk b/rules/sphinx.mk
index 823a2af06d..f3c46b449f 100644
--- a/rules/sphinx.mk
+++ b/rules/sphinx.mk
@@ -60,6 +60,10 @@ $1/$2.pdf: $1/conf.py $$($1_RST_SOURCES)
$(SPHINXBUILD) -b latex -d $1/.doctrees-pdf $(SPHINXOPTS) $1 $1/build-pdf/$2
cd $1/build-pdf/$2 ; xelatex $2.tex
cd $1/build-pdf/$2 ; xelatex $2.tex
+ cd $1/build-pdf/$2 ; xelatex $2.tex
+ cd $1/build-pdf/$2 ; makeindex $2.idx
+ cd $1/build-pdf/$2 ; xelatex $2.tex
+ cd $1/build-pdf/$2 ; xelatex $2.tex
cp $1/build-pdf/$2/$2.pdf $1/$2.pdf
endif