Skip to contentSkip to conversation

cmake-native: enabled zstd support

PATCH In review Ruslan Babayev (fib) 4 participants 8 messages Jul 23, 2021 – Jul 27, 2021 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

PATCH v2 1/3 cmake-native: enabled zstd support

From: Samuli Piippo <[email protected]>

CMake depends on having all formats supported and build issues can arise when zstd is not available:
https://gitlab.kitware.com/cmake/cmake/-/issues/21552

Quote from a CMake dev:
"As far as CMake's design is concerned, we have no optional formats. All should be supported. That's why we bundle sufficiently new versions of libarchive and libzstd. If a distro builds with an older libarchive that doesn't have zstd support, then that is not a proper packaging of CMake."

---
 meta/recipes-devtools/cmake/cmake-native_3.16.5.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +1 -1
index b2952ee5f5..6034b654da 100644
@@ -1,7 +1,7 @@
 require cmake.inc
 inherit native
 
-DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native"
+DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native zstd-native"
 
 SRC_URI += "file://OEToolchainConfig.cmake \
             file://environment.d-cmake.sh \
Signature · 1 line
2.26.2.Cisco
#2 lore raw
Quoted 25 lines · Ruslan Babayev (fib) via lists.openembedded.org

From: Samuli Piippo <[email protected]>

CMake depends on having all formats supported and build issues can arise when zstd is not available:
https://gitlab.kitware.com/cmake/cmake/-/issues/21552

Quote from a CMake dev:
"As far as CMake's design is concerned, we have no optional formats. All should be supported. That's why we bundle sufficiently new versions of libarchive and libzstd. If a distro builds with an older libarchive that doesn't have zstd support, then that is not a proper packaging of CMake."

---
 meta/recipes-devtools/cmake/cmake-native_3.16.5.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -0
index b2952ee5f5..6034b654da 100644

meta/recipes-devtools/cmake/cmake-native_3.16.5.bb line 4

Quoted 5 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +1 -1
@@ -1,7 +1,7 @@
 require cmake.inc
 inherit native
 
-DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native"
+DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native zstd-native"

In hardknott/master the zstd recipe has been moved from meta-openembedded to oe-core. This is not the case for dunfell, so this change will result in failures for builds that do not include meta-openembedded.

So this patch is not suitable for dunfell unless the community/steering committee decide to also move the recipe in dunfell.

Steve

Quoted 9 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -1
 SRC_URI += "file://OEToolchainConfig.cmake \
             file://environment.d-cmake.sh \
--

2.26.2.Cisco

#3 lore raw

Hi Steve,

Thanks for reviewing the patches. I understand the problem of merging this patch as is.
But Dunfell currently has a host contamination issue on systems with zstd installed as part of base OS resulting in broken cmake-native recipe. Can you help bring this up to the attention of the steering committee?

As for the other two patches in the series. Do they look OK? Do you see any issues in merging them? Or would you like me to separated them from the cmake patch?

Thanks,
Ruslan

-----Original Message-----
From: Steve Sakoman <[email protected]>
Sent: Monday, July 26, 2021 8:05 AM
To: Ruslan Babayev (fib) <[email protected]>
Cc: Patches and discussions about the oe-core layer <[email protected]>; Samuli Piippo <[email protected]>; Samuli Piippo <[email protected]>; Richard Purdie <[email protected]>
Subject: Re: [OE-core][dunfell][PATCH v2 1/3] cmake-native: enabled zstd support

Quoted 26 lines · Ruslan Babayev (fib) via lists.openembedded.org

From: Samuli Piippo <[email protected]>

CMake depends on having all formats supported and build issues can arise when zstd is not available:
https://gitlab.kitware.com/cmake/cmake/-/issues/21552

Quote from a CMake dev:
"As far as CMake's design is concerned, we have no optional formats.
All should be supported. That's why we bundle sufficiently new
versions of libarchive and libzstd. If a distro builds with an older libarchive that doesn't have zstd support, then that is not a proper packaging of CMake."

---
 meta/recipes-devtools/cmake/cmake-native_3.16.5.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -0
index b2952ee5f5..6034b654da 100644

meta/recipes-devtools/cmake/cmake-native_3.16.5.bb line 4

Quoted 5 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +1 -1
@@ -1,7 +1,7 @@
 require cmake.inc
 inherit native
 
-DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native"
+DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native zstd-native"

In hardknott/master the zstd recipe has been moved from meta-openembedded to oe-core. This is not the case for dunfell, so this change will result in failures for builds that do not include meta-openembedded.

So this patch is not suitable for dunfell unless the community/steering committee decide to also move the recipe in dunfell.

Steve

Quoted 9 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -1
 SRC_URI += "file://OEToolchainConfig.cmake \
             file://environment.d-cmake.sh \
--

2.26.2.Cisco

#4 lore raw
Quoted 5 lines · Ruslan Babayev (fib)

Hi Steve,

Thanks for reviewing the patches. I understand the problem of merging this patch as is.
But Dunfell currently has a host contamination issue on systems with zstd installed as part of base OS resulting in broken cmake-native recipe. Can you help bring this up to the attention of the steering committee?

Perhaps Richard can comment on this. You are asking for a feature change to dunfell that involves modifications in both openembedded-core and meta-openembedded. So both technical steering committees would need to agree that this is appropriate.

Quoted 1 line

As for the other two patches in the series. Do they look OK? Do you see any issues in merging them? Or would you like me to separated them from the cmake patch?

The other two patches don't have issues, so no need to re-submit!

Steve

Quoted 59 lines

Thanks,
Ruslan

-----Original Message-----
From: Steve Sakoman <[email protected]>
Sent: Monday, July 26, 2021 8:05 AM
To: Ruslan Babayev (fib) <[email protected]>
Cc: Patches and discussions about the oe-core layer <[email protected]>; Samuli Piippo <[email protected]>; Samuli Piippo <[email protected]>; Richard Purdie <[email protected]>
Subject: Re: [OE-core][dunfell][PATCH v2 1/3] cmake-native: enabled zstd support

Quoted 26 lines · Ruslan Babayev (fib) via lists.openembedded.org

From: Samuli Piippo <[email protected]>

CMake depends on having all formats supported and build issues can arise when zstd is not available:
https://gitlab.kitware.com/cmake/cmake/-/issues/21552

Quote from a CMake dev:
"As far as CMake's design is concerned, we have no optional formats.
All should be supported. That's why we bundle sufficiently new
versions of libarchive and libzstd. If a distro builds with an older libarchive that doesn't have zstd support, then that is not a proper packaging of CMake."

---
 meta/recipes-devtools/cmake/cmake-native_3.16.5.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -0
index b2952ee5f5..6034b654da 100644

meta/recipes-devtools/cmake/cmake-native_3.16.5.bb line 4

Quoted 5 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +1 -1
@@ -1,7 +1,7 @@
 require cmake.inc
 inherit native
 
-DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native"
+DEPENDS += "bzip2-replacement-native expat-native xz-native zlib-native curl-native ncurses-native zstd-native"

In hardknott/master the zstd recipe has been moved from meta-openembedded to oe-core. This is not the case for dunfell, so this change will result in failures for builds that do not include meta-openembedded.

So this patch is not suitable for dunfell unless the community/steering committee decide to also move the recipe in dunfell.

Steve

Quoted 9 lines
meta/recipes-devtools/cmake/cmake-native_3.16.5.bb +0 -1
 SRC_URI += "file://OEToolchainConfig.cmake \
             file://environment.d-cmake.sh \
--

2.26.2.Cisco

#5 lore raw
Quoted 10 lines · Steve Sakoman
Quoted 8 lines · Ruslan Babayev (fib)

Hi Steve,

Thanks for reviewing the patches. I understand the problem of merging this patch as is.
But Dunfell currently has a host contamination issue on systems with zstd installed as part of base OS resulting in broken cmake-native recipe. Can you help bring this up to the attention of the steering committee?

Quoted 4 lines

Perhaps Richard can comment on this. You are asking for a feature change to dunfell that involves modifications in both openembedded-core and meta-openembedded. So both technical steering committees would need to agree that this is appropriate.

We don't have to go straight to the TSC, the layer maintainers can try and agree a plan first.

I've added Armin as meta-openembedded maintainer for dunfell.

Context: cmake-native suffers host contamination on dunfell due to zstd being detected on the host. The upstream cmake community say they don't support configuring it without it.

Do we agree we should move zstd from meta-oe to oe-core in dunfell to fix this? Should we patch cmake in dunfell to try and use it's own copy of zstd internally? The latter is more risky in that we've not tried that and multiple configures can be 'fun' in builds. Moving the recipe has a different kind of pain.

Thoughts?

Cheers,

Richard

#6 lore raw
Quoted 26 lines · Richard Purdie
Quoted 10 lines · Steve Sakoman
Quoted 8 lines · Ruslan Babayev (fib)

Hi Steve,

Thanks for reviewing the patches. I understand the problem of merging this patch as is.
But Dunfell currently has a host contamination issue on systems with zstd installed as part of base OS resulting in broken cmake-native recipe. Can you help bring this up to the attention of the steering committee?

Quoted 4 lines

Perhaps Richard can comment on this. You are asking for a feature change to dunfell that involves modifications in both openembedded-core and meta-openembedded. So both technical steering committees would need to agree that this is appropriate.

We don't have to go straight to the TSC, the layer maintainers can try and agree a plan first.

I've added Armin as meta-openembedded maintainer for dunfell.

Context: cmake-native suffers host contamination on dunfell due to zstd being detected on the host. The upstream cmake community say they don't support configuring it without it.

Quoted 5 lines

Do we agree we should move zstd from meta-oe to oe-core in dunfell to fix this? Should we patch cmake in dunfell to try and use it's own copy of zstd internally? The latter is more risky in that we've not tried that and multiple configures can be 'fun' in builds. Moving the recipe has a different kind of pain.

There's no need to move the recipe, just adding to oe-core should be enough.

#7 lore raw

PATCH v2 2/3 qemu.inc: Add seccomp PACKAGECONFIG option

In reply to a message not in the archive

From: Nathan Rossi <[email protected]>

Add the seccomp PACKAGECONFIG option to allow building seccomp features in QEMU. The libseccomp library is available in additional layers (e.g. meta-security).

Additionally this serves as a way to disable seccomp by default to avoid the configure of QEMU automatically finding it (via pkg-config) on the build host when building qemu-system-native and auto enabling the feature.

---
 meta/recipes-devtools/qemu/qemu.inc | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-devtools/qemu/qemu.inc +1 -0
index 8f927bdf54..e25c2524aa 100644
@@ -210,6 +210,7 @@ PACKAGECONFIG[glusterfs] = "--enable-glusterfs,--disable-glusterfs"
 PACKAGECONFIG[xkbcommon] = "--enable-xkbcommon,--disable-xkbcommon,libxkbcommon"
 PACKAGECONFIG[libudev] = "--enable-libudev,--disable-libudev,eudev"
 PACKAGECONFIG[libxml2] = "--enable-libxml2,--disable-libxml2,libxml2"
+PACKAGECONFIG[seccomp] = "--enable-seccomp,--disable-seccomp,libseccomp"
 
 INSANE_SKIP_${PN} = "arch"
 
Signature · 1 line
2.26.2.Cisco
#8 lore raw

PATCH v2 3/3 qemu: Enable seccomp if FEATURE is set

In reply to a message not in the archive

From: Armin Kuster <[email protected]>

---
 meta/recipes-devtools/qemu/qemu_4.2.0.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-devtools/qemu/qemu_4.2.0.bb +1 -0
index 9c76144749..f9905e2812 100644
@@ -26,5 +26,6 @@ do_install_append_class-nativesdk() {
 PACKAGECONFIG ??= " \
     fdt sdl kvm \
     ${@bb.utils.filter('DISTRO_FEATURES', 'alsa xen', d)} \
+    ${@bb.utils.filter('DISTRO_FEATURES', 'seccomp', d)} \
 "
 PACKAGECONFIG_class-nativesdk ??= "fdt sdl kvm"
Signature · 1 line
2.26.2.Cisco