2020-08-22 11:20:50 +02:00
|
|
|
# Shows how to cross compile ooniprobe
|
|
|
|
name: cross
|
|
|
|
on:
|
|
|
|
push:
|
2021-02-03 16:13:37 +01:00
|
|
|
branches:
|
|
|
|
- 'release/**'
|
2020-08-22 11:20:50 +02:00
|
|
|
schedule:
|
|
|
|
- cron: "14 17 * * 3"
|
|
|
|
jobs:
|
|
|
|
|
|
|
|
windows_from_linux_build:
|
|
|
|
runs-on: "ubuntu-latest"
|
|
|
|
steps:
|
|
|
|
- uses: actions/setup-go@v1
|
|
|
|
with:
|
2021-03-02 12:08:24 +01:00
|
|
|
go-version: "1.16"
|
2020-08-22 11:20:50 +02:00
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: sudo apt update
|
|
|
|
- run: sudo apt install --yes mingw-w64
|
|
|
|
- run: ./build.sh windows
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
|
|
with:
|
|
|
|
name: ooniprobe-windows-amd64-compiled-from-linux
|
|
|
|
path: ./CLI/windows/amd64/ooniprobe.exe
|
|
|
|
|
|
|
|
test_build_from_linux:
|
|
|
|
needs: windows_from_linux_build
|
|
|
|
runs-on: "windows-latest"
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions/download-artifact@v2
|
|
|
|
with:
|
|
|
|
name: ooniprobe-windows-amd64-compiled-from-linux
|
|
|
|
- run: bash.exe ./smoketest.sh ./ooniprobe.exe
|
|
|
|
|
|
|
|
windows_from_macos_build:
|
|
|
|
runs-on: "macos-latest"
|
|
|
|
steps:
|
|
|
|
- uses: actions/setup-go@v1
|
|
|
|
with:
|
2021-03-02 12:08:24 +01:00
|
|
|
go-version: "1.16"
|
2020-08-22 11:20:50 +02:00
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- run: brew install mingw-w64
|
|
|
|
- run: ./build.sh windows
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
|
|
with:
|
|
|
|
name: ooniprobe-windows-amd64-compiled-from-macos
|
|
|
|
path: ./CLI/windows/amd64/ooniprobe.exe
|
|
|
|
|
|
|
|
test_build_from_macos:
|
|
|
|
needs: windows_from_macos_build
|
|
|
|
runs-on: "windows-latest"
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions/download-artifact@v2
|
|
|
|
with:
|
|
|
|
name: ooniprobe-windows-amd64-compiled-from-macos
|
|
|
|
- run: bash.exe ./smoketest.sh ./ooniprobe.exe
|