Makefile: allow top-level parallel build with BR2_PER_PACKAGE_DIRECTORIES=y
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> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>2020.02.x
parent
c4e6d5c8be
commit
d9a4c0c7ea
19
Makefile
19
Makefile
|
@ -227,21 +227,12 @@ ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
|
||||||
-include $(BR2_CONFIG)
|
-include $(BR2_CONFIG)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Parallel execution of this Makefile is disabled because it changes
|
ifeq ($(BR2_PER_PACKAGE_DIRECTORIES),)
|
||||||
# the packages building order, that can be a problem for two reasons:
|
# Disable top-level parallel build if per-package directories is not
|
||||||
# - If a package has an unspecified optional dependency and that
|
# used. Indeed, per-package directories is necessary to guarantee
|
||||||
# dependency is present when the package is built, it is used,
|
# determinism and reproducibility with top-level parallel build.
|
||||||
# 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))
|
|
||||||
.NOTPARALLEL:
|
.NOTPARALLEL:
|
||||||
|
endif
|
||||||
|
|
||||||
# timezone and locale may affect build output
|
# timezone and locale may affect build output
|
||||||
ifeq ($(BR2_REPRODUCIBLE),y)
|
ifeq ($(BR2_REPRODUCIBLE),y)
|
||||||
|
|
Loading…
Reference in New Issue