-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy pathMouseTracks.spec
83 lines (76 loc) · 2.27 KB
/
MouseTracks.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# -*- mode: python ; coding: utf-8 -*-
import glob
import os
from scipy import __file__ as scipy_path
a = Analysis(
['launch.py'],
pathex=[],
binaries=[],
datas=[
('config/colours.txt', 'config'),
('resources/images/icon.png', 'resources/images'),
],
hiddenimports=['resources.build.scipy'],
hookspath=[],
hooksconfig={},
runtime_hooks=[],
excludes=['scipy'],
noarchive=False,
optimize=0,
)
pyz = PYZ(a.pure)
# Remove unused binaries
binaries = [
(name, path, type) for name, path, type in a.binaries
if name in (r'PySide6\Qt6Core.dll', r'PySide6\Qt6Gui.dll', r'PySide6\Qt6Widgets.dll',
r'PySide6\QtCore.pyd', r'PySide6\QtGui.pyd', r'PySide6\QtWidgets.pyd')
or name.startswith((r'PySide6\plugins\platforms', r'PySide6\plugins\styles'))
or not (
name.startswith(r'PySide6\Qt6') and name.endswith('.dll')
or name.startswith(r'PySide6\Qt') and name.endswith('.pyd')
or name.startswith((
r'PIL\_webp', # 398 kb
r'PIL\_imagingcms', # 257 kb
r'PySide6\plugins', # 2864 kb
r'numpy\random', # 2288 kb
r'numpy\fft', # 273 kb
))
or name in (
r'PySide6\opengl32sw.dll', # 20157 kb
'libcrypto-3.dll', # 5071 kb
'python27.dll', # 3352 kb
'libssl-3.dll', # 769 kb
'_decimal.pyd', # 248 kb
'_lzma.pyd', # 156 kb
)
)
]
# Add scipy ndimage binaries
binaries.extend((f'resources/build/scipy/ndimage/{os.path.basename(filepath)}', filepath, 'BINARY')
for filepath in glob.glob(os.path.join(os.path.dirname(scipy_path), 'ndimage', '_nd_image.*')))
# Remove unused data files
datas = [
(name, path, type) for name, path, type in a.datas
if not name.startswith(r'PySide6\translations') # 6037 kb
]
exe = EXE(
pyz,
a.scripts,
binaries,
datas,
[],
name='MouseTracks',
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
upx_exclude=[],
runtime_tmpdir=None,
console=True,
disable_windowed_traceback=False,
argv_emulation=False,
target_arch=None,
codesign_identity=None,
entitlements_file=None,
icon=['resources\\images\\icon.ico'],
)