All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH next v8 2/6] Makefile: allow top-level parallel build with BR2_PER_PACKAGE_DIRECTORIES=y
Date: Tue,  5 Nov 2019 17:46:41 +0100	[thread overview]
Message-ID: <20191105164646.23820-3-thomas.petazzoni@bootlin.com> (raw)
In-Reply-To: <20191105164646.23820-1-thomas.petazzoni@bootlin.com>

With per-package folder support, top-level parallel build becomes
safe, so we can enclose the .NOTPARALLEL statement in a
!BR2_PER_PACKAGE_DIRECTORIES condition.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Acked-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
---
 Makefile | 19 +++++--------------
 1 file changed, 5 insertions(+), 14 deletions(-)

diff --git a/Makefile b/Makefile
index 823c219c86..c117da7e8c 100644
--- a/Makefile
+++ b/Makefile
@@ -227,21 +227,12 @@ ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
 -include $(BR2_CONFIG)
 endif
 
-# Parallel execution of this Makefile is disabled because it changes
-# the packages building order, that can be a problem for two reasons:
-# - If a package has an unspecified optional dependency and that
-#   dependency is present when the package is built, it is used,
-#   otherwise it isn't (but compilation happily proceeds) so the end
-#   result will differ if the order is swapped due to parallel
-#   building.
-# - Also changing the building order can be a problem if two packages
-#   manipulate the same file in the target directory.
-#
-# Taking into account the above considerations, if you still want to execute
-# this top-level Makefile in parallel comment the ".NOTPARALLEL" line and
-# use the -j<jobs> option when building, e.g:
-#      make -j$((`getconf _NPROCESSORS_ONLN`+1))
+ifeq ($(BR2_PER_PACKAGE_DIRECTORIES),)
+# Disable top-level parallel build if per-package directories is not
+# used. Indeed, per-package directories is necessary to guarantee
+# determinism and reproducibility with top-level parallel build.
 .NOTPARALLEL:
+endif
 
 # timezone and locale may affect build output
 ifeq ($(BR2_REPRODUCIBLE),y)
-- 
2.21.0

  parent reply	other threads:[~2019-11-05 16:46 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-05 16:46 [Buildroot] [PATCH next v8 0/6] Top-level parallel build support Thomas Petazzoni
2019-11-05 16:46 ` [Buildroot] [PATCH next v8 1/6] core: implement per-package SDK and target Thomas Petazzoni
2019-11-29 14:20   ` Peter Korsgaard
2023-11-10 14:12   ` [Buildroot] [BUG?] per-package not fully working with dependencies and rebuild John Ernberg
2019-11-05 16:46 ` Thomas Petazzoni [this message]
2019-11-29 14:20   ` [Buildroot] [PATCH next v8 2/6] Makefile: allow top-level parallel build with BR2_PER_PACKAGE_DIRECTORIES=y Peter Korsgaard
2019-11-05 16:46 ` [Buildroot] [PATCH next v8 3/6] package/pkg-generic: make libtool .la files compatible with per-package directories Thomas Petazzoni
2019-11-20 20:22   ` Matthew Weber
2019-11-29 14:24   ` Peter Korsgaard
2019-11-05 16:46 ` [Buildroot] [PATCH next v8 4/6] package/pkg-kconfig: handle KCONFIG_DEPENDENCIES " Thomas Petazzoni
2019-11-29 14:39   ` Peter Korsgaard
2019-11-05 16:46 ` [Buildroot] [PATCH next v8 5/6] docs/manual: add details about top-level parallel build support Thomas Petazzoni
2019-11-29 14:43   ` Peter Korsgaard
2019-11-05 16:46 ` [Buildroot] [PATCH next v8 6/6] docs/manual: document the effect of per-package directory on variables Thomas Petazzoni
2019-11-29 14:43   ` Peter Korsgaard
2019-11-06 19:37 ` [Buildroot] [PATCH next v8 0/6] Top-level parallel build support Bernd Kuhls

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191105164646.23820-3-thomas.petazzoni@bootlin.com \
    --to=thomas.petazzoni@bootlin.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.