I had to write an article in a class derived (apparently) from SIG-ALTERNATE.CLS/ACM_PROC_ARTICLE-SP.CLS. Then, I wanted to build a version without images, so I wanted to use the [demo] option of {graphicx} package. Interestingly, as soon as I tried that, Latex 'crashed' with 'option clash' error.
I think I managed to boil the problem down on this MWE:
Code: Select all
% test.tex
\documentclass[a4paper,12pt]{article}
% with just the below four lines as preamble, all is fine:
% \usepackage[demo]{graphicx}
% \usepackage{url}
% \usepackage[breaklinks]{hyperref}
% \usepackage{breakurl}
% with this preamble - getting an 'option clash' error
% when using [demo]{graphicx} (but compiles without demo option)
% (copies SIG-ALTERNATE.CLS/ACM_PROC_ARTICLE-SP.CLS)
\usepackage{epsfig}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage[demo]{graphicx}
\usepackage{url}
\usepackage[breaklinks]{hyperref}
\usepackage{breakurl}
\begin{document}
\includegraphics[width=0.5\linewidth]{demo}
\end{document}
Code: Select all
! LaTeX Error: Option clash for package graphicx.
See the LaTeX manual or LaTeX Companion for explanation.
Type H <return> for immediate help.
...
l.18 \usepackage
{url}
? X
No pages of output.
Transcript written on test.log.
Anyways - does anyone know what is the problem here, and how could I use the [demo] option of {graphicx} without it clashing with {url}, within this kind of a class environment??
Thanks in advance for any answers,
Cheers!