@@ -216,30 +216,27 @@ jobs:
216216 - name : Create Windows 7 PyInstaller spec
217217 if : matrix.build-type == 'win7-compatible'
218218 run : |
219- python -c "
220- spec_content = ''' # -*- mode: python ; coding: utf-8 -*-
219+ cat > SilverFlagOVERSEE-Win7.spec << 'SPEC_EOF'
220+ # -*- mode: python ; coding: utf-8 -*-
221221 import sys
222222 from PyInstaller.building.build_main import Analysis, PYZ, EXE
223223 from PyInstaller.building.datastruct import Tree
224224
225225 block_cipher = None
226226
227- # Windows 7 compatible analysis
228227 a = Analysis(
229228 ['src/main.py'],
230229 pathex=[],
231230 binaries=[],
232231 datas=[],
233232 hiddenimports=[
234- # Common hidden imports for Windows 7 compatibility
235233 'win32api', 'win32con', 'win32gui', 'win32process',
236234 'pywintypes', 'pythoncom', 'pkg_resources.py2_warn'
237235 ],
238236 hookspath=[],
239237 hooksconfig={},
240238 runtime_hooks=[],
241239 excludes=[
242- # Exclude modules that might cause Windows 7 issues
243240 'tkinter', '_tkinter', 'unittest', 'test'
244241 ],
245242 win_no_prefer_redirects=False,
@@ -261,7 +258,7 @@ jobs:
261258 debug=False,
262259 bootloader_ignore_signals=False,
263260 strip=False,
264- upx=False, # Disable UPX for better Windows 7 compatibility
261+ upx=False,
265262 upx_exclude=[],
266263 runtime_tmpdir=None,
267264 console=False,
@@ -270,17 +267,10 @@ jobs:
270267 target_arch=None,
271268 codesign_identity=None,
272269 entitlements_file=None,
273- icon='logo.ico' if open('logo.ico', 'rb') if os.path.exists('logo.ico') else None,
274270 manifest='app.manifest',
275271 version_file=None,
276272 )
277- '''
278-
279- import os
280- with open('SilverFlagOVERSEE-Win7.spec', 'w', encoding='utf-8') as f:
281- f.write(spec_content)
282- print('Windows 7 PyInstaller spec created')
283- "
273+ SPEC_EOF
284274 shell : bash
285275
286276 - name : Build with PyInstaller
0 commit comments