Skip to contentSkip to conversation

ref-manual: Warn about COMPATIBLE_MACHINE skipping native recipes

PATCH In review Arne Schwerdt 2 participants 2 messages Oct 11, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ref-manual: Warn about COMPATIBLE_MACHINE skipping native recipes

---
A recipe inherits from the native.bbclass is always skipped when the COMPATIBLE_MACHINE is set. This behavior has been introduced with daisy (poky/meta/classes/native.bbclass:107). It should be at least mentioned in the documentation.

 documentation/ref-manual/variables.rst | 6 ++++++
 1 file changed, 6 insertions(+)
documentation/ref-manual/variables.rst +6 -0
index 11523bb9e..a6f7ea03a 100644
@@ -1358,6 +1358,12 @@ system and gives an overview of their function and contents.
       speed since the build system skips parsing recipes not compatible
       with the current machine.
 
+      .. note::
+
+         When :term:`COMPATIBLE_MACHINE` is set in a recipe inherits from native, the recipe is always skipped.
+         All native recipes must be entirely target independent and should not rely on :term:`MACHINE`. 
+
+
    :term:`COMPLEMENTARY_GLOB`
       Defines wildcards to match when installing a list of complementary
       packages for all the packages explicitly (or implicitly) installed in
Signature · 1 line
2.39.2
Reviewed-by on v1 1/1
#1 lore raw

Hi Arne

Quoted 13 lines · Arne Schwerdt

---
A recipe inherits from the native.bbclass is always skipped when the COMPATIBLE_MACHINE is set. This behavior has been introduced with daisy (poky/meta/classes/native.bbclass:107). It should be at least mentioned in the documentation.

  documentation/ref-manual/variables.rst | 6 ++++++
  1 file changed, 6 insertions(+)
documentation/ref-manual/variables.rst +0 -0
index 11523bb9e..a6f7ea03a 100644
@@ -1358,6 +1358,12 @@ system and gives an overview of their function and contents.
        speed since the build system skips parsing recipes not compatible
        with the current machine.

documentation/ref-manual/variables.rst system and gives an overview of their function and contents. · line 1369

Quoted 10 lines
documentation/ref-manual/variables.rst +6 -0
 
+      .. note::
+
+         When :term:`COMPATIBLE_MACHINE` is set in a recipe inherits from native, the recipe is always skipped.
+         All native recipes must be entirely target independent and should not rely on :term:`MACHINE`.
+
+
     :term:`COMPLEMENTARY_GLOB`
        Defines wildcards to match when installing a list of complementary
        packages for all the packages explicitly (or implicitly) installed in

Thanks for the patch!
Oops, you forget to sign-off your patch. Next time you should use "git commit -s" (see https://docs.yoctoproject.org/contributor-guide/submit-changes.html#creating-patches).
I fixed this by myself.

and merged into "master-next".

Thanks again!
Cheers
Michael.

Signature · 3 lines
Michael Opdenacker, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com