From a54221102b5473b93b08f52785f74cb933b355b1 Mon Sep 17 00:00:00 2001 From: Alexis Ballier Date: Tue, 9 Feb 2016 14:02:30 +0100 Subject: eclass/latex-package.eclass: Try pdflatex first and fallback on old texi2dvi way if it fails. Should fix bug #574168, bug #574180 and probably others, while installing pdf documentation which is more portable than dvi these days. --- eclass/latex-package.eclass | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'eclass') diff --git a/eclass/latex-package.eclass b/eclass/latex-package.eclass index 1a092d3d7d37..030c899ccf9e 100644 --- a/eclass/latex-package.eclass +++ b/eclass/latex-package.eclass @@ -128,7 +128,12 @@ latex-package_src_doinstall() { for i in `find . -maxdepth 1 -type f -name "*.${1}"` do einfo "Making documentation: $i" - texi2dvi -q -c --language=latex $i &> /dev/null || die + if `pdflatex --interaction=batchmode $i &> /dev/null` ; then + pdflatex --interaction=batchmode $i &> /dev/null || die + else + einfo "pdflatex failed, trying texi2dvi" + texi2dvi -q -c --language=latex $i &> /dev/null || die + fi done fi ;; -- cgit v1.2.3-65-gdbad