1 Answer
1

TeX4ht overloads the LaTeX macros for file input to support configuration files. These files are named with the base name and extension .4ht. Package minitoc generates and loads a file \jobname.mtc0. Thus TeX4ht loads \jobname.4ht if this file exists. In case of \jobname equals index the file index.4ht exists, because TeX4ht supports the package index. Therefore index.4ht assumes that package index is loaded, where \printindex is defined. Since other packages also might generate such auxiliary files like minitoc, the solution would be to avoid job names that are packages or classes, if htlatex is used.

@egreg The cause is \input{\jobname.mtc0} in minitoc.sty that triggers tex4ht to load \jobname.4ht. The extension .mtc0 does not matter.
–
Heiko OberdiekJan 17 '13 at 0:33

hi, when you say he solution would be to avoid job names that are packages or classes, if htlatex is used. So this translates to, in terms new users like me can understand, is to not to use minitoc when running tex4ht? OK. Just wanted to make sure I understood. That is fine. Will do that. I removed minitoc package since I want to always use tex4ht as well.
–
NasserJan 17 '13 at 4:38

@Nasser no, you only need not to give your tex file same name as is the name of some package, because then tex4ht includes config file for this package and this may cause some problems.
–
michal.h21Jan 17 '13 at 7:34