Update sdl2 version and add Python 3.12 to supported matrix #91
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: macOS Test | |
on: | |
push: | |
paths: | |
- 'osx/**' | |
- '.github/workflows/test_macos.yaml' | |
pull_request: | |
paths: | |
- 'osx/**' | |
- '.github/workflows/test_macos.yaml' | |
jobs: | |
build_dmg: | |
runs-on: ${{ matrix.runs_on }} | |
strategy: | |
matrix: | |
include: | |
- runs_on: macos-11 | |
python: 3.9 | |
- runs_on: apple-silicon-m1 | |
python: 3.9.7 | |
name: macOS build dmg ( ${{ matrix.runs_on }} ) | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.x | |
# Needs to be skipped on our self-hosted runners tagged as 'apple-silicon-m1' | |
if: ${{ matrix.runs_on != 'apple-silicon-m1' }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python }} | |
- name: Install Platypus | |
run: | | |
source ci/osx_ci.sh | |
arm64_set_path_and_python_version ${{ matrix.python }} | |
install_platypus | |
- name: Create macOS App Bundle with extras [dev] | |
run: | | |
source ci/osx_ci.sh | |
arm64_set_path_and_python_version ${{ matrix.python }} | |
cd osx | |
./create-osx-bundle.sh -e "dev" | |
- name: Test Fix bundle metadata | |
run: | | |
source ci/osx_ci.sh | |
arm64_set_path_and_python_version ${{ matrix.python }} | |
cd osx | |
./fix-bundle-metadata.sh build/Kivy.app -v "1.2.3" | |
./fix-bundle-metadata.sh build/Kivy.app -v "master" | |
- name: Test Relocation | |
run: | | |
source ci/osx_ci.sh | |
arm64_set_path_and_python_version ${{ matrix.python }} | |
cd osx | |
./relocate.sh build/Kivy.app | |
- name: Test dmg creation and store it in osx_artifacts | |
run: | | |
source ci/osx_ci.sh | |
arm64_set_path_and_python_version ${{ matrix.python }} | |
cd osx | |
./create-osx-dmg.sh build/Kivy.app Kivy | |
cd .. | |
mkdir osx_artifacts | |
mv osx/Kivy.dmg osx_artifacts/${{ matrix.runs_on }}-Kivy.dmg | |
- name: Upload dmg as artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: KivySDKPackager | |
path: osx_artifacts | |
test_dmg: | |
needs: build_dmg | |
runs-on: ${{ matrix.runs_on }} | |
strategy: | |
matrix: | |
runs_on: [macos-11, apple-silicon-m1] | |
name: macOS test dmg ( ${{ matrix.runs_on }} ) | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Download dmg from artifacts | |
uses: actions/download-artifact@v2 | |
with: | |
name: KivySDKPackager | |
path: osx_artifacts | |
- name: Mount build from macos-11 runner on Apple Silicon runner | |
if: ${{ matrix.runs_on == 'apple-silicon-m1' }} | |
run: hdiutil attach osx_artifacts/macos-11-Kivy.dmg -mountroot . | |
- name: Mount build from Apple Silicon runner on macos-11 runner | |
if: ${{ matrix.runs_on != 'apple-silicon-m1' }} | |
run: hdiutil attach osx_artifacts/apple-silicon-m1-Kivy.dmg -mountroot . | |
- name: Copy Kivy.app to Applications | |
run: cp -R Kivy/Kivy.app /Applications/Kivy.app | |
- name: Activate Kivy.app venv and test kivy | |
run: | | |
source ci/osx_ci.sh | |
activate_app_venv_and_test_kivy |