* [OE-core][Patch v1] devicetree.bbclass: fix setting S
@ 2024-06-25 18:30 max.oss.09
2024-07-02 13:05 ` Max Krummenacher
2024-07-02 14:08 ` Richard Purdie
0 siblings, 2 replies; 3+ messages in thread
From: max.oss.09 @ 2024-06-25 18:30 UTC (permalink / raw)
To: openembedded-core; +Cc: Andrey Zhizhikin, Max Krummenacher
From: Max Krummenacher <max.krummenacher@toradex.com>
When a user of devicetree.bbclass overrides setting S, e.g. to
git/overlays then having UNPACKDIR set to S results in that
git repo unpacked inside UNPACKDIR. Thus the sources are actually
in git/overlays/git/overlays rather than the expected git/overlays.
Change the logic, so that S by default is set to UNPACKDIR,
but a user can change S to point to were the sources actually
will be.
Fixes: 7a06069a041a ("devicetree.bbclass: switch away from S = WORKDIR")
Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
---
meta/classes-recipe/devicetree.bbclass | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/meta/classes-recipe/devicetree.bbclass b/meta/classes-recipe/devicetree.bbclass
index 1806cb62cbf7..e5dbd9a85714 100644
--- a/meta/classes-recipe/devicetree.bbclass
+++ b/meta/classes-recipe/devicetree.bbclass
@@ -40,8 +40,8 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
SYSROOT_DIRS += "/boot/devicetree"
FILES:${PN} = "/boot/devicetree/*.dtb /boot/devicetree/*.dtbo"
-S = "${WORKDIR}/sources"
-UNPACKDIR = "${S}"
+UNPACKDIR = "${WORKDIR}/sources"
+S = "${UNPACKDIR}"
B = "${WORKDIR}/build"
# Default kernel includes, these represent what are normally used for in-kernel
--
2.42.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [OE-core][Patch v1] devicetree.bbclass: fix setting S
2024-06-25 18:30 [OE-core][Patch v1] devicetree.bbclass: fix setting S max.oss.09
@ 2024-07-02 13:05 ` Max Krummenacher
2024-07-02 14:08 ` Richard Purdie
1 sibling, 0 replies; 3+ messages in thread
From: Max Krummenacher @ 2024-07-02 13:05 UTC (permalink / raw)
To: openembedded-core; +Cc: Andrey Zhizhikin, Max Krummenacher
Hello
On Tue, Jun 25, 2024 at 08:30:46PM +0200, max.oss.09@gmail.com wrote:
> From: Max Krummenacher <max.krummenacher@toradex.com>
>
> When a user of devicetree.bbclass overrides setting S, e.g. to
> git/overlays then having UNPACKDIR set to S results in that
> git repo unpacked inside UNPACKDIR. Thus the sources are actually
> in git/overlays/git/overlays rather than the expected git/overlays.
>
> Change the logic, so that S by default is set to UNPACKDIR,
> but a user can change S to point to were the sources actually
> will be.
>
> Fixes: 7a06069a041a ("devicetree.bbclass: switch away from S = WORKDIR")
Gentle ping.
Any comments on this commit?
For me the referenced commit causes a regression. If I understand it
correctly it will do so for any user which uses the devicetree.bbclass
and did set S to anything other than WORKDIR.
I think this should be fixed here rather than any recipe which sets S
also setting UNPACKDIR.
Thanks.
Max
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
> meta/classes-recipe/devicetree.bbclass | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes-recipe/devicetree.bbclass b/meta/classes-recipe/devicetree.bbclass
> index 1806cb62cbf7..e5dbd9a85714 100644
> --- a/meta/classes-recipe/devicetree.bbclass
> +++ b/meta/classes-recipe/devicetree.bbclass
> @@ -40,8 +40,8 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> SYSROOT_DIRS += "/boot/devicetree"
> FILES:${PN} = "/boot/devicetree/*.dtb /boot/devicetree/*.dtbo"
>
> -S = "${WORKDIR}/sources"
> -UNPACKDIR = "${S}"
> +UNPACKDIR = "${WORKDIR}/sources"
> +S = "${UNPACKDIR}"
> B = "${WORKDIR}/build"
>
> # Default kernel includes, these represent what are normally used for in-kernel
> --
> 2.42.0
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [OE-core][Patch v1] devicetree.bbclass: fix setting S
2024-06-25 18:30 [OE-core][Patch v1] devicetree.bbclass: fix setting S max.oss.09
2024-07-02 13:05 ` Max Krummenacher
@ 2024-07-02 14:08 ` Richard Purdie
1 sibling, 0 replies; 3+ messages in thread
From: Richard Purdie @ 2024-07-02 14:08 UTC (permalink / raw)
To: max.oss.09, openembedded-core; +Cc: Andrey Zhizhikin, Max Krummenacher
On Tue, 2024-06-25 at 20:30 +0200, Max Krummenacher via
lists.openembedded.org wrote:
> From: Max Krummenacher <max.krummenacher@toradex.com>
>
> When a user of devicetree.bbclass overrides setting S, e.g. to
> git/overlays then having UNPACKDIR set to S results in that
> git repo unpacked inside UNPACKDIR. Thus the sources are actually
> in git/overlays/git/overlays rather than the expected git/overlays.
>
> Change the logic, so that S by default is set to UNPACKDIR,
> but a user can change S to point to were the sources actually
> will be.
>
> Fixes: 7a06069a041a ("devicetree.bbclass: switch away from S =
> WORKDIR")
> Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
> ---
> meta/classes-recipe/devicetree.bbclass | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes-recipe/devicetree.bbclass b/meta/classes-
> recipe/devicetree.bbclass
> index 1806cb62cbf7..e5dbd9a85714 100644
> --- a/meta/classes-recipe/devicetree.bbclass
> +++ b/meta/classes-recipe/devicetree.bbclass
> @@ -40,8 +40,8 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> SYSROOT_DIRS += "/boot/devicetree"
> FILES:${PN} = "/boot/devicetree/*.dtb /boot/devicetree/*.dtbo"
>
> -S = "${WORKDIR}/sources"
> -UNPACKDIR = "${S}"
> +UNPACKDIR = "${WORKDIR}/sources"
> +S = "${UNPACKDIR}"
> B = "${WORKDIR}/build"
>
> # Default kernel includes, these represent what are normally used
> for in-kernel
This doesn't seem to be the right thing to do to me. These settings are
really closely related to SRC_URI so I think they probably shouldn't be
in the class at all but in the recipes alongside SRC_URI?
Cheers,
Richard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-07-02 14:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-25 18:30 [OE-core][Patch v1] devicetree.bbclass: fix setting S max.oss.09
2024-07-02 13:05 ` Max Krummenacher
2024-07-02 14:08 ` Richard Purdie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox