summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Barker <pbarker@toganlabs.com>2018-02-26 13:59:23 +0000
committerPaul Barker <pbarker@toganlabs.com>2018-02-26 21:54:11 +0000
commitec26440fb1f504451c20d4fced0ba88093f6f695 (patch)
treee80cec4d94e7d5a4773275d5815afb5acf384823
parent72bc798ff548ba610e8dea53c80e39a37de8e043 (diff)
downloadmeta-raspberrypi-ec26440fb1f504451c20d4fced0ba88093f6f695.tar.gz
Fix do_image_rpi_sdimg/do_image_wic dependencies
The dependency resolution code in bitbake has recently been optimized and this seems to have slightly changed the behaviour of do_image_rpi_sdimg and do_image_wic. We ensure that the main build artifacts are present by depending on the relevant do_deploy and do_populate_sysroot tasks. However, we need to ensure that other build tasks for these dependencies have also been executed before we try to create our image. This can be achieved by adding a recursive dependency on do_build, so that the do_build tasks of all recipes in the dependency chain of do_image_rpi_sdimg/do_image_wic are executed before the image function itself is executed. The original issue seen here was that 'recipedata' files were not copied to 'tmp/deploy/licenses' as do_populate_lic for each dependency had not been ran before the image creation function. The write_deploy_manifest function from license.bbclass (listed in IMAGE_POSTPROCESS_COMMAND) therefore failed. Adding the recursive dependency on do_build fixes this issue, ensuring do_populate_lic runs before do_image_rpi_sdimg/do_image_wic. Signed-off-by: Paul Barker <pbarker@toganlabs.com>
-rw-r--r--classes/sdcard_image-rpi.bbclass2
-rw-r--r--conf/machine/include/rpi-base.inc2
2 files changed, 4 insertions, 0 deletions
diff --git a/classes/sdcard_image-rpi.bbclass b/classes/sdcard_image-rpi.bbclass
index 2dd9326..3cb6baa 100644
--- a/classes/sdcard_image-rpi.bbclass
+++ b/classes/sdcard_image-rpi.bbclass
@@ -58,6 +58,8 @@ do_image_rpi_sdimg[depends] = " \
58 ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \ 58 ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \
59 " 59 "
60 60
61do_image_rpi_sdimg[recrdeps] = "do_build"
62
61# SD card image name 63# SD card image name
62SDIMG = "${IMGDEPLOYDIR}/${IMAGE_NAME}.rootfs.rpi-sdimg" 64SDIMG = "${IMGDEPLOYDIR}/${IMAGE_NAME}.rootfs.rpi-sdimg"
63 65
diff --git a/conf/machine/include/rpi-base.inc b/conf/machine/include/rpi-base.inc
index 937a8b1..ae71818 100644
--- a/conf/machine/include/rpi-base.inc
+++ b/conf/machine/include/rpi-base.inc
@@ -104,6 +104,8 @@ do_image_wic[depends] += " \
104 ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \ 104 ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'u-boot:do_deploy', '',d)} \
105 " 105 "
106 106
107do_image_wic[recrdeps] = "do_build"
108
107# The kernel image is installed into the FAT32 boot partition and does not need 109# The kernel image is installed into the FAT32 boot partition and does not need
108# to also be installed into the rootfs. 110# to also be installed into the rootfs.
109RDEPENDS_${KERNEL_PACKAGE_NAME}-base = "" 111RDEPENDS_${KERNEL_PACKAGE_NAME}-base = ""