Skip to content

Commit

Permalink
Kivy attempt 2 (#17)
Browse files Browse the repository at this point in the history
* Added basic kivy build.

* Let's try adding tree.

* Adding glew deps appears to have done the trick?

* Renaming to move to kivy.

* Now let's see if we can get it to build remotely.

* update requirements.txt

* only build windows.

* angle backend.

* disable cli and change paramters a bit.

* fix build command.

* re-enable mac.

* Explicit callout of deps and glew.

* added osx spec file.

* disable fail-fast.

* remove unnecessary dependencies

* extension fix.

* update osx extension

* Added feature parity.

* Added feature parity.

* alphabetized buttons.

* Added async labels.
  • Loading branch information
n2qzshce authored Mar 24, 2021
1 parent ffc1f5c commit b148a79
Show file tree
Hide file tree
Showing 5 changed files with 215 additions and 188 deletions.
16 changes: 9 additions & 7 deletions .github/workflows/pyinstaller-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@
name: Build executeable

env:
semver: 1.4.0.${{ github.run_number }}
semver: 1.5.0.${{ github.run_number }}
python-version: 3.8
KIVY_GL_BACKEND: 'angle_sdl2'

on:
pull_request:
Expand All @@ -17,6 +18,7 @@ jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [windows-2019, macos-10.15]
include:
Expand All @@ -25,7 +27,7 @@ jobs:
short-name: win
move-command: move
- os: macos-10.15
exe-extension:
exe-extension: .app
short-name: osx
move-command: mv
steps:
Expand All @@ -41,16 +43,16 @@ jobs:
- name: Run Tests
run: |
python -m unittest discover test "*_test.py"
- name: Build GUI executable
run: |
pyinstaller radio_sync_gui_${{ matrix.short-name }}.spec
${{ matrix.move-command }} dist/radio_sync_gui${{ matrix.exe-extension }} radio_sync-${{ matrix.short-name }}_gui-${{ env.semver }}${{ matrix.exe-extension }}
7z a -tzip radio_sync-${{ matrix.short-name }}-${{ env.semver }}.zip radio_sync-${{ matrix.short-name }}_gui-${{ env.semver }}${{ matrix.exe-extension }}
- name: Build CLI executable
run: |
pyinstaller -F radio_sync.py -n radio_sync-${{ matrix.short-name }}-${{ env.semver }}${{ matrix.exe-extension }}
${{ matrix.move-command }} dist/radio_sync-${{ matrix.short-name }}-${{ env.semver }}${{ matrix.exe-extension }} ./
7z a -tzip radio_sync-${{ matrix.short-name }}-${{ env.semver }}.zip radio_sync-${{ matrix.short-name }}-${{ env.semver }}${{ matrix.exe-extension }}
- name: Build GUI executable
run: |
pyinstaller -w -F radio_sync_gui.py -n radio_sync-${{ matrix.short-name }}_gui-${{ env.semver }}${{ matrix.exe-extension }}
${{ matrix.move-command }} dist/radio_sync-${{ matrix.short-name }}_gui-${{ env.semver }}${{ matrix.exe-extension }} ./
7z a -tzip radio_sync-${{ matrix.short-name }}-${{ env.semver }}.zip radio_sync-${{ matrix.short-name }}_gui-${{ env.semver }}${{ matrix.exe-extension }}
- name: Upload executable
id: upload_executable
uses: actions/upload-artifact@v2
Expand Down
33 changes: 33 additions & 0 deletions radio_sync_gui_osx.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# -*- mode: python ; coding: utf-8 -*-

block_cipher = None


a = Analysis(['radio_sync_gui.py'],
pathex=['C:\\Users\\***REMOVED***\\dev\\radio_sync'],
binaries=[],
datas=[],
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)
exe = EXE(pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
[],
name='radio_sync_gui.app',
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
upx_exclude=[],
runtime_tmpdir=None,
console=True )
35 changes: 35 additions & 0 deletions radio_sync_gui_win.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# -*- mode: python ; coding: utf-8 -*-
from kivy_deps import sdl2, glew

block_cipher = None


a = Analysis(['radio_sync_gui.py'],
pathex=['C:\\Users\\***REMOVED***\\dev\\radio_sync'],
binaries=[],
datas=[],
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)
exe = EXE(pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
*[Tree(p) for p in (sdl2.dep_bins + glew.dep_bins)],
[],
name='radio_sync_gui',
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
upx_exclude=[],
runtime_tmpdir=None,
console=False )
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
openpyxl == 3.0.7 #xlsx support
pyinstaller == 4.2 #compilation
pysimplegui == 4.38.0 #gui
Kivy == 2.0.0 #gui
Loading

0 comments on commit b148a79

Please sign in to comment.