# generic targets
-default: autogen-doc tutorial development glossary validate-xrefs
+default: autogen-doc tutorial development glossary class_index.html validate-xrefs
all: default autogen-doc-all
cd publications ; $(MAKE) validate-xrefs
+# generate a class index from each of the various include directories
+class_index.html: $(shell echo $D/base/include/base/*.h \
+ $D/lac/include/lac/*.h \
+ $D/deal.II/include/*/*.h)
+ @echo '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"\n\
+ "http://www.w3.org/TR/REC-html40/strict.dtd">\n \
+ <html>\n\
+ <head>\n\
+ <link href="screen.css" rel="StyleSheet" title="deal.II Homepage" media="screen">\n\
+ <link href="print.css" rel="StyleSheet" title="deal.II Homepage" media="print">\n\
+ <title>The deal.II Homepage</title>\n\
+ <meta name="author" content="Wolfgang Bangerth <deal@iwr.uni-heidelberg.de>">\n\
+ <meta name="keywords" content="deal.II"></head>\n\
+ \n\
+ <body>\n\n' > $@
+ @echo "<h2>Class index for sub-libraries and their API references</h2>" \
+ >> $@
+ @echo "This file contains a list of classes in the different sub-libraries.\n" \
+ "Use this file if you are looking for the documentation of a\n" \
+ " certain class and are unsure\n" \
+ "in which API documentation to find the corresponding reference.\n" \
+ "<p>" \
+ "This file is automatically generated, so please excuse the strange layout.\n" \
+ >> $@
+ for dir in $D/base/include/base \
+ $D/lac/include/lac \
+ $(shell echo $D/deal.II/include/*); do \
+ if test -d $$dir -a \
+ ! "`echo $$dir | $(PERL) -p -e 's!.*/!!;'`" = CVS; then \
+ echo "Creating class index for $$dir" ; \
+ dirbasename="`echo $$dir | $(PERL) -p -e 's!.*/!!;'`" ; \
+ echo "<h3><a href=\"auto/kdoc/$$dirbasename/index.html\""\
+ " target=\"body\">" \
+ "$$dirbasename sub-library</a></h3>\n\n" >> $@ ; \
+ echo '<dir>\n' >> $@ ; \
+ $(PERL) ../common/scripts/forward_declarations.pl \
+ `echo $$dir/*.h | \
+ $(PERL) -pi -e s'/[\w\/]*forward_declarations.h//g;'`\
+ | $(PERL) -e 'while (<>) { if (/;$$/) {print;}}' \
+ | $(PERL) -pi -e 's/.*(struct|class)\s+//g;' \
+ | sort \
+ | uniq \
+ | $(PERL) -pi -e 's/&/&/g; s/</</g; s/>/>/g;' \
+ | $(PERL) -pi -e 's/;\n/ <br> \n/g;' >> $@ ; \
+ echo "\n\n" >> $@ ; \
+ echo "</dir>\n" >> $@ ; \
+ fi \
+ done
+ @echo '</body></html>' >> $@
+
+
+
clean:
cd auto ; $(MAKE) clean
cd tutorial ; $(MAKE) clean
cd development ; $(MAKE) clean
cd glossary ; $(MAKE) clean
+ -rm class_index.html
.PHONY: default all autogen-doc autogen-doc-all tutorial clean development validate-xrefs glossary