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 74695f5
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 10 deletions.
55 changes: 47 additions & 8 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -506,11 +506,30 @@ 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:
- os_version: "12"
arch: "x86_64"
runner_suffix: ""
- os_version: "13"
arch: "x86_64"
runner_suffix: ""
- os_version: "13"
arch: "arm64"
runner_suffix: "-xlarge"
- os_version: "14"
arch: "x86_64"
runner_suffix: "-large"
- os_version: "14"
arch: "arm64"
runner_suffix: ""
name: macOS-${{ matrix.os_version }} ${{ matrix.arch }}
runs-on: macos-${{ matrix.os_version }}${{ matrix.runner_suffix }}

steps:
- name: Checkout
Expand Down Expand Up @@ -594,15 +613,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 +641,26 @@ 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:
- os_version: "12"
arch: "x86_64"
release: true
- os_version: "13"
arch: "x86_64"
- os_version: "13"
arch: "arm64"
runner_suffix: "-xlarge"
- os_version: "14"
arch: "x86_64"
runner_suffix: "-large"
- os_version: "14"
arch: "arm64"
name: Macports (macOS-${{ matrix.os_version }} ${{ matrix.arch }})
runs-on: macos-${{ matrix.os_version }}${{ matrix.runner_suffix }}

steps:
- name: Checkout
Expand Down Expand Up @@ -725,13 +763,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 74695f5

Please sign in to comment.