waf: build_summary: don't call size for empty list of nodes

Otherwise, that will cause an error.
This commit is contained in:
Gustavo Jose de Sousa 2016-08-29 18:41:18 -03:00 committed by Lucas De Marchi
parent 71212942da
commit 5d7ca3fd27

View File

@ -142,6 +142,7 @@ def _build_summary(bld):
filtered_taskgens.append(tg) filtered_taskgens.append(tg)
taskgens = filtered_taskgens taskgens = filtered_taskgens
if nodes:
l = bld.size_summary(nodes) l = bld.size_summary(nodes)
for i, data in enumerate(l): for i, data in enumerate(l):
taskgens[i].build_summary.update(data) taskgens[i].build_summary.update(data)
@ -153,8 +154,7 @@ def _build_summary(bld):
Logs.info('') Logs.info('')
Logs.pprint( Logs.pprint(
'NORMAL', 'NORMAL',
'Note: Some targets were suppressed. Use --summary-all if you ' + 'Note: Some targets were suppressed. Use --summary-all if you want information of all targets.',
'want information of all targets.',
) )
if hasattr(bld, 'extra_build_summary'): if hasattr(bld, 'extra_build_summary'):