Add graph option for callgraph

main
Michael Hayes 15 years ago
parent 0ea62d5d8e
commit 81d1040226

@ -59,7 +59,7 @@ appcallgraph: $(APPCALLGRAPH)
./graphdeps.py $< --out $@ --showops
../%/callgraph.pdf: ../%/callgraph.d
(cd $(dir $@); ../../etc/graphdeps.py $(notdir $<) --out $(notdir $@))
(cd $(dir $@); ../../etc/graphdeps.py --calls $(notdir $<) --out $(notdir $@))
../%/files.d: ../%/Makefile
(cd $(dir $@); ../../etc/makemake.py --relpath --files . . ../../drivers ../../drivers/avr ../../utils --exclude system.h > files.d)

@ -61,6 +61,10 @@ def node_output (dotfile, name, options):
colour = 'orange'
shape = 'rectangle'
if options.calls:
colour = 'magenta'
shape = 'rectangle'
dotfile.write ('\t"' + name + '"\t [style=filled,shape=' + shape + ',color=' + colour + '];\n')
return name
@ -145,6 +149,10 @@ def main(argv = None):
dest = 'modules', default = False,
help = 'show module dependencies')
parser.add_option('--calls', action = 'store_true',
dest = 'calls', default = False,
help = 'show callgraph')
parser.add_option('--fullpaths', action = 'store_true',
dest = 'fullpaths', default = False,
help = 'show full paths')

Loading…
Cancel
Save