xindy is an index processor that can be used to generate book-like indexes for arbitrary document-preparation systems. This includes systems such as TeX and LaTeX, the roff-family, and SGML/XML-based systems (e.g., HTML).
perl-based scripts to transform xml'ish files. It has scripts to scan C text,
make some xml'ish intermediate form, transform the xml'ish data, and it has
scripts to spit out the xml'ish data as html or docbook.