public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH] dpkg.bbclass: add lockfile for do_build
@ 2018-01-10 16:04 Christopher Larson
  2018-01-11 10:31 ` Alexander Smirnov
  0 siblings, 1 reply; 5+ messages in thread
From: Christopher Larson @ 2018-01-10 16:04 UTC (permalink / raw)
  To: isar-users

All recipes using this class will run build.sh in the same chroot, and
build.sh runs apt-get to install deps, so the build can fail due to dpkg
being unable to acquire its lock. Add a bitbake lockfile to ensure that
only one do_build task for recipes inheriting this class runs at a time.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
---
 meta/classes/dpkg.bbclass | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/classes/dpkg.bbclass b/meta/classes/dpkg.bbclass
index c10f5ba..3966a71 100644
--- a/meta/classes/dpkg.bbclass
+++ b/meta/classes/dpkg.bbclass
@@ -7,3 +7,4 @@ inherit dpkg-base
 dpkg_runbuild() {
     sudo chroot ${BUILDCHROOT_DIR} /build.sh ${PP}/${SRC_DIR}
 }
+do_build[lockfiles] += "${TMPDIR}/dpkg.lock"
-- 
2.11.0


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

end of thread, other threads:[~2018-01-11 17:20 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-10 16:04 [PATCH] dpkg.bbclass: add lockfile for do_build Christopher Larson
2018-01-11 10:31 ` Alexander Smirnov
2018-01-11 12:14   ` Henning Schild
2018-01-11 15:20     ` Christopher Larson
2018-01-11 17:20       ` Henning Schild

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox