Bug 7030 - Re-building meta package does not trigger image rebuilds
Summary: Re-building meta package does not trigger image rebuilds
Status: RESOLVED WONTFIX
Alias: None
Product: BitBake
Classification: Build System, Metadata & Runtime
Component: bitbake (show other bugs)
Version: 1.5.3
Hardware: x86 Multiple
: Undecided normal
Target Milestone: ---
Assignee: Richard Purdie
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2014-12-04 17:11 UTC by mikko.rapeli
Modified: 2014-12-09 14:18 UTC (History)
2 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mikko.rapeli 2014-12-04 17:11:07 UTC
I'm building a custom yocto 1.5.3 based distro with a number of layers. To simplify building I created a meta package which depends on all real target images, sdk, tests etc.

But it seems that image recipies are not build when they are listed in DEPENDS += "image sdk" of the meta package.

With yocto 1.6 this is working as expected.

I verified with 'bitbake -g meta-package' that dependency to image recipe is correctly recorded, and 'bitbake image' naturally works.

Tried to go through patches in poky/bitbake poky/meta/classes which might be fixing this but didn't find them yet.
Comment 1 mikko.rapeli 2014-12-05 08:13:19 UTC
I'm also using SSTATE_CACHE if it matters. From 'bitbake -g meta' output I can see that package dependencies are correct, but task-depends.dot does not show any of the image tasks. I guess this is the problem then. None of the image tasks get executed via the meta package dependency.
Comment 2 mikko.rapeli 2014-12-05 09:30:03 UTC
Found a workaround by using inter-task dependencies http://www.yoctoproject.org/docs/1.6/bitbake-user-manual/bitbake-user-manual.html#inter-task-dependencies

In meta package .bb:

do_build[depends] += "image:do_install_version_info"

It seems that version info is the last task executed on our layers when creating the image.
Comment 3 Richard Purdie 2014-12-09 14:18:00 UTC
Using DEPENDS for this may not do what you expect. DEPENDS means that the do_configure of the task should depend on the do_populate_sysroot of the thing in DEPENDS. These are equivalent:

DEPENDS += "xxxx"
and
do_configure[depends] += "xxxx:do_populate_sysroot"

In the case of a rootfs, you want the do_rootfs task, not do_populate_sysroot so DEPENDS is not the correct thing to use. You are therefore correct in adding the dependencies.

The change between 1.5.and 1.6 was likely some fixes to do_build dependencies and recrdep dependency handling in bitbake. Those changes were problematic/invasive and will not be backported to 1.5 at this point. As such I'm going to mark this as WONTFIX.