2022-08-31 13:28:46 +03:00
|
|
|
on: [pull_request]
|
|
|
|
|
|
|
|
name: Test windows build
|
|
|
|
|
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
|
|
|
env:
|
|
|
|
RUST_BACKTRACE: 1
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
windows-cargo-build:
|
|
|
|
name: windows-cargo-build
|
|
|
|
runs-on: windows-2022
|
2022-08-31 17:24:05 +03:00
|
|
|
env:
|
2022-08-31 18:38:03 +03:00
|
|
|
LLVM_SYS_130_PREFIX: "C:/LLVM-13.0.0-win64"
|
2022-08-31 13:28:46 +03:00
|
|
|
timeout-minutes: 90
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
2022-09-05 18:22:39 +03:00
|
|
|
|
2022-09-05 18:26:54 +03:00
|
|
|
- run: $env:PATH | Format-Table -Wrap -AutoSize
|
2022-08-31 13:28:46 +03:00
|
|
|
|
2022-09-05 17:31:13 +03:00
|
|
|
- name: install visual studio build tools
|
|
|
|
run: |
|
|
|
|
curl.exe -L -O https://aka.ms/vs/17/release/vs_BuildTools.exe
|
2022-09-05 17:48:16 +03:00
|
|
|
dir
|
|
|
|
./vs_BuildTools.exe
|
2022-09-05 17:31:13 +03:00
|
|
|
|
2022-08-31 13:28:46 +03:00
|
|
|
- name: download and install zig
|
|
|
|
run: |
|
|
|
|
curl.exe --output "C:\zig-windows-x86_64-0.9.1.zip" --url https://ziglang.org/download/0.9.1/zig-windows-x86_64-0.9.1.zip
|
|
|
|
cd C:\
|
|
|
|
7z x zig-windows-x86_64-0.9.1.zip
|
|
|
|
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.9.1\"
|
|
|
|
|
|
|
|
- name: zig version
|
|
|
|
run: zig version
|
|
|
|
|
|
|
|
- name: set up llvm
|
|
|
|
run: |
|
2022-08-31 17:04:15 +03:00
|
|
|
curl.exe -L -O https://github.com/PLC-lang/llvm-package-windows/releases/download/v13.0.0/LLVM-13.0.0-win64.7z
|
2022-08-31 18:38:03 +03:00
|
|
|
7z x LLVM-13.0.0-win64.7z -oC:/LLVM-13.0.0-win64
|
2022-09-03 14:54:22 +03:00
|
|
|
@("C:/LLVM-13.0.0-win64/bin") + (Get-Content $env:GITHUB_PATH) | Set-Content $env:GITHUB_PATH
|
|
|
|
# ^^^ llvm bin path needs to be prepended and not appended to work
|
2022-09-03 15:29:36 +03:00
|
|
|
|
2022-09-03 13:00:01 +03:00
|
|
|
- name: build tests
|
|
|
|
run: cargo test --no-run --locked --release
|