Bug 10113

Summary: native recipes do not include runtime dependencies when populating sysroot
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Otavio Salvador <otavio>
Component: coreAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: Medium CC: meta.mr.watcher, meta.watcher, richard.purdie, sgw
Version: 2.1   
Target Milestone: Future   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Otavio Salvador 2016-08-11 12:17:07 UTC
This error has been catch with a Python recipe which include some runtime dependencies on other packages.

The do_populate_sysroot does not include dependencies on the runtime dependencies so those are not installed at all, leaving the tool in a non-working state.

Adding:

do_populate_sysroot[rdeptask] = "do_populate_sysroot"

To the recipe workaround the problem.
Comment 1 Richard Purdie 2016-08-11 12:33:49 UTC
To elaborate, if you have a recipe foo which does:

RDEPENDS_${PN} = " \
    python3-requests \
"
BBCLASSEXTEND = "native"

and you "bitbake foo-native -g", depends.dot shows foo-native has an RDEPENDS on python3-requests-native but task-depends.dot doesn't show a dependency from the do_populate_sysroot task. If we add the line:

do_populate_sysroot[rdeptask] = "do_populate_sysroot"

then the python3-requests-native:do_populate_sysroot dependency shows up correctly. Sadly adding this line to native.bbclass results in circular dependency errors however :(
Comment 2 Richard Purdie 2017-06-06 11:05:55 UTC
Unfortunately this creates a lot of issues when trying to fix it properly. I would like to do that but its going to take a lot of time which we don't have right now and we have workarounds for the immediate issues. Reprioritising accordingly.
Comment 3 Richard Purdie 2019-02-17 10:26:09 UTC
Finally found time to fix this http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=eea86c4f0a960d0094571a78dc0cf9d46d162a22 (was easier once the dependency look code in bitbake was fixed)