All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
@ 2025-11-06 11:47 Alexander Kanavin
  2025-11-06 12:11 ` [bitbake-devel] " Antonin Godard
  0 siblings, 1 reply; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-06 11:47 UTC (permalink / raw)
  To: bitbake-devel; +Cc: Alexander Kanavin

From: Alexander Kanavin <alex@linutronix.de>

{THISDIR} is a special value token that can be used in the list of enabled
layers to specify the layer location relative to the confguration file:
https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92

This replaces the token with an explicit separate keyword for such layers:
so that special processing to determine the final value can be avoided, and
the feature can be formalized in the json schema:

instead of
   "bb-layers": [
        "{THISDIR}/meta-my-project"
    ]

this allows
   "bb-layers-relative-to-this-file": [
        "meta-my-project"

Going forward I think we should strive to avoid any further special value tokens.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
 bin/bitbake-setup     | 28 ++++++++++++++++------------
 lib/bb/tests/setup.py | 20 ++++++++++----------
 2 files changed, 26 insertions(+), 22 deletions(-)

diff --git a/bin/bitbake-setup b/bin/bitbake-setup
index 47de4654e..7e227d82d 100755
--- a/bin/bitbake-setup
+++ b/bin/bitbake-setup
@@ -129,21 +129,24 @@ def checkout_layers(layers, layerdir, d):
     return layers_fixed_revisions
 
 def setup_bitbake_build(bitbake_config, layerdir, setupdir, thisdir):
-    def _setup_build_conf(layers, build_conf_dir):
+    def _setup_build_conf(layers, relative_layers, build_conf_dir):
         os.makedirs(build_conf_dir)
         layers_s = []
+
         for l in layers:
-            if l.startswith("{THISDIR}/"):
-                if thisdir:
-                    l = l.format(THISDIR=thisdir)
-                else:
-                    raise Exception("Configuration is using {THISDIR} to specify " \
-                    "a layer path relative to itself. This can be done only " \
-                    "when the configuration is specified by its path on local " \
-                    "disk, not when it's in a registry or is fetched over http.")
-            if not os.path.isabs(l):
-                l = os.path.join(layerdir, l)
+            l = os.path.join(layerdir, l)
+            layers_s.append("  {} \\".format(l))
+
+        for l in relative_layers:
+            if thisdir:
+                l = os.path.join(thisdir, l)
+            else:
+                raise Exception("Configuration is using {THISDIR} to specify " \
+                "a layer path relative to itself. This can be done only " \
+                "when the configuration is specified by its path on local " \
+                "disk, not when it's in a registry or is fetched over http.")
             layers_s.append("  {} \\".format(l))
+
         layers_s = "\n".join(layers_s)
         bblayers_conf = """BBLAYERS ?= " \\
 {}
@@ -220,7 +223,8 @@ def setup_bitbake_build(bitbake_config, layerdir, setupdir, thisdir):
         os.rename(bitbake_confdir, backup_bitbake_confdir)
 
     if layers:
-        _setup_build_conf(layers, bitbake_confdir)
+        relative_layers = bitbake_config.get("bb-layers-relative-to-this-file") or []
+        _setup_build_conf(layers, relative_layers, bitbake_confdir)
 
     if template:
         bb.process.run("{} setup -c {} -b {} --no-shell".format(oesetupbuild, template, bitbake_builddir))
diff --git a/lib/bb/tests/setup.py b/lib/bb/tests/setup.py
index 767a6298d..83b1794a3 100644
--- a/lib/bb/tests/setup.py
+++ b/lib/bb/tests/setup.py
@@ -148,9 +148,10 @@ print("BBPATH is {{}}".format(os.environ["BBPATH"]))
                 "oe-fragments": ["test-fragment-2"]
             },
             {
-                "name": "gizmo-notemplate-with-thisdir",
-                "description": "Gizmo notemplate configuration using THISDIR",
-                "bb-layers": ["layerC","layerD/meta-layer","{THISDIR}/layerE/meta-layer"],
+                "name": "gizmo-notemplate-with-relative-layers",
+                "description": "Gizmo notemplate configuration using relative layers",
+                "bb-layers": ["layerC","layerD/meta-layer"],
+                "bb-layers-relative-to-this-file": ["layerE/meta-layer"],
                 "oe-fragments": ["test-fragment-2"]
             }
         ]
@@ -204,14 +205,13 @@ print("BBPATH is {{}}".format(os.environ["BBPATH"]))
             with open(os.path.join(bb_conf_path, 'bblayers.conf')) as f:
                 bblayers = f.read()
                 for l in bitbake_config["bb-layers"]:
-                    if l.startswith('{THISDIR}/'):
-                        thisdir_layer = os.path.join(
+                    self.assertIn(os.path.join(setuppath, "layers", l), bblayers)
+                for l in bitbake_config.get("bb-layers-relative-to-this-file") or []:
+                    relative_layer = os.path.join(
                             os.path.dirname(config_upstream["path"]),
-                            l.removeprefix("{THISDIR}/"),
+                            l,
                         )
-                        self.assertIn(thisdir_layer, bblayers)
-                    else:
-                        self.assertIn(os.path.join(setuppath, "layers", l), bblayers)
+                    self.assertIn(relative_layer, bblayers)
 
         if 'oe-fragment' in bitbake_config.keys():
             for f in bitbake_config["oe-fragments"]:
@@ -298,7 +298,7 @@ print("BBPATH is {{}}".format(os.environ["BBPATH"]))
                                                                   'gizmo-env-passthrough',
                                                                   'gizmo-no-fragment',
                                                                   'gadget-notemplate','gizmo-notemplate',
-                                                                  'gizmo-notemplate-with-thisdir')}
+                                                                  'gizmo-notemplate-with-relative-layers')}
                                }
         for cf, v in test_configurations.items():
             for c in v['buildconfigs']:
-- 
2.39.5



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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 11:47 [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword Alexander Kanavin
@ 2025-11-06 12:11 ` Antonin Godard
  2025-11-06 12:28   ` Alexander Kanavin
  0 siblings, 1 reply; 14+ messages in thread
From: Antonin Godard @ 2025-11-06 12:11 UTC (permalink / raw)
  To: alex.kanavin, bitbake-devel; +Cc: Alexander Kanavin

Hi,

On Thu Nov 6, 2025 at 12:47 PM CET, Alexander Kanavin via lists.openembedded.org wrote:
> From: Alexander Kanavin <alex@linutronix.de>
>
> {THISDIR} is a special value token that can be used in the list of enabled
> layers to specify the layer location relative to the confguration file:
> https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92
>
> This replaces the token with an explicit separate keyword for such layers:
> so that special processing to determine the final value can be avoided, and
> the feature can be formalized in the json schema:
>
> instead of
>    "bb-layers": [
>         "{THISDIR}/meta-my-project"
>     ]
>
> this allows
>    "bb-layers-relative-to-this-file": [

Can I suggest naming it "bb-layers-local"? "bb-layers-relative-to-this-file"
feels bit overwhelming, I think with associated documentation users will be
able to figure what "local" stands for in this case.

I can't help but wonder: why is there a need to have a separate keyword? Can't
bitbake-setup do:

  for <layer> in bb-layers; do
    if <layer> is not in <sources>; then 
      if <layer> is found next to the .conf.json; then 
        use this local layer
      else
        error
      fi
    else
      use setup/layers/<layer>
    fi
  done

?

Antonin

-- 
Antonin Godard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com



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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 12:11 ` [bitbake-devel] " Antonin Godard
@ 2025-11-06 12:28   ` Alexander Kanavin
  2025-11-06 15:15     ` Richard Purdie
  0 siblings, 1 reply; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-06 12:28 UTC (permalink / raw)
  To: Antonin Godard; +Cc: bitbake-devel, Alexander Kanavin

[-- Attachment #1: Type: text/plain, Size: 1864 bytes --]

On Thu 6. Nov 2025 at 13.11, Antonin Godard <antonin.godard@bootlin.com>
wrote:

> Hi,
>
> On Thu Nov 6, 2025 at 12:47 PM CET, Alexander Kanavin via
> lists.openembedded.org wrote:
> > From: Alexander Kanavin <alex@linutronix.de>
> >
> > {THISDIR} is a special value token that can be used in the list of
> enabled
> > layers to specify the layer location relative to the confguration file:
> >
> https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92
> >
> > This replaces the token with an explicit separate keyword for such
> layers:
> > so that special processing to determine the final value can be avoided,
> and
> > the feature can be formalized in the json schema:
> >
> > instead of
> >    "bb-layers": [
> >         "{THISDIR}/meta-my-project"
> >     ]
> >
> > this allows
> >    "bb-layers-relative-to-this-file": [
>
> Can I suggest naming it "bb-layers-local"?
> "bb-layers-relative-to-this-file"
> feels bit overwhelming, I think with associated documentation users will be
> able to figure what "local" stands for in this case.



‘Local’ implies the path can be absolute, which is not supported, and it
doesn’t suggest what the path should be relative to. I’d rather make it
longer but clearer.



>
> I can't help but wonder: why is there a need to have a separate keyword?
> Can't
> bitbake-setup do:
>
>   for <layer> in bb-layers; do
>     if <layer> is not in <sources>; then
>       if <layer> is found next to the .conf.json; then
>         use this local layer
>       else
>         error
>       fi
>     else
>       use setup/layers/<layer>
>     fi
>   done
>
> ?



With hidden logic like this it’s not clear by reading the config what is
local and what isn’t. There’s also a possibility of paths clashing.

Alex

>

[-- Attachment #2: Type: text/html, Size: 3308 bytes --]

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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 12:28   ` Alexander Kanavin
@ 2025-11-06 15:15     ` Richard Purdie
  2025-11-06 15:26       ` Robert P. J. Day
  2025-11-07  0:59       ` Peter Kjellerstedt
  0 siblings, 2 replies; 14+ messages in thread
From: Richard Purdie @ 2025-11-06 15:15 UTC (permalink / raw)
  To: alex.kanavin, Antonin Godard; +Cc: bitbake-devel, Alexander Kanavin

On Thu, 2025-11-06 at 13:28 +0100, Alexander Kanavin via lists.openembedded.org wrote:
> On Thu 6. Nov 2025 at 13.11, Antonin Godard <antonin.godard@bootlin.com> wrote:
> > Hi,
> > 
> > On Thu Nov 6, 2025 at 12:47 PM CET, Alexander Kanavin via lists.openembedded.org wrote:
> > > From: Alexander Kanavin <alex@linutronix.de>
> > > 
> > > {THISDIR} is a special value token that can be used in the list of enabled
> > > layers to specify the layer location relative to the confguration file:
> > > https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92
> > > 
> > > This replaces the token with an explicit separate keyword for such layers:
> > > so that special processing to determine the final value can be avoided, and
> > > the feature can be formalized in the json schema:
> > > 
> > > instead of
> > >     "bb-layers": [
> > >          "{THISDIR}/meta-my-project"
> > >      ]
> > > 
> > > this allows
> > >     "bb-layers-relative-to-this-file": [
> > 
> > Can I suggest naming it "bb-layers-local"? "bb-layers-relative-to-this-file"
> > feels bit overwhelming, I think with associated documentation users will be
> > able to figure what "local" stands for in this case.
> > 
> 
> 
> 
> ‘Local’ implies the path can be absolute, which is not supported, and it doesn’t suggest what the path should be relative to. I’d rather make it longer but clearer.

bb-layers-relative maybe?

bb-layers-relative-to-this-file is precise but does feel a bit too
unwieldy. Any other options?

Cheers,

Richard


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 15:15     ` Richard Purdie
@ 2025-11-06 15:26       ` Robert P. J. Day
  2025-11-06 17:09         ` Alexander Kanavin
  2025-11-07  0:59       ` Peter Kjellerstedt
  1 sibling, 1 reply; 14+ messages in thread
From: Robert P. J. Day @ 2025-11-06 15:26 UTC (permalink / raw)
  To: richard.purdie
  Cc: alex.kanavin, Antonin Godard, bitbake-devel, Alexander Kanavin

[-- Attachment #1: Type: text/plain, Size: 1741 bytes --]

On Thu, 6 Nov 2025, Richard Purdie via lists.openembedded.org wrote:

> On Thu, 2025-11-06 at 13:28 +0100, Alexander Kanavin via lists.openembedded.org wrote:
> > On Thu 6. Nov 2025 at 13.11, Antonin Godard <antonin.godard@bootlin.com> wrote:
> > > Hi,
> > >
> > > On Thu Nov 6, 2025 at 12:47 PM CET, Alexander Kanavin via lists.openembedded.org wrote:
> > > > From: Alexander Kanavin <alex@linutronix.de>
> > > >
> > > > {THISDIR} is a special value token that can be used in the list of enabled
> > > > layers to specify the layer location relative to the confguration file:
> > > > https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92
> > > >
> > > > This replaces the token with an explicit separate keyword for such layers:
> > > > so that special processing to determine the final value can be avoided, and
> > > > the feature can be formalized in the json schema:
> > > >
> > > > instead of
> > > >     "bb-layers": [
> > > >          "{THISDIR}/meta-my-project"
> > > >      ]
> > > >
> > > > this allows
> > > >     "bb-layers-relative-to-this-file": [
> > >
> > > Can I suggest naming it "bb-layers-local"? "bb-layers-relative-to-this-file"
> > > feels bit overwhelming, I think with associated documentation users will be
> > > able to figure what "local" stands for in this case.
> > >
> >
> >
> >
> > ‘Local’ implies the path can be absolute, which is not supported, and it doesn’t suggest what the path should be relative to. I’d rather make it longer but clearer.
>
> bb-layers-relative maybe?
>
> bb-layers-relative-to-this-file is precise but does feel a bit too
> unwieldy. Any other options?

  the qualifier "-to-this-file" seems implied and thus superfluous.

rday

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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 15:26       ` Robert P. J. Day
@ 2025-11-06 17:09         ` Alexander Kanavin
  0 siblings, 0 replies; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-06 17:09 UTC (permalink / raw)
  To: rpjday; +Cc: richard.purdie, Antonin Godard, bitbake-devel, Alexander Kanavin

On Thu, 6 Nov 2025 at 16:23, Robert P. J. Day via
lists.openembedded.org <rpjday=crashcourse.ca@lists.openembedded.org>
wrote:

> > bb-layers-relative maybe?
> >
> > bb-layers-relative-to-this-file is precise but does feel a bit too
> > unwieldy. Any other options?
>
>   the qualifier "-to-this-file" seems implied and thus superfluous.

Alright. I sent a respin that uses 'bb-layers-relative'.

Alex


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

* RE: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-06 15:15     ` Richard Purdie
  2025-11-06 15:26       ` Robert P. J. Day
@ 2025-11-07  0:59       ` Peter Kjellerstedt
  2025-11-07  3:32         ` Alexander Kanavin
       [not found]         ` <18759C05E6F46C57.499307@lists.openembedded.org>
  1 sibling, 2 replies; 14+ messages in thread
From: Peter Kjellerstedt @ 2025-11-07  0:59 UTC (permalink / raw)
  To: richard.purdie@linuxfoundation.org, alex.kanavin@gmail.com,
	Antonin Godard
  Cc: bitbake-devel@lists.openembedded.org, Alexander Kanavin

> -----Original Message-----
> From: bitbake-devel@lists.openembedded.org <bitbake-devel@lists.openembedded.org> On Behalf Of Richard Purdie via lists.openembedded.org
> Sent: den 6 november 2025 16:16
> To: alex.kanavin@gmail.com; Antonin Godard <antonin.godard@bootlin.com>
> Cc: bitbake-devel@lists.openembedded.org; Alexander Kanavin <alex@linutronix.de>
> Subject: Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
> 
> On Thu, 2025-11-06 at 13:28 +0100, Alexander Kanavin via lists.openembedded.org wrote:
> > On Thu 6. Nov 2025 at 13.11, Antonin Godard <antonin.godard@bootlin.com> wrote:
> > > Hi,
> > >
> > > On Thu Nov 6, 2025 at 12:47 PM CET, Alexander Kanavin via lists.openembedded.org wrote:
> > > > From: Alexander Kanavin <alex@linutronix.de>
> > > >
> > > > {THISDIR} is a special value token that can be used in the list of enabled
> > > > layers to specify the layer location relative to the confguration file:
> > > > https://git.openembedded.org/bitbake/commit/?id=b3153be29de8b8570b0c184369bd41f4c646cf92
> > > >
> > > > This replaces the token with an explicit separate keyword for such layers:
> > > > so that special processing to determine the final value can be avoided, and
> > > > the feature can be formalized in the json schema:
> > > >
> > > > instead of
> > > >     "bb-layers": [
> > > >          "{THISDIR}/meta-my-project"
> > > >      ]
> > > >
> > > > this allows
> > > >     "bb-layers-relative-to-this-file": [
> > >
> > > Can I suggest naming it "bb-layers-local"? "bb-layers-relative-to-this-file"
> > > feels bit overwhelming, I think with associated documentation users will be
> > > able to figure what "local" stands for in this case.
> >
> > ‘Local’ implies the path can be absolute, which is not supported, and it
> > doesn’t suggest what the path should be relative to. I’d rather make it
> > longer but clearer.
> 
> bb-layers-relative maybe?
> 
> bb-layers-relative-to-this-file is precise but does feel a bit too
> unwieldy. Any other options?
> 
> Cheers,
> 
> Richard

After I saw Alex' patch for bitbake-setup.schema.json:
https://lore.kernel.org/openembedded-core/20251106170815.2439421-1-alex.kanavin@gmail.com/T/#u
it made me realize that I had not thought that paths in both 
bb-layers and bb-layers-relative are actually relative, just to 
different locations. Unfortunately, I think the newly suggested 
name is then misleading as it implies that paths in bb-layers 
are not relative. :( I now also understand why the longer 
bb-layers-relative-to-this-file was originally proposed.

I don't have a good solution for this. The best I can come up 
with is to rename them both to, e.g., bb-layers-dir-relative and 
bb-layers-file-relative.

//Peter


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07  0:59       ` Peter Kjellerstedt
@ 2025-11-07  3:32         ` Alexander Kanavin
  2025-11-07  9:55           ` Richard Purdie
       [not found]         ` <18759C05E6F46C57.499307@lists.openembedded.org>
  1 sibling, 1 reply; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-07  3:32 UTC (permalink / raw)
  To: Peter Kjellerstedt
  Cc: richard.purdie@linuxfoundation.org, Antonin Godard,
	bitbake-devel@lists.openembedded.org, Alexander Kanavin

[-- Attachment #1: Type: text/plain, Size: 1195 bytes --]

On Fri 7. Nov 2025 at 1.59, Peter Kjellerstedt <peter.kjellerstedt@axis.com>
wrote:

>
> >
> > bb-layers-relative maybe?
> >
> > bb-layers-relative-to-this-file is precise but does feel a bit too
> > unwieldy. Any other options?
> >
> > Cheers,
> >
> > Richard
>
> After I saw Alex' patch for bitbake-setup.schema.json:
>
> https://lore.kernel.org/openembedded-core/20251106170815.2439421-1-alex.kanavin@gmail.com/T/#u
> it made me realize that I had not thought that paths in both
> bb-layers and bb-layers-relative are actually relative, just to
> different locations. Unfortunately, I think the newly suggested
> name is then misleading as it implies that paths in bb-layers
> are not relative. :( I now also understand why the longer
> bb-layers-relative-to-this-file was originally proposed.
>
> I don't have a good solution for this. The best I can come up
> with is to rename them both to, e.g., bb-layers-dir-relative and
> bb-layers-file-relative


I tend to agree. I’d rather call them ‘bb-layers-in-sources’ and
‘bb-layers-in-this-dir’. Patch is coming even though I’m technically on
holiday since midnight. This is important.

Alex

>

[-- Attachment #2: Type: text/html, Size: 2069 bytes --]

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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
       [not found]         ` <18759C05E6F46C57.499307@lists.openembedded.org>
@ 2025-11-07  8:07           ` Alexander Kanavin
  0 siblings, 0 replies; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-07  8:07 UTC (permalink / raw)
  To: alex.kanavin
  Cc: Peter Kjellerstedt, richard.purdie@linuxfoundation.org,
	Antonin Godard, bitbake-devel@lists.openembedded.org,
	Alexander Kanavin

On Fri, 7 Nov 2025 at 04:32, Alexander Kanavin via
lists.openembedded.org <alex.kanavin=gmail.com@lists.openembedded.org>
wrote:
>> After I saw Alex' patch for bitbake-setup.schema.json:
>> https://lore.kernel.org/openembedded-core/20251106170815.2439421-1-alex.kanavin@gmail.com/T/#u
>> it made me realize that I had not thought that paths in both
>> bb-layers and bb-layers-relative are actually relative, just to
>> different locations. Unfortunately, I think the newly suggested
>> name is then misleading as it implies that paths in bb-layers
>> are not relative. :( I now also understand why the longer
>> bb-layers-relative-to-this-file was originally proposed.
>>
>> I don't have a good solution for this. The best I can come up
>> with is to rename them both to, e.g., bb-layers-dir-relative and
>> bb-layers-file-relative
>
>
> I tend to agree. I’d rather call them ‘bb-layers-in-sources’ and ‘bb-layers-in-this-dir’. Patch is coming even though I’m technically on holiday since midnight. This is important.

Patches sent:
https://lists.openembedded.org/g/bitbake-devel/message/18298
https://lists.openembedded.org/g/bitbake-devel/message/18297
https://lists.openembedded.org/g/openembedded-core/topic/patch/116167407

I also renamed the sources unpack dir from 'layers' to 'sources',
which is somewhat more invasive, but is a real improvement too. This
needed adjustments in yocto-autobuilder-helper as well, hopefully I
got most (or all!) of it right.
https://lists.yoctoproject.org/g/yocto-patches/topic/yocto_autobuilder_helper_patch/116167410

Alex


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07  3:32         ` Alexander Kanavin
@ 2025-11-07  9:55           ` Richard Purdie
  2025-11-07 10:14             ` Alexander Kanavin
  0 siblings, 1 reply; 14+ messages in thread
From: Richard Purdie @ 2025-11-07  9:55 UTC (permalink / raw)
  To: Alexander Kanavin, Peter Kjellerstedt
  Cc: Antonin Godard, bitbake-devel@lists.openembedded.org,
	Alexander Kanavin

On Fri, 2025-11-07 at 04:32 +0100, Alexander Kanavin wrote:
> On Fri 7. Nov 2025 at 1.59, Peter Kjellerstedt <peter.kjellerstedt@axis.com> wrote:
> > 
> > > 
> > > bb-layers-relative maybe?
> > > 
> > > bb-layers-relative-to-this-file is precise but does feel a bit too
> > > unwieldy. Any other options?
> > > 
> > > Cheers,
> > > 
> > > Richard
> > 
> > After I saw Alex' patch for bitbake-setup.schema.json:
> > https://lore.kernel.org/openembedded-core/20251106170815.2439421-1-alex.kanavin@gmail.com/T/#u
> > it made me realize that I had not thought that paths in both 
> > bb-layers and bb-layers-relative are actually relative, just to 
> > different locations. Unfortunately, I think the newly suggested 
> > name is then misleading as it implies that paths in bb-layers 
> > are not relative. :( I now also understand why the longer 
> > bb-layers-relative-to-this-file was originally proposed.
> > 
> > I don't have a good solution for this. The best I can come up 
> > with is to rename them both to, e.g., bb-layers-dir-relative and 
> > bb-layers-file-relative
> 
> I tend to agree. I’d rather call them ‘bb-layers-in-sources’ and ‘bb-
> layers-in-this-dir’. Patch is coming even though I’m technically on
> holiday since midnight. This is important.

I don't agree with "sources" in here.

I think if we call them:

bb-layers

and

bb-layers-file-relative

then this should be ok? I agree we need to get this right.

Cheers,

Richard



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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07  9:55           ` Richard Purdie
@ 2025-11-07 10:14             ` Alexander Kanavin
  2025-11-07 10:17               ` Richard Purdie
  0 siblings, 1 reply; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-07 10:14 UTC (permalink / raw)
  To: Richard Purdie
  Cc: Peter Kjellerstedt, Antonin Godard,
	bitbake-devel@lists.openembedded.org, Alexander Kanavin

On Fri, 7 Nov 2025 at 10:55, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:
> > I tend to agree. I’d rather call them ‘bb-layers-in-sources’ and ‘bb-
> > layers-in-this-dir’. Patch is coming even though I’m technically on
> > holiday since midnight. This is important.
>
> I don't agree with "sources" in here.
>
> I think if we call them:
>
> bb-layers
>
> and
>
> bb-layers-file-relative
>
> then this should be ok? I agree we need to get this right.

That's not too bad, I'm ok with it. Sadly I'm running out out of time,
as travel is happening today, so this last tweak is on someone else
than me :-/

Alex


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07 10:14             ` Alexander Kanavin
@ 2025-11-07 10:17               ` Richard Purdie
  2025-11-07 10:20                 ` Alexander Kanavin
  0 siblings, 1 reply; 14+ messages in thread
From: Richard Purdie @ 2025-11-07 10:17 UTC (permalink / raw)
  To: alex.kanavin
  Cc: Peter Kjellerstedt, Antonin Godard,
	bitbake-devel@lists.openembedded.org, Alexander Kanavin

On Fri, 2025-11-07 at 11:14 +0100, Alexander Kanavin via lists.openembedded.org wrote:
> On Fri, 7 Nov 2025 at 10:55, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > > I tend to agree. I’d rather call them ‘bb-layers-in-sources’ and ‘bb-
> > > layers-in-this-dir’. Patch is coming even though I’m technically on
> > > holiday since midnight. This is important.
> > 
> > I don't agree with "sources" in here.
> > 
> > I think if we call them:
> > 
> > bb-layers
> > 
> > and
> > 
> > bb-layers-file-relative
> > 
> > then this should be ok? I agree we need to get this right.
> 
> That's not too bad, I'm ok with it. Sadly I'm running out out of time,
> as travel is happening today, so this last tweak is on someone else
> than me :-/

No problem, I can make this one based on one of your patches.

Cheers,

Richard


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07 10:17               ` Richard Purdie
@ 2025-11-07 10:20                 ` Alexander Kanavin
  2025-11-07 13:18                   ` Richard Purdie
  0 siblings, 1 reply; 14+ messages in thread
From: Alexander Kanavin @ 2025-11-07 10:20 UTC (permalink / raw)
  To: Richard Purdie
  Cc: Peter Kjellerstedt, Antonin Godard,
	bitbake-devel@lists.openembedded.org, Alexander Kanavin

On Fri, 7 Nov 2025 at 11:17, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:

> No problem, I can make this one based on one of your patches.

Thanks! Don't forget the json schema too (I sent patches for it, so
can be reused too :)

I'm packing a suitcase right this moment, but I will keep an eye on
emails over the next days.

Alex


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

* Re: [bitbake-devel] [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword
  2025-11-07 10:20                 ` Alexander Kanavin
@ 2025-11-07 13:18                   ` Richard Purdie
  0 siblings, 0 replies; 14+ messages in thread
From: Richard Purdie @ 2025-11-07 13:18 UTC (permalink / raw)
  To: Alexander Kanavin
  Cc: Peter Kjellerstedt, Antonin Godard,
	bitbake-devel@lists.openembedded.org, Alexander Kanavin

On Fri, 2025-11-07 at 11:20 +0100, Alexander Kanavin wrote:
> On Fri, 7 Nov 2025 at 11:17, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> 
> > No problem, I can make this one based on one of your patches.
> 
> Thanks! Don't forget the json schema too (I sent patches for it, so
> can be reused too :)

I sorted the scheme too, yes. Thanks for the reminder.

Cheers,

Richard


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

end of thread, other threads:[~2025-11-07 13:19 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-06 11:47 [PATCH] bitbake-setup: replace {THISDIR} token with an explicit keyword Alexander Kanavin
2025-11-06 12:11 ` [bitbake-devel] " Antonin Godard
2025-11-06 12:28   ` Alexander Kanavin
2025-11-06 15:15     ` Richard Purdie
2025-11-06 15:26       ` Robert P. J. Day
2025-11-06 17:09         ` Alexander Kanavin
2025-11-07  0:59       ` Peter Kjellerstedt
2025-11-07  3:32         ` Alexander Kanavin
2025-11-07  9:55           ` Richard Purdie
2025-11-07 10:14             ` Alexander Kanavin
2025-11-07 10:17               ` Richard Purdie
2025-11-07 10:20                 ` Alexander Kanavin
2025-11-07 13:18                   ` Richard Purdie
     [not found]         ` <18759C05E6F46C57.499307@lists.openembedded.org>
2025-11-07  8:07           ` Alexander Kanavin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.