diff --git a/gftools-builder.spec b/gftools-builder.spec deleted file mode 100644 index 75500aae8..000000000 --- a/gftools-builder.spec +++ /dev/null @@ -1,47 +0,0 @@ -# -*- mode: python ; coding: utf-8 -*- -from PyInstaller.utils.hooks import collect_all - -datas = [] -binaries = [] -hiddenimports = [] -tmp_ret = collect_all('glyphsLib') -datas += tmp_ret[0]; binaries += tmp_ret[1]; hiddenimports += tmp_ret[2] - - -block_cipher = None - - -a = Analysis(['bin/gftools-builder.py'], - pathex=[], - binaries=binaries, - datas=datas, - hiddenimports=hiddenimports, - hookspath=[], - hooksconfig={}, - 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) - -exe = EXE(pyz, - a.scripts, - a.binaries, - a.zipfiles, - a.datas, - [], - name='gftools-builder', - debug=False, - bootloader_ignore_signals=False, - strip=False, - upx=True, - upx_exclude=[], - runtime_tmpdir=None, - console=True, - disable_windowed_traceback=False, - target_arch=None, - codesign_identity=None, - entitlements_file=None ) diff --git a/gftools-qa.spec b/gftools-qa.spec deleted file mode 100644 index 2a31c5425..000000000 --- a/gftools-qa.spec +++ /dev/null @@ -1,47 +0,0 @@ -# -*- mode: python ; coding: utf-8 -*- -from PyInstaller.utils.hooks import collect_all - -datas = [] -binaries = [('venv/lib/python3.9/site-packages/freetype/libfreetype.dylib', '.')] -hiddenimports = [] -tmp_ret = collect_all('gftools') -datas += tmp_ret[0]; binaries += tmp_ret[1]; hiddenimports += tmp_ret[2] - - -block_cipher = None - - -a = Analysis(['bin/gftools-qa.py'], - pathex=[], - binaries=binaries, - datas=datas, - hiddenimports=hiddenimports, - hookspath=[], - hooksconfig={}, - 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) - -exe = EXE(pyz, - a.scripts, - a.binaries, - a.zipfiles, - a.datas, - [], - name='gftools-qa', - debug=False, - bootloader_ignore_signals=False, - strip=False, - upx=True, - upx_exclude=[], - runtime_tmpdir=None, - console=True, - disable_windowed_traceback=False, - target_arch=None, - codesign_identity=None, - entitlements_file=None ) diff --git a/gftools.spec b/gftools.spec index fe5327421..e1af843b9 100644 --- a/gftools.spec +++ b/gftools.spec @@ -2,99 +2,98 @@ from PyInstaller.utils.hooks import collect_all datas = [] -binaries = [('venv/lib/python3.9/site-packages/freetype/libfreetype.dylib', '.')] +binaries = [("venv/lib/python3.9/site-packages/freetype/libfreetype.dylib", ".")] hiddenimports = [] -tmp_ret = collect_all('gftools') -datas += tmp_ret[0]; binaries += tmp_ret[1]; hiddenimports += tmp_ret[2] -tmp_ret = collect_all('glyphsLib') -datas += tmp_ret[0]; binaries += tmp_ret[1]; hiddenimports += tmp_ret[2] - - - - - -qa_a = Analysis(['bin/gftools-qa.py'], - pathex=[], - binaries=[], - datas=[], - hiddenimports=[], - hookspath=[], - hooksconfig={}, - runtime_hooks=[], - excludes=[], - win_no_prefer_redirects=False, - win_private_assemblies=False, - noarchive=False) - -builder_a = Analysis(['bin/gftools-builder.py'], - pathex=[], - binaries=[], - datas=[], - hiddenimports=[], - hookspath=[], - hooksconfig={}, - runtime_hooks=[], - excludes=[], - win_no_prefer_redirects=False, - win_private_assemblies=False, - noarchive=False) - - -MERGE((qa_a, 'gftools-qa', 'bin/gftools-qa.py'), (builder_a, 'gftools-builder', 'bin/gftools-builder.py')) - - - -qa_pyz = PYZ(qa_a.pure) - -qa_exe = EXE(qa_pyz, - qa_a.scripts, - [], - exclude_binaries=True, - name='gftools-qa', - debug=False, - bootloader_ignore_signals=False, - strip=False, - upx=True, - console=True, - disable_windowed_traceback=False, - target_arch=None, - codesign_identity=None, - entitlements_file=None ) - -qa_coll = COLLECT(qa_exe, - qa_a.binaries, - qa_a.zipfiles, - qa_a.datas, - strip=False, - upx=True, - upx_exclude=[], - name='gftools-qa') - - - - -builder_pyz = PYZ(builder_a.pure) - -builder_exe = EXE(builder_pyz, - builder_a.scripts, - [], - exclude_binaries=True, - name='gftools-builder', - debug=False, - bootloader_ignore_signals=False, - strip=False, - upx=True, - console=True, - disable_windowed_traceback=False, - target_arch=None, - codesign_identity=None, - entitlements_file=None ) - -builder_coll = COLLECT(builder_exe, - builder_a.binaries, - builder_a.zipfiles, - builder_a.datas, - strip=False, - upx=True, - upx_exclude=[], - name='gftools-builder') \ No newline at end of file +tmp_ret = collect_all("gftools") +datas += tmp_ret[0] +binaries += tmp_ret[1] +hiddenimports += tmp_ret[2] + +# from gftools builder +tmp_ret = collect_all("glyphsLib") +datas += tmp_ret[0] +binaries += tmp_ret[1] +hiddenimports += tmp_ret[2] + + + +block_cipher = None + + +a_qa = Analysis( + ["bin/gftools-qa.py"], + pathex=["."], + binaries=binaries, + datas=datas, + hiddenimports=hiddenimports, + hookspath=[], + hooksconfig={}, + runtime_hooks=[], + excludes=[], + win_no_prefer_redirects=False, + win_private_assemblies=False, + cipher=block_cipher, + noarchive=False, +) +a_builder = Analysis( + ["bin/gftools-builder.py"], + pathex=["."], + binaries=binaries, + datas=datas, + hiddenimports=hiddenimports, + hookspath=[], + hooksconfig={}, + runtime_hooks=[], + excludes=[], + win_no_prefer_redirects=False, + win_private_assemblies=False, + cipher=block_cipher, + noarchive=False, +) + +MERGE( + (a_qa, "gftools-qa", "gftools-qa"), + (a_builder, "gftools-builder", "gftools-builder"), +) + +pyz_qa = PYZ(a_qa.pure, a_qa.zipped_data, cipher=block_cipher) +pyz_builder = PYZ(a_builder.pure, a_builder.zipped_data, cipher=block_cipher) + +exe_qa = EXE( + pyz_qa, + a_qa.scripts, + a_qa.binaries, + a_qa.dependencies, + a_qa.zipfiles, + a_qa.datas, + [], + name="gftools-qa", + debug=False, + bootloader_ignore_signals=False, + strip=False, + upx=True, + console=True, + disable_windowed_traceback=False, + target_arch=None, + codesign_identity=None, + entitlements_file=None, +) +exe_builder = EXE( + pyz_builder, + a_builder.scripts, + a_builder.binaries, + a_builder.dependencies, + a_builder.zipfiles, + a_builder.datas, + [], + name="gftools-builder", + debug=False, + bootloader_ignore_signals=False, + strip=False, + upx=True, + console=True, + disable_windowed_traceback=False, + target_arch=None, + codesign_identity=None, + entitlements_file=None, +) \ No newline at end of file