Test Go bindings on all platforms (#332)
* Test Go bindings on all platforms * Update setup-go action * Specify flags in the env section
This commit is contained in:
parent
de151d8fd7
commit
f62c9738b1
|
@ -9,24 +9,32 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ${{ matrix.os }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os:
|
||||||
|
- ubuntu-latest
|
||||||
|
- windows-latest
|
||||||
|
- macos-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Setup Go
|
- name: Setup Go
|
||||||
uses: actions/setup-go@v2
|
uses: actions/setup-go@v4
|
||||||
with:
|
with:
|
||||||
go-version: ^1.19
|
go-version: stable
|
||||||
id: go
|
id: go
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Test
|
- name: Test
|
||||||
run: |
|
run: go test
|
||||||
cd bindings/go
|
working-directory: bindings/go
|
||||||
CGO_CFLAGS="-O2 -D__BLST_PORTABLE__" go test
|
env:
|
||||||
|
CGO_CFLAGS: "-O2 -D__BLST_PORTABLE__"
|
||||||
- name: Benchmark
|
- name: Benchmark
|
||||||
run: |
|
run: go test -bench=Benchmark
|
||||||
cd bindings/go
|
working-directory: bindings/go
|
||||||
CGO_CFLAGS="-O2 -D__BLST_PORTABLE__" go test -bench=Benchmark
|
env:
|
||||||
|
CGO_CFLAGS: "-O2 -D__BLST_PORTABLE__"
|
||||||
- name: Check headers
|
- name: Check headers
|
||||||
run: |
|
run: |
|
||||||
cmp blst/bindings/blst.h bindings/go/blst_headers/blst.h
|
cmp blst/bindings/blst.h bindings/go/blst_headers/blst.h
|
||||||
|
|
Loading…
Reference in New Issue