Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am currently writing my thesis and I've ran into a problem while increasing the complexity of the packages I needed to use. I was originally using the \cite{} macro to do all the references but I needed some more functionality hence I opted for the natbib package. Unfortunately when I try to compile the tex file I get the following error:

/usr/local/texlive/2011/texmf-dist/tex/latex/natbib/natbib.sty:739: LaTeX Error: Command \citetext already defined.
           Or name \end... illegal, see p.192 of the manual.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              

￼l.739 ...ommand\citetext[1]{\NAT@open#1\NAT@close}

I think that the natbib package might be conflicting with another package that already defines the \citetext key, but how can I tell? I've tried a process of elimination but wasn't able to track down the offending package - if it even is that case - . The packages are imported into the main tex file with \input{packages} and include:

%%%%%%%%%%%%%%%%%%%%%%
%% Declare packages %%
%%%%%%%%%%%%%%%%%%%%%%

\usepackage{ccaption, graphicx, textcomp, tabularx, booktabs, longtable, rotating, lscape}

\DeclareGraphicsExtensions{.jpg, .eps, .png}


\usepackage{enumerate,latexsym,amsmath,amssymb, amsthm, algorithm, algorithmic, verbatim}

\usepackage{listings}
\usepackage{color}

% Use of & in the acronyms
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}



%%%%%%%%%%%%%%
%% Acronyms %%
%%%%%%%%%%%%%%
\usepackage[printonlyused,withpage]{acronym} 

\newcommand{\listofacronymsname}{Acronyms}

\newcommand{\listofacronyms}{%
\chapter*{\listofacronymsname}%
\addcontentsline{toc}{chapter}{\listofacronymsname}%
\label{sec:acronyms}%
\markboth{\listofacronymsname}{\listofacronymsname}%
}


\usepackage[authoryear,round, nonamebreak]{natbib}

% Reference which pages the citation was referenced in
\usepackage[pagebackref, breaklinks]{hyperref} 
\renewcommand*{\backref}[1]{[pp. #1]}

Can anyone think of any reason why this error might be coming up? I'm really stumped here. Please let me know if you need any more information. I know this is a bit skim, but the thesis is quite large at this point and I'm not sure what would be of help or not.

Cheers, Christos

share|improve this question

closed as too localized by Andrew Swann, Guido, lockstep, Claudio Fiandrino, Stefan Kottwitz Feb 18 '13 at 11:40

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1  
Welcome to TeX.SE! If you've only recently switched from another citation management package (which may define the \citetext macro in a way that's incompatible with natbib's definition) to natbib, you may well come across some puzzling error messages. Try wiping out the .aux (and all other auxiliary) files and then rerunning latex/bibtex/latex/latex. –  Mico Jun 29 '12 at 16:13
    
Hey Mico, thanks for the reply. I should also mention the setup I'm currently working with, as it is important. I'm working on OSX with TeX Live installed, and Latexian as the editor. What Latexian does is generate temporary files for a live preview every time. Which means that a new aux file is generated as well. –  cmdel Jun 29 '12 at 17:23

Browse other questions tagged or ask your own question.
http://tex.stackexchange.com/questions/61689/conflict-with-natbib
tex.stackexchange.com
crawl=CC-MAIN-2014-52
56947
application/http; msgtype=response
sha1:QF3HXO6DHMVRFQUVTXBRLZ56SZX3ZMTT
<urn:uuid:e7ca23d6-db30-40c1-923c-5c86e5825796>
2014-12-21T05:48:05Z
198.252.206.140
sha1:XSQ76S6TJ2CD6XN5Q6HACB2QYSKTO5OS
<urn:uuid:fc45b99e-3d30-4d44-a6b7-10cc52b73ee8>
http://tex.stackexchange.com/questions/61689/conflict-with-natbib
response
<urn:uuid:3cb6c4a2-7e34-4830-a52b-8e759aadc09e>
robots: classic
hostname: ip-10-231-17-201.ec2.internal
software: Nutch 1.6 (CC)/CC WarcExport 1.0
isPartOf: CC-MAIN-2014-52
operator: CommonCrawl Admin
description: Wide crawl of the web with URLs provided by Blekko for December 2014
publisher: CommonCrawl
format: WARC File Format 1.0
conformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf