gentoo/dev-python/pyside/files/pyside-6.10.1-pass-ninja-opts.patch
Paul Zander 9586188784
dev-python/pyside: 6.10.1 handle empty NINJAOPTS
Do not pass a separator to pythons split to handle empty strings or extra
whitespace correctly.

Closes: https://bugs.gentoo.org/967989
Fixes: 23e0f39f781c2d6f0ba1fa8d7611ea84c66a2c1f
Signed-off-by: Paul Zander <negril.nx+gentoo@gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/45170
Closes: https://github.com/gentoo/gentoo/pull/45170
Signed-off-by: Sam James <sam@gentoo.org>
2025-12-27 03:48:41 +00:00

21 lines
837 B
Diff

Allows passing --load-average and not passing --jobs which would stop the jobserver from working.
This is a Gentoo'ism so its not upstreamable in this form.
diff --git a/build_scripts/main.py b/build_scripts/main.py
index cdaa439ff..3e088961e 100644
--- a/build_scripts/main.py
+++ b/build_scripts/main.py
@@ -854,8 +854,8 @@ class PysideBuild(_build, CommandMixin, BuildInfoCollectorMixin):
log.info(f"-- Compiling module {extension}...")
cmd_make = [str(self.make_path)]
- if OPTION["JOBS"]:
- cmd_make.append(OPTION["JOBS"])
+ if self.make_generator == "Ninja":
+ cmd_make.extend(os.getenv("NINJAOPTS").split())
if OPTION["LOG_LEVEL"] == LogLevel.VERBOSE and self.make_generator == "Ninja":
cmd_make.append("-v")
if run_process(cmd_make) != 0: