From 401c8134dd84e3ad271c6a0a1e6248cf090d7fe4 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Thu, 1 Jul 2021 14:17:49 +0200 Subject: Pyside6/Qt Designer: Fix Python code preview not working on UNIX Qt Designer as bundled by PySide6 was unable to find the uic binary in the libexec directory of the bundled Qt since that was only copied when QtWebEngine was built and the rcc/uic binaries were copied into the main directory. Also, libexec existed as a file containing qt.conf, which was created by a copy statement not checking for the target directory. Fix that by actually creating a libexec directory for uic, rcc and QtWebEngineProcess. Patch the executables accordingly. Add checks before copying qt.conf. Adapt pyside-tool to use libexec. The Windows code path remains the same, everything uses main directory there. Change-Id: I0c9f46fb776ed0315eecb6ed00202ea8d8f17fe2 Reviewed-by: Qt CI Bot Reviewed-by: Christian Tismer --- build_scripts/platforms/macos.py | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'build_scripts/platforms/macos.py') diff --git a/build_scripts/platforms/macos.py b/build_scripts/platforms/macos.py index 81e826d73..dcbaff3a3 100644 --- a/build_scripts/platforms/macos.py +++ b/build_scripts/platforms/macos.py @@ -160,12 +160,6 @@ def prepare_standalone_package_macos(self, vars): recursive=True, vars=vars, force_copy_symlinks=True) if self.is_webengine_built(built_modules): - copydir("{qt_lib_execs_dir}", - "{st_build_dir}/{st_package_name}/Qt/libexec", - filter=None, - recursive=False, - vars=vars) - copydir("{qt_prefix_dir}/resources", "{st_build_dir}/{st_package_name}/Qt/resources", filter=None, @@ -181,10 +175,11 @@ def prepare_standalone_package_macos(self, vars): if copy_qt_conf: # Copy the qt.conf file to libexec. + if not os.path.isdir(qt_libexec_path): + os.makedirs(qt_libexec_path) copyfile( f"{{build_dir}}/{PYSIDE}/{{st_package_name}}/qt.conf", - "{st_build_dir}/{st_package_name}/Qt/libexec", - vars=vars) + qt_libexec_path, vars=vars) if copy_plugins: # /plugins/* -> /{st_package_name}/Qt/plugins -- cgit v1.2.3