[commit: ghc] ghc-8.0: users-guide: Fix index in PDF output (528fb33)

git at git.haskell.org git at git.haskell.org
Sat May 21 17:11:14 UTC 2016


Repository : ssh://git@git.haskell.org/ghc

On branch  : ghc-8.0
Link       : http://ghc.haskell.org/trac/ghc/changeset/528fb332de50b5719f4e83470cbb3887cd535f1c/ghc

>---------------------------------------------------------------

commit 528fb332de50b5719f4e83470cbb3887cd535f1c
Author: Ben Gamari <ben at smart-cactus.org>
Date:   Sat May 21 13:20:15 2016 +0200

    users-guide: Fix index in PDF output
    
    The madness that is latex never ceases to amaze.


>---------------------------------------------------------------

528fb332de50b5719f4e83470cbb3887cd535f1c
 docs/users_guide/conf.py | 1 +
 rules/sphinx.mk          | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/docs/users_guide/conf.py b/docs/users_guide/conf.py
index f9c326e..b2311c4 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 823a2af..f3c46b4 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
 



More information about the ghc-commits mailing list