diff options
Diffstat (limited to 'meta/classes/devtool-source.bbclass')
-rw-r--r-- | meta/classes/devtool-source.bbclass | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/meta/classes/devtool-source.bbclass b/meta/classes/devtool-source.bbclass index a8110006fb..280d6009f3 100644 --- a/meta/classes/devtool-source.bbclass +++ b/meta/classes/devtool-source.bbclass | |||
@@ -97,17 +97,15 @@ python devtool_post_unpack() { | |||
97 | local_files = oe.recipeutils.get_recipe_local_files(d) | 97 | local_files = oe.recipeutils.get_recipe_local_files(d) |
98 | 98 | ||
99 | if is_kernel_yocto: | 99 | if is_kernel_yocto: |
100 | for key in local_files.copy(): | 100 | for key in [f for f in local_files if f.endswith('scc')]: |
101 | if key.endswith('scc'): | 101 | with open(local_files[key], 'r') as sccfile: |
102 | sccfile = open(local_files[key], 'r') | ||
103 | for l in sccfile: | 102 | for l in sccfile: |
104 | line = l.split() | 103 | line = l.split() |
105 | if line and line[0] in ('kconf', 'patch'): | 104 | if line and line[0] in ('kconf', 'patch'): |
106 | cfg = os.path.join(os.path.dirname(local_files[key]), line[-1]) | 105 | cfg = os.path.join(os.path.dirname(local_files[key]), line[-1]) |
107 | if not cfg in local_files.values(): | 106 | if cfg not in local_files.values(): |
108 | local_files[line[-1]] = cfg | 107 | local_files[line[-1]] = cfg |
109 | shutil.copy2(cfg, workdir) | 108 | shutil.copy2(cfg, workdir) |
110 | sccfile.close() | ||
111 | 109 | ||
112 | # Ignore local files with subdir={BP} | 110 | # Ignore local files with subdir={BP} |
113 | srcabspath = os.path.abspath(srcsubdir) | 111 | srcabspath = os.path.abspath(srcsubdir) |