-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Stephen Gutekanst <[email protected]>
- Loading branch information
Showing
1 changed file
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
name: CI | ||
on: | ||
pull_request: | ||
paths-ignore: | ||
- "**.md" | ||
jobs: | ||
all: | ||
strategy: | ||
matrix: | ||
target: [ | ||
'x86_64-linux-gnu', | ||
'x86_64-linux-musl', | ||
'aarch64-linux-gnu', | ||
'aarch64-linux-musl', | ||
'x86_64-windows-gnu', | ||
'aarch64-windows-gnu', | ||
'x86_64-macos-none', | ||
'aarch64-macos-none', | ||
] | ||
optimize: [Debug, ReleaseFast] | ||
include: | ||
- target: 'x86_64-linux-gnu' | ||
cpu: '-Dcpu=x86_64_v2' | ||
- target: 'x86_64-linux-musl' | ||
cpu: '-Dcpu=x86_64_v2' | ||
- target: 'x86_64-windows-gnu' | ||
cpu: '-Dcpu=x86_64_v2' | ||
- target: 'x86_64-macos-none' | ||
cpu: '-Dcpu=x86_64_v2' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Setup Zig | ||
run: | | ||
sudo apt install xz-utils | ||
sudo sh -c 'wget -c https://pkg.machengine.org/zig/zig-linux-x86_64-0.14.0-dev.1710+8ee52f99c.tar.xz -O - | tar -xJ --strip-components=1 -C /usr/local/bin' | ||
- name: build | ||
run: zig build -Dfrom_source -Dtarget=${{ matrix.target }} -Doptimize=${{ matrix.optimize }} ${{ matrix.cpu }} install dxc | ||
msvc: | ||
# TODO: re-enable required MSVC builds | ||
continue-on-error: true | ||
strategy: | ||
matrix: | ||
target: [ | ||
'x86_64-windows-msvc', | ||
# TODO: 'machine type x64 conflicts with arm64' during linking (zig bug) | ||
# 'aarch64-windows-msvc', | ||
] | ||
optimize: [Debug, ReleaseFast] | ||
include: | ||
- target: 'x86_64-windows-msvc' | ||
cpu: '-Dcpu=x86_64_v2' | ||
runs-on: windows-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Setup Zig | ||
run: | | ||
$ProgressPreference = 'SilentlyContinue' | ||
Invoke-WebRequest -Uri "https://pkg.machengine.org/zig/zig-windows-x86_64-0.14.0-dev.1710+8ee52f99c.zip" -OutFile "C:\zig.zip" | ||
cd C:\ | ||
7z x zig.zip | ||
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.14.0-dev.1710+8ee52f99c\" | ||
- name: build | ||
run: zig build -Dfrom_source -Dtarget=${{ matrix.target }} -Doptimize=${{ matrix.optimize }} ${{ matrix.cpu }} install dxc |