Extended the way the Qt executables are searched for. eric7

Thu, 22 Sep 2022 19:45:29 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Thu, 22 Sep 2022 19:45:29 +0200
branch
eric7
changeset 9345
58a1e7c960b8
parent 9344
52990830b13f
child 9346
eda0bdb22e67

Extended the way the Qt executables are searched for.

src/eric7/Globals/__init__.py file | annotate | diff | comparison | revisions
--- a/src/eric7/Globals/__init__.py	Wed Sep 21 10:38:52 2022 +0200
+++ b/src/eric7/Globals/__init__.py	Thu Sep 22 19:45:29 2022 +0200
@@ -17,11 +17,12 @@
 import sys
 
 from PyQt6.QtCore import (
-    QDir,
     QByteArray,
     QCoreApplication,
+    QDir,
+    QLibraryInfo,
+    QProcess,
     QT_VERSION,
-    QProcess,
     qVersion,
 )
 
@@ -388,7 +389,15 @@
             if not os.path.exists(binPath):
                 binPath = ""
 
-    # step 3: determine from used Python interpreter (designer is test object)
+    # step3: determine via QLibraryInfo
+    if not binPath:
+        binPath = (
+            QLibraryInfo.path(QLibraryInfo.LibraryPath.LibraryExecutablesPath)
+            if libexec else
+            QLibraryInfo.path(QLibraryInfo.LibraryPath.BinariesPath)
+        )
+
+    # step 4: determine from used Python interpreter (designer is test object)
     if not binPath:
         program = "designer"
         if isWindowsPlatform():

eric ide

mercurial