From 3c09b8999e08543cd473f6f4ca1146f27228965e Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sat, 7 Mar 2026 12:03:43 +0200 Subject: [PATCH 1/6] Try Win11 arm64 build --- .github/workflows/go.yml | 144 ++++++++++++++++++++++----------------- 1 file changed, 81 insertions(+), 63 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 02dcb03..d505284 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -6,71 +6,89 @@ permissions: contents: read jobs: - build: - name: Test on ${{ matrix.os }} / ${{ matrix.arch }} - runs-on: ${{ matrix.os }} - strategy: - matrix: - include: - - os: ubuntu-latest - arch: amd64 - - os: ubuntu-24.04-arm - arch: arm64 - - os: windows-latest - arch: amd64 - - os: macos-26-intel - arch: amd64 - - os: macos-26 - arch: arm64 - steps: - - uses: actions/checkout@v6 - - - name: Set up Go - uses: actions/setup-go@v6 - with: - go-version-file: './go.mod' - - - name: Test examples - run: go test -v -gcflags="all=-N -l" ./examples/... - - - name: Unit tests - run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - - - name: Upload coverage reports to Codecov - if: ${{ matrix.os == 'ubuntu-latest' && matrix.arch == 'amd64' && github.ref == 'refs/heads/main' }} - uses: codecov/codecov-action@v5 - with: - token: ${{ secrets.CODECOV_TOKEN }} +# build: +# name: Test on ${{ matrix.os }} / ${{ matrix.arch }} +# runs-on: ${{ matrix.os }} +# strategy: +# matrix: +# include: +# - os: ubuntu-latest +# arch: amd64 +# - os: ubuntu-24.04-arm +# arch: arm64 +# - os: windows-latest +# arch: amd64 +# - os: macos-26-intel +# arch: amd64 +# - os: macos-26 +# arch: arm64 +# steps: +# - uses: actions/checkout@v6 +# +# - name: Set up Go +# uses: actions/setup-go@v6 +# with: +# go-version-file: './go.mod' +# +# - name: Test examples +# run: go test -v -gcflags="all=-N -l" ./examples/... +# +# - name: Unit tests +# run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . +# +# - name: Upload coverage reports to Codecov +# if: ${{ matrix.os == 'ubuntu-latest' && matrix.arch == 'amd64' && github.ref == 'refs/heads/main' }} +# uses: codecov/codecov-action@v5 +# with: +# token: ${{ secrets.CODECOV_TOKEN }} - freebsd-amd64: - name: Test on freebsd / amd64 - runs-on: ubuntu-latest + win-arm64: + name: Windows 11 / arm64 + runs-on: windows-11-arm steps: + # Prevent Git from converting LF to CRLF, which can cause test failures on Windows + - run: git config --global core.autocrlf input - uses: actions/checkout@v6 - - name: Test - uses: vmactions/freebsd-vm@v1 - with: - usesh: true - copyback: false - prepare: | - pkg install -y go - run: | - go test -v -gcflags="all=-N -l" ./examples/... - go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - freebsd-arm64: - name: Test on freebsd / arm64 - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v6 - - name: Test - uses: vmactions/freebsd-vm@v1 + - name: Set up environment + uses: msys2/setup-msys2@v2 with: - arch: aarch64 - usesh: true - copyback: false - prepare: | - pkg install -y go - run: | - go test -v -gcflags="all=-N -l" ./examples/... - go test -v -gcflags="all=-N -l" -coverprofile coverage.out . + msystem: CLANGARM64 + install: mingw-w64-clang-aarch64-gcc-compat + + - name: Test examples + shell: msys2 {0} + run: go test -v -gcflags="all=-N -l" ./examples/... + +# freebsd-amd64: +# name: Test on freebsd / amd64 +# runs-on: ubuntu-latest +# steps: +# - uses: actions/checkout@v6 +# - name: Test +# uses: vmactions/freebsd-vm@v1 +# with: +# usesh: true +# copyback: false +# prepare: | +# pkg install -y go +# run: | +# go test -v -gcflags="all=-N -l" ./examples/... +# go test -v -gcflags="all=-N -l" -coverprofile coverage.out . +# +# freebsd-arm64: +# name: Test on freebsd / arm64 +# runs-on: ubuntu-latest +# steps: +# - uses: actions/checkout@v6 +# - name: Test +# uses: vmactions/freebsd-vm@v1 +# with: +# arch: aarch64 +# usesh: true +# copyback: false +# prepare: | +# pkg install -y go +# run: | +# go test -v -gcflags="all=-N -l" ./examples/... +# go test -v -gcflags="all=-N -l" -coverprofile coverage.out . From 4be2f24d3564b5022654aa8c92cc14c7a64403fb Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sat, 7 Mar 2026 12:11:25 +0200 Subject: [PATCH 2/6] Setup Go on arm64 --- .github/workflows/go.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index d505284..57a592a 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -56,6 +56,11 @@ jobs: msystem: CLANGARM64 install: mingw-w64-clang-aarch64-gcc-compat + - name: Set up Go + uses: actions/setup-go@v6 + with: + go-version-file: './go.mod' + - name: Test examples shell: msys2 {0} run: go test -v -gcflags="all=-N -l" ./examples/... From df9ed1bdd0c59c04485231924ffb7ce04d4480de Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sat, 7 Mar 2026 12:24:46 +0200 Subject: [PATCH 3/6] Install Go --- .github/workflows/go.yml | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 57a592a..a45cf0e 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -50,16 +50,11 @@ jobs: - run: git config --global core.autocrlf input - uses: actions/checkout@v6 - - name: Set up environment + - name: Set up Go uses: msys2/setup-msys2@v2 with: msystem: CLANGARM64 - install: mingw-w64-clang-aarch64-gcc-compat - - - name: Set up Go - uses: actions/setup-go@v6 - with: - go-version-file: './go.mod' + install: mingw-w64-clang-aarch64-gcc-compat mingw-w64-clang-aarch64-go - name: Test examples shell: msys2 {0} From a920e9233a79384bf5fd6dc536f67af93443fe43 Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sat, 7 Mar 2026 12:34:13 +0200 Subject: [PATCH 4/6] All builds --- .github/workflows/go.yml | 146 +++++++++++++++++++++------------------ 1 file changed, 77 insertions(+), 69 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index a45cf0e..1e1a752 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -6,41 +6,47 @@ permissions: contents: read jobs: -# build: -# name: Test on ${{ matrix.os }} / ${{ matrix.arch }} -# runs-on: ${{ matrix.os }} -# strategy: -# matrix: -# include: -# - os: ubuntu-latest -# arch: amd64 -# - os: ubuntu-24.04-arm -# arch: arm64 -# - os: windows-latest -# arch: amd64 -# - os: macos-26-intel -# arch: amd64 -# - os: macos-26 -# arch: arm64 -# steps: -# - uses: actions/checkout@v6 -# -# - name: Set up Go -# uses: actions/setup-go@v6 -# with: -# go-version-file: './go.mod' -# -# - name: Test examples -# run: go test -v -gcflags="all=-N -l" ./examples/... -# -# - name: Unit tests -# run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . -# -# - name: Upload coverage reports to Codecov -# if: ${{ matrix.os == 'ubuntu-latest' && matrix.arch == 'amd64' && github.ref == 'refs/heads/main' }} -# uses: codecov/codecov-action@v5 -# with: -# token: ${{ secrets.CODECOV_TOKEN }} + matrix-build: + name: ${{ matrix.label }} + runs-on: ${{ matrix.image }} + strategy: + matrix: + include: + - image: ubuntu-latest + arch: amd64 + label: Ubuntu 24 / amd64 + - image: ubuntu-24.04-arm + arch: arm64 + label: Ubuntu 24 / arm64 + - image: macos-26-intel + arch: amd64 + label: macOS 26 / amd64 + - image: macos-26-arm + arch: arm64 + label: macOS 26 / arm64 + - image: windows-latest + arch: amd64 + label: Windows 11 / amd64 + + steps: + - uses: actions/checkout@v6 + + - name: Set up Go + uses: actions/setup-go@v6 + with: + go-version-file: './go.mod' + + - name: Test examples + run: go test -v -gcflags="all=-N -l" ./examples/... + + - name: Unit tests + run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . + + - name: Upload coverage reports to Codecov + if: ${{ matrix.image == 'ubuntu-latest' && matrix.arch == 'amd64' && github.ref == 'refs/heads/main' }} + uses: codecov/codecov-action@v5 + with: + token: ${{ secrets.CODECOV_TOKEN }} win-arm64: name: Windows 11 / arm64 @@ -56,39 +62,41 @@ jobs: msystem: CLANGARM64 install: mingw-w64-clang-aarch64-gcc-compat mingw-w64-clang-aarch64-go - - name: Test examples + - name: Test shell: msys2 {0} - run: go test -v -gcflags="all=-N -l" ./examples/... + run: | + go test -v -gcflags="all=-N -l" ./examples/... + go test -v -gcflags="all=-N -l" -coverprofile coverage.out . -# freebsd-amd64: -# name: Test on freebsd / amd64 -# runs-on: ubuntu-latest -# steps: -# - uses: actions/checkout@v6 -# - name: Test -# uses: vmactions/freebsd-vm@v1 -# with: -# usesh: true -# copyback: false -# prepare: | -# pkg install -y go -# run: | -# go test -v -gcflags="all=-N -l" ./examples/... -# go test -v -gcflags="all=-N -l" -coverprofile coverage.out . -# -# freebsd-arm64: -# name: Test on freebsd / arm64 -# runs-on: ubuntu-latest -# steps: -# - uses: actions/checkout@v6 -# - name: Test -# uses: vmactions/freebsd-vm@v1 -# with: -# arch: aarch64 -# usesh: true -# copyback: false -# prepare: | -# pkg install -y go -# run: | -# go test -v -gcflags="all=-N -l" ./examples/... -# go test -v -gcflags="all=-N -l" -coverprofile coverage.out . + freebsd-amd64: + name: FreeBSD 15 / amd64 + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Test + uses: vmactions/freebsd-vm@v1 + with: + usesh: true + copyback: false + prepare: | + pkg install -y go + run: | + go test -v -gcflags="all=-N -l" ./examples/... + go test -v -gcflags="all=-N -l" -coverprofile coverage.out . + + freebsd-arm64: + name: FreeBSD 15 / arm64 + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Test + uses: vmactions/freebsd-vm@v1 + with: + arch: aarch64 + usesh: true + copyback: false + prepare: | + pkg install -y go + run: | + go test -v -gcflags="all=-N -l" ./examples/... + go test -v -gcflags="all=-N -l" -coverprofile coverage.out . From ce3a11ab8ec4e443cb26d7ba7a06a5df90876bd6 Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sun, 8 Mar 2026 18:36:29 +0200 Subject: [PATCH 5/6] Revert to more stable macOS 15 images --- .github/workflows/go.yml | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 1e1a752..bbf8dbd 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -13,20 +13,15 @@ jobs: matrix: include: - image: ubuntu-latest - arch: amd64 - label: Ubuntu 24 / amd64 + label: Linux / x86-64 - image: ubuntu-24.04-arm - arch: arm64 - label: Ubuntu 24 / arm64 - - image: macos-26-intel - arch: amd64 - label: macOS 26 / amd64 - - image: macos-26-arm - arch: arm64 - label: macOS 26 / arm64 + label: Linux / arm64 + - image: macos-15-intel + label: macOS / x86-64 + - image: macos-latest + label: macOS / arm64 - image: windows-latest - arch: amd64 - label: Windows 11 / amd64 + label: Windows / x86-64 steps: - uses: actions/checkout@v6 @@ -43,13 +38,13 @@ jobs: run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - name: Upload coverage reports to Codecov - if: ${{ matrix.image == 'ubuntu-latest' && matrix.arch == 'amd64' && github.ref == 'refs/heads/main' }} + if: ${{ matrix.image == 'ubuntu-latest' && github.ref == 'refs/heads/main' }} uses: codecov/codecov-action@v5 with: token: ${{ secrets.CODECOV_TOKEN }} win-arm64: - name: Windows 11 / arm64 + name: Windows / arm64 runs-on: windows-11-arm steps: # Prevent Git from converting LF to CRLF, which can cause test failures on Windows @@ -69,7 +64,7 @@ jobs: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . freebsd-amd64: - name: FreeBSD 15 / amd64 + name: FreeBSD / x86-64 runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 @@ -85,7 +80,7 @@ jobs: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . freebsd-arm64: - name: FreeBSD 15 / arm64 + name: FreeBSD / arm64 runs-on: ubuntu-latest steps: - uses: actions/checkout@v6 From 3789175834fcf1bc99b4157a47128e2dfd9ad071 Mon Sep 17 00:00:00 2001 From: Ilya Caramishev Date: Sun, 8 Mar 2026 18:47:21 +0200 Subject: [PATCH 6/6] Build script simplified --- .github/workflows/go.yml | 49 ++++++++++++++-------------------------- 1 file changed, 17 insertions(+), 32 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index bbf8dbd..1bc4f69 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -6,7 +6,7 @@ permissions: contents: read jobs: - matrix-build: + regular: name: ${{ matrix.label }} runs-on: ${{ matrix.image }} strategy: @@ -22,21 +22,16 @@ jobs: label: macOS / arm64 - image: windows-latest label: Windows / x86-64 - steps: - uses: actions/checkout@v6 - - name: Set up Go uses: actions/setup-go@v6 with: go-version-file: './go.mod' - - - name: Test examples - run: go test -v -gcflags="all=-N -l" ./examples/... - - - name: Unit tests - run: go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - + - name: Test + run: | + go test -v -gcflags="all=-N -l" ./examples/... + go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - name: Upload coverage reports to Codecov if: ${{ matrix.image == 'ubuntu-latest' && github.ref == 'refs/heads/main' }} uses: codecov/codecov-action@v5 @@ -48,46 +43,36 @@ jobs: runs-on: windows-11-arm steps: # Prevent Git from converting LF to CRLF, which can cause test failures on Windows - - run: git config --global core.autocrlf input + - name: Configure Git for Windows + run: git config --global core.autocrlf input - uses: actions/checkout@v6 - - name: Set up Go uses: msys2/setup-msys2@v2 with: msystem: CLANGARM64 install: mingw-w64-clang-aarch64-gcc-compat mingw-w64-clang-aarch64-go - - name: Test shell: msys2 {0} run: | go test -v -gcflags="all=-N -l" ./examples/... go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - freebsd-amd64: - name: FreeBSD / x86-64 - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v6 - - name: Test - uses: vmactions/freebsd-vm@v1 - with: - usesh: true - copyback: false - prepare: | - pkg install -y go - run: | - go test -v -gcflags="all=-N -l" ./examples/... - go test -v -gcflags="all=-N -l" -coverprofile coverage.out . - - freebsd-arm64: - name: FreeBSD / arm64 + freebsd: + name: ${{ matrix.label }} runs-on: ubuntu-latest + strategy: + matrix: + include: + - arch: x86_64 + label: FreeBSD / x86-64 + - arch: aarch64 + label: FreeBSD / arm64 steps: - uses: actions/checkout@v6 - name: Test uses: vmactions/freebsd-vm@v1 with: - arch: aarch64 + arch: ${{ matrix.arch }} usesh: true copyback: false prepare: |