Skip to contentSkip to conversation

qemu-helper-native/systemtap-native: Ensure sysroots are populated with dependencies

PATCH In review Richard Purdie 2 participants 2 messages Dec 5, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qemu-helper-native/systemtap-native: Ensure sysroots are populated with dependencies

As Alex Kanavin found, dependencies aren't always populated, particularly with the hash equivalence server enabled locally:

'bitbake core-image-minimal' with gtk+ disabled.
can confirm with: $ tmp/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/qemu-system-x86_64 -display gtk
qemu-system-x86_64: Display 'gtk' is not available.
Enable gtk in local.conf with: PACKAGECONFIG_append_pn-qemu-system-native = " gtk+"
'bitbake core-image-minimal', without deleting tmp/

$ tmp/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/qemu-system-x86_64 -display gtk
qemu-system-x86_64: Display 'gtk' is not available.

This change ensures the dependencies are correctly handled as the full sysroot is always depended upon even if things come from sstate.

---
 meta/classes/native.bbclass                           | 2 +-
 meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb  | 2 +-
 meta/recipes-kernel/systemtap/systemtap-native_git.bb | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
meta/classes/native.bbclass +1 -1
index d5b6f6af8bb..2cc6ad60b34 100644
@@ -185,7 +185,7 @@ native_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
 python do_addto_recipe_sysroot () {
     bb.build.exec_func("extend_recipe_sysroot", d)
 }
-addtask addto_recipe_sysroot after do_populate_sysroot
+addtask addto_recipe_sysroot after do_populate_sysroot do_prepare_recipe_sysroot
 
 inherit nopackages
 
meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb +1 -1
index 372eebd8864..ab4eb2d2268 100644
@@ -21,4 +21,4 @@ do_install() {
 }
 
 DEPENDS += "qemu-system-native"
-addtask addto_recipe_sysroot after do_populate_sysroot before do_build
+addtask addto_recipe_sysroot after do_populate_sysroot do_prepare_recipe_sysroot before do_build
meta/recipes-kernel/systemtap/systemtap-native_git.bb +1 -1
index 19cc1cf0f0a..b00f66e25dd 100644
@@ -3,4 +3,4 @@ require systemtap_git.bb
 
 inherit native
 
-addtask addto_recipe_sysroot after do_populate_sysroot before do_build
+addtask addto_recipe_sysroot after do_prepare_recipe_sysroot do_populate_sysroot before do_build
Signature · 1 line
2.20.1
#1 lore raw
Quoted 26 lines · Richard Purdie

As Alex Kanavin found, dependencies aren't always populated, particularly with the hash equivalence server enabled locally:

'bitbake core-image-minimal' with gtk+ disabled.
can confirm with: $ tmp/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/qemu-system-x86_64 -display gtk
qemu-system-x86_64: Display 'gtk' is not available.
Enable gtk in local.conf with: PACKAGECONFIG_append_pn-qemu-system-native = " gtk+"
'bitbake core-image-minimal', without deleting tmp/

$ tmp/work/x86_64-linux/qemu-helper-native/1.0-r1/recipe-sysroot-native/usr/bin/qemu-system-x86_64 -display gtk
qemu-system-x86_64: Display 'gtk' is not available.

This change ensures the dependencies are correctly handled as the full sysroot is always depended upon even if things come from sstate.

---
  meta/classes/native.bbclass                           | 2 +-
  meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb  | 2 +-
  meta/recipes-kernel/systemtap/systemtap-native_git.bb | 2 +-
  3 files changed, 3 insertions(+), 3 deletions(-)
meta/classes/native.bbclass +0 -0
index d5b6f6af8bb..2cc6ad60b34 100644

meta/classes/native.bbclass native_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise" · line 188

Quoted 5 lines
meta/classes/native.bbclass +1 -1
@@ -185,7 +185,7 @@ native_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
  python do_addto_recipe_sysroot () {
      bb.build.exec_func("extend_recipe_sysroot", d)
  }
-addtask addto_recipe_sysroot after do_populate_sysroot
+addtask addto_recipe_sysroot after do_populate_sysroot do_prepare_recipe_sysroot

I didn't mention it, but cross.bbclass does this too.

Quoted 23 lines
meta/classes/native.bbclass +0 -0
  inherit nopackages
 
meta/recipes-devtools/qemu/qemu-helper-native_1.0.bb +1 -1
index 372eebd8864..ab4eb2d2268 100644
@@ -21,4 +21,4 @@ do_install() {
  }
 
  DEPENDS += "qemu-system-native"
-addtask addto_recipe_sysroot after do_populate_sysroot before do_build
+addtask addto_recipe_sysroot after do_populate_sysroot do_prepare_recipe_sysroot before do_build
meta/recipes-kernel/systemtap/systemtap-native_git.bb +1 -1
index 19cc1cf0f0a..b00f66e25dd 100644
@@ -3,4 +3,4 @@ require systemtap_git.bb
 
  inherit native
 
-addtask addto_recipe_sysroot after do_populate_sysroot before do_build
+addtask addto_recipe_sysroot after do_prepare_recipe_sysroot do_populate_sysroot before do_build