aboutsummaryrefslogtreecommitdiffstats
path: root/build_scripts
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2022-11-07 17:46:43 +0100
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2022-11-08 10:09:19 +0100
commita9fc4a26a88165c743a38412f9d48de6c43ab167 (patch)
treec5b58717b1a95e1bec0791994b93eee3dcdc0c37 /build_scripts
parentf6ed29c7ae8c93c4600226ebd0c2b69f6adabafc (diff)
Build system: Fix cross builds
Move the conversion of Options.self.qt_target_path to Path up, fixing: File "pyside-setup_was/build_scripts/options.py", line 333, in _do_finalize if not self._determine_defaults_and_check(): File "pyside-setup_was/build_scripts/options.py", line 510, in _determine_defaults_and_check if self.qt_target_path and not self.qt_target_path.exists(): AttributeError: 'str' object has no attribute 'exists' Amends 2afcf8e7545c681e412e5b6d04ab8867e5edd5c7. Task-number: PYSIDE-2080 Change-Id: I4fe2bc7dcef1f8ff76c3e8e1353b4ca5afe7d596 Reviewed-by: Adrian Herrmann <adrian.herrmann@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Diffstat (limited to 'build_scripts')
-rw-r--r--build_scripts/options.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/build_scripts/options.py b/build_scripts/options.py
index 9f1cb1f5e..449597633 100644
--- a/build_scripts/options.py
+++ b/build_scripts/options.py
@@ -375,10 +375,7 @@ class CommandMixin(object):
self.qt_host_path = OPTION['QT_HOST_PATH']
OPTION['QT_TARGET_PATH'] = self.qt_target_path
- qt_target_path = None
- if self.qt_target_path:
- self.qt_target_path = Path(self.qt_target_path)
- qt_target_path = self.qt_target_path
+ qt_target_path = self.qt_target_path
# We use the CMake project to find host Qt if neither qmake or
# qtpaths is available. This happens when building the host
@@ -474,6 +471,8 @@ class CommandMixin(object):
self.qtpaths = Path(self.qtpaths)
if isinstance(self.qmake, str):
self.qmake = Path(self.qmake)
+ if self.qt_target_path and isinstance(self.qt_target_path, str):
+ self.qt_target_path = Path(self.qt_target_path)
# When cross-compiling, we only accept the qt-target-path
# option and don't rely on auto-searching in PATH or the other