X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=senfscons%2FSENFSCons.py;h=a9961d60a7f2b61b5677576f74b318b371623fae;hb=f11bb3f5a7eeb232a74d13b7d7ddc6746ca2c2d2;hp=91bac5b7a7db6a56514b1f551ccb29d265361b95;hpb=f4e0d3d4a32cc0bfc37855ad7f2c1e829911d233;p=senf.git diff --git a/senfscons/SENFSCons.py b/senfscons/SENFSCons.py index 91bac5b..a9961d6 100644 --- a/senfscons/SENFSCons.py +++ b/senfscons/SENFSCons.py @@ -151,11 +151,13 @@ def Doxygen(env, doxyfile = "Doxyfile", extra_sources = []): # ||| WITHIN THE DOXYGEN BUILDER docs = env.Doxygen(doxyfile)[:] xmlnode = None + htmlnode = None tagnode = None for doc in docs: if isinstance(doc,SCons.Node.FS.Dir): continue if doc.name == 'xml.stamp' : xmlnode = doc - if os.path.splitext(doc.name)[1] == '.stamp' : continue # file stamp + if doc.name == 'html.stamp' : htmlnode = doc + if os.path.splitext(doc.name)[1] == '.stamp' : continue # ignore other file stamps # otherwise it must be the tag file tagnode = doc @@ -164,10 +166,21 @@ def Doxygen(env, doxyfile = "Doxyfile", extra_sources = []): # references env.AddPostAction( docs, - env.Action("xsltproc -o %(target)s.temp %(template)s %(target)s && mv %(target)s.temp %(target)s" + env.Action("xsltproc --nonet -o %(target)s.temp %(template)s %(target)s && mv %(target)s.temp %(target)s" % { 'target': tagnode.abspath, 'template': os.path.join(basedir,"tagmunge.xsl") })) + if htmlnode and env.get('DOXY_HTML_XSL'): + xslfile = env.File(env['DOXY_HTML_XSL']) + env.AddPostAction( + docs, + env.Action(("for html in %s/*.html; do " + + "xsltproc --nonet --html -o $${html}.new %s $${html} && mv $${html}.new $${html}; " + + "done") + % (htmlnode.dir.abspath, xslfile.abspath))) + for doc in docs: + env.Depends(doc,xslfile) + if xmlnode: xrefs = [] for type in env.get("DOXY_XREF_TYPES",[ "bug", "todo" ]): @@ -218,7 +231,8 @@ def DoxyXRef(env, docs=None, "sed -e 's/\\$$title/$TITLE/g' -e 's/\\$$projectname/Overview/g' ${SOURCES[%d]} >> $TARGET" % (HTML_HEADER and 3 or 2)) - xref = env.Command("doc/html/xref.html", sources, commands) + xref = env.Command("doc/html/xref.html", sources, commands, + TITLE = TITLE) env.Alias('all_docs',xref) return xref