Add downloads for packaged versions for various OS's #37
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build MacOS | |
on: [push] | |
env: | |
KIVY_GL_BACKEND: angle_sdl2 | |
# https://github.com/Alb-310/Geogramint/issues/8#issuecomment-1366548008 | |
jobs: | |
Build-MacOS: | |
runs-on: macos-latest | |
# runs-on: macos-13 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: setup python | |
uses: actions/setup-python@v5 | |
with: | |
# python-version: "3.x" | |
python-version: "3.12" | |
- name: macos - build dependacies | |
# run: brew reinstall --build-from-source sdl2 sdl2_image sdl2_ttf sdl2_mixer | |
run: brew reinstall sdl2 sdl2_image sdl2_ttf sdl2_mixer | |
- name: install pip packages - macos | |
run: pip install -r build_requirements/pip_requirements-macos.txt | |
- name: install pip packages - kivy | |
run: pip install -r build_requirements/pip_requirements.txt | |
- name: copy spec file | |
run: cp build_requirements/ImgSplitter-macos-onefile.spec.src ImgSplitter.spec | |
# - name: build | |
# run: python -m PyInstaller --name ImgSplitter src/main.py | |
# run: python -m PyInstaller --onefile --name ImgSplitter src/main.py | |
# python -m PyInstaller --name ImgSplitter --icon path/to/icon.ico src/main.py | |
# - name: generate spec | |
# # run: pyinstaller -y --clean --windowed --name ImgSplitter --exclude-module _tkinter --exclude-module Tkinter --exclude-module enchant --exclude-module twisted --target-arch universal2 src/main.py | |
# # run: pyinstaller -y --clean --windowed --name ImgSplitter --exclude-module _tkinter --exclude-module Tkinter --exclude-module enchant --exclude-module twisted --target-arch x86_64 src/main.py | |
# run: pyinstaller -y --clean --windowed --name ImgSplitter --exclude-module _tkinter --exclude-module Tkinter --exclude-module enchant --exclude-module twisted --target-arch arm64 src/main.py | |
# | |
# - name: Archive Manager spec | |
# uses: actions/upload-artifact@v4 | |
# with: | |
# name: spec-macos | |
# path: ImgSplitter.spec | |
# --target-architecture ARCH, --target-arch ARCH | |
# Target architecture (macOS only; valid values: x86_64, arm64, universal2). Enables switching between universal2 and single-arch version of frozen application (provided | |
# python installation supports the target architecture). If not target architecture is not specified, the current running architecture is targeted. | |
- name: build spec | |
# run: python -m PyInstaller ImgSplitter.spec | |
run: PyInstaller -y --clean ImgSplitter.spec | |
# run: PyInstaller -y --clean --target-arch universal2 ImgSplitter.spec | |
# run: pyinstaller -y --clean --windowed ImgSplitter.spec | |
- name: Archive Manager Build | |
uses: actions/upload-artifact@v4 | |
with: | |
name: build-macos | |
path: build | |
- name: Archive Manager dist | |
uses: actions/upload-artifact@v4 | |
with: | |
name: dist-macos | |
path: dist | |
- name: Create DMG File | |
# run: | |
# pushd dist | |
# hdiutil create ./ImgSplitter.dmg -srcfolder ImgSplitter.app -ov | |
# popd | |
run: | |
hdiutil create ./ImgSplitter.dmg -srcfolder dist/ImgSplitter.app -ov | |
- name: Archive Manager dmg | |
uses: actions/upload-artifact@v4 | |
with: | |
name: dmg-macos | |
path: ImgSplitter.dmg |