public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH v1]  core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
@ 2025-10-01 16:02 Adam Nilsson
  2025-10-06 20:09 ` [OE-core] " Ross Burton
  0 siblings, 1 reply; 7+ messages in thread
From: Adam Nilsson @ 2025-10-01 16:02 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Nilsson, Peter Kjellerstedt, Adam Nilsson

From: Adam Nilsson <adamni@axis.com>

Add a zsh-completion-pkgs image feature to install *-zsh-completion
packages into an image. This is similar to the existing
bash-completion-pkgs feature.

Suggested-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Signed-off-by: Adam Nilsson <Adam.X.Nilsson@axis.com>
---
 meta/classes-recipe/core-image.bbclass        | 1 +
 meta/classes-recipe/populate_sdk_base.bbclass | 1 +
 2 files changed, 2 insertions(+)

diff --git a/meta/classes-recipe/core-image.bbclass b/meta/classes-recipe/core-image.bbclass
index 4072e420c5..309a7c577b 100644
--- a/meta/classes-recipe/core-image.bbclass
+++ b/meta/classes-recipe/core-image.bbclass
@@ -33,6 +33,7 @@
 #                         LICENSE_CREATE_PACKAGE="1" to be set when building packages too
 # - doc-pkgs            - documentation packages for all installed packages in the rootfs
 # - bash-completion-pkgs - bash-completion packages for recipes using bash-completion bbclass
+# - zsh-completion-pkgs - zsh-completion packages
 # - ptest-pkgs          - ptest packages for all ptest-enabled recipes
 # - read-only-rootfs    - tweaks an image to support read-only rootfs
 # - stateless-rootfs    - systemctl-native not run, image populated by systemd at runtime
diff --git a/meta/classes-recipe/populate_sdk_base.bbclass b/meta/classes-recipe/populate_sdk_base.bbclass
index 0c2fd26e6f..8e671cf28f 100644
--- a/meta/classes-recipe/populate_sdk_base.bbclass
+++ b/meta/classes-recipe/populate_sdk_base.bbclass
@@ -24,6 +24,7 @@ COMPLEMENTARY_GLOB[dbg-pkgs] = '*-dbg'
 COMPLEMENTARY_GLOB[src-pkgs] = '*-src'
 COMPLEMENTARY_GLOB[ptest-pkgs] = '*-ptest ${MLPREFIX}ptest-runner'
 COMPLEMENTARY_GLOB[bash-completion-pkgs] = '*-bash-completion'
+COMPLEMENTARY_GLOB[zsh-completion-pkgs] = '*-zsh-completion'

 def complementary_globs(featurevar, d):
     all_globs = d.getVarFlags('COMPLEMENTARY_GLOB')


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-01 16:02 [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature Adam Nilsson
@ 2025-10-06 20:09 ` Ross Burton
  2025-10-06 21:28   ` Khem Raj
  0 siblings, 1 reply; 7+ messages in thread
From: Ross Burton @ 2025-10-06 20:09 UTC (permalink / raw)
  To: Adam.X.Nilsson@axis.com
  Cc: openembedded-core@lists.openembedded.org, Adam Nilsson,
	Peter Kjellerstedt

On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
> 
> From: Adam Nilsson <adamni@axis.com>
> 
> Add a zsh-completion-pkgs image feature to install *-zsh-completion
> packages into an image. This is similar to the existing
> bash-completion-pkgs feature.

By my count there’s just three recipes in core that have -zsh-completion packages.  Until it’s more common, I’d suggest putting the COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use it.

Cheers,
Ross

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-06 20:09 ` [OE-core] " Ross Burton
@ 2025-10-06 21:28   ` Khem Raj
  2025-10-07 10:33     ` Ross Burton
  0 siblings, 1 reply; 7+ messages in thread
From: Khem Raj @ 2025-10-06 21:28 UTC (permalink / raw)
  To: ross.burton
  Cc: Adam.X.Nilsson@axis.com, openembedded-core@lists.openembedded.org,
	Adam Nilsson, Peter Kjellerstedt

On Mon, Oct 6, 2025 at 1:10 PM Ross Burton via lists.openembedded.org
<ross.burton=arm.com@lists.openembedded.org> wrote:
>
> On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
> >
> > From: Adam Nilsson <adamni@axis.com>
> >
> > Add a zsh-completion-pkgs image feature to install *-zsh-completion
> > packages into an image. This is similar to the existing
> > bash-completion-pkgs feature.
>
> By my count there’s just three recipes in core that have -zsh-completion packages.  Until it’s more common, I’d suggest putting the COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use it.

It does help people using zsh as default shell and working with yocto SDKs.

>
> Cheers,
> Ross
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#224503): https://lists.openembedded.org/g/openembedded-core/message/224503
> Mute This Topic: https://lists.openembedded.org/mt/115536491/1997914
> Group Owner: openembedded-core+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-06 21:28   ` Khem Raj
@ 2025-10-07 10:33     ` Ross Burton
  2025-10-07 11:48       ` Peter Kjellerstedt
  0 siblings, 1 reply; 7+ messages in thread
From: Ross Burton @ 2025-10-07 10:33 UTC (permalink / raw)
  To: Khem Raj
  Cc: Adam.X.Nilsson@axis.com, openembedded-core@lists.openembedded.org,
	Adam Nilsson, Peter Kjellerstedt

On 6 Oct 2025, at 22:28, Khem Raj <raj.khem@gmail.com> wrote:
> 
> On Mon, Oct 6, 2025 at 1:10 PM Ross Burton via lists.openembedded.org
> <ross.burton=arm.com@lists.openembedded.org> wrote:
>> 
>> On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
>>> 
>>> From: Adam Nilsson <adamni@axis.com>
>>> 
>>> Add a zsh-completion-pkgs image feature to install *-zsh-completion
>>> packages into an image. This is similar to the existing
>>> bash-completion-pkgs feature.
>> 
>> By my count there’s just three recipes in core that have -zsh-completion packages.  Until it’s more common, I’d suggest putting the COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use it.
> 
> It does help people using zsh as default shell and working with yocto SDKs.

Does it though?

$ git grep FILES.*zsh-completion
meta/recipes-core/systemd/systemd_257.8.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh/site-functions"
meta/recipes-devtools/patchelf/patchelf_0.18.0.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh"
meta/recipes-kernel/kmod/kmod_34.2.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh”

How many SDKs ship with nativesdk builds of systemd, patchelf, or kmod?

Ross

^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-07 10:33     ` Ross Burton
@ 2025-10-07 11:48       ` Peter Kjellerstedt
  2025-10-07 12:41         ` Richard Purdie
  0 siblings, 1 reply; 7+ messages in thread
From: Peter Kjellerstedt @ 2025-10-07 11:48 UTC (permalink / raw)
  To: Ross Burton, Khem Raj
  Cc: Adam X Nilsson, openembedded-core@lists.openembedded.org,
	Adam X Nilsson

> -----Original Message-----
> From: Ross Burton <Ross.Burton@arm.com>
> Sent: den 7 oktober 2025 12:34
> To: Khem Raj <raj.khem@gmail.com>
> Cc: Adam X Nilsson <Adam.X.Nilsson@axis.com>; openembedded-core@lists.openembedded.org; Adam X Nilsson <Adam.X.Nilsson@axis.com>; Peter Kjellerstedt <peter.kjellerstedt@axis.com>
> Subject: Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
> 
> On 6 Oct 2025, at 22:28, Khem Raj <raj.khem@gmail.com> wrote:
> >
> > On Mon, Oct 6, 2025 at 1:10 PM Ross Burton via lists.openembedded.org <ross.burton=arm.com@lists.openembedded.org> wrote:
> >>
> >> On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
> >>>
> >>> From: Adam Nilsson <adamni@axis.com>
> >>>
> >>> Add a zsh-completion-pkgs image feature to install *-zsh-completion
> >>> packages into an image. This is similar to the existing
> >>> bash-completion-pkgs feature.
> >>
> >> By my count there’s just three recipes in core that have -zsh-
> >> completion packages.  Until it’s more common, I’d suggest putting the
> >> COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use
> >> it.
> >
> > It does help people using zsh as default shell and working with yocto SDKs.
> 
> Does it though?
> 
> $ git grep FILES.*zsh-completion
> meta/recipes-core/systemd/systemd_257.8.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh/site-functions"
> meta/recipes-devtools/patchelf/patchelf_0.18.0.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh"
> meta/recipes-kernel/kmod/kmod_34.2.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh”
> 
> How many SDKs ship with nativesdk builds of systemd, patchelf, or kmod?
> 
> Ross

Please think outside OE-Core. Just because there are only three recipes 
in OE-Core that currently create zsh-completion packages, does not mean 
that it is not more common outside of OE-Core. Also, one recipe that 
could benefit from creating a zsh-completion package is bluez5, which 
currently has it disabled.

One of the main reasons I suggested Adam to send this patch upstream 
is for consistency. Since bash-completions-pkgs is a well established 
feature, I would expect the same possibility for others shells (which 
in our case happens to be zsh).

//Peter


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-07 11:48       ` Peter Kjellerstedt
@ 2025-10-07 12:41         ` Richard Purdie
  2025-10-08 20:00           ` Peter Kjellerstedt
  0 siblings, 1 reply; 7+ messages in thread
From: Richard Purdie @ 2025-10-07 12:41 UTC (permalink / raw)
  To: peter.kjellerstedt, Ross Burton, Khem Raj
  Cc: Adam X Nilsson, openembedded-core@lists.openembedded.org

On Tue, 2025-10-07 at 11:48 +0000, Peter Kjellerstedt via lists.openembedded.org wrote:
> > -----Original Message-----
> > From: Ross Burton <Ross.Burton@arm.com>
> > Sent: den 7 oktober 2025 12:34
> > To: Khem Raj <raj.khem@gmail.com>
> > Cc: Adam X Nilsson <Adam.X.Nilsson@axis.com>; openembedded-core@lists.openembedded.org; Adam X Nilsson <Adam.X.Nilsson@axis.com>; Peter Kjellerstedt <peter.kjellerstedt@axis.com>
> > Subject: Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
> > 
> > On 6 Oct 2025, at 22:28, Khem Raj <raj.khem@gmail.com> wrote:
> > > 
> > > On Mon, Oct 6, 2025 at 1:10 PM Ross Burton via lists.openembedded.org <ross.burton=arm.com@lists.openembedded.org> wrote:
> > > > 
> > > > On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
> > > > > 
> > > > > From: Adam Nilsson <adamni@axis.com>
> > > > > 
> > > > > Add a zsh-completion-pkgs image feature to install *-zsh-completion
> > > > > packages into an image. This is similar to the existing
> > > > > bash-completion-pkgs feature.
> > > > 
> > > > By my count there’s just three recipes in core that have -zsh-
> > > > completion packages.  Until it’s more common, I’d suggest putting the
> > > > COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use
> > > > it.
> > > 
> > > It does help people using zsh as default shell and working with yocto SDKs.
> > 
> > Does it though?
> > 
> > $ git grep FILES.*zsh-completion
> > meta/recipes-core/systemd/systemd_257.8.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh/site-functions"
> > meta/recipes-devtools/patchelf/patchelf_0.18.0.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh"
> > meta/recipes-kernel/kmod/kmod_34.2.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh”
> > 
> > How many SDKs ship with nativesdk builds of systemd, patchelf, or kmod?
> > 
> > Ross
> 
> Please think outside OE-Core. Just because there are only three recipes 
> in OE-Core that currently create zsh-completion packages, does not mean 
> that it is not more common outside of OE-Core. Also, one recipe that 
> could benefit from creating a zsh-completion package is bluez5, which
> currently has it disabled.
> 
> One of the main reasons I suggested Adam to send this patch upstream 
> is for consistency. Since bash-completions-pkgs is a well established
> feature, I would expect the same possibility for others shells (which
> in our case happens to be zsh).

I'm not sure we should have let the bash-completions one in. Now that
we have, we have the inevitable followups and this is why I worry a lot
about precedent when merging patches as people do use it against me
later.

One the one hand, it is a trivial patch. On the other, we have key
features like dev packages and dbg packages being mixed with much lower
priority things like shell completion. This makes it harder for new
users to find the important takeaways from the less important ones.

I really don't know what to do with the patch. I'm not particularly
keen on it and my first impression was no, equally, I'm burnt out and
really don't have the time/energy to write long emails arguing points
about it.

Cheers,

Richard




^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
  2025-10-07 12:41         ` Richard Purdie
@ 2025-10-08 20:00           ` Peter Kjellerstedt
  0 siblings, 0 replies; 7+ messages in thread
From: Peter Kjellerstedt @ 2025-10-08 20:00 UTC (permalink / raw)
  To: Richard Purdie, Ross Burton, Khem Raj
  Cc: Adam X Nilsson, openembedded-core@lists.openembedded.org

> -----Original Message-----
> From: Richard Purdie <richard.purdie@linuxfoundation.org>
> Sent: den 7 oktober 2025 14:42
> To: Peter Kjellerstedt <peter.kjellerstedt@axis.com>; Ross Burton <Ross.Burton@arm.com>; Khem Raj <raj.khem@gmail.com>
> Cc: Adam X Nilsson <Adam.X.Nilsson@axis.com>; openembedded-core@lists.openembedded.org
> Subject: Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
> 
> On Tue, 2025-10-07 at 11:48 +0000, Peter Kjellerstedt via lists.openembedded.org wrote:
> > > -----Original Message-----
> > > From: Ross Burton <Ross.Burton@arm.com>
> > > Sent: den 7 oktober 2025 12:34
> > > To: Khem Raj <raj.khem@gmail.com>
> > > Cc: Adam X Nilsson <Adam.X.Nilsson@axis.com>; openembedded-core@lists.openembedded.org; Adam X Nilsson <Adam.X.Nilsson@axis.com>; Peter Kjellerstedt <peter.kjellerstedt@axis.com>
> > > Subject: Re: [OE-core] [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature
> > >
> > > On 6 Oct 2025, at 22:28, Khem Raj <raj.khem@gmail.com> wrote:
> > > >
> > > > On Mon, Oct 6, 2025 at 1:10 PM Ross Burton via lists.openembedded.org <ross.burton=arm.com@lists.openembedded.org> wrote:
> > > > >
> > > > > On 1 Oct 2025, at 17:02, Adam Nilsson via lists.openembedded.org <Adam.X.Nilsson=axis.com@lists.openembedded.org> wrote:
> > > > > >
> > > > > > From: Adam Nilsson <adamni@axis.com>
> > > > > >
> > > > > > Add a zsh-completion-pkgs image feature to install *-zsh-completion
> > > > > > packages into an image. This is similar to the existing
> > > > > > bash-completion-pkgs feature.
> > > > >
> > > > > By my count there’s just three recipes in core that have -zsh-
> > > > > completion packages.  Until it’s more common, I’d suggest putting the
> > > > > COMPLEMENTARY_GLOBS assignment in your own image recipe if you want to use
> > > > > it.
> > > >
> > > > It does help people using zsh as default shell and working with yocto SDKs.
> > >
> > > Does it though?
> > >
> > > $ git grep FILES.*zsh-completion
> > > meta/recipes-core/systemd/systemd_257.8.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh/site-functions"
> > > meta/recipes-devtools/patchelf/patchelf_0.18.0.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh"
> > > meta/recipes-kernel/kmod/kmod_34.2.bb:FILES:${PN}-zsh-completion = "${datadir}/zsh”
> > >
> > > How many SDKs ship with nativesdk builds of systemd, patchelf, or kmod?
> > >
> > > Ross
> >
> > Please think outside OE-Core. Just because there are only three recipes
> > in OE-Core that currently create zsh-completion packages, does not mean
> > that it is not more common outside of OE-Core. Also, one recipe that
> > could benefit from creating a zsh-completion package is bluez5, which
> > currently has it disabled.
> >
> > One of the main reasons I suggested Adam to send this patch upstream
> > is for consistency. Since bash-completions-pkgs is a well established
> > feature, I would expect the same possibility for others shells (which
> > in our case happens to be zsh).
> 
> I'm not sure we should have let the bash-completions one in. Now that
> we have, we have the inevitable followups and this is why I worry a lot
> about precedent when merging patches as people do use it against me
> later.
> 
> One the one hand, it is a trivial patch. On the other, we have key
> features like dev packages and dbg packages being mixed with much lower
> priority things like shell completion. This makes it harder for new
> users to find the important takeaways from the less important ones.

To me, this sounds like a situation we should be able to improve by 
having better descriptions of the features in the core-image.bbclass. 
I have sent a patch series that I think does this. I do not know if 
it will sway your position about accepting the zsh-completion-pkgs 
feature, but it was worth a try. (The patch series is in four parts 
to separate the different changes I did, but it may be easier to 
just look at the resulting file after they are all applied.)

> 
> I really don't know what to do with the patch. I'm not particularly
> keen on it and my first impression was no, equally, I'm burnt out and
> really don't have the time/energy to write long emails arguing points
> about it.
> 
> Cheers,
> 
> Richard

//Peter


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-10-08 20:00 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-01 16:02 [PATCH v1] core-image, populate_sdk_base: Add zsh-completion-pkgs image feature Adam Nilsson
2025-10-06 20:09 ` [OE-core] " Ross Burton
2025-10-06 21:28   ` Khem Raj
2025-10-07 10:33     ` Ross Burton
2025-10-07 11:48       ` Peter Kjellerstedt
2025-10-07 12:41         ` Richard Purdie
2025-10-08 20:00           ` Peter Kjellerstedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox