sources = SatSCons.GlobSources()
SatSCons.StandardTargets(env)
-SatSCons.Lib(env, 'Packets', sources)
-env.AddPreAction(
- SatSCons.Doxygen(env,sources),
- env.Action("make -f imgconvert.mak structure.png"))
+SatSCons.Lib(env, 'Packets', sources, )
+SatSCons.Doxygen(env,sources, image = [ "structure.dia" ])
return base+ext
def Doxygen(env, target, source, image=[]):
+ global __file__
path, name = os.path.split(str(target))
stamp = os.path.join(path, '.'+name+'.stamp')
dir = env.Dir(target)
+ mak = os.path.join(os.path.split(__file__)[0],'imgconvert.mak')
env.Depends(dir,
[ env.Command(os.path.splitext(img)[0]+".png", img,
- [ 'TERM=dumb make -f imgconvert.mak $TARGET' ])
+ [ 'TERM=dumb make -f %s $TARGET' % mak ])
for img in image ] +
[ env.Command(stamp, source,
[ 'cd $TARGET.dir && $DOXYGENCOM',
- 'cd $TARGET.dir/doc/html && (sed -ne \'1,/<table>/p\' <annotated.html && grep -F \'<tr>\' <annotated.html | sort -ft\'>\' -k4 && sed -ne \'/<\\/table>/,$$p\' <annotated.html) >annotated.html.new && mv annotated.html.new annotated.html',
- 'touch $TARGET' ],
+ # 'cd $TARGET.dir/doc/html && (sed -ne \'1,/<table>/p\' <annotated.html && grep -F \'<tr>\' <annotated.html | sort -ft\'>\' -k4 && sed -ne \'/<\\/table>/,$$p\' <annotated.html) >annotated.html.new && mv annotated.html.new annotated.html',
+ "touch $TARGET" ],
source_scanner = SCons.Defaults.ObjSourceScan) ])
env.Clean(stamp, dir)
return dir
return objects
-def Doxygen(env, sources, testSources = None):
+def Doxygen(env, sources, testSources = None, image = []):
if type(sources) == type(()):
testSources = sources[1]
sources = sources[0]
doc = env.Doxygen(
target = 'doc',
- source = sources )
+ source = sources,
+ image = image)
env.Alias('all_docs', doc)
return doc