Skip to content

Commit

Permalink
GH Actions: Specify zig version in a dedicated field
Browse files Browse the repository at this point in the history
Issue #602 (bdwgc).
  • Loading branch information
ivmai committed Jan 11, 2024
1 parent 749ee98 commit f9251a4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/zig-build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This workflow is for zig-based build/test running on Linux/x86_64.
name: zig build

on: [push, pull_request]
on: [ push, pull_request ]

jobs:
build:
Expand All @@ -13,6 +13,8 @@ jobs:
fail-fast: false

matrix:
# TODO: move from nightly to zig 0.12 final when released.
zig_version: [ "0.12.0-dev.2076+8fd15c6ca" ]
gc_assertions: [ true ]
large_config: [ false ]
enable_threads: [ false, true ]
Expand All @@ -36,12 +38,11 @@ jobs:
- enable_gc_debug: true # FIXME: some tests fail if gc_debug+redirect
redirect_malloc: true

# TODO: move from nightly to zig 0.12 final when released.
steps:
- uses: actions/checkout@v4
- name: "Install zig"
run: |
mkdir zig && curl https://ziglang.org/builds/zig-linux-x86_64-0.12.0-dev.2076+8fd15c6ca.tar.xz | tar Jx --directory=zig --strip-components=1
mkdir zig && curl https://ziglang.org/builds/zig-linux-x86_64-${{matrix.zig_version}}.tar.xz | tar Jx --directory=zig --strip-components=1
- name: Build
run: >
zig/zig build
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/zig-cross-compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ jobs:
strategy:
fail-fast: false
matrix:
# TODO: move from nightly to zig 0.12 final when released.
zig_version: [ "0.12.0-dev.2076+8fd15c6ca" ]
# Some of the triples are commented out just to speedup this workflow.
ttriple: [
aarch64-linux-gnu,
Expand Down Expand Up @@ -97,12 +99,11 @@ jobs:
- shared_libs: true
ttriple: x86_64-linux-gnux32 # FIXME: recompile with -fPIC

# TODO: move from nightly to zig 0.12 final when released.
steps:
- uses: actions/checkout@v4
- name: "Install zig"
run: |
mkdir zig && curl https://ziglang.org/builds/zig-linux-x86_64-0.12.0-dev.2076+8fd15c6ca.tar.xz | tar Jx --directory=zig --strip-components=1
mkdir zig && curl https://ziglang.org/builds/zig-linux-x86_64-${{matrix.zig_version}}.tar.xz | tar Jx --directory=zig --strip-components=1
- name: Build
run: >
zig/zig build -Dtarget=${{ matrix.ttriple }}
Expand Down

0 comments on commit f9251a4

Please sign in to comment.