sstate: Add a rule for target sysroot requirements from cross dependencies

Submitted by Richard Purdie on Nov. 22, 2012, 9:38 p.m.

Details

Message ID 1353620300.10459.61.camel@ted
State Accepted
Commit 4b45039be4d1808e369f9cd22f332c6e3c540f1c
Headers show

Commit Message

Richard Purdie Nov. 22, 2012, 9:38 p.m.
For example gcc-cross depends on linux-libc-headers and needs it to be present
to build/work correctly.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---

Patch hide | download patch | download mbox

diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
index 470e0ee..b8a766b 100644
--- a/meta/classes/sstate.bbclass
+++ b/meta/classes/sstate.bbclass
@@ -663,6 +663,10 @@  def setscene_depvalid(task, taskdependees, notneeded, d):
         # Native/Cross populate_sysroot need their dependencies
         if isNativeCross(taskdependees[task][0]) and isNativeCross(taskdependees[dep][0]) and taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
             return False
+        # Target populate_sysroot depended on by cross tools need to be installed
+        if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot' and isNativeCross(taskdependees[dep][0]):
+            return False
+
         # Target populate_sysroot do not need their dependencies
         if taskdependees[task][1] == 'do_populate_sysroot' and taskdependees[dep][1] == 'do_populate_sysroot':
             continue