Skip to content

Commit f22ab4d

Browse files
committed
adds en-US.pak
1 parent 8c2d6cb commit f22ab4d

3 files changed

Lines changed: 12 additions & 9 deletions

File tree

src/artisan-linux.spec

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ BINARIES.extend([(os.path.join(yocto_lib_path, fn),'yoctopuce/cdll') for fn in o
1414
phidgets_lib_path = os.path.join(get_package_paths('Phidget22')[1], '.libs')
1515
BINARIES.extend([(os.path.join(phidgets_lib_path, fn),'Phidget22/.libs') for fn in os.listdir(phidgets_lib_path) if fn.endswith('.so')])
1616

17-
# add missing Qt6QmlMeta.so
17+
# add missing QtWebEngine shared libs
1818
BINARIES.append((os.path.join(get_package_paths('PyQt6')[1], 'Qt6/lib/libQt6QmlMeta.so.6'), 'PyQt6/Qt6/lib'))
1919
BINARIES.append((os.path.join(get_package_paths('PyQt6')[1], 'Qt6/lib/libQt6QmlWorkerScript.so.6'), 'PyQt6/Qt6/lib'))
2020

@@ -29,13 +29,9 @@ if not os.path.isdir(path):
2929
hiddenimports_list=[
3030
'matplotlib.backends.backend_pdf',
3131
'matplotlib.backends.backend_svg',
32-
# 'PyQt6.QtPositioning', # unclear
32+
'PyQt6.QtPositioning',
3333
'PyQt6.QtWebChannel', ## Win incl., but did not help
3434
'PyQt6.QtWebEngineCore', ## Win incl.
35-
# 'PyQt6.QtQuick', # links to QmlMeta, but did not help
36-
# 'PyQt6.QtWebEngineQuick', # links to QmlMeta, but did not help
37-
# 'PyQt6.QtQml', # unclear, but did not help
38-
# 'PyQt6.QtQuick3D', # links to QmlMeta, not tried yet
3935
'babel.numbers' # should not be needed as it got fixed in pyinstaller 6.11
4036
] + collect_submodules('dbus_fast')
4137

@@ -62,10 +58,16 @@ EXCLUDES = [
6258
# 'PyQt6.QtWebEngineQuick'
6359
]
6460

61+
62+
DATA_FILES = [
63+
# (os.path.join(get_package_paths('PyQt6')[1], 'Qt6/translations/qtwebengine_locales/en-US.pak'), 'locales')
64+
(os.path.join(get_package_paths('PyQt6')[1], 'Qt6/translations/qtwebengine_locales/en-US.pak'), 'PyQt6/Qt6/translations/qtwebengine_locale')
65+
]
66+
6567
a = Analysis(['artisan.py'],
6668
pathex=[path],
6769
binaries=BINARIES,
68-
datas=[],
70+
datas=DATA_FILES,
6971
hookspath=[],
7072
runtime_hooks=['./pyinstaller_hooks/rthooks/pyi_rth_mplconfig.py'], # overwrites default MPL runtime hook which keeps loading font cache from (new) temp directory
7173
# excludes=EXCLUDES,

src/artisan-mac.spec

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ qt_plugin_files = [
287287
'libqjpeg.dylib',
288288
# 'libqmacjp2.dylib',
289289
# 'libqpdf.dylib',
290-
'libqsvg.dylib',
290+
'libqsvg.dylib',
291291
# 'libqtga.dylib',
292292
# 'libqtiff.dylib',
293293
# 'libqwbmp.dylib',
@@ -297,7 +297,6 @@ qt_plugin_files = [
297297
'libqmacstyle.dylib'
298298
]
299299

300-
301300
## remove unused Qt frameworks libs (not in Qt_modules_frameworks)
302301
for subdir, dirs, _files in os.walk('./Artisan.app/Contents/Frameworks/PyQt6/Qt6/lib'):
303302
for di in dirs:

src/artisanlib/main.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27917,6 +27917,8 @@ def main() -> None:
2791727917
_log.info('loaded %s settings in %.2fs', len(QSettings().allKeys()), libtime.process_time() - start_time)
2791827918
# _log.debug("PRINT mpl.get_cachedir(): %s",mpl.get_cachedir())
2791927919

27920+
_log.debug('PRINT QLibraryInfo.LibraryPath.TranslationsPath: %s', QLibraryInfo.path(QLibraryInfo.LibraryPath.TranslationsPath))
27921+
2792027922
appWindow.set_ui_mode(appWindow.ui_mode)
2792127923

2792227924
# inform the user the debug logging is on

0 commit comments

Comments
 (0)