1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-12-27 16:31:31 +00:00

Update GitHub workflow: also build SDL UI on macOS

This commit is contained in:
Ryan Carsten Schmidt 2023-12-14 17:19:59 -06:00
parent def1f90d86
commit 8256500877

View File

@ -2,8 +2,11 @@ name: Build
on: [pull_request]
jobs:
build-mac:
name: Build Mac UI
runs-on: macos-latest
name: Mac UI on ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
@ -11,15 +14,38 @@ jobs:
working-directory: OSBindings/Mac
run: xcodebuild CODE_SIGN_IDENTITY=-
build-sdl:
name: Build SDL UI
runs-on: ubuntu-latest
name: SDL UI on ${{ matrix.os }}
strategy:
matrix:
os: [macos-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install dependencies
shell: bash
run: |
sudo apt-get --allow-releaseinfo-change update
sudo apt-get --fix-missing install gcc-10 libsdl2-dev scons
case $RUNNER_OS in
Linux)
sudo apt-get --allow-releaseinfo-change update
sudo apt-get --fix-missing install gcc-10 libsdl2-dev scons
;;
macOS)
brew install scons sdl2
;;
esac
- name: Make
working-directory: OSBindings/SDL
run: scons -j$(nproc --all)
shell: bash
run: |
case $RUNNER_OS in
Linux)
jobs=$(nproc --all)
;;
macOS)
jobs=$(sysctl -n hw.activecpu)
;;
*)
jobs=1
esac
scons -j"$jobs"