lasyer.conf/qemu-system-native: Improve native DISTRO_FEATURE handling
PATCH 1/1 lasyer.conf/qemu-system-native: Improve native DISTRO_FEATURE handling
OE-Core needs to make some improvements to the way DISTRO_FEATURES is being built but this will break the way meta-virtualization is handling native propagation.
Use DISTRO_FEATURES_FILTER_NATIVE which is designed for this.
That then means updating the bbappend just to look at DISTRO_FEATURES and to look for both possible values.
--- conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-)
conf/layer.conf +1 -1
@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURES for qemu virtfs support # This enables virtio-9p in qemu-system-native for container-cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization" NON_MULTILIB_RECIPES:append:x86-64 = " kubernetes"
recipes-devtools/qemu/qemu-system-native_%.bbappend +3 -3
@@ -6,7 +6,7 @@ # This is required for the fast batch-import path in container-cross-install. # # Note: Native recipes don't see target DISTRO_FEATURES directly. -# The layer.conf propagates virtualization to DISTRO_FEATURES_NATIVE when -# vcontainer or virtualization is in the target DISTRO_FEATURES. +# The layer.conf propagates virtualization and vcontainer to DISTRO_FEATURES +# using DISTRO_FEATURES_FILTER_NATIVE. -PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES_NATIVE', 'virtualization', ' virtfs', '', d)}" +PACKAGECONFIG:append = "${@bb.utils.contains_any('DISTRO_FEATURES', 'virtualization vcontainer', ' virtfs', '', d)}"
Quoted 24 lines · Richard Purdie via lists.yoctoproject.org
OE-Core needs to make some improvements to the way
DISTRO_FEATURESis being built
but this will break the way meta-virtualization is handling native propagation.Use
DISTRO_FEATURES_FILTER_NATIVEwhich is designed for this.That then means updating the bbappend just to look at
DISTRO_FEATURESand to
look for both possible values.Signed-off-by Richard Purdie <[email protected]>--- conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-)conf/layer.conf +0
-0@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURES for qemu
Quoted 8 lines
virtfs support
# This enables virtio-9p in qemu-system-native for
container-cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization"
I'm good to use DISTRO_FEATURES_FILTER_NATIVE, but it was less the mapping of vcontainer -> virtualization I was going for (although I did like the simplicity of just checking one), it was the yocto compat question.
Doesn't that change now make it an unconditional update to that variable (and everyone that had meta-virt in their layers now gets those two variables filtered )? Or is by the native of it being distro features there is special handling and it won't cause compatibility issues ?
Bruce
Quoted 35 lines
NON_MULTILIB_RECIPES:append:x86-64 = " kubernetes"
recipes-devtools/qemu/qemu-system-native_%.bbappend +0
-0@@ -6,7 +6,7 @@ # This is required for the fast batch-import path incontainer-cross-install.
#
# Note: Native recipes don't see targetDISTRO_FEATURESdirectly.recipes-devtools/qemu/qemu-system-native_%.bbappend +1
-2-# The layer.conf propagates virtualization to DISTRO_FEATURES_NATIVE when -# vcontainer or virtualization is in the target DISTRO_FEATURES. +# The layer.conf propagates virtualization and vcontainer to
DISTRO_FEATURESrecipes-devtools/qemu/qemu-system-native_%.bbappend +1
-1+# using DISTRO_FEATURES_FILTER_NATIVE. -PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES_NATIVE','virtualization', ' virtfs', '', d)}" +PACKAGECONFIG:append = "${@bb.utils.contains_any('DISTRO_FEATURES', 'virtualization vcontainer', ' virtfs', '', d)}"
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9728):
https://lists.yoctoproject.org/g/meta-virtualization/message/9728
Mute This Topic: https://lists.yoctoproject.org/mt/118973947/1050810
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Signature · 3 lines
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end - "Use the force Harry" - Gandalf, Star Trek II
Quoted 42 lines · Bruce Ashfield via lists.yoctoproject.org
Quoted 24 lines · Richard Purdie via lists.yoctoproject.org
OE-Core needs to make some improvements to the way
DISTRO_FEATURESis being built
but this will break the way meta-virtualization is handling native propagation.Use
DISTRO_FEATURES_FILTER_NATIVEwhich is designed for this.That then means updating the bbappend just to look at
DISTRO_FEATURESand to
look for both possible values.Signed-off-by Richard Purdie <[email protected]>--- conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-)conf/layer.conf +0
-0@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURES for qemuQuoted 8 lines
virtfs support
# This enables virtio-9p in qemu-system-native for
container-cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization"I'm good to use
DISTRO_FEATURES_FILTER_NATIVE, but it was less the mapping of vcontainer -> virtualization I was going for (although I did like the simplicity of just checking one), it was the yocto compat question.
Quoted 8 lines
Doesn't that change now make it an unconditional update to that variable (and everyone that had meta-virt in their layers now gets those two variables filtered )? Or is by the native of it being distro features there is special handling and it won't cause compatibility issues ?
Bruce
I think we have a related problem with DISTRO_FEATURES_FILTER_NATIVESDK:
ERROR: Nothing PROVIDES 'nativesdk-libseccomp' (but mc:vruntime-aarch64:virtual:nativesdk:/home/pokybuild/yocto-worker/vcontainer-tarball/build/layers/openembedded-core/meta/recipes-support/gnutls/ gnutls_3.8.12.bb DEPENDS on or otherwise requires it). ...
--Tim
Quoted 46 lines
Quoted 21 lines
NON_MULTILIB_RECIPES:append:x86-64 = " kubernetes"
recipes-devtools/qemu/qemu-system-native_%.bbappend +0
-0@@ -6,7 +6,7 @@ # This is required for the fast batch-import path incontainer-cross-install.
#
# Note: Native recipes don't see targetDISTRO_FEATURESdirectly.recipes-devtools/qemu/qemu-system-native_%.bbappend +1
-2-# The layer.conf propagates virtualization to DISTRO_FEATURES_NATIVE when -# vcontainer or virtualization is in the target DISTRO_FEATURES. +# The layer.conf propagates virtualization and vcontainer to
DISTRO_FEATURESrecipes-devtools/qemu/qemu-system-native_%.bbappend +1
-1+# using DISTRO_FEATURES_FILTER_NATIVE. -PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES_NATIVE',Quoted 7 lines
'virtualization', ' virtfs', '', d)}" +PACKAGECONFIG:append = "${@bb.utils.contains_any('DISTRO_FEATURES', 'virtualization vcontainer', ' virtfs', '', d)}"
--
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end
- "Use the force Harry" - Gandalf, Star Trek II-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9732):
https://lists.yoctoproject.org/g/meta-virtualization/message/9732
Mute This Topic: https://lists.yoctoproject.org/mt/118973947/924729
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 53 lines · Tim Orling via lists.yoctoproject.org
Quoted 48 lines · Bruce Ashfield via lists.yoctoproject.org
Quoted 24 lines · Richard Purdie via lists.yoctoproject.org
OE-Core needs to make some improvements to the way
DISTRO_FEATURESis being built
but this will break the way meta-virtualization is handling native propagation.Use
DISTRO_FEATURES_FILTER_NATIVEwhich is designed for this.That then means updating the bbappend just to look at
DISTRO_FEATURESand to
look for both possible values.Signed-off-by Richard Purdie <[email protected]>--- conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-)conf/layer.conf +0
-0@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURES forQuoted 8 lines
qemu virtfs support
# This enables virtio-9p in qemu-system-native for
container-cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization"I'm good to use
DISTRO_FEATURES_FILTER_NATIVE, but it was less the mapping of vcontainer -> virtualization I was going for (although I did like the simplicity of just checking one), it was the yocto compat question.Doesn't that change now make it an unconditional update to that variable (and everyone that had meta-virt in their layers now gets those two variables filtered )? Or is by the native of it being distro features there is special handling and it won't cause compatibility issues ?
Quoted 9 lines
Quoted 3 lines
Bruce
I think we have a related problem with
DISTRO_FEATURES_FILTER_NATIVESDK:
ERROR: Nothing PROVIDES 'nativesdk-libseccomp' (but mc:vruntime-aarch64:virtual:nativesdk:/home/pokybuild/yocto-worker/vcontainer-tarball/build/layers/openembedded-core/meta/recipes-support/gnutls/ gnutls_3.8.12.bb DEPENDS on or otherwise requires it). ...
Fixed with https://lists.yoctoproject.org/g/meta-virtualization/message/9736
In this case it was DISTRO_FEATURES_DEFAULT => DISTRO_FEATURES_DEFAULTS that only got uncovered by recent change to filtering.
Quoted 53 lines
--Tim
Quoted 21 lines
Quoted 21 lines
NON_MULTILIB_RECIPES:append:x86-64 = " kubernetes"
recipes-devtools/qemu/qemu-system-native_%.bbappend +0
-0@@ -6,7 +6,7 @@ # This is required for the fast batch-import path incontainer-cross-install.
#
# Note: Native recipes don't see targetDISTRO_FEATURESdirectly.
-# The layer.conf propagates virtualization toDISTRO_FEATURES_NATIVEwhenrecipes-devtools/qemu/qemu-system-native_%.bbappend +1
-1-# vcontainer or virtualization is in the target DISTRO_FEATURES. +# The layer.conf propagates virtualization and vcontainer to
DISTRO_FEATURES
+# usingDISTRO_FEATURES_FILTER_NATIVE.Quoted 18 lines
Quoted 8 lines
-PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES_NATIVE', 'virtualization', ' virtfs', '', d)}"
+PACKAGECONFIG:append = "${@bb.utils.contains_any('DISTRO_FEATURES', 'virtualization vcontainer', ' virtfs', '', d)}"--
- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end
- "Use the force Harry" - Gandalf, Star Trek II-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#9735):
https://lists.yoctoproject.org/g/meta-virtualization/message/9735
Mute This Topic: https://lists.yoctoproject.org/mt/118973947/924729
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/meta-virtualization/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Quoted 35 lines · Bruce Ashfield
Quoted 19 lines · Richard Purdie via lists.yoctoproject.org
OE-Core needs to make some improvements to the way
DISTRO_FEATURESis being built but this will break the way meta-virtualization is handling native propagation.Use
DISTRO_FEATURES_FILTER_NATIVEwhich is designed for this.That then means updating the bbappend just to look at
DISTRO_FEATURESand to look for both possible values.Signed-off-by Richard Purdie <[email protected]>---
conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++---2 files changed, 4 insertions(+), 4 deletions(-)conf/layer.conf +0
-0conf/layer.conf HOSTTOOLS_NONFATAL += "getent" · line 76
Quoted 6 lines
conf/layer.conf +1
-1@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURES for qemu virtfs support # This enables virtio-9p in qemu-system-native for container-cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization"I'm good to use
DISTRO_FEATURES_FILTER_NATIVE, but it was less the mapping of vcontainer -> virtualization I was going for (although I did like the simplicity of just checking one), it was the yocto compat question.
Quoted 5 lines
Doesn't that change now make it an unconditional update to that variable (and everyone that had meta-virt in their layers now gets those two variables filtered )? Or is by the native of it being distro features there is special handling and it won't cause compatibility issues ?
The problem isn't an unconditional update in itself, it would be an unconditional update to a variable things actually depend upon.
If that breaks YP compat, I think we globally exclude DISTRO_FEATURES_FILTER_NATIVE from hashes since the piece that matters is DISTRO_FEATURES itself. I don't think that dependency should be picked up but I'm not 100% sure and there may be a path the dependency code can find.
DISTRO_FEATURES is the thing which would change than code would actually be depending upon.
Unfortunately meta-virtualization YP compat was already failing with another issue so we need to fix that one first before we can test this.
Cheers,
Richard
Quoted 41 lines · Bruce Ashfield
Quoted 24 lines · Richard Purdie via lists.yoctoproject.org
OE-Core needs to make some improvements to the way
DISTRO_FEATURESis being built
but this will break the way meta-virtualization is handling native propagation.Use
DISTRO_FEATURES_FILTER_NATIVEwhich is designed for this.That then means updating the bbappend just to look at
DISTRO_FEATURESand to
look for both possible values.Signed-off-by Richard Purdie <[email protected]>---
conf/layer.conf | 2 +- recipes-devtools/qemu/qemu-system-native_%.bbappend | 6 +++---2 files changed, 4 insertions(+), 4 deletions(-)conf/layer.conf +0
-0@@ -72,7 +72,7 @@ HOSTTOOLS_NONFATAL += "getent" # Propagate virtualization/vcontainer to native DISTRO_FEATURESQuoted 9 lines
for qemu virtfs support
# This enables virtio-9p in qemu-system-native for container- cross-install batch imports -DISTRO_FEATURES_NATIVE:append = " ${@bb.utils.contains_any('DISTRO_FEATURES', 'vcontainer virtualization', 'virtualization', '', d)}" +DISTRO_FEATURES_FILTER_NATIVE:append = " vcontainer virtualization"I'm good to use
DISTRO_FEATURES_FILTER_NATIVE, but it was less the mapping of vcontainer -> virtualization I was going for (although I did like the simplicity of just checking one), it was the yocto compat question.
Quoted 5 lines
Doesn't that change now make it an unconditional update to that variable (and everyone that had meta-virt in their layers now gets those two variables filtered )? Or is by the native of it being distro features there is special handling and it won't cause compatibility issues ?
Just to follow up, I fixed the ca-certificates issue (patch sent) and once I did that, I could confirm that after my patch, yocto-check-layer still passes. We're therefore good on that front.
I also compiled a list of usability issues we need to fix in yocto- check-layer:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=16266
Cheers,
Richard