summaryrefslogtreecommitdiffstats
path: root/lib/python/qmk/cli/multibuild.py
diff options
context:
space:
mode:
authorruro <ruro.ruro@ya.ru>2021-08-18 01:46:59 +0300
committerGitHub <noreply@github.com>2021-08-18 08:46:59 +1000
commit3b28178deb7a42a2df8c19b9bf190bb5da732b33 (patch)
treebbffcc4752948a0f5a52c31930f3ada863e67f44 /lib/python/qmk/cli/multibuild.py
parent999391f3ae6bab3fe1784d0f53bffd0320a9e076 (diff)
`--parallel` improvements (#13800)
* improve make parallel jobs support * document the --parallel option * disable the output-sync for interactive targets
Diffstat (limited to 'lib/python/qmk/cli/multibuild.py')
-rwxr-xr-xlib/python/qmk/cli/multibuild.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/python/qmk/cli/multibuild.py b/lib/python/qmk/cli/multibuild.py
index bdb0b493c8..85ed0fa1e9 100755
--- a/lib/python/qmk/cli/multibuild.py
+++ b/lib/python/qmk/cli/multibuild.py
@@ -10,7 +10,7 @@ from subprocess import DEVNULL
from milc import cli
from qmk.constants import QMK_FIRMWARE
-from qmk.commands import _find_make
+from qmk.commands import _find_make, get_make_parallel_args
import qmk.keyboard
import qmk.keymap
@@ -28,7 +28,7 @@ def _is_split(keyboard_name):
return True if 'SPLIT_KEYBOARD' in rules_mk and rules_mk['SPLIT_KEYBOARD'].lower() == 'yes' else False
-@cli.argument('-j', '--parallel', type=int, default=1, help="Set the number of parallel make jobs to run.")
+@cli.argument('-j', '--parallel', type=int, default=1, help="Set the number of parallel make jobs; 0 means unlimited.")
@cli.argument('-c', '--clean', arg_only=True, action='store_true', help="Remove object files before compiling.")
@cli.argument('-f', '--filter', arg_only=True, action='append', default=[], help="Filter the list of keyboards based on the supplied value in rules.mk. Supported format is 'SPLIT_KEYBOARD=yes'. May be passed multiple times.")
@cli.argument('-km', '--keymap', type=str, default='default', help="The keymap name to build. Default is 'default'.")
@@ -80,7 +80,7 @@ all: {keyboard_safe}_binary
)
# yapf: enable
- cli.run([make_cmd, '-j', str(cli.args.parallel), '-f', makefile.as_posix(), 'all'], capture_output=False, stdin=DEVNULL)
+ cli.run([make_cmd, *get_make_parallel_args(cli.args.parallel), '-f', makefile.as_posix(), 'all'], capture_output=False, stdin=DEVNULL)
# Check for failures
failures = [f for f in builddir.glob(f'failed.log.{os.getpid()}.*')]