diff mbox series

[02/19] useradd.bbclass: list all needed items for package_setscene task

Message ID 20231127101751.3187950-2-alex@linutronix.de
State New
Headers show
Series [01/19] sstate.bbclass: setscene_depvalid(): do not exclude shadow-native from task dependency resolution | expand

Commit Message

Alexander Kanavin Nov. 27, 2023, 10:17 a.m. UTC
Latest shadow-native links with additional libraries;
I was unable to find a way to resolve those in setscene context
where tasks do not contain such dependencies.

Signed-off-by: Alexander Kanavin <alex@linutronix.de>
---
 meta/classes/useradd.bbclass | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

Comments

Richard Purdie Nov. 27, 2023, 10:59 a.m. UTC | #1
On Mon, 2023-11-27 at 11:17 +0100, Alexander Kanavin wrote:
> Latest shadow-native links with additional libraries;
> I was unable to find a way to resolve those in setscene context
> where tasks do not contain such dependencies.
> 
> Signed-off-by: Alexander Kanavin <alex@linutronix.de>
> ---
>  meta/classes/useradd.bbclass | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass
> index 4d3bd9a5f56..a35785c9c23 100644
> --- a/meta/classes/useradd.bbclass
> +++ b/meta/classes/useradd.bbclass
> @@ -179,7 +179,13 @@ SSTATEPREINSTFUNCS:append:class-target = " useradd_sysroot_sstate"
>  
>  do_package_setscene[depends] += "${USERADDSETSCENEDEPS}"
>  do_populate_sysroot_setscene[depends] += "${USERADDSETSCENEDEPS}"
> -USERADDSETSCENEDEPS:class-target = "${MLPREFIX}base-passwd:do_populate_sysroot_setscene pseudo-native:do_populate_sysroot_setscene shadow-native:do_populate_sysroot_setscene ${MLPREFIX}shadow-sysroot:do_populate_sysroot_setscene"
> +USERADDSETSCENEDEPS:class-target = "${MLPREFIX}base-passwd:do_populate_sysroot_setscene \
> +                                    pseudo-native:do_populate_sysroot_setscene \
> +                                    shadow-native:do_populate_sysroot_setscene \
> +                                    attr-native:do_populate_sysroot_setscene \
> +                                    libbsd-native:do_populate_sysroot_setscene \
> +                                    libmd-native:do_populate_sysroot_setscene \
> +                                    ${MLPREFIX}shadow-sysroot:do_populate_sysroot_setscene"
>  USERADDSETSCENEDEPS = ""
>  
>  # Recipe parse-time sanity checks


FWIW I'm still leaning towards static linking for this. The setscence
dependencies are playing with fire and we *really* don't want to do
this :(

Cheers,

Richard
Alexander Kanavin Nov. 27, 2023, 11:06 a.m. UTC | #2
On Mon, 27 Nov 2023 at 11:59, Richard Purdie
<richard.purdie@linuxfoundation.org> wrote:

> FWIW I'm still leaning towards static linking for this. The setscence
> dependencies are playing with fire and we *really* don't want to do
> this :(

Was there some half-done branch with that approach? I could pick that
up once I get somewhere with the failing printdiff selftest.

Alex
Richard Purdie Nov. 27, 2023, 4:44 p.m. UTC | #3
On Mon, 2023-11-27 at 12:06 +0100, Alexander Kanavin wrote:
> On Mon, 27 Nov 2023 at 11:59, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> 
> > FWIW I'm still leaning towards static linking for this. The setscence
> > dependencies are playing with fire and we *really* don't want to do
> > this :(
> 
> Was there some half-done branch with that approach? I could pick that
> up once I get somewhere with the failing printdiff selftest.

https://git.yoctoproject.org/poky-contrib/commit/?h=rpurdie/t222&id=a3ad82f026adbe9c58f6927a4b97d2eb09c08439

(I'd just take the patch, not the branch)

Cheers,

Richard
diff mbox series

Patch

diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass
index 4d3bd9a5f56..a35785c9c23 100644
--- a/meta/classes/useradd.bbclass
+++ b/meta/classes/useradd.bbclass
@@ -179,7 +179,13 @@  SSTATEPREINSTFUNCS:append:class-target = " useradd_sysroot_sstate"
 
 do_package_setscene[depends] += "${USERADDSETSCENEDEPS}"
 do_populate_sysroot_setscene[depends] += "${USERADDSETSCENEDEPS}"
-USERADDSETSCENEDEPS:class-target = "${MLPREFIX}base-passwd:do_populate_sysroot_setscene pseudo-native:do_populate_sysroot_setscene shadow-native:do_populate_sysroot_setscene ${MLPREFIX}shadow-sysroot:do_populate_sysroot_setscene"
+USERADDSETSCENEDEPS:class-target = "${MLPREFIX}base-passwd:do_populate_sysroot_setscene \
+                                    pseudo-native:do_populate_sysroot_setscene \
+                                    shadow-native:do_populate_sysroot_setscene \
+                                    attr-native:do_populate_sysroot_setscene \
+                                    libbsd-native:do_populate_sysroot_setscene \
+                                    libmd-native:do_populate_sysroot_setscene \
+                                    ${MLPREFIX}shadow-sysroot:do_populate_sysroot_setscene"
 USERADDSETSCENEDEPS = ""
 
 # Recipe parse-time sanity checks