Skip to content

Commit a0be1dd

Browse files
committed
测试
1 parent 28ec23e commit a0be1dd

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

.github/workflows/build.yml

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ jobs:
1616
include:
1717
- { os: ubuntu-latest, target: linux, platform: linux-x64,}
1818
- { os: macos-latest, target: darwin, platform: darwin-x64,}
19-
- { os: macos-latest, target: darwin, platform: darwin-arm64, cmake: "-DCMAKE_OSX_ARCHITECTURES=x86_64;arm64"}
20-
- { os: windows-latest, target: windows, platform: win32-x64, cmake: "-DCMAKE_USER_MAKE_RULES_OVERRIDE=${{ github.workspace }}/cmake/flags_override.cmake" }
19+
- { os: macos-latest, target: darwin, platform: darwin-arm64}
20+
- { os: windows-latest, target: windows, platform: win32-x64 }
2121
steps:
2222
- uses: actions/checkout@v2
2323
with:
@@ -30,12 +30,17 @@ jobs:
3030
echo "CXX=g++-11" >> $GITHUB_ENV
3131
- name: Build-Release
3232
run: |
33-
mkdir build
34-
cd build
35-
cmake .. ${{ matrix.cmake }}
36-
cmake --build . --config Release
37-
ctest -V -C Release
38-
cmake --install . --config Release --prefix ${{ github.workspace }}/artifact/
33+
mkdir build
34+
cd build
35+
if [[ "${{ matrix.platform }}" = darwin-arm64 ]]; then
36+
cmake .. -DCMAKE_OSX_ARCHITECTURES="x86_64;arm64"
37+
else
38+
cmake .. -DCMAKE_USER_MAKE_RULES_OVERRIDE="${{ github.workspace }}/cmake/flags_override.cmake"
39+
fi
40+
cmake --build . --config Release
41+
ctest -V -C Release
42+
cmake --install . --config Release --prefix ${{ github.workspace }}/artifact/
43+
3944
- name: Upload
4045
uses: actions/upload-artifact@v2
4146
with:

0 commit comments

Comments
 (0)