Skip to content

Commit

Permalink
Try to build both x64 and arm64 on macos-14
Browse files Browse the repository at this point in the history
  • Loading branch information
aliddell committed Jul 10, 2024
1 parent 6b84612 commit bdb5577
Showing 1 changed file with 55 additions and 55 deletions.
110 changes: 55 additions & 55 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,61 +9,7 @@ on:
- "main"

jobs:
mac-build:
strategy:
matrix:
build_type:
- "Debug"
- "Release"
platform:
- "macos-13"
- "macos-14"
include:
- platform: "macos-13"
vcpkg_triplet: "x64-osx"
- platform: "macos-14"
vcpkg_triplet: "arm64-osx"

runs-on: ${{matrix.platform}}

permissions:
actions: write

steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
with:
submodules: true

- name: Install vcpkg
run: |
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg && ./bootstrap-vcpkg.sh
echo "VCPKG_ROOT=${{github.workspace}}/vcpkg" >> $GITHUB_ENV
echo "${{github.workspace}}/vcpkg" >> $GITHUB_PATH
./vcpkg integrate install
shell: bash

- name: CMake
run: |
cmake --preset=default -DVCPKG_TARGET_TRIPLET=${{matrix.vcpkg_triplet}}
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{matrix.build_type}}
- name: Build
run: |
cmake --build ${{github.workspace}}/build --config ${{matrix.build_type}}
cpack --config ${{github.workspace}}/build/CPackConfig.cmake -C ${{matrix.build_type}} -G ZIP
- uses: actions/upload-artifact@v3
with:
name: ${{matrix.platform}} ${{matrix.build_type}} binaries
path: ${{github.workspace}}/*.zip

# build:
# windows-and-linux-build:
# strategy:
# matrix:
# build_type:
Expand Down Expand Up @@ -116,3 +62,57 @@ jobs:
# with:
# name: ${{matrix.platform}} ${{matrix.build_type}} binaries
# path: ${{github.workspace}}/*.zip

mac-build:
strategy:
matrix:
build_type:
- "Debug"
- "Release"
vcpkg_triplet:
- "x64-osx"
- "arm64-osx"
# include:
# - platform: "macos-13"
# vcpkg_triplet: "x64-osx"
# - platform: "macos-14"
# vcpkg_triplet: "arm64-osx"

runs-on: "macos-14"

permissions:
actions: write

steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
with:
submodules: true

- name: Install vcpkg
run: |
git clone https://github.com/microsoft/vcpkg.git
cd vcpkg && ./bootstrap-vcpkg.sh
echo "VCPKG_ROOT=${{github.workspace}}/vcpkg" >> $GITHUB_ENV
echo "${{github.workspace}}/vcpkg" >> $GITHUB_PATH
./vcpkg integrate install
shell: bash

- name: CMake
run: |
cmake --preset=default -DVCPKG_TARGET_TRIPLET=${{matrix.vcpkg_triplet}}
cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{matrix.build_type}}
- name: Build
run: |
cmake --build ${{github.workspace}}/build --config ${{matrix.build_type}}
cpack --config ${{github.workspace}}/build/CPackConfig.cmake -C ${{matrix.build_type}} -G ZIP
- uses: actions/upload-artifact@v3
with:
name: macos-latest ${{matrix.vcpkg_triplet}} ${{matrix.build_type}} binaries
path: ${{github.workspace}}/*.zip

0 comments on commit bdb5577

Please sign in to comment.