Bug 13127

Summary: changes in bbappend do not trigger a rebuild
Product: [Build System, Metadata & Runtime] BitBake Reporter: Jin <jin>
Component: bitbakeAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: poky.bs.watcher, poky.watcher, ross.burton
Version: unspecified   
Target Milestone: 2.7 M2   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Jin 2019-01-07 17:49:15 UTC
We're using poky 2.5.1, bitbake version reports:

bitbake --version
BitBake Build Tool Core version 1.38.0

We have a msmtp_%.bbappend where we modify pkg_postinst_ontarget by appending to it:

pkg_postinst_ontarget_${PN}_append() {
    killall -9 inotifyd || true
}

I am observing that changes in pkg_postinst_ontarget_${PN}_append() are not being picked up in incremental builds, i.e. I can change the line in the ontarget append function and the package is not being rebuilt.

If I cleanall the package and build it again, then my changes are there.

We are using prserv in our setup and for instance, changes in do_install_append() cause a rebuild an a prserv initiated pr bump, but changes in pkg_postinst_ontarget_${PN}_append() seem to be ignored. I can easily and consistently reproduce it in my setup.

It's worth mentioning, that when I run bitbake -e msmtp and look for pkg_postinst_ontarget_msmtp= in the output, then I do see my changes there.
Comment 1 Richard Purdie 2019-01-10 15:29:18 UTC
At a guess pkg_postinst_ontarget needs to be listed in PACKAGEVARS in package.bbclass for this to work properly.
Comment 3 Alexander Kanavin 2019-01-28 10:50:10 UTC
*** Bug 13151 has been marked as a duplicate of this bug. ***