From c130c0c239a9faa9aa40f9a2b74dfef1db9a90c8 Mon Sep 17 00:00:00 2001 From: Xie Zicong Date: Mon, 30 Sep 2024 19:20:16 +0800 Subject: [PATCH] Update build-release.yml --- .github/workflows/build-release.yml | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-release.yml b/.github/workflows/build-release.yml index b0c1242..6572684 100644 --- a/.github/workflows/build-release.yml +++ b/.github/workflows/build-release.yml @@ -12,7 +12,7 @@ jobs: fail-fast: false matrix: os: [ubuntu-latest, windows-latest, macos-latest] - arch: [x86, x64] + arch: [x86, x64, arm64] include: - os: ubuntu-latest arch: x86 @@ -22,6 +22,10 @@ jobs: arch: x64 c_compiler: gcc cpp_compiler: g++ + - os: ubuntu-latest + arch: arm64 + c_compiler: gcc + cpp_compiler: g++ - os: windows-latest arch: x86 c_compiler: cl @@ -30,6 +34,10 @@ jobs: arch: x64 c_compiler: cl cpp_compiler: cl + - os: windows-latest + arch: arm64 + c_compiler: cl + cpp_compiler: cl - os: macos-latest arch: x86 c_compiler: clang @@ -38,6 +46,10 @@ jobs: arch: x64 c_compiler: clang cpp_compiler: clang++ + - os: macos-latest + arch: arm64 + c_compiler: clang + cpp_compiler: clang++ steps: - uses: actions/checkout@v3 @@ -58,17 +70,17 @@ jobs: - name: Compress Release Asset (Ubuntu) if: matrix.os == 'ubuntu-latest' run: | - zip -r aq-${{ github.event.release.tag_name }}-${{ matrix.os }}-${{ matrix.arch }}.zip build + zip -r aq-${{ github.event.release.tag_name }}-${{ matrix.os/'-latest'/'' }}-${{ matrix.arch }}.zip build - name: Compress Release Asset (Windows) if: matrix.os == 'windows-latest' run: | - powershell Compress-Archive -Path build\* -DestinationPath aq-${{ github.event.release.tag_name }}-${{ matrix.os }}-${{ matrix.arch }}.zip + powershell Compress-Archive -Path build\* -DestinationPath aq-${{ github.event.release.tag_name }}-${{ matrix.os/'-latest'/'' }}-${{ matrix.arch }}.zip - name: Compress Release Asset (macOS) if: matrix.os == 'macos-latest' run: | - zip -r aq-${{ github.event.release.tag_name }}-${{ matrix.os }}-${{ matrix.arch }}.zip build + zip -r aq-${{ github.event.release.tag_name }}-${{ matrix.os/'-latest'/'' }}-${{ matrix.arch }}.zip build - name: Upload Release Asset uses: actions/upload-release-asset@v1 @@ -76,6 +88,6 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: upload_url: ${{ github.event.release.upload_url }} - asset_path: aq-${{ github.event.release.tag_name }}-${{ matrix.os }}-${{ matrix.arch }}.zip - asset_name: aq-${{ github.event.release.tag_name }}-${{ matrix.os }}-${{ matrix.arch }} + asset_path: aq-${{ github.event.release.tag_name }}-${{ matrix.os/'-latest'/'' }}-${{ matrix.arch }}.zip + asset_name: aq-${{ github.event.release.tag_name }}-${{ matrix.os/'-latest'/'' }}-${{ matrix.arch }}.zip asset_content_type: application/zip