* [PATCH V2] make-mod-scripts: Fix a rare build race condition
@ 2020-05-27 19:46 Khem Raj
2020-05-27 20:07 ` [OE-core] " Andre McCurdy
0 siblings, 1 reply; 2+ messages in thread
From: Khem Raj @ 2020-05-27 19:46 UTC (permalink / raw)
To: openembedded-core; +Cc: Khem Raj, Bruce Ashfield
There is a build break which often happens whem using 4.1 kernel
/bin/sh: 1: scripts/basic/fixdep: Permission denied
scripts/Makefile.host:124: recipe for target 'scripts/dtc/srcpos.o' failed
make[3]: *** [scripts/dtc/srcpos.o] Error 126
this patch sequences the build targets so it can work reliably with
different kernel versions
Divide the target into scripts_basic scripts is not
strictly necessary and was simply what was used for
testing on kernel 4.1, which is quite an old kernel
perhaps just using scripts is sufficient, but it is not tested to not
known will cause the build race as seen above.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Cc: Bruce Ashfield <bruce.ashfield@gmail.com>
---
v2: Improve commit msg
.../make-mod-scripts/make-mod-scripts_1.0.bb | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
index 0be1422a24..c7edb20ee4 100644
--- a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
+++ b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
@@ -23,7 +23,8 @@ EXTRA_OEMAKE = " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="
#
do_configure() {
unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
- oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
- -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts prepare
-
+ for t in prepare scripts_basic scripts; do
+ oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
+ -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} $t
+ done
}
--
2.26.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [OE-core] [PATCH V2] make-mod-scripts: Fix a rare build race condition
2020-05-27 19:46 [PATCH V2] make-mod-scripts: Fix a rare build race condition Khem Raj
@ 2020-05-27 20:07 ` Andre McCurdy
0 siblings, 0 replies; 2+ messages in thread
From: Andre McCurdy @ 2020-05-27 20:07 UTC (permalink / raw)
To: Khem Raj; +Cc: OE Core mailing list, Bruce Ashfield
On Wed, May 27, 2020 at 12:46 PM Khem Raj <raj.khem@gmail.com> wrote:
>
> There is a build break which often happens whem using 4.1 kernel
Perhaps change "often" to "rarely" to match the title...
> /bin/sh: 1: scripts/basic/fixdep: Permission denied
> scripts/Makefile.host:124: recipe for target 'scripts/dtc/srcpos.o' failed
> make[3]: *** [scripts/dtc/srcpos.o] Error 126
>
> this patch sequences the build targets so it can work reliably with
> different kernel versions
>
> Divide the target into scripts_basic scripts is not
> strictly necessary and was simply what was used for
> testing on kernel 4.1, which is quite an old kernel
>
> perhaps just using scripts is sufficient, but it is not tested to not
> known will cause the build race as seen above.
>
> Signed-off-by: Khem Raj <raj.khem@gmail.com>
> Cc: Bruce Ashfield <bruce.ashfield@gmail.com>
> ---
> v2: Improve commit msg
>
> .../make-mod-scripts/make-mod-scripts_1.0.bb | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
> index 0be1422a24..c7edb20ee4 100644
> --- a/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
> +++ b/meta/recipes-kernel/make-mod-scripts/make-mod-scripts_1.0.bb
> @@ -23,7 +23,8 @@ EXTRA_OEMAKE = " HOSTCC="${BUILD_CC} ${BUILD_CFLAGS} ${BUILD_LDFLAGS}" HOSTCPP="
> #
> do_configure() {
> unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
> - oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> - -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} scripts prepare
> -
> + for t in prepare scripts_basic scripts; do
> + oe_runmake CC="${KERNEL_CC}" LD="${KERNEL_LD}" AR="${KERNEL_AR}" \
> + -C ${STAGING_KERNEL_DIR} O=${STAGING_KERNEL_BUILDDIR} $t
> + done
> }
> --
> 2.26.2
>
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-05-27 20:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-27 19:46 [PATCH V2] make-mod-scripts: Fix a rare build race condition Khem Raj
2020-05-27 20:07 ` [OE-core] " Andre McCurdy
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.