diff options
author | Alexandru Croitor <alexandru.croitor@qt.io> | 2019-11-11 19:03:36 +0100 |
---|---|---|
committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2019-11-12 10:13:02 +0000 |
commit | 4fe8330b5b71c546c891a6ec3e706e48842ea67a (patch) | |
tree | 5bad2aee1e8b0e4c50440b5bccf8a8cd8bb64f3c /util/cmake | |
parent | 2c66bdde5a79f1597ca9bb610d4d51a7a4ec61c1 (diff) | |
download | qtbase-4fe8330b5b71c546c891a6ec3e706e48842ea67a.tar.gz |
pro2cmake: Fix formatting and mypy errors
Change-Id: Ic41998c39f5f5b890b3aa8ec43c6f3f03fee54da
Reviewed-by: Leander Beernaert <leander.beernaert@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'util/cmake')
-rwxr-xr-x | util/cmake/pro2cmake.py | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/util/cmake/pro2cmake.py b/util/cmake/pro2cmake.py index f3c9873e62..b40c35e355 100755 --- a/util/cmake/pro2cmake.py +++ b/util/cmake/pro2cmake.py @@ -1879,9 +1879,11 @@ def map_to_cmake_condition(condition: str = "") -> str: r'(TEST_architecture_arch STREQUAL "\1")', condition or "", ) - condition = condition.replace('QT___contains___opengl', 'QT_FEATURE_opengl') - condition = condition.replace('QT___contains___widgets', 'QT_FEATURE_widgets') - condition = condition.replace('DEFINES___contains___QT_NO_PRINTER', '(QT_FEATURE_printer EQUAL FALSE)') + condition = condition.replace("QT___contains___opengl", "QT_FEATURE_opengl") + condition = condition.replace("QT___contains___widgets", "QT_FEATURE_widgets") + condition = condition.replace( + "DEFINES___contains___QT_NO_PRINTER", "(QT_FEATURE_printer EQUAL FALSE)" + ) return condition @@ -2698,7 +2700,7 @@ def write_binary(cm_fh: IO[str], scope: Scope, gui: bool = False, *, indent: int extra = ["GUI"] if gui and not is_qt_test_helper else [] cmake_function_call = "add_qt_executable" - extra_keys = [] + extra_keys: List[str] = [] if is_qt_test_helper: binary_name += "_helper" @@ -3134,7 +3136,7 @@ def handle_app_or_lib( ) and "testlib" not in scope.expand("QT") if is_jar: - tar = write_jar(cm_fh, scope, indent=indent) + write_jar(cm_fh, scope, indent=indent) elif is_example: target = write_example(cm_fh, scope, gui, indent=indent, is_plugin=is_plugin) elif is_qt_plugin: |