diff options
Diffstat (limited to 'meta/classes/rm_work.bbclass')
-rw-r--r-- | meta/classes/rm_work.bbclass | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/meta/classes/rm_work.bbclass b/meta/classes/rm_work.bbclass index 054c93716e..2490a69c62 100644 --- a/meta/classes/rm_work.bbclass +++ b/meta/classes/rm_work.bbclass | |||
@@ -102,6 +102,12 @@ do_rm_work () { | |||
102 | rm -f $i | 102 | rm -f $i |
103 | done | 103 | done |
104 | } | 104 | } |
105 | do_rm_work_all () { | ||
106 | : | ||
107 | } | ||
108 | do_rm_work_all[recrdeptask] = "do_rm_work" | ||
109 | do_rm_work_all[noexec] = "1" | ||
110 | addtask rm_work_all after before do_build | ||
105 | 111 | ||
106 | do_populate_sdk[postfuncs] += "rm_work_populatesdk" | 112 | do_populate_sdk[postfuncs] += "rm_work_populatesdk" |
107 | rm_work_populatesdk () { | 113 | rm_work_populatesdk () { |
@@ -138,9 +144,8 @@ python inject_rm_work() { | |||
138 | # do_build inherits additional runtime dependencies on | 144 | # do_build inherits additional runtime dependencies on |
139 | # other recipes and thus will typically run much later than completion of | 145 | # other recipes and thus will typically run much later than completion of |
140 | # work in the recipe itself. | 146 | # work in the recipe itself. |
141 | deps = bb.build.preceedtask('do_build', True, d) | 147 | deps = set(bb.build.preceedtask('do_build', True, d)) |
142 | if 'do_build' in deps: | 148 | deps.difference_update(('do_build', 'do_rm_work_all')) |
143 | deps.remove('do_build') | ||
144 | # In practice, addtask() here merely updates the dependencies. | 149 | # In practice, addtask() here merely updates the dependencies. |
145 | bb.build.addtask('do_rm_work', 'do_build', ' '.join(deps), d) | 150 | bb.build.addtask('do_rm_work', 'do_build', ' '.join(deps), d) |
146 | } | 151 | } |