Skip to contentSkip to conversation

kernel-devsrc: Ensure we don't race against do_make_scripts from module-base.bbclass

PATCH New Richard Purdie 1 participant 1 message Dec 21, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kernel-devsrc: Ensure we don't race against do_make_scripts from module-base.bbclass

do_install for kernel-devsrc can race against do_make_scripts from module-base.bbclass. Since there is a lock there to guard against concurrency already, we can just use it here to avoid a race.

Ultimately, this can all likely be much more streamlined but this resolves the immediate build failures.

meta/recipes-kernel/linux/kernel-devsrc.bb +2 -0
index 1557c27..9fb761b 100644
@@ -55,6 +55,8 @@ do_install() {
                 cp ${S}/arch/powerpc/lib/crtsavres.o $kerneldir/arch/powerpc/lib/crtsavres.o
         fi
 }
+# Ensure we don't race against "make scripts" during cpio
+do_install[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
 
 PACKAGES = "kernel-devsrc"
 FILES_${PN} = "${KERNEL_SRC_PATH}"