From 3802754f0517e96db8e73f6d789957b104400215 Mon Sep 17 00:00:00 2001 From: bernard Date: Wed, 13 Dec 2017 20:13:45 +0800 Subject: [Tools] Fix the walk_children issue --- tools/codeblocks.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'tools/codeblocks.py') diff --git a/tools/codeblocks.py b/tools/codeblocks.py index cb07956e73..7db82b49e9 100644 --- a/tools/codeblocks.py +++ b/tools/codeblocks.py @@ -31,17 +31,20 @@ import xml.etree.ElementTree as etree from xml.etree.ElementTree import SubElement from utils import _make_path_relative from utils import xml_indent + +import utils + fs_encoding = sys.getfilesystemencoding() def CB_AddHeadFiles(program, elem, project_path): - building.source_ext = [] - building.source_ext = ["h"] + utils.source_ext = [] + utils.source_ext = ["h"] for item in program: - building.walk_children(item) - building.source_list.sort() - # print building.source_list + utils.walk_children(item) + utils.source_list.sort() + # print utils.source_list - for f in building.source_list: + for f in utils.source_list: path = _make_path_relative(project_path, f) Unit = SubElement(elem, 'Unit') Unit.set('filename', path.decode(fs_encoding)) -- cgit v1.3.1