summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bitbake/lib/bb/codeparser.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/bitbake/lib/bb/codeparser.py b/bitbake/lib/bb/codeparser.py
index d249af326e..4bc6adbe45 100644
--- a/bitbake/lib/bb/codeparser.py
+++ b/bitbake/lib/bb/codeparser.py
@@ -72,12 +72,20 @@ def add_module_functions(fn, functions, namespace):
72 parser.parse_python(None, filename=fn, lineno=1, fixedhash=fixedhash+f) 72 parser.parse_python(None, filename=fn, lineno=1, fixedhash=fixedhash+f)
73 #bb.warn("Cached %s" % f) 73 #bb.warn("Cached %s" % f)
74 except KeyError: 74 except KeyError:
75 targetfn = inspect.getsourcefile(functions[f]) 75 try:
76 targetfn = inspect.getsourcefile(functions[f])
77 except TypeError:
78 # Builtin
79 continue
76 if fn != targetfn: 80 if fn != targetfn:
77 # Skip references to other modules outside this file 81 # Skip references to other modules outside this file
78 #bb.warn("Skipping %s" % name) 82 #bb.warn("Skipping %s" % name)
79 continue 83 continue
80 lines, lineno = inspect.getsourcelines(functions[f]) 84 try:
85 lines, lineno = inspect.getsourcelines(functions[f])
86 except TypeError:
87 # Builtin
88 continue
81 src = "".join(lines) 89 src = "".join(lines)
82 parser.parse_python(src, filename=fn, lineno=lineno, fixedhash=fixedhash+f) 90 parser.parse_python(src, filename=fn, lineno=lineno, fixedhash=fixedhash+f)
83 #bb.warn("Not cached %s" % f) 91 #bb.warn("Not cached %s" % f)