Re: [OE-core] [PATCH 2/3] module.bbclass: Add KERNEL_SRC in EXTRA_OEMAKE
On Wed, 2015-01-07 at 13:45 -0500, Bruce Ashfield wrote: On Wed, Jan 7, 2015 at 12:25 PM, Otavio Salvador ota...@ossystems.com.br wrote: When the sstate hash changes for do_configure task, the do_configure default implementation triggers the 'clean' to be run. For it to succeed we need to have KERNEL_SRC defined in EXTRA_OEMAKE. Fixes following error: I wanted to reproduce this locally, since I've never seen the problem myself. What's the best way to trigger the sstate hash change ? bitbake virtual/kernel -c configure -f Cheers, Richard -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: [OE-core] [PATCH 2/3] module.bbclass: Add KERNEL_SRC in EXTRA_OEMAKE
On Wed, Jan 7, 2015 at 4:45 PM, Bruce Ashfield bruce.ashfi...@gmail.com wrote: On Wed, Jan 7, 2015 at 12:25 PM, Otavio Salvador ota...@ossystems.com.br wrote: When the sstate hash changes for do_configure task, the do_configure default implementation triggers the 'clean' to be run. For it to succeed we need to have KERNEL_SRC defined in EXTRA_OEMAKE. Fixes following error: I wanted to reproduce this locally, since I've never seen the problem myself. What's the best way to trigger the sstate hash change ? I also have a question below ... This was triggered when I did a change in the kernel-module-mcc; so when I changed the recipe it triggered the configure. , | DEBUG: Executing shell function do_configure | NOTE: make -e MAKEFLAGS= clean | make -C M=.../tmp/work/... clean | make[1]: *** M=.../tmp/work/...: No such file or directory. Stop. | Makefile:20: recipe for target 'clean' failed | make: *** [clean] Error 2 | ERROR: oe_runmake failed ` Signed-off-by: Otavio Salvador ota...@ossystems.com.br --- meta/classes/module.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass index ad6f7af..5cb8623 100644 --- a/meta/classes/module.bbclass +++ b/meta/classes/module.bbclass @@ -6,10 +6,11 @@ addtask make_scripts after do_patch before do_compile do_make_scripts[lockfiles] = ${TMPDIR}/kernel-scripts.lock do_make_scripts[deptask] = do_populate_sysroot +EXTRA_OEMAKE += KERNEL_SRC=${STAGING_KERNEL_DIR} + I'm not seeing very well at the moment and my ability to browse the code is restricted, so bear with a potentially stupid question. No worries. It's clear from the error message above why this is needed, but I'm not seeing the code that is respecting/using KERNEL_SRC to trigger the clean in the right directory. Where exactly is this being used (I know your related base.bbclass change will pull in the extra make args, but I'm just not seeing the Makefile that respects it). Basically, I'm trying to decide if it would be better to handle this all in the module class, and add a do_configure to the do_compile and do_install we already have. Since I'm not seeing it, others might not as well .. and we can enhance the comments to make it clear. It was triggered from the module Makefile. So it basically runned: make clean and it tried to load it from kernel source, which obviously failed. -- Otavio Salvador O.S. Systems http://www.ossystems.com.brhttp://code.ossystems.com.br Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: [OE-core] [PATCH 2/3] module.bbclass: Add KERNEL_SRC in EXTRA_OEMAKE
On Wed, Jan 7, 2015 at 12:25 PM, Otavio Salvador ota...@ossystems.com.br wrote: When the sstate hash changes for do_configure task, the do_configure default implementation triggers the 'clean' to be run. For it to succeed we need to have KERNEL_SRC defined in EXTRA_OEMAKE. Fixes following error: I wanted to reproduce this locally, since I've never seen the problem myself. What's the best way to trigger the sstate hash change ? I also have a question below ... , | DEBUG: Executing shell function do_configure | NOTE: make -e MAKEFLAGS= clean | make -C M=.../tmp/work/... clean | make[1]: *** M=.../tmp/work/...: No such file or directory. Stop. | Makefile:20: recipe for target 'clean' failed | make: *** [clean] Error 2 | ERROR: oe_runmake failed ` Signed-off-by: Otavio Salvador ota...@ossystems.com.br --- meta/classes/module.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass index ad6f7af..5cb8623 100644 --- a/meta/classes/module.bbclass +++ b/meta/classes/module.bbclass @@ -6,10 +6,11 @@ addtask make_scripts after do_patch before do_compile do_make_scripts[lockfiles] = ${TMPDIR}/kernel-scripts.lock do_make_scripts[deptask] = do_populate_sysroot +EXTRA_OEMAKE += KERNEL_SRC=${STAGING_KERNEL_DIR} + I'm not seeing very well at the moment and my ability to browse the code is restricted, so bear with a potentially stupid question. It's clear from the error message above why this is needed, but I'm not seeing the code that is respecting/using KERNEL_SRC to trigger the clean in the right directory. Where exactly is this being used (I know your related base.bbclass change will pull in the extra make args, but I'm just not seeing the Makefile that respects it). Basically, I'm trying to decide if it would be better to handle this all in the module class, and add a do_configure to the do_compile and do_install we already have. Since I'm not seeing it, others might not as well .. and we can enhance the comments to make it clear. Bruce module_do_compile() { unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \ - KERNEL_SRC=${STAGING_KERNEL_DIR}\ KERNEL_VERSION=${KERNEL_VERSION}\ CC=${KERNEL_CC} LD=${KERNEL_LD} \ AR=${KERNEL_AR} \ @@ -19,7 +20,6 @@ module_do_compile() { module_do_install() { unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS oe_runmake DEPMOD=echo INSTALL_MOD_PATH=${D} \ - KERNEL_SRC=${STAGING_KERNEL_DIR} \ CC=${KERNEL_CC} LD=${KERNEL_LD} \ modules_install } -- 2.1.4 -- ___ 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 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH 2/3] module.bbclass: Add KERNEL_SRC in EXTRA_OEMAKE
When the sstate hash changes for do_configure task, the do_configure default implementation triggers the 'clean' to be run. For it to succeed we need to have KERNEL_SRC defined in EXTRA_OEMAKE. Fixes following error: , | DEBUG: Executing shell function do_configure | NOTE: make -e MAKEFLAGS= clean | make -C M=.../tmp/work/... clean | make[1]: *** M=.../tmp/work/...: No such file or directory. Stop. | Makefile:20: recipe for target 'clean' failed | make: *** [clean] Error 2 | ERROR: oe_runmake failed ` Signed-off-by: Otavio Salvador ota...@ossystems.com.br --- meta/classes/module.bbclass | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/classes/module.bbclass b/meta/classes/module.bbclass index ad6f7af..5cb8623 100644 --- a/meta/classes/module.bbclass +++ b/meta/classes/module.bbclass @@ -6,10 +6,11 @@ addtask make_scripts after do_patch before do_compile do_make_scripts[lockfiles] = ${TMPDIR}/kernel-scripts.lock do_make_scripts[deptask] = do_populate_sysroot +EXTRA_OEMAKE += KERNEL_SRC=${STAGING_KERNEL_DIR} + module_do_compile() { unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS oe_runmake KERNEL_PATH=${STAGING_KERNEL_DIR} \ - KERNEL_SRC=${STAGING_KERNEL_DIR}\ KERNEL_VERSION=${KERNEL_VERSION}\ CC=${KERNEL_CC} LD=${KERNEL_LD} \ AR=${KERNEL_AR} \ @@ -19,7 +20,6 @@ module_do_compile() { module_do_install() { unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS oe_runmake DEPMOD=echo INSTALL_MOD_PATH=${D} \ - KERNEL_SRC=${STAGING_KERNEL_DIR} \ CC=${KERNEL_CC} LD=${KERNEL_LD} \ modules_install } -- 2.1.4 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core