From fad57e9e0fe2b57e9569aa26307c6344522c2a43 Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Sat, 26 Apr 2025 08:00:51 +0100 Subject: [PATCH] build: Fix `macdeployqtplus` after switching to Qt 6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Homebrew’s `qt@6` package places the `translations` and `plugins` directories in the `share/qt` subdirectory. This change updates the `macdeployqtplus` script accordingly. --- contrib/macdeploy/macdeployqtplus | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/contrib/macdeploy/macdeployqtplus b/contrib/macdeploy/macdeployqtplus index 21250ebcaa..ba532d7774 100755 --- a/contrib/macdeploy/macdeployqtplus +++ b/contrib/macdeploy/macdeployqtplus @@ -157,20 +157,19 @@ class DeploymentInfo(object): self.qtPath = None self.pluginPath = None self.deployedFrameworks = [] - + def detectQtPath(self, frameworkDirectory: str): parentDir = os.path.dirname(frameworkDirectory) - if os.path.exists(os.path.join(parentDir, "translations")): - # Classic layout, e.g. "/usr/local/Trolltech/Qt-4.x.x" + if os.path.exists(os.path.join(parentDir, "share", "qt", "translations")): self.qtPath = parentDir else: self.qtPath = os.getenv("QTDIR", None) if self.qtPath is not None: - pluginPath = os.path.join(self.qtPath, "plugins") + pluginPath = os.path.join(self.qtPath, "share", "qt", "plugins") if os.path.exists(pluginPath): self.pluginPath = pluginPath - + def usesFramework(self, name: str) -> bool: for framework in self.deployedFrameworks: if framework.endswith(".framework"):