Pass -jN from Make to BOOTSTRAP_ARGS

Enables the same functionality as `x -jN` in Make by
passing the `-jN` arg from Make to the `BOOTSTRAP_ARGS` args
if it is specified.

Signed-off-by: onur-ozkan <work@onurozkan.dev>
This commit is contained in:
onur-ozkan 2023-09-23 23:58:43 +03:00
parent bf982631df
commit 863d2fddd7

View File

@ -6,6 +6,13 @@ Q := @
BOOTSTRAP_ARGS :=
endif
# Pass `-jN` to the bootstrap if it is specified.
ifdef MAKEFLAGS
ifneq (,$(findstring -j, $(MAKEFLAGS)))
BOOTSTRAP_ARGS += $(filter -j%, $(MAKEFLAGS))
endif
endif
BOOTSTRAP := $(CFG_PYTHON) $(CFG_SRC_DIR)src/bootstrap/bootstrap.py
all: