diff options
Diffstat (limited to 'bitbake/lib/bb/utils.py')
-rw-r--r-- | bitbake/lib/bb/utils.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py index ee4ef73bfc..44a42a0136 100644 --- a/bitbake/lib/bb/utils.py +++ b/bitbake/lib/bb/utils.py | |||
@@ -218,13 +218,15 @@ def better_compile(text, file, realfile, mode = "exec"): | |||
218 | 218 | ||
219 | raise | 219 | raise |
220 | 220 | ||
221 | def better_exec(code, context, text, realfile = "<code>"): | 221 | def better_exec(code, context, text = None, realfile = "<code>", data = None): |
222 | """ | 222 | """ |
223 | Similiar to better_compile, better_exec will | 223 | Similiar to better_compile, better_exec will |
224 | print the lines that are responsible for the | 224 | print the lines that are responsible for the |
225 | error. | 225 | error. |
226 | """ | 226 | """ |
227 | import bb.parse | 227 | import bb.parse |
228 | if not text: | ||
229 | text = code | ||
228 | if not hasattr(code, "co_filename"): | 230 | if not hasattr(code, "co_filename"): |
229 | code = better_compile(code, realfile, realfile) | 231 | code = better_compile(code, realfile, realfile) |
230 | try: | 232 | try: |