diff --git a/gui/build.py b/gui/build.py index 0f802d178..f4c6e70ba 100644 --- a/gui/build.py +++ b/gui/build.py @@ -12,7 +12,7 @@ import subprocess import sys import tarfile -from pathlib import Path +# from pathlib import Path IS_WIN = os.name == "nt" IS_MAC = sys.platform == "darwin" @@ -92,7 +92,7 @@ def do_bundle(options): makensis_path = os.path.join(options.nsis_path, "makensis.exe") call(makensis_path, "wininst.nsi", cwd="wininst") elif IS_MAC: - Path("dist/mozregression GUI").unlink() + # Path("dist/mozregression GUI").unlink() with tarfile.open("mozregression-gui-app-bundle.tar.gz", "w:gz") as tar: tar.add(r"dist", arcname="mozregression-gui-app-bundle") else: diff --git a/gui/gui.spec b/gui/gui.spec index 0440b6947..e8a61bfc4 100644 --- a/gui/gui.spec +++ b/gui/gui.spec @@ -1,7 +1,6 @@ # -*- mode: python -*- import sys from PyInstaller.utils.hooks import (collect_all, collect_submodules) -from mozregression.pyinstaller import BUNDLE_WITH_TK IS_MAC = sys.platform == "darwin" @@ -18,38 +17,35 @@ for pkgname in ['glean', 'glean_parser', 'mozregression', 'yamllint', 'bs4']: # https://github.com/pypa/setuptools/issues/1963 hiddenimports.extend(collect_submodules('pkg_resources')) -analysis_kwargs = { - "binaries": binaries, - "datas": datas, - "hiddenimports": hiddenimports, - "hookspath": [], - "excludes": [], - "win_no_prefer_redirects": False, - "win_private_assemblies": False, - "cipher": block_cipher, - "noarchive": False -} -if IS_MAC: - analysis_kwargs["runtime_hooks"] = ["splash_hook.py"] - -a = Analysis(['mozregression-gui.py'], **analysis_kwargs) +a = Analysis(['mozregression-gui.py'], + binaries=binaries, + datas=datas, + hiddenimports=hiddenimports, + hookspath=[], + runtime_hooks=[], + excludes=[], + win_no_prefer_redirects=False, + win_private_assemblies=False, + cipher=block_cipher, + noarchive=False) pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher) if IS_MAC: exe = EXE(pyz, a.scripts, - a.binaries, - a.zipfiles, - a.datas, [], + exclude_binaries=True, name='mozregression GUI', debug=False, bootloader_ignore_signals=False, strip=False, upx=False, - console=False, - target_arch="universal2") - app = BUNDLE_WITH_TK(exe, + target_arch="universal2", + console=False) + app = BUNDLE(exe, + a.binaries, + a.zipfiles, + a.datas, strip=False, upx=True, name='mozregression GUI.app',