* [PATCH] kernel: module: module-base: depend on elfutils-native
@ 2018-02-20 16:41 Justin Bronder
2018-02-20 17:06 ` Bruce Ashfield
2018-02-20 17:35 ` ✗ patchtest: failure for " Patchwork
0 siblings, 2 replies; 5+ messages in thread
From: Justin Bronder @ 2018-02-20 16:41 UTC (permalink / raw)
To: openembedded-core
libelf is required for CONFIG_STACK_VALIDATION which is required by
CONFIG_UNWINDER_ORC (the default in 4.14+).
We also need to update the module classes to pass HOSTCC and HOSTCPP
just like the kernel class already does. Otherwise the test for libelf
in the kernel Makefile fails.
---
meta/classes/kernel.bbclass | 2 +-
meta/classes/module-base.bbclass | 1 +
meta/classes/module.bbclass | 4 +++-
3 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 5cdff581ef..d3a7e1e1cb 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -4,7 +4,7 @@ KERNEL_PACKAGE_NAME ??= "kernel"
KERNEL_DEPLOYSUBDIR ??= "${@ "" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else d.getVar("KERNEL_PACKAGE_NAME") }"
PROVIDES += "${@ "virtual/kernel" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else "" }"
-DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native"
+DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native elfutils-native"
PACKAGE_WRITE_DEPS += "depmodwrapper-cross"
do_deploy[depends] += "depmodwrapper-cross:do_populate_sysroot"
diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
index f851b85163..3b56e04534 100644
--- a/meta/classes/module-base.bbclass
+++ b/meta/classes/module-base.bbclass
@@ -23,5 +23,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
do_make_scripts() {
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
make CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
+ HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}" \
-C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts
}
diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass
index 78d1b21dbd..89dee2dae8 100644
--- a/meta/classes/module.bbclass
+++ b/meta/classes/module.bbclass
@@ -1,10 +1,12 @@
inherit module-base kernel-module-split pkgconfig
+DEPENDS += "elfutils-native"
+
addtask make_scripts after do_prepare_recipe_sysroot before do_configure
do_make_scripts[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
do_make_scripts[depends] += "virtual/kernel:do_shared_workdir"
-EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR}"
+EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR} HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
MODULES_INSTALL_TARGET ?= "modules_install"
MODULES_MODULE_SYMVERS_LOCATION ?= ""
--
2.13.6
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] kernel: module: module-base: depend on elfutils-native
2018-02-20 16:41 [PATCH] kernel: module: module-base: depend on elfutils-native Justin Bronder
@ 2018-02-20 17:06 ` Bruce Ashfield
2018-02-20 20:45 ` Justin Bronder
2018-02-20 17:35 ` ✗ patchtest: failure for " Patchwork
1 sibling, 1 reply; 5+ messages in thread
From: Bruce Ashfield @ 2018-02-20 17:06 UTC (permalink / raw)
To: Justin Bronder; +Cc: Patches and discussions about the oe-core layer
On Tue, Feb 20, 2018 at 11:41 AM, Justin Bronder
<jsbronder@cold-front.org> wrote:
> libelf is required for CONFIG_STACK_VALIDATION which is required by
> CONFIG_UNWINDER_ORC (the default in 4.14+).
As you'll see in the discussion about adding bison-native, we don't want to add
these version specific dependencies globally.
>
> We also need to update the module classes to pass HOSTCC and HOSTCPP
This is already covered in my v3 "make-modules-script" changes.
Bruce
> just like the kernel class already does. Otherwise the test for libelf
> in the kernel Makefile fails.
> ---
> meta/classes/kernel.bbclass | 2 +-
> meta/classes/module-base.bbclass | 1 +
> meta/classes/module.bbclass | 4 +++-
> 3 files changed, 5 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
> index 5cdff581ef..d3a7e1e1cb 100644
> --- a/meta/classes/kernel.bbclass
> +++ b/meta/classes/kernel.bbclass
> @@ -4,7 +4,7 @@ KERNEL_PACKAGE_NAME ??= "kernel"
> KERNEL_DEPLOYSUBDIR ??= "${@ "" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else d.getVar("KERNEL_PACKAGE_NAME") }"
>
> PROVIDES += "${@ "virtual/kernel" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else "" }"
> -DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native"
> +DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native elfutils-native"
> PACKAGE_WRITE_DEPS += "depmodwrapper-cross"
>
> do_deploy[depends] += "depmodwrapper-cross:do_populate_sysroot"
> diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
> index f851b85163..3b56e04534 100644
> --- a/meta/classes/module-base.bbclass
> +++ b/meta/classes/module-base.bbclass
> @@ -23,5 +23,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> do_make_scripts() {
> unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
> make CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> + HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}" \
> -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts
> }
> diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass
> index 78d1b21dbd..89dee2dae8 100644
> --- a/meta/classes/module.bbclass
> +++ b/meta/classes/module.bbclass
> @@ -1,10 +1,12 @@
> inherit module-base kernel-module-split pkgconfig
>
> +DEPENDS += "elfutils-native"
> +
> addtask make_scripts after do_prepare_recipe_sysroot before do_configure
> do_make_scripts[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
> do_make_scripts[depends] += "virtual/kernel:do_shared_workdir"
>
> -EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR}"
> +EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR} HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
>
> MODULES_INSTALL_TARGET ?= "modules_install"
> MODULES_MODULE_SYMVERS_LOCATION ?= ""
> --
> 2.13.6
>
> --
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
--
"Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end"
^ permalink raw reply [flat|nested] 5+ messages in thread
* ✗ patchtest: failure for kernel: module: module-base: depend on elfutils-native
2018-02-20 16:41 [PATCH] kernel: module: module-base: depend on elfutils-native Justin Bronder
2018-02-20 17:06 ` Bruce Ashfield
@ 2018-02-20 17:35 ` Patchwork
1 sibling, 0 replies; 5+ messages in thread
From: Patchwork @ 2018-02-20 17:35 UTC (permalink / raw)
To: Justin Bronder; +Cc: openembedded-core
== Series Details ==
Series: kernel: module: module-base: depend on elfutils-native
Revision: 1
URL : https://patchwork.openembedded.org/series/11018/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:
* Patch kernel: module: module-base: depend on elfutils-native
Issue Patch is missing Signed-off-by [test_signed_off_by_presence]
Suggested fix Sign off the patch (either manually or with "git commit --amend -s")
If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).
---
Guidelines: https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: kernel: module: module-base: depend on elfutils-native
2018-02-20 17:06 ` Bruce Ashfield
@ 2018-02-20 20:45 ` Justin Bronder
2018-02-20 21:44 ` Bruce Ashfield
0 siblings, 1 reply; 5+ messages in thread
From: Justin Bronder @ 2018-02-20 20:45 UTC (permalink / raw)
To: Bruce Ashfield; +Cc: Patches and discussions about the oe-core layer
On 20/02/18 12:06 -0500, Bruce Ashfield wrote:
> On Tue, Feb 20, 2018 at 11:41 AM, Justin Bronder
> <jsbronder@cold-front.org> wrote:
> > libelf is required for CONFIG_STACK_VALIDATION which is required by
> > CONFIG_UNWINDER_ORC (the default in 4.14+).
>
> As you'll see in the discussion about adding bison-native, we don't want to add
> these version specific dependencies globally.
I was watching but didn't see a definitive conclusion in that thread yet.
Ignoring out of tree modules, I suppose it is pretty trivial to just add the
extra DEPENDS to the kernel recipe for a while until they're required by all
supported kernel versions. However, for out of tree modules, it's a bit more of
a burden to add it for every recipe. Is that the suggested way forward to deal
with this or is there a better method?
>
> >
> > We also need to update the module classes to pass HOSTCC and HOSTCPP
>
> This is already covered in my v3 "make-modules-script" changes.
That does cover the patch to module-base.bbclass, but it's missing the addition
to EXTRA_OEMAKE in module.bbclass which is still needed in order to be able to
find elfutils-native if I add it to the DEPENDS of the module.
>
> Bruce
>
> > just like the kernel class already does. Otherwise the test for libelf
> > in the kernel Makefile fails.
> > ---
> > meta/classes/kernel.bbclass | 2 +-
> > meta/classes/module-base.bbclass | 1 +
> > meta/classes/module.bbclass | 4 +++-
> > 3 files changed, 5 insertions(+), 2 deletions(-)
> >
> > diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
> > index 5cdff581ef..d3a7e1e1cb 100644
> > --- a/meta/classes/kernel.bbclass
> > +++ b/meta/classes/kernel.bbclass
> > @@ -4,7 +4,7 @@ KERNEL_PACKAGE_NAME ??= "kernel"
> > KERNEL_DEPLOYSUBDIR ??= "${@ "" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else d.getVar("KERNEL_PACKAGE_NAME") }"
> >
> > PROVIDES += "${@ "virtual/kernel" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else "" }"
> > -DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native"
> > +DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native elfutils-native"
> > PACKAGE_WRITE_DEPS += "depmodwrapper-cross"
> >
> > do_deploy[depends] += "depmodwrapper-cross:do_populate_sysroot"
> > diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
> > index f851b85163..3b56e04534 100644
> > --- a/meta/classes/module-base.bbclass
> > +++ b/meta/classes/module-base.bbclass
> > @@ -23,5 +23,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> > do_make_scripts() {
> > unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
> > make CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> > + HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}" \
> > -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts
> > }
> > diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass
> > index 78d1b21dbd..89dee2dae8 100644
> > --- a/meta/classes/module.bbclass
> > +++ b/meta/classes/module.bbclass
> > @@ -1,10 +1,12 @@
> > inherit module-base kernel-module-split pkgconfig
> >
> > +DEPENDS += "elfutils-native"
> > +
> > addtask make_scripts after do_prepare_recipe_sysroot before do_configure
> > do_make_scripts[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
> > do_make_scripts[depends] += "virtual/kernel:do_shared_workdir"
> >
> > -EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR}"
> > +EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR} HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
> >
> > MODULES_INSTALL_TARGET ?= "modules_install"
> > MODULES_MODULE_SYMVERS_LOCATION ?= ""
> > --
> > 2.13.6
> >
> > --
> > _______________________________________________
> > Openembedded-core mailing list
> > Openembedded-core@lists.openembedded.org
> > http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
>
>
> --
> "Thou shalt not follow the NULL pointer, for chaos and madness await
> thee at its end"
--
Justin Bronder
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: kernel: module: module-base: depend on elfutils-native
2018-02-20 20:45 ` Justin Bronder
@ 2018-02-20 21:44 ` Bruce Ashfield
0 siblings, 0 replies; 5+ messages in thread
From: Bruce Ashfield @ 2018-02-20 21:44 UTC (permalink / raw)
To: Justin Bronder; +Cc: Patches and discussions about the oe-core layer
On Tue, Feb 20, 2018 at 3:45 PM, Justin Bronder
<jsbronder@cold-front.org> wrote:
> On 20/02/18 12:06 -0500, Bruce Ashfield wrote:
>> On Tue, Feb 20, 2018 at 11:41 AM, Justin Bronder
>> <jsbronder@cold-front.org> wrote:
>> > libelf is required for CONFIG_STACK_VALIDATION which is required by
>> > CONFIG_UNWINDER_ORC (the default in 4.14+).
>>
>> As you'll see in the discussion about adding bison-native, we don't want to add
>> these version specific dependencies globally.
>
> I was watching but didn't see a definitive conclusion in that thread yet.
> Ignoring out of tree modules, I suppose it is pretty trivial to just add the
> extra DEPENDS to the kernel recipe for a while until they're required by all
> supported kernel versions. However, for out of tree modules, it's a bit more of
> a burden to add it for every recipe. Is that the suggested way forward to deal
> with this or is there a better method?
Adding it to the new make-mod-scripts recipe is the suggested way
forward, it may need to be version dependent .. which is why I haven't
added it yet, but instead have been carrying them in kernel recipes.
Since the mod-scripts depend on the kernel recipe, that should be pulling
in a version specific dependency.
>
>>
>> >
>> > We also need to update the module classes to pass HOSTCC and HOSTCPP
>>
>> This is already covered in my v3 "make-modules-script" changes.
>
> That does cover the patch to module-base.bbclass, but it's missing the addition
> to EXTRA_OEMAKE in module.bbclass which is still needed in order to be able to
> find elfutils-native if I add it to the DEPENDS of the module.
Once I get that first iteration in tree, my plan was to follow up with any
additional dependencies.
Bruce
>
>>
>> Bruce
>>
>> > just like the kernel class already does. Otherwise the test for libelf
>> > in the kernel Makefile fails.
>> > ---
>> > meta/classes/kernel.bbclass | 2 +-
>> > meta/classes/module-base.bbclass | 1 +
>> > meta/classes/module.bbclass | 4 +++-
>> > 3 files changed, 5 insertions(+), 2 deletions(-)
>> >
>> > diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
>> > index 5cdff581ef..d3a7e1e1cb 100644
>> > --- a/meta/classes/kernel.bbclass
>> > +++ b/meta/classes/kernel.bbclass
>> > @@ -4,7 +4,7 @@ KERNEL_PACKAGE_NAME ??= "kernel"
>> > KERNEL_DEPLOYSUBDIR ??= "${@ "" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else d.getVar("KERNEL_PACKAGE_NAME") }"
>> >
>> > PROVIDES += "${@ "virtual/kernel" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else "" }"
>> > -DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native"
>> > +DEPENDS += "virtual/${TARGET_PREFIX}binutils virtual/${TARGET_PREFIX}gcc kmod-native bc-native lzop-native elfutils-native"
>> > PACKAGE_WRITE_DEPS += "depmodwrapper-cross"
>> >
>> > do_deploy[depends] += "depmodwrapper-cross:do_populate_sysroot"
>> > diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
>> > index f851b85163..3b56e04534 100644
>> > --- a/meta/classes/module-base.bbclass
>> > +++ b/meta/classes/module-base.bbclass
>> > @@ -23,5 +23,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
>> > do_make_scripts() {
>> > unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
>> > make CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
>> > + HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}" \
>> > -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts
>> > }
>> > diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass
>> > index 78d1b21dbd..89dee2dae8 100644
>> > --- a/meta/classes/module.bbclass
>> > +++ b/meta/classes/module.bbclass
>> > @@ -1,10 +1,12 @@
>> > inherit module-base kernel-module-split pkgconfig
>> >
>> > +DEPENDS += "elfutils-native"
>> > +
>> > addtask make_scripts after do_prepare_recipe_sysroot before do_configure
>> > do_make_scripts[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
>> > do_make_scripts[depends] += "virtual/kernel:do_shared_workdir"
>> >
>> > -EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR}"
>> > +EXTRA_OEMAKE += "KERNEL_SRC=${STAGING_KERNEL_DIR} HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
>> >
>> > MODULES_INSTALL_TARGET ?= "modules_install"
>> > MODULES_MODULE_SYMVERS_LOCATION ?= ""
>> > --
>> > 2.13.6
>> >
>> > --
>> > _______________________________________________
>> > Openembedded-core mailing list
>> > Openembedded-core@lists.openembedded.org
>> > http://lists.openembedded.org/mailman/listinfo/openembedded-core
>>
>>
>>
>> --
>> "Thou shalt not follow the NULL pointer, for chaos and madness await
>> thee at its end"
>
> --
> Justin Bronder
--
"Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end"
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-02-20 21:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-20 16:41 [PATCH] kernel: module: module-base: depend on elfutils-native Justin Bronder
2018-02-20 17:06 ` Bruce Ashfield
2018-02-20 20:45 ` Justin Bronder
2018-02-20 21:44 ` Bruce Ashfield
2018-02-20 17:35 ` ✗ patchtest: failure for " Patchwork
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox