]> code.ossystems Code Review - openembedded-core.git/commitdiff
archiver.bbclass: Run deploy_archives in $WORKDIR
authorClemens Lang <clemens.lang@bmw-carit.de>
Mon, 17 Aug 2015 08:37:47 +0000 (10:37 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 19 Aug 2015 16:57:51 +0000 (17:57 +0100)
In recipes that are exempt from source code archiving due to
COPYLEFT_LICENSE_EXCLUDE, do_deploy_archives does not have a transitive
dependency on do_unpack. Given enough parallelism, this means
do_deploy_archives can run at the same time or before do_unpack.

Because do_deploy_archives did not specify a working directory, its
working directory was ${B}, which defaults to ${S}, which may be set by
a recipe to a directory that is created by do_unpack.

In this case, do_deploy_archives can fail because do_unpack deletes and
re-creates the directory and do_deploy_archives cannot change into the
non-existent directory. Avoid this problem by explicitly specifying
a working directory for do_deploy_archives (and for
do_deploy_all_archives as well for good measure).

Signed-off-by: Clemens Lang <clemens.lang@bmw-carit.de>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/classes/archiver.bbclass

index d908d162b173ef54c8e4de771a992f5b59b10f29..089d70748c1bcaaf19a5179a68ab09df0b8e0baf 100644 (file)
@@ -45,6 +45,8 @@ ARCHIVER_WORKDIR = "${WORKDIR}/archiver-work/"
 do_dumpdata[dirs] = "${ARCHIVER_OUTDIR}"
 do_ar_recipe[dirs] = "${ARCHIVER_OUTDIR}"
 do_ar_original[dirs] = "${ARCHIVER_OUTDIR} ${ARCHIVER_WORKDIR}"
+do_deploy_archives[dirs] = "${WORKDIR}"
+do_deploy_all_archives[dirs] = "${WORKDIR}"
 
 # This is a convenience for the shell script to use it