%%% START: latex or pdflatex? %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \usepackage{ifthen} \newboolean{USE_LATEX} \input{config.inc.tex} % this file is created by a batch file that controls compilation %\setboolean{USE_LATEX}{true} % for latex \ these two steps are automatized %\setboolean{USE_LATEX}{false} % for pdflatex / by the previous "input" line \ifthenelse{\boolean{USE_LATEX}} { % we are running latex, not pdflatex \usepackage{graphicx} }{ % we are running pdflatex, so convert .eps files to .pdf \usepackage[pdftex]{graphicx} %\usepackage{epstopdf} % it'd call epstopdf, but it doesn't correct eps files! % so we should do the conversion manually: (1) eps2eps, to correct, then (2) epstopdf } %%% END: latex or pdflatex? %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%