| author | |
| committer | |
| log | e07ad33f1d3f7fd48baa81b9eeeffb9b7315df9e |
| tree | dc615fa1619b8d0cdda11197e4f2a5f1400e7b99 |
| parent | f6f0fefd8b69c0cc7d73317ca7295df50eae5fa0 |
Also makes the windows CI scripts fetch the tarballs from the network if
not already on disk.11 files changed, 45 insertions(+), 12 deletions(-)
.github/workflows/ci.yaml+1| ... | @@ -4,6 +4,7 @@ on: | ... | @@ -4,6 +4,7 @@ on: |
| 4 | push: | 4 | push: |
| 5 | branches: | 5 | branches: |
| 6 | - master | 6 | - master |
| 7 | - llvm18 | ||
| 7 | concurrency: | 8 | concurrency: |
| 8 | # Cancels pending runs when a PR gets updated. | 9 | # Cancels pending runs when a PR gets updated. |
| 9 | group: ${{ github.head_ref || github.run_id }}-${{ github.actor }} | 10 | group: ${{ github.head_ref || github.run_id }}-${{ github.actor }} |
ci/aarch64-linux-debug.sh+1-1| ... | @@ -8,7 +8,7 @@ set -e | ... | @@ -8,7 +8,7 @@ set -e |
| 8 | ARCH="$(uname -m)" | 8 | ARCH="$(uname -m)" |
| 9 | TARGET="$ARCH-linux-musl" | 9 | TARGET="$ARCH-linux-musl" |
| 10 | MCPU="baseline" | 10 | MCPU="baseline" |
| 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.203+d3bc1cfc4" | 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" | 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" |
| 13 | ZIG="$PREFIX/bin/zig" | 13 | ZIG="$PREFIX/bin/zig" |
| 14 | 14 |
ci/aarch64-linux-release.sh+1-1| ... | @@ -8,7 +8,7 @@ set -e | ... | @@ -8,7 +8,7 @@ set -e |
| 8 | ARCH="$(uname -m)" | 8 | ARCH="$(uname -m)" |
| 9 | TARGET="$ARCH-linux-musl" | 9 | TARGET="$ARCH-linux-musl" |
| 10 | MCPU="baseline" | 10 | MCPU="baseline" |
| 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.203+d3bc1cfc4" | 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" | 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" |
| 13 | ZIG="$PREFIX/bin/zig" | 13 | ZIG="$PREFIX/bin/zig" |
| 14 | 14 |
ci/aarch64-macos-debug.sh+1-1| ... | @@ -9,7 +9,7 @@ set -e | ... | @@ -9,7 +9,7 @@ set -e |
| 9 | ZIGDIR="$PWD" | 9 | ZIGDIR="$PWD" |
| 10 | TARGET="$ARCH-macos-none" | 10 | TARGET="$ARCH-macos-none" |
| 11 | MCPU="baseline" | 11 | MCPU="baseline" |
| 12 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.467+0345d7866" | 12 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 13 | PREFIX="$HOME/$CACHE_BASENAME" | 13 | PREFIX="$HOME/$CACHE_BASENAME" |
| 14 | ZIG="$PREFIX/bin/zig" | 14 | ZIG="$PREFIX/bin/zig" |
| 15 | 15 |
ci/aarch64-macos-release.sh+1-1| ... | @@ -9,7 +9,7 @@ set -e | ... | @@ -9,7 +9,7 @@ set -e |
| 9 | ZIGDIR="$PWD" | 9 | ZIGDIR="$PWD" |
| 10 | TARGET="$ARCH-macos-none" | 10 | TARGET="$ARCH-macos-none" |
| 11 | MCPU="baseline" | 11 | MCPU="baseline" |
| 12 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.467+0345d7866" | 12 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 13 | PREFIX="$HOME/$CACHE_BASENAME" | 13 | PREFIX="$HOME/$CACHE_BASENAME" |
| 14 | ZIG="$PREFIX/bin/zig" | 14 | ZIG="$PREFIX/bin/zig" |
| 15 | 15 |
ci/aarch64-windows.ps1+1-1| ... | @@ -1,5 +1,5 @@ | ... | @@ -1,5 +1,5 @@ |
| 1 | $TARGET = "$($Env:ARCH)-windows-gnu" | 1 | $TARGET = "$($Env:ARCH)-windows-gnu" |
| 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.12.0-dev.2087+e9a18010b" | 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 3 | $MCPU = "baseline" | 3 | $MCPU = "baseline" |
| 4 | $ZIG_LLVM_CLANG_LLD_URL = "https://ziglang.org/deps/$ZIG_LLVM_CLANG_LLD_NAME.zip" | 4 | $ZIG_LLVM_CLANG_LLD_URL = "https://ziglang.org/deps/$ZIG_LLVM_CLANG_LLD_NAME.zip" |
| 5 | $PREFIX_PATH = "$(Get-Location)\..\$ZIG_LLVM_CLANG_LLD_NAME" | 5 | $PREFIX_PATH = "$(Get-Location)\..\$ZIG_LLVM_CLANG_LLD_NAME" |
ci/x86_64-linux-debug.sh+1-1| ... | @@ -8,7 +8,7 @@ set -e | ... | @@ -8,7 +8,7 @@ set -e |
| 8 | ARCH="$(uname -m)" | 8 | ARCH="$(uname -m)" |
| 9 | TARGET="$ARCH-linux-musl" | 9 | TARGET="$ARCH-linux-musl" |
| 10 | MCPU="baseline" | 10 | MCPU="baseline" |
| 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.203+d3bc1cfc4" | 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" | 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" |
| 13 | ZIG="$PREFIX/bin/zig" | 13 | ZIG="$PREFIX/bin/zig" |
| 14 | 14 |
ci/x86_64-linux-release.sh+1-1| ... | @@ -8,7 +8,7 @@ set -e | ... | @@ -8,7 +8,7 @@ set -e |
| 8 | ARCH="$(uname -m)" | 8 | ARCH="$(uname -m)" |
| 9 | TARGET="$ARCH-linux-musl" | 9 | TARGET="$ARCH-linux-musl" |
| 10 | MCPU="baseline" | 10 | MCPU="baseline" |
| 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.203+d3bc1cfc4" | 11 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" | 12 | PREFIX="$HOME/deps/$CACHE_BASENAME" |
| 13 | ZIG="$PREFIX/bin/zig" | 13 | ZIG="$PREFIX/bin/zig" |
| 14 | 14 |
ci/x86_64-macos-release.sh+1-1| ... | @@ -6,7 +6,7 @@ set -e | ... | @@ -6,7 +6,7 @@ set -e |
| 6 | ZIGDIR="$PWD" | 6 | ZIGDIR="$PWD" |
| 7 | TARGET="$ARCH-macos-none" | 7 | TARGET="$ARCH-macos-none" |
| 8 | MCPU="baseline" | 8 | MCPU="baseline" |
| 9 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.12.0-dev.467+0345d7866" | 9 | CACHE_BASENAME="zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 10 | PREFIX="$HOME/$CACHE_BASENAME" | 10 | PREFIX="$HOME/$CACHE_BASENAME" |
| 11 | JOBS="-j3" | 11 | JOBS="-j3" |
| 12 | 12 |
ci/x86_64-windows-debug.ps1+18-2| ... | @@ -1,10 +1,20 @@ | ... | @@ -1,10 +1,20 @@ |
| 1 | $TARGET = "$($Env:ARCH)-windows-gnu" | 1 | $TARGET = "$($Env:ARCH)-windows-gnu" |
| 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.12.0-dev.2073+402fe565a" | 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 3 | $MCPU = "baseline" | 3 | $MCPU = "baseline" |
| 4 | $PREFIX_PATH = "$($Env:USERPROFILE)\$ZIG_LLVM_CLANG_LLD_NAME" | 4 | $ZIG_LLVM_CLANG_LLD_URL = "https://ziglang.org/deps/$ZIG_LLVM_CLANG_LLD_NAME.zip" |
| 5 | $PREFIX_PATH = "$(Get-Location)\..\$ZIG_LLVM_CLANG_LLD_NAME" | ||
| 5 | $ZIG = "$PREFIX_PATH\bin\zig.exe" | 6 | $ZIG = "$PREFIX_PATH\bin\zig.exe" |
| 6 | $ZIG_LIB_DIR = "$(Get-Location)\lib" | 7 | $ZIG_LIB_DIR = "$(Get-Location)\lib" |
| 7 | 8 | ||
| 9 | if (!(Test-Path "..\$ZIG_LLVM_CLANG_LLD_NAME.zip")) { | ||
| 10 | Write-Output "Downloading $ZIG_LLVM_CLANG_LLD_URL" | ||
| 11 | Invoke-WebRequest -Uri "$ZIG_LLVM_CLANG_LLD_URL" -OutFile "..\$ZIG_LLVM_CLANG_LLD_NAME.zip" | ||
| 12 | |||
| 13 | Write-Output "Extracting..." | ||
| 14 | Add-Type -AssemblyName System.IO.Compression.FileSystem ; | ||
| 15 | [System.IO.Compression.ZipFile]::ExtractToDirectory("$PWD\..\$ZIG_LLVM_CLANG_LLD_NAME.zip", "$PWD\..") | ||
| 16 | } | ||
| 17 | |||
| 8 | function CheckLastExitCode { | 18 | function CheckLastExitCode { |
| 9 | if (!$?) { | 19 | if (!$?) { |
| 10 | exit 1 | 20 | exit 1 |
| ... | @@ -25,6 +35,12 @@ Remove-Item -Path 'build-debug' -Recurse -Force -ErrorAction Ignore | ... | @@ -25,6 +35,12 @@ Remove-Item -Path 'build-debug' -Recurse -Force -ErrorAction Ignore |
| 25 | New-Item -Path 'build-debug' -ItemType Directory | 35 | New-Item -Path 'build-debug' -ItemType Directory |
| 26 | Set-Location -Path 'build-debug' | 36 | Set-Location -Path 'build-debug' |
| 27 | 37 | ||
| 38 | # Override the cache directories because they won't actually help other CI runs | ||
| 39 | # which will be testing alternate versions of zig, and ultimately would just | ||
| 40 | # fill up space on the hard drive for no reason. | ||
| 41 | $Env:ZIG_GLOBAL_CACHE_DIR="$(Get-Location)\zig-global-cache" | ||
| 42 | $Env:ZIG_LOCAL_CACHE_DIR="$(Get-Location)\zig-local-cache" | ||
| 43 | |||
| 28 | # CMake gives a syntax error when file paths with backward slashes are used. | 44 | # CMake gives a syntax error when file paths with backward slashes are used. |
| 29 | # Here, we use forward slashes only to work around this. | 45 | # Here, we use forward slashes only to work around this. |
| 30 | & cmake .. ` | 46 | & cmake .. ` |
ci/x86_64-windows-release.ps1+18-2| ... | @@ -1,10 +1,20 @@ | ... | @@ -1,10 +1,20 @@ |
| 1 | $TARGET = "$($Env:ARCH)-windows-gnu" | 1 | $TARGET = "$($Env:ARCH)-windows-gnu" |
| 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.12.0-dev.2073+402fe565a" | 2 | $ZIG_LLVM_CLANG_LLD_NAME = "zig+llvm+lld+clang-$TARGET-0.13.0-dev.69+c8b808826" |
| 3 | $MCPU = "baseline" | 3 | $MCPU = "baseline" |
| 4 | $PREFIX_PATH = "$($Env:USERPROFILE)\$ZIG_LLVM_CLANG_LLD_NAME" | 4 | $ZIG_LLVM_CLANG_LLD_URL = "https://ziglang.org/deps/$ZIG_LLVM_CLANG_LLD_NAME.zip" |
| 5 | $PREFIX_PATH = "$(Get-Location)\..\$ZIG_LLVM_CLANG_LLD_NAME" | ||
| 5 | $ZIG = "$PREFIX_PATH\bin\zig.exe" | 6 | $ZIG = "$PREFIX_PATH\bin\zig.exe" |
| 6 | $ZIG_LIB_DIR = "$(Get-Location)\lib" | 7 | $ZIG_LIB_DIR = "$(Get-Location)\lib" |
| 7 | 8 | ||
| 9 | if (!(Test-Path "..\$ZIG_LLVM_CLANG_LLD_NAME.zip")) { | ||
| 10 | Write-Output "Downloading $ZIG_LLVM_CLANG_LLD_URL" | ||
| 11 | Invoke-WebRequest -Uri "$ZIG_LLVM_CLANG_LLD_URL" -OutFile "..\$ZIG_LLVM_CLANG_LLD_NAME.zip" | ||
| 12 | |||
| 13 | Write-Output "Extracting..." | ||
| 14 | Add-Type -AssemblyName System.IO.Compression.FileSystem ; | ||
| 15 | [System.IO.Compression.ZipFile]::ExtractToDirectory("$PWD\..\$ZIG_LLVM_CLANG_LLD_NAME.zip", "$PWD\..") | ||
| 16 | } | ||
| 17 | |||
| 8 | function CheckLastExitCode { | 18 | function CheckLastExitCode { |
| 9 | if (!$?) { | 19 | if (!$?) { |
| 10 | exit 1 | 20 | exit 1 |
| ... | @@ -25,6 +35,12 @@ Remove-Item -Path 'build-release' -Recurse -Force -ErrorAction Ignore | ... | @@ -25,6 +35,12 @@ Remove-Item -Path 'build-release' -Recurse -Force -ErrorAction Ignore |
| 25 | New-Item -Path 'build-release' -ItemType Directory | 35 | New-Item -Path 'build-release' -ItemType Directory |
| 26 | Set-Location -Path 'build-release' | 36 | Set-Location -Path 'build-release' |
| 27 | 37 | ||
| 38 | # Override the cache directories because they won't actually help other CI runs | ||
| 39 | # which will be testing alternate versions of zig, and ultimately would just | ||
| 40 | # fill up space on the hard drive for no reason. | ||
| 41 | $Env:ZIG_GLOBAL_CACHE_DIR="$(Get-Location)\zig-global-cache" | ||
| 42 | $Env:ZIG_LOCAL_CACHE_DIR="$(Get-Location)\zig-local-cache" | ||
| 43 | |||
| 28 | # CMake gives a syntax error when file paths with backward slashes are used. | 44 | # CMake gives a syntax error when file paths with backward slashes are used. |
| 29 | # Here, we use forward slashes only to work around this. | 45 | # Here, we use forward slashes only to work around this. |
| 30 | & cmake .. ` | 46 | & cmake .. ` |