Skip to content

Commit

Permalink
build(macos): add build strategy matrix
Browse files Browse the repository at this point in the history
  • Loading branch information
ReenigneArcher committed Mar 4, 2024
1 parent 529f1b8 commit 8a0969b
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 10 deletions.
44 changes: 36 additions & 8 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -506,11 +506,23 @@ jobs:
prerelease: ${{ needs.setup_release.outputs.pre_release }}

build_mac:
name: MacOS
runs-on: macos-11
needs: [check_changelog, setup_release]
env:
BOOST_VERSION: 1.83.0
strategy:
fail-fast: false # false to test all, true to fail entire job if any fail
matrix:
include:
# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories
# while GitHub has larger macOS runners, they are not available for our repos :(
- os_version: "12"
arch: "x86_64"
- os_version: "13"
arch: "x86_64"
- os_version: "14"
arch: "arm64"
name: macOS-${{ matrix.os_version }} ${{ matrix.arch }}
runs-on: macos-${{ matrix.os_version }}

steps:
- name: Checkout
Expand Down Expand Up @@ -594,15 +606,17 @@ jobs:
# package
cpack -G DragNDrop
mv ./cpack_artifacts/Sunshine.dmg ../artifacts/sunshine.dmg
mv ./cpack_artifacts/Sunshine.dmg \
../artifacts/sunshine-macos-${{ matrix.os_version }}-${{ matrix.arch }}.dmg
# cpack -G Bundle
# mv ./cpack_artifacts/Sunshine.dmg ../artifacts/sunshine-bundle.dmg
# mv ./cpack_artifacts/Sunshine.dmg \
../artifacts/sunshine-macos-bundle-${{ matrix.os_version }}-${{ matrix.arch }}.dmg
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: sunshine-macos
name: sunshine-macos-${{ matrix.os_version }}-${{ matrix.arch }}
path: artifacts/

- name: Create/Update GitHub Release
Expand All @@ -620,9 +634,22 @@ jobs:
prerelease: ${{ needs.setup_release.outputs.pre_release }}

build_mac_port:
name: Macports
needs: [check_changelog, setup_release]
runs-on: macos-11
strategy:
fail-fast: false # false to test all, true to fail entire job if any fail
matrix:
include:
# https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories
# while GitHub has larger macOS runners, they are not available for our repos :(
- os_version: "12"
arch: "x86_64"
release: true
- os_version: "13"
arch: "x86_64"
- os_version: "14"
arch: "arm64"
name: Macports (macOS-${{ matrix.os_version }} ${{ matrix.arch }})
runs-on: macos-${{ matrix.os_version }}

steps:
- name: Checkout
Expand Down Expand Up @@ -725,13 +752,14 @@ jobs:
echo "::endgroup::"
- name: Upload Artifacts
if: ${{ matrix.release == 'true' }}
uses: actions/upload-artifact@v4
with:
name: sunshine-macports
path: artifacts/

- name: Create/Update GitHub Release
if: ${{ needs.setup_release.outputs.create_release == 'true' }}
if: ${{ needs.setup_release.outputs.create_release == 'true' && matrix.release == 'true' }}
uses: ncipollo/release-action@v1
with:
name: ${{ needs.setup_release.outputs.release_name }}
Expand Down
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ System Requirements
+------------+------------------------------------------------------------+
| OS | Windows: 10+ (Windows Server not supported) |
| +------------------------------------------------------------+
| | macOS: 11.7+ |
| | macOS: 12+ |
| +------------------------------------------------------------+
| | Linux/Debian: 11 (bullseye) |
| +------------------------------------------------------------+
| | Linux/Fedora: 37+ |
| | Linux/Fedora: 38+ |
| +------------------------------------------------------------+
| | Linux/Ubuntu: 20.04+ (focal) |
+------------+------------------------------------------------------------+
Expand Down

0 comments on commit 8a0969b

Please sign in to comment.