booru-viewer/booru-viewer.spec

69 lines
1.3 KiB
Python

# -*- mode: python ; coding: utf-8 -*-
import sys
from PyInstaller.utils.hooks import collect_data_files, collect_submodules
block_cipher = None
hiddenimports = [
*collect_submodules('booru_viewer'),
'httpx',
'httpx._transports',
'httpx._transports.default',
'h2',
'hpack',
'hyperframe',
'PIL',
'PIL.Image',
'PIL.JpegImagePlugin',
'PIL.PngImagePlugin',
'PIL.GifImagePlugin',
'PIL.WebPImagePlugin',
'PIL.BmpImagePlugin',
'mpv',
]
a = Analysis(
['booru_viewer/main_gui.py'],
pathex=[],
binaries=[('libmpv-2.dll', '.')] if sys.platform == 'win32' else [],
datas=[('icon.png', '.')],
hiddenimports=hiddenimports,
hookspath=[],
hooksconfig={},
runtime_hooks=[],
excludes=['textual', 'tkinter', 'unittest'],
noarchive=True,
optimize=2,
cipher=block_cipher,
)
pyz = PYZ(a.pure, cipher=block_cipher)
exe = EXE(
pyz,
a.scripts,
[],
exclude_binaries=True,
name='booru-viewer',
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=False,
upx_exclude=[],
console=False,
disable_windowed_traceback=False,
argv_emulation=False,
icon='icon.ico',
)
coll = COLLECT(
exe,
a.binaries,
a.datas,
strip=False,
upx=False,
upx_exclude=[],
name='booru-viewer',
)