diff options
Diffstat (limited to 'bitbake/lib/bb/parse/parse_py/BBHandler.py')
-rw-r--r-- | bitbake/lib/bb/parse/parse_py/BBHandler.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bitbake/lib/bb/parse/parse_py/BBHandler.py b/bitbake/lib/bb/parse/parse_py/BBHandler.py index ab479c1eb2..1ba81886a7 100644 --- a/bitbake/lib/bb/parse/parse_py/BBHandler.py +++ b/bitbake/lib/bb/parse/parse_py/BBHandler.py | |||
@@ -80,12 +80,13 @@ def inherit(files, d): | |||
80 | include(fn, file, d, "inherit") | 80 | include(fn, file, d, "inherit") |
81 | __inherit_cache = data.getVar('__inherit_cache', d) or [] | 81 | __inherit_cache = data.getVar('__inherit_cache', d) or [] |
82 | 82 | ||
83 | def get_statements(filename, absolsute_filename, base_name, file): | 83 | def get_statements(filename, absolsute_filename, base_name): |
84 | global cached_statements | 84 | global cached_statements |
85 | 85 | ||
86 | try: | 86 | try: |
87 | return cached_statements[absolsute_filename] | 87 | return cached_statements[absolsute_filename] |
88 | except KeyError: | 88 | except KeyError: |
89 | file = open(absolsute_filename, 'r') | ||
89 | statements = ast.StatementGroup() | 90 | statements = ast.StatementGroup() |
90 | 91 | ||
91 | lineno = 0 | 92 | lineno = 0 |
@@ -133,13 +134,13 @@ def handle(fn, d, include): | |||
133 | else: | 134 | else: |
134 | oldfile = None | 135 | oldfile = None |
135 | 136 | ||
136 | (f, abs_fn) = resolve_file(fn, d) | 137 | abs_fn = resolve_file(fn, d) |
137 | 138 | ||
138 | if include: | 139 | if include: |
139 | bb.parse.mark_dependency(d, abs_fn) | 140 | bb.parse.mark_dependency(d, abs_fn) |
140 | 141 | ||
141 | # actual loading | 142 | # actual loading |
142 | statements = get_statements(fn, abs_fn, base_name, f) | 143 | statements = get_statements(fn, abs_fn, base_name) |
143 | 144 | ||
144 | # DONE WITH PARSING... time to evaluate | 145 | # DONE WITH PARSING... time to evaluate |
145 | if ext != ".bbclass": | 146 | if ext != ".bbclass": |