diff options
author | Alexandru Croitor <alexandru.croitor@qt.io> | 2021-11-12 15:02:22 +0100 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-11-15 12:15:06 +0000 |
commit | 4ed2415f961c721730ffa8bbfd5ff5f5c08356d9 (patch) | |
tree | cf05bb589f73affb2fa21c8bacfa18ea0aedaa61 | |
parent | f8d9c3e234417e817b33976dd874e0c6e001e36d (diff) |
setup: Make ninja output the commands it runs in a verbose build
Verbose build output worked when using the Makefiles generator because
we set CMAKE_VERBOSE_MAKEFILE to ON, but that does not affect ninja.
For ninja we need to explicitly pass -v on the command line.
The verbose ninja output is useful when debugging build issues in the
CI (which uses verbose build).
Change-Id: Ib1532db0225744184d89bf796c4b3a6a40d718ca
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
(cherry picked from commit 9594789fcc58cb250900c935e1adb4b2ce9ed8b6)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
-rw-r--r-- | build_scripts/main.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/build_scripts/main.py b/build_scripts/main.py index 887e8e293..5237c8ca7 100644 --- a/build_scripts/main.py +++ b/build_scripts/main.py @@ -897,6 +897,8 @@ class PysideBuild(_build, DistUtilsCommandMixin): cmd_make = [self.make_path] if OPTION["JOBS"]: cmd_make.append(OPTION["JOBS"]) + if OPTION["VERBOSE_BUILD"] and self.make_generator == "Ninja": + cmd_make.append("-v") if run_process(cmd_make) != 0: raise DistutilsSetupError(f"Error compiling {extension}") @@ -914,7 +916,10 @@ class PysideBuild(_build, DistUtilsCommandMixin): import sphinx log.info("Generating Shiboken documentation") - if run_process([self.make_path, "doc"]) != 0: + make_doc_cmd = [self.make_path, "doc"] + if OPTION["VERBOSE_BUILD"] and self.make_generator == "Ninja": + make_doc_cmd.append("-v") + if run_process(make_doc_cmd) != 0: raise DistutilsSetupError("Error generating documentation " f"for {extension}") except ImportError: |