summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/classes/archiver.bbclass22
1 files changed, 11 insertions, 11 deletions
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 221c7f4797..4064674294 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -156,8 +156,9 @@ python do_ar_patched() {
156 156
157 # Get the ARCHIVER_OUTDIR before we reset the WORKDIR 157 # Get the ARCHIVER_OUTDIR before we reset the WORKDIR
158 ar_outdir = d.getVar('ARCHIVER_OUTDIR', True) 158 ar_outdir = d.getVar('ARCHIVER_OUTDIR', True)
159 ar_workdir = d.getVar('ARCHIVER_WORKDIR', True)
159 bb.note('Archiving the patched source...') 160 bb.note('Archiving the patched source...')
160 d.setVar('WORKDIR', ar_outdir) 161 d.setVar('WORKDIR', ar_workdir)
161 create_tarball(d, d.getVar('S', True), 'patched', ar_outdir) 162 create_tarball(d, d.getVar('S', True), 'patched', ar_outdir)
162} 163}
163 164
@@ -250,21 +251,20 @@ python do_unpack_and_patch() {
250 [ 'patched', 'configured'] and \ 251 [ 'patched', 'configured'] and \
251 d.getVarFlag('ARCHIVER_MODE', 'diff', True) != '1': 252 d.getVarFlag('ARCHIVER_MODE', 'diff', True) != '1':
252 return 253 return
253 # Change the WORKDIR to make do_unpack do_patch run in another dir.
254 ar_outdir = d.getVar('ARCHIVER_OUTDIR', True) 254 ar_outdir = d.getVar('ARCHIVER_OUTDIR', True)
255 d.setVar('WORKDIR', ar_outdir) 255 ar_workdir = d.getVar('ARCHIVER_WORKDIR', True)
256
257 # The changed 'WORKDIR' also caused 'B' changed, create dir 'B' for the
258 # possibly requiring of the following tasks (such as some recipes's
259 # do_patch required 'B' existed).
260 bb.utils.mkdirhier(d.getVar('B', True))
261 256
262 # The kernel class functions require it to be on work-shared, so we dont change WORKDIR 257 # The kernel class functions require it to be on work-shared, so we dont change WORKDIR
263 if not bb.data.inherits_class('kernel-yocto', d): 258 if not bb.data.inherits_class('kernel-yocto', d):
264 ar_outdir = d.getVar('ARCHIVER_OUTDIR', True) 259 # Change the WORKDIR to make do_unpack do_patch run in another dir.
265 d.setVar('WORKDIR', ar_outdir) 260 d.setVar('WORKDIR', ar_workdir)
266 bb.build.exec_func('do_unpack', d)
267 261
262 # The changed 'WORKDIR' also caused 'B' changed, create dir 'B' for the
263 # possibly requiring of the following tasks (such as some recipes's
264 # do_patch required 'B' existed).
265 bb.utils.mkdirhier(d.getVar('B', True))
266
267 bb.build.exec_func('do_unpack', d)
268 268
269 # Save the original source for creating the patches 269 # Save the original source for creating the patches
270 if d.getVarFlag('ARCHIVER_MODE', 'diff', True) == '1': 270 if d.getVarFlag('ARCHIVER_MODE', 'diff', True) == '1':