From 297c1647110b766c6d0aeadcbaa74a365d75d2a1 Mon Sep 17 00:00:00 2001 From: jfbu Date: Wed, 30 Dec 2015 10:22:09 +0100 Subject: [PATCH] Load graphicx without specifying the driver This is issue #2164. On the current main TeX installations (TeXLive, MikTeX), \pdftexversion is defined also when running latex to produce dvi files. This commit deletes TeX code which resulted in the "pdftex" driver being always assumed, which made it a priori impossible to compile via latex. The graphicx packages is smart enough to detect correctly the driver (pdftex, xetex, ...) and defaults to dvips. --- sphinx/texinputs/sphinx.sty | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/sphinx/texinputs/sphinx.sty b/sphinx/texinputs/sphinx.sty index fe22111c2..e9c35b9b5 100644 --- a/sphinx/texinputs/sphinx.sty +++ b/sphinx/texinputs/sphinx.sty @@ -58,12 +58,7 @@ \fi \fi -% For graphicx, check if we are compiling under latex or pdflatex. -\ifx\pdftexversion\undefined - \usepackage{graphicx} -\else - \usepackage[pdftex]{graphicx} -\fi +\RequirePackage{graphicx} % for PDF output, use colors and maximal compression \newif\ifsphinxpdfoutput\sphinxpdfoutputfalse