|
12 | 12 | - { os: windows-latest, target: windows, platform: win32-x64} |
13 | 13 | - { os: windows-latest, target: windows, platform: win32-x86, cmake_arch: "-A Win32"} |
14 | 14 | - { os: ubuntu-latest, target: linux, platform: linux-x64} |
| 15 | + - { os: ubuntu-latest, target: linux, platform: linux-x64-zig, zig_build: true} |
15 | 16 | - { os: macos-latest, target: darwin, platform: darwin-x64} |
16 | 17 | - { os: macos-latest, target: darwin, platform: darwin-arm64} |
17 | 18 | steps: |
@@ -42,11 +43,22 @@ jobs: |
42 | 43 | - name: Build-linux |
43 | 44 | if: startsWith(matrix.os, 'ubuntu') |
44 | 45 | run: | |
45 | | - mkdir build |
46 | | - cd build |
47 | | - cmake .. -DCMAKE_BUILD_TYPE=Release -DEMMY_CORE_VERSION=${{env.TAG}} |
48 | | - cmake --build . --config Release |
49 | | - cmake --install . --config Release --prefix ${{ github.workspace }}/artifact/ |
| 46 | + if [[ "${{ matrix.zig_build }}" == "true" ]]; then |
| 47 | + wget https://ziglang.org/builds/zig-linux-x86_64-0.11.0.tar.xz |
| 48 | + tar -xf zig-linux-x86_64-0.11.0.tar.xz |
| 49 | + export PATH=$PWD/zig-linux-x86_64-0.11.0:$PATH |
| 50 | + mkdir build |
| 51 | + cd build |
| 52 | + CC="zig cc -target x86_64-linux-gnu.2.17" cmake .. -DCMAKE_BUILD_TYPE=Release -DEMMY_CORE_VERSION=${{env.TAG}} |
| 53 | + cmake --build . --config Release |
| 54 | + cmake --install . --config Release --prefix ${{ github.workspace }}/artifact/ |
| 55 | + else |
| 56 | + mkdir build |
| 57 | + cd build |
| 58 | + cmake .. -DCMAKE_BUILD_TYPE=Release -DEMMY_CORE_VERSION=${{env.TAG}} |
| 59 | + cmake --build . --config Release |
| 60 | + cmake --install . --config Release --prefix ${{ github.workspace }}/artifact/ |
| 61 | + fi |
50 | 62 | - name: Build-macosx |
51 | 63 | if: startsWith(matrix.os, 'macos') |
52 | 64 | run: | |
|
0 commit comments