# Windows-only cx_freeze setup file, macOS may work but I've not tested it. import sys from cx_Freeze import setup, Executable import pygame from version import buildVersion if sys.version_info < (3, 0, 0): sys.exit("Python versions lower than 3 are not supported.") def is_64bit() -> bool: return sys.maxsize > 2**32 path = "" base = None if sys.platform == "win32": base = "Win32GUI" path = sys.path if is_64bit() == True: path.append(r"C:\Program Files (x86)\Windows Kits\10\Redist\10.0.22000.0\ucrt\DLLs\x64") elif is_64bit() == False: path.append(r"C:\Program Files (x86)\Windows Kits\10\Redist\10.0.22000.0\ucrt\DLLs\x86") print("Path = " + str(path)) includefiles = ["quirks", "smilies", "themes", "docs", "README.md", "LICENSE", "CHANGELOG.md", "PCskins.png", "Pesterchum.png"] build_exe_options = { "includes": ['PyQt5.QtCore', 'PyQt5.QtGui', 'PyQt5.QtWidgets'], "excludes": ['collections.sys', 'collections._sre', 'collections._json', 'collections._locale', 'collections._struct', 'collections.array', 'collections._weakref', 'PyQt5.QtMultimedia', 'PyQt5.QtDBus', 'PyQt5.QtDeclarative', 'PyQt5.QtHelp', 'PyQt5.QtNetwork', 'PyQt5.QtSql', 'PyQt5.QtSvg', 'PyQt5.QtTest', 'PyQt5.QtWebKit', 'PyQt5.QtXml', 'PyQt5.QtXmlPatterns', 'PyQt5.phonon', 'PyQt5.QtAssistant', 'PyQt5.QtDesigner', 'PyQt5.QAxContainer', 'pygame.docs' # Hopefully we can just not have pygame at all at some point =3 # (when QtMultimedia stops relying on local codecs