summaryrefslogtreecommitdiffstats
path: root/meta/classes/archiver.bbclass
diff options
context:
space:
mode:
authorTom Hochstein <tom.hochstein@nxp.com>2018-04-03 08:51:15 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-04-05 14:49:07 +0100
commita6567a4c21f6d2a3f1fd4462d1e67d014b55472f (patch)
treec7acc4c1e11489905dce80f342d9b2af9794eef3 /meta/classes/archiver.bbclass
parentc2eec907cb9483dcc286eb1d6d2d7cfd6a649a39 (diff)
downloadpoky-a6567a4c21f6d2a3f1fd4462d1e67d014b55472f.tar.gz
archiver: Fix archive for linked kernel source
When archiving a kernel, if S is ${WORKDIR}/git, then ${WORKDIR}/git is in fact a soft link into work-shared, and the archive contains just the soft link. Fix by archiving the real directory. (From OE-Core rev: 564204dd6b73697ef4b6c17243067892876cc323) Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/archiver.bbclass')
-rw-r--r--meta/classes/archiver.bbclass5
1 files changed, 5 insertions, 0 deletions
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index c1076155b7..31c9b7eb4b 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -277,6 +277,11 @@ def create_tarball(d, srcdir, suffix, ar_outdir):
277 if (d.getVar('SRC_URI') == ""): 277 if (d.getVar('SRC_URI') == ""):
278 return 278 return
279 279
280 # For the kernel archive, srcdir may just be a link to the
281 # work-shared location. Use os.path.realpath to make sure
282 # that we archive the actual directory and not just the link.
283 srcdir = os.path.realpath(srcdir)
284
280 bb.utils.mkdirhier(ar_outdir) 285 bb.utils.mkdirhier(ar_outdir)
281 if suffix: 286 if suffix:
282 filename = '%s-%s.tar.gz' % (d.getVar('PF'), suffix) 287 filename = '%s-%s.tar.gz' % (d.getVar('PF'), suffix)