Prerequisite tools are Bash 2.x, Doxygen, and the GNU coreutils. (GNU versions of find, xargs, and possibly sed and grep are used, just because the GNU versions make things very easy.)
To generate the pretty pictures and hierarchy graphs, the Graphviz package will need to be installed.
The Makefile rules
make doc-html-doxygenand
make doc-xml-doxygenand
make doc-man-doxygenin the libstdc++ build directory generate the HTML docs, the XML docs, and the man pages.
	Careful observers will see that the Makefile rules simply call
	a script from the source tree, run_doxygen, which
	does the actual work of running Doxygen and then (most
	importantly) massaging the output files. If for some reason
	you prefer to not go through the Makefile, you can call this
	script directly. (Start by passing --help.)
      
	If you wish to tweak the Doxygen settings, do so by editing
	doc/doxygen/user.cfg.in. Notes to fellow
	library hackers are written in triple-# comments.
      
In general, libstdc++ files should be formatted according to the rules found in the Coding Standard. Before any doxygen-specific formatting tweaks are made, please try to make sure that the initial formatting is sound.
Adding Doxygen markup to a file (informally called “doxygenating”) is very simple. The Doxygen manual can be found here. We try to use a very-recent version of Doxygen.
	For classes, use
	deque/vector/list
	and std::pair as examples.  For
	functions, see their member functions, and the free functions
	in stl_algobase.h. Member functions of
	other container-like types should read similarly to these
	member functions.
      
These points accompany the first list in section 3.1 of the Doxygen manual:
Use the Javadoc style...
...not the Qt style. The intermediate *'s are preferred.
Use the triple-slash style only for one-line comments (the “brief” mode). Very recent versions of Doxygen permit full-mode comments in triple-slash blocks, but the formatting still comes out wonky.
This is disgusting. Don't do this.
Use the @-style of commands, not the !-style. Please be careful about whitespace in your markup comments. Most of the time it doesn't matter; doxygen absorbs most whitespace, and both HTML and *roff are agnostic about whitespace. However, in <pre> blocks and @code/@endcode sections, spacing can have “interesting” effects.
	Use either kind of grouping, as
	appropriate. doxygroups.cc exists for this
	purpose. See stl_iterator.h for a good example
	of the “other” kind of grouping.
      
Please use markup tags like @p and @a when referring to things such as the names of function parameters. Use @e for emphasis when necessary. Use @c to refer to other standard names. (Examples of all these abound in the present code.)
Editing the DocBook sources requires an XML editor. Many exist: some noteable options include emacs, Kate, or Conglomerate.
Some editors support special “XML Validation” modes that can validate the file as it is produced. Recommended is the nXML Mode for emacs.
Besides an editor, additional DocBook files and XML tools are also required.
	Access to the DocBook stylesheets and DTD is required. The
	stylesheets are usually packaged by vendor, in something
	like docbook-style-xsl. The installation
	directory for this package corresponds to
	the XSL_STYLE_DIR
	in doc/Makefile.am and defaults
	to /usr/share/sgml/docbook/xsl-stylesheets.
      
	For procesessing XML, an XML processor and some style
	sheets are necessary. Defaults are xsltproc
	provided by libxslt.
      
	For validating the XML document, you'll need
	something like xmllint and access to the
	DocBook DTD. These are provided
	by a vendor package like lixml2.
      
	For PDF output, something that transforms valid XML to PDF is
	required. Possible solutions include xmlto,
	Apache
	FOP, or prince. Other options are
	listed on the DocBook web pages. Please
	consult the <libstdc++@gcc.gnu.org> list when
	preparing printed manuals for current best practice and suggestions.
      
	Make sure that the XML documentation and markup is valid for
	any change. This can be done easily, with the validation rules
	in the Makefile, which is equivalent to doing: 
      
	  
xmllint --noout --valid xml/index.xml
	  
	The Makefile rules
make doc-htmland
make doc-pdfand
make doc-xml-singleand
make doc-xml-validatein the libstdc++ build directory result respectively in the following: the generation of an HTML version of all the documentation, a PDF version of the same, a single XML document, and the results of validating the XML document.
      Which files are important
      All Docbook files are in the directory
      libstdc++-v3/doc/xml
      Inside this directory, the files of importance:
      spine.xml  	- index to documentation set
      manual/spine.xml  - index to manual
      manual/*.xml  	- individual chapters and sections of the manual
      faq.xml  		- index to FAQ
      api.xml  		- index to source level / API 
      All *.txml files are template xml files, ie otherwise empty files with
      the correct structure, suitable for filling in with new information.
      Cannonical Writing Style
      class template
      function template
      member function template
      (via C++ Templates, Vandevoorde)
      class in namespace std: allocator, not std::allocator
      header file: iostream, not <iostream>
      General structure
      <set>
      <book>
      </book>
      <book>
      <chapter>
      </chapter>
      </book>
      <book>	
      <part>
      <chapter>
      <section>
      </section>
      <sect1>
      </sect1>
      <sect1>
      <sect2>
      </sect2>
      </sect1>
      </chapter>
      <chapter>
      </chapter>
      </part>  
      </book>
      </set>
    
      HTML to XML rough equivalents
      <p>			<para>
      <pre>			<computeroutput>
      <pre>			<programlisting>
      <pre>			<literallayout>
      <ul>			<itemizedlist>
      <ol>			<orderedlist>
      <il>			<listitem>
      <dl>			<variablelist>
      <varlistentry>
      <dt> 			  <term>
      </dt>			  </term>
      <dd>  			  <listitem>
      </dt>			  </listitem>
      </varlistentry>
      <a href			<ulink url
      <code>			<literal>
      <code>			<programlisting>
      <strong>		<emphasis>
      <em>			<emphasis>
      "			<quote>
      ctype.h			<filename class="headerfile"></filename>
      
      build_dir   		<filename class="directory">path_to_build_dir</filename>
      Finer gradations of <code>
      <classname>		<classname>string</classname>
      <classname>vector<></classname>			
      <function>fs.clear()</function>
      <structname>
      <function>		<function>clear()</function>
      <type>			<type>long long</type>
      <varname>		<varname>fs</varname>
      <literal>		<literal>-Weffc++</literal> 
      <literal>rel_ops</literal>
      <constant>		<constant>_GNU_SOURCE</constant>
      <constant>3.0</constant>
      <filename>
      <command>		<command>g++</command>
      <errortext>		<errortext>foo Concept </errortext>