All of lore.kernel.org
 help / color / mirror / Atom feed
* [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE
@ 2018-08-16  1:22 Denys Dmytriyenko
  2018-08-16  2:27 ` akuster808
  0 siblings, 1 reply; 4+ messages in thread
From: Denys Dmytriyenko @ 2018-08-16  1:22 UTC (permalink / raw)
  To: openembedded-core; +Cc: Bruce Ashfield, Denys Dmytriyenko

From: Denys Dmytriyenko <denys@ti.com>

Commit d2aa88a6a92985f21414fceea2dc0facbf7f8779 was meant to backport build
dependencies on bc-native and openssl-native, but it also changed execution
of do_make_scripts() from calling make directly to using oe_runmake. That
change was made in master/sumo as part of a separate make-mod-scripts recipe.

Unfortunately, that doesn't work here in rocko in the context of module-base
class, as it gets executed inside out-of-tree module environment. Quite often
those out-of-tree modules provide own Makefile with custom EXTRA_OEMAKE var
defined. But do_make_scripts() gets executed within STAGING_KERNEL_DIR and
cannot simply use custom EXTRA_OEMAKE set by a module.

Move back to calling make and passing HOSTCC/HOSTCPP directly w/o using
EXTRA_OEMAKE.

For more details please see:
http://lists.openembedded.org/pipermail/openembedded-core/2018-August/154189.html

Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Cc: Bruce Ashfield <bruce.ashfield@windriver.com>
Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: Anuj Mittal <anuj.mittal@intel.com>
Cc: Armin Kuster <akuster808@gmail.com>
---
 meta/classes/module-base.bbclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
index 9f3465e..c1fa3ad 100644
--- a/meta/classes/module-base.bbclass
+++ b/meta/classes/module-base.bbclass
@@ -13,7 +13,6 @@ export CROSS_COMPILE = "${TARGET_PREFIX}"
 export KBUILD_OUTPUT = "${STAGING_KERNEL_BUILDDIR}"
 
 DEPENDS += "bc-native"
-EXTRA_OEMAKE += " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
 
 export KERNEL_VERSION = "${@base_read_file('${STAGING_KERNEL_BUILDDIR}/kernel-abiversion')}"
 KERNEL_OBJECT_SUFFIX = ".ko"
@@ -25,6 +24,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
 # be called before do_compile. See module.bbclass for an example.
 do_make_scripts() {
 	unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS 
-	oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
+	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 prepare
 }
-- 
2.7.4



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

* Re: [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE
  2018-08-16  1:22 [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE Denys Dmytriyenko
@ 2018-08-16  2:27 ` akuster808
  2018-08-24  1:15   ` Denys Dmytriyenko
  0 siblings, 1 reply; 4+ messages in thread
From: akuster808 @ 2018-08-16  2:27 UTC (permalink / raw)
  To: Denys Dmytriyenko, openembedded-core; +Cc: Bruce Ashfield, Denys Dmytriyenko



On 08/15/2018 06:22 PM, Denys Dmytriyenko wrote:
> From: Denys Dmytriyenko <denys@ti.com>
>
> Commit d2aa88a6a92985f21414fceea2dc0facbf7f8779 was meant to backport build
> dependencies on bc-native and openssl-native, but it also changed execution
> of do_make_scripts() from calling make directly to using oe_runmake. That
> change was made in master/sumo as part of a separate make-mod-scripts recipe.
>
> Unfortunately, that doesn't work here in rocko in the context of module-base
> class, as it gets executed inside out-of-tree module environment. Quite often
> those out-of-tree modules provide own Makefile with custom EXTRA_OEMAKE var
> defined. But do_make_scripts() gets executed within STAGING_KERNEL_DIR and
> cannot simply use custom EXTRA_OEMAKE set by a module.
>
> Move back to calling make and passing HOSTCC/HOSTCPP directly w/o using
> EXTRA_OEMAKE.

Got this stagged it my rocko mut branch for testing.
thanks
Armin
>
> For more details please see:
> http://lists.openembedded.org/pipermail/openembedded-core/2018-August/154189.html
>
> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
> Cc: Bruce Ashfield <bruce.ashfield@windriver.com>
> Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
> Cc: Anuj Mittal <anuj.mittal@intel.com>
> Cc: Armin Kuster <akuster808@gmail.com>
> ---
>  meta/classes/module-base.bbclass | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
> index 9f3465e..c1fa3ad 100644
> --- a/meta/classes/module-base.bbclass
> +++ b/meta/classes/module-base.bbclass
> @@ -13,7 +13,6 @@ export CROSS_COMPILE = "${TARGET_PREFIX}"
>  export KBUILD_OUTPUT = "${STAGING_KERNEL_BUILDDIR}"
>  
>  DEPENDS += "bc-native"
> -EXTRA_OEMAKE += " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
>  
>  export KERNEL_VERSION = "${@base_read_file('${STAGING_KERNEL_BUILDDIR}/kernel-abiversion')}"
>  KERNEL_OBJECT_SUFFIX = ".ko"
> @@ -25,6 +24,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
>  # be called before do_compile. See module.bbclass for an example.
>  do_make_scripts() {
>  	unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS 
> -	oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> +	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 prepare
>  }



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

* Re: [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE
  2018-08-16  2:27 ` akuster808
@ 2018-08-24  1:15   ` Denys Dmytriyenko
  2018-08-29  2:39     ` Denys Dmytriyenko
  0 siblings, 1 reply; 4+ messages in thread
From: Denys Dmytriyenko @ 2018-08-24  1:15 UTC (permalink / raw)
  To: akuster808; +Cc: Bruce Ashfield, Denys Dmytriyenko, openembedded-core

On Wed, Aug 15, 2018 at 07:27:50PM -0700, akuster808 wrote:
> 
> 
> On 08/15/2018 06:22 PM, Denys Dmytriyenko wrote:
> > From: Denys Dmytriyenko <denys@ti.com>
> >
> > Commit d2aa88a6a92985f21414fceea2dc0facbf7f8779 was meant to backport build
> > dependencies on bc-native and openssl-native, but it also changed execution
> > of do_make_scripts() from calling make directly to using oe_runmake. That
> > change was made in master/sumo as part of a separate make-mod-scripts recipe.
> >
> > Unfortunately, that doesn't work here in rocko in the context of module-base
> > class, as it gets executed inside out-of-tree module environment. Quite often
> > those out-of-tree modules provide own Makefile with custom EXTRA_OEMAKE var
> > defined. But do_make_scripts() gets executed within STAGING_KERNEL_DIR and
> > cannot simply use custom EXTRA_OEMAKE set by a module.
> >
> > Move back to calling make and passing HOSTCC/HOSTCPP directly w/o using
> > EXTRA_OEMAKE.
> 
> Got this stagged it my rocko mut branch for testing.

Ping


> thanks
> Armin
> >
> > For more details please see:
> > http://lists.openembedded.org/pipermail/openembedded-core/2018-August/154189.html
> >
> > Signed-off-by: Denys Dmytriyenko <denys@ti.com>
> > Cc: Bruce Ashfield <bruce.ashfield@windriver.com>
> > Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
> > Cc: Anuj Mittal <anuj.mittal@intel.com>
> > Cc: Armin Kuster <akuster808@gmail.com>
> > ---
> >  meta/classes/module-base.bbclass | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
> > index 9f3465e..c1fa3ad 100644
> > --- a/meta/classes/module-base.bbclass
> > +++ b/meta/classes/module-base.bbclass
> > @@ -13,7 +13,6 @@ export CROSS_COMPILE = "${TARGET_PREFIX}"
> >  export KBUILD_OUTPUT = "${STAGING_KERNEL_BUILDDIR}"
> >  
> >  DEPENDS += "bc-native"
> > -EXTRA_OEMAKE += " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
> >  
> >  export KERNEL_VERSION = "${@base_read_file('${STAGING_KERNEL_BUILDDIR}/kernel-abiversion')}"
> >  KERNEL_OBJECT_SUFFIX = ".ko"
> > @@ -25,6 +24,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> >  # be called before do_compile. See module.bbclass for an example.
> >  do_make_scripts() {
> >  	unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS 
> > -	oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> > +	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 prepare
> >  }
> 


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

* Re: [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE
  2018-08-24  1:15   ` Denys Dmytriyenko
@ 2018-08-29  2:39     ` Denys Dmytriyenko
  0 siblings, 0 replies; 4+ messages in thread
From: Denys Dmytriyenko @ 2018-08-29  2:39 UTC (permalink / raw)
  To: akuster808; +Cc: Bruce Ashfield, openembedded-core

On Thu, Aug 23, 2018 at 09:15:55PM -0400, Denys Dmytriyenko wrote:
> On Wed, Aug 15, 2018 at 07:27:50PM -0700, akuster808 wrote:
> > 
> > 
> > On 08/15/2018 06:22 PM, Denys Dmytriyenko wrote:
> > > From: Denys Dmytriyenko <denys@ti.com>
> > >
> > > Commit d2aa88a6a92985f21414fceea2dc0facbf7f8779 was meant to backport build
> > > dependencies on bc-native and openssl-native, but it also changed execution
> > > of do_make_scripts() from calling make directly to using oe_runmake. That
> > > change was made in master/sumo as part of a separate make-mod-scripts recipe.
> > >
> > > Unfortunately, that doesn't work here in rocko in the context of module-base
> > > class, as it gets executed inside out-of-tree module environment. Quite often
> > > those out-of-tree modules provide own Makefile with custom EXTRA_OEMAKE var
> > > defined. But do_make_scripts() gets executed within STAGING_KERNEL_DIR and
> > > cannot simply use custom EXTRA_OEMAKE set by a module.
> > >
> > > Move back to calling make and passing HOSTCC/HOSTCPP directly w/o using
> > > EXTRA_OEMAKE.
> > 
> > Got this stagged it my rocko mut branch for testing.
> 
> Ping

Ping again - are there any problems with this patch?


> > thanks
> > Armin
> > >
> > > For more details please see:
> > > http://lists.openembedded.org/pipermail/openembedded-core/2018-August/154189.html
> > >
> > > Signed-off-by: Denys Dmytriyenko <denys@ti.com>
> > > Cc: Bruce Ashfield <bruce.ashfield@windriver.com>
> > > Cc: Richard Purdie <richard.purdie@linuxfoundation.org>
> > > Cc: Anuj Mittal <anuj.mittal@intel.com>
> > > Cc: Armin Kuster <akuster808@gmail.com>
> > > ---
> > >  meta/classes/module-base.bbclass | 4 ++--
> > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/meta/classes/module-base.bbclass b/meta/classes/module-base.bbclass
> > > index 9f3465e..c1fa3ad 100644
> > > --- a/meta/classes/module-base.bbclass
> > > +++ b/meta/classes/module-base.bbclass
> > > @@ -13,7 +13,6 @@ export CROSS_COMPILE = "${TARGET_PREFIX}"
> > >  export KBUILD_OUTPUT = "${STAGING_KERNEL_BUILDDIR}"
> > >  
> > >  DEPENDS += "bc-native"
> > > -EXTRA_OEMAKE += " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="${BUILD_CPP}""
> > >  
> > >  export KERNEL_VERSION = "${@base_read_file('${STAGING_KERNEL_BUILDDIR}/kernel-abiversion')}"
> > >  KERNEL_OBJECT_SUFFIX = ".ko"
> > > @@ -25,6 +24,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
> > >  # be called before do_compile. See module.bbclass for an example.
> > >  do_make_scripts() {
> > >  	unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS 
> > > -	oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> > > +	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 prepare
> > >  }
> > 
> -- 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core


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

end of thread, other threads:[~2018-08-29  2:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-16  1:22 [rocko][PATCH] module-base.bbclass: fix out-of-tree module builds with custom EXTRA_OEMAKE Denys Dmytriyenko
2018-08-16  2:27 ` akuster808
2018-08-24  1:15   ` Denys Dmytriyenko
2018-08-29  2:39     ` Denys Dmytriyenko

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.