From 22a0d14168280d12259c7e65d0dceb377165cf1e Mon Sep 17 00:00:00 2001 From: danemadsen Date: Tue, 30 Jul 2024 14:46:37 +1000 Subject: [PATCH] macos actions --- .github/workflows/build-macos.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml index 94ab361..3ac265f 100644 --- a/.github/workflows/build-macos.yml +++ b/.github/workflows/build-macos.yml @@ -13,10 +13,10 @@ on: jobs: build: - runs-on: macos-latest + runs-on: ${{ matrix.os }} strategy: matrix: - arch: [x86_64, arm64] + os: [macos-13, macos-14] steps: - name: Checkout @@ -35,7 +35,7 @@ jobs: run: echo "CPU_CORES=$(sysctl -n hw.ncpu)" >> $GITHUB_ENV - name: Configure CMake - run: cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_OSX_ARCHITECTURES=${{ matrix.arch }} + run: cmake -B build -DCMAKE_BUILD_TYPE=Release - name: Build run: cmake --build build --config Release -- -j${{ env.CPU_CORES }} @@ -43,7 +43,7 @@ jobs: - name: Upload Build Artifacts uses: actions/upload-artifact@v3 with: - name: macos-${{ matrix.arch }} + name: ${{ matrix.os }} path: lib/ create-universal-dylibs: @@ -53,21 +53,21 @@ jobs: - name: Download x86_64 Build Artifacts uses: actions/download-artifact@v3 with: - name: macos-x86_64 - path: macos-x86_64 + name: macos-13 + path: macos-13 - name: Download arm64 Build Artifacts uses: actions/download-artifact@v3 with: - name: macos-arm64 - path: macos-arm64 + name: macos-14 + path: macos-14 - name: Create Universal dylibs run: | mkdir -p universal/lib - for dylib in macos-x86_64/*.dylib; do + for dylib in macos-13/*.dylib; do dylib_name=$(basename $dylib) - lipo -create macos-x86_64/$dylib_name macos-arm64/$dylib_name -output universal/$dylib_name + lipo -create macos-13/$dylib_name macos-14/$dylib_name -output universal/$dylib_name done - name: Upload Universal dylibs