public inbox for poky@lists.yoctoproject.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Alexander Kanavin <alex.kanavin@gmail.com>
Cc: poky@lists.yoctoproject.org, Alexander Kanavin <alex@linutronix.de>
Subject: Re: [poky] [PATCH 2/4] conf/fragments: add fragments for qemux86-64 and qemuarm64
Date: Wed, 04 Jun 2025 10:47:37 +0100	[thread overview]
Message-ID: <9a662df92ce0918c77ec8a66bc39a2191cd942d6.camel@linuxfoundation.org> (raw)
In-Reply-To: <CANNYZj-jTjD281=McMDzQtABizNqZ5csbbE9aiJZLRA2U6BX5g@mail.gmail.com>

On Wed, 2025-06-04 at 11:05 +0200, Alexander Kanavin wrote:
> On Wed, 4 Jun 2025 at 10:48, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > > I think bitbake-config-build should be extended to have
> > > 'list-machines/set-machine/list-distros/set-distro', and then
> > > bitbake-setup would call out to that, like it already does for
> > > fragments. There's already 'show-machines' in bitbake-layers, which
> > > should be renamed and moved, so that bitbake-layers is less
> > > over-stuffed with sub-commands.
> > 
> > Maybe. I do like the idea of being able to express a configuration with
> > just a list of fragments so a magic mapping of machine/XXX and
> > distro/XXX does still have some appeal. We could code something:
> > 
> > BBCONFIG_FRAGMENT_VARIABLE_MAPS = "machine/:MACHINE and distro/:DISTRO"
> > 
> > to make the code generic?
> 
> My idea was to do away with fragments for machine/distro, and have
> 'bitbake-config-build set-machine XXX' write 'MACHINE = 'XXX' into
> conf/auto.conf.

Let me just throw some ideas around here. I'm not saying any are
right/wrong, this is in the spirit of sharing ideas.

Moving the "machine" commands into one standard place would make sense
so I do like that aspect of what you're suggesting.

I have some caution about teaching "bitbake" commands machine/distro
specific as it breaks layers of separation. Note that bitbake-layers
list-machines is part of OE-Core, not bitbake.

I also have an idea in the back of my mind that being able to reproduce
common setups with a list of fragments would be a nice idea. If you
have to say:

set-machine XXX
set-distro YYY
set-features A B C

it isn't a very succinct explanation to people. If you can say:

set-features A B C machine/XXX distro/YYY

then it becomes a bit of a nicer thing for someone else to copy. This
is all generic in that someone else can add their own fragments. The
autobuilder can also then simplify configs too. Someone could add an
extra variable mapping for an extra level of config, say
toolchain/clang to set TOOLCHAIN = "clang", not that I'm suggesting
that specifically but you get the idea.

> And then bitbake-setup config files would have a particular syntax for
> that, e.g. replace the current:
> 
>             "qemux86-64-poky": {
>                 "description": "Poky reference distro build for qemux86-64",
>                 "oe-template": "poky-blank",
>                 "oe-fragments":
> ["core/machines/qemux86-64","yocto/distros/poky","core/yocto/sstate-mirror-cdn","core/qemu/enable-native-sdl"],
>                 "targets": ["bitbake core-image-minimal
> core-image-full-cmdline core-image-sato-sdk core-image-weston"]
>             },
> 
> with
> 
>           "qemux86-64-poky": {
>                 "description": "Poky reference distro build for qemux86-64",
>                 "oe-template": "poky-blank",
>                 "oe-distro": "poky",
>                 "oe-machine": "qemux86-64",
>                 "oe-fragments":
> ["core/yocto/sstate-mirror-cdn","core/qemu/enable-native-sdl"],
>                 "targets": ["bitbake core-image-minimal
> core-image-full-cmdline core-image-sato-sdk core-image-weston"]
>             },
> 
> I don't have a strong opinion either way, perhaps it's best to 'upload
> discussion data in brain and process', while fixing further do_unpack
> rework fails :) If you can respond with further points I'd appreciate
> that! (so I better see the forest)

playing devils advocate:

          "qemux86-64-poky": {
                "description": "Poky reference distro build for qemux86-64",
                "oe-template": "poky-blank",
                "oe-fragments": ["core/yocto/sstate-mirror-cdn","core/qemu/enable-native-sdl", "machine/qemux86-64 distro/poky],
                "targets": ["bitbake core-image-minimal core-image-full-cmdline core-image-sato-sdk core-image-weston"]
            },

Cheers,

Richard



  reply	other threads:[~2025-06-04  9:47 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-03 11:35 [PATCH 1/4] meta/conf/templates: add a blank template Alexander Kanavin
2025-06-03 11:35 ` [PATCH 2/4] conf/fragments: add fragments for qemux86-64 and qemuarm64 Alexander Kanavin
2025-06-03 19:48   ` [poky] " Richard Purdie
2025-06-04  7:46     ` Alexander Kanavin
2025-06-04  8:48       ` Richard Purdie
2025-06-04  9:05         ` Alexander Kanavin
2025-06-04  9:47           ` Richard Purdie [this message]
2025-06-03 11:35 ` [PATCH 3/4] conf/fragments: add a fragment for CDN sstate mirror Alexander Kanavin
2025-06-03 11:35 ` [PATCH 4/4] fragments/qemu: add support for enabling sdl in qemu Alexander Kanavin
2025-06-03 19:44   ` [poky] " Richard Purdie
2025-06-04  7:40     ` Alexander Kanavin
2025-06-04  7:43       ` Richard Purdie
2025-06-03 11:39 ` [PATCH 1/4] meta/conf/templates: add a blank template Alexander Kanavin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9a662df92ce0918c77ec8a66bc39a2191cd942d6.camel@linuxfoundation.org \
    --to=richard.purdie@linuxfoundation.org \
    --cc=alex.kanavin@gmail.com \
    --cc=alex@linutronix.de \
    --cc=poky@lists.yoctoproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox