From 932a4ddd81e1df3faa49a14e3872e789d278dce3 Mon Sep 17 00:00:00 2001 From: Michael Hansen Date: Wed, 27 Sep 2023 15:14:50 -0500 Subject: [PATCH] Add macos build --- .github/workflows/main.yml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index d1ac609..6e9d225 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -87,3 +87,35 @@ jobs: asset_path: _install/piper-phonemize_windows_amd64.zip asset_name: piper-phonemize_windows_amd64.zip asset_content_type: application/zip + build_macos: + runs-on: macos-latest + name: "mac build: ${{ matrix.arch }}" + needs: create_release # we need to know the upload URL + strategy: + fail-fast: true + matrix: + arch: [x64, aarch64] + steps: + - uses: actions/checkout@v3 + - name: configure + run: | + cmake -Bbuild -DCMAKE_INSTALL_PREFIX=_install/piper-phonemize + - name: build + run: | + cmake --build build --config Release + - name: install + run: | + cmake --install build + - name: package + run: | + cd _install && \ + tar -czf piper-phonemize_macos_${{ matrix.arch }}.tar.gz piper-phonemize/ + - name: upload + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ github.token }} + with: + upload_url: ${{ needs.create_release.outputs.upload_url }} + asset_path: _install/piper-phonemize_macos_${{ matrix.arch }}.tar.gz + asset_name: piper-phonemize_macos_${{ matrix.arch }}.tar.gz + asset_content_type: application/octet-stream