# Compile Error: KOMA-script (scrextend) 'Command \setfootnoterule already defined'; Package clash?

I followed the instruction to indent a block of text in my document. So I added new package scrextend and simple code:

\begin{addmargin}[1em]
indented text text text


but when I compile I get following error:

/usr/share/texlive/texmf-dist/tex/latex/koma-script/scrextend.sty:1206:
LaTeX Error: Command \setfootnoterule already defined.
Or name \end... illegal, see p.192 of the manual.


I don't have a definition of \setfootnoterule anywhere, so I assume it comes from one of the other packages I'm using, which I tried to comment one by one, but it didn't help...

Can somebody please point out what I'm doing wrong?

%%%%%%%%%%%class file
\documentclass[a4paper, 12pt]{memoir}

%%%%%%%%%%%%%%%%%%
%default package
\usepackage{latexsym,amssymb,lastpage}
\usepackage{graphicx,amsfonts}
\usepackage{times,mathptmx,bm,amsmath}
\usepackage{dcolumn}
% mine
\usepackage[margin=2.5cm]{geometry}
\usepackage{csquotes}
\usepackage{listings}
\usepackage{color}
\usepackage{lmodern}
\usepackage[T1]{fontenc}
% package for strikethrough (\st{})
\usepackage{soul}
% package for adding margin to block of text
%\lipsum[1]
\usepackage{scrextend}
%%%%%%%%%%%%%%%%%

\renewcommand{\theequation}{\thesection.\arabic{equation}}
\numberwithin{equation}{section}
\def\citeasnoun{\cite}

\renewcommand{\UrlFont}{\scriptsize}

% modify listing property
\lstset{
basicstyle=\tiny
}

\begin{document}

\chapter{Introduction}

indented text text text

\end{document}

• I wouldn't use this package. It is a mix of various KOMA-definitions but it doesn't really make a effort to keep compability with other classes. With the standard classes it can work quite ok but with a class like memoir the probability of clashes is high. – Ulrike Fischer Aug 14 '15 at 11:04
• You should try one the first two answers to tex.stackexchange.com/q/35933/5872 (from which the question you mention is a duplicate) to achieve the desired effect without needing scrextend – henrique Aug 14 '15 at 13:18
• BTW, amssymb loads amsfonts, and latexsym is thus superfluous. – campa Aug 14 '15 at 13:33
• Thank you for all the explanation and words of advice. I assumed a clash between packages, I didn't suspect that class has anything to do with it : ). I changed indenting using changepage package. I will play with KOMA some other time. – pet5o Aug 14 '15 at 14:01

The command \setfootnoterule is defined both by the class memoir and the package scrextend. Changing the class e.g. to scrbook seems to work fine.
• The first paragraph of your answer is incorrect (except for the part about the geometry package): The scrextend package is meant to be used with non-KOMA-Script classes, especially the standard classes, and does provide features which could be separated from the KOMA-Script classes. – lockstep Aug 14 '15 at 11:16