diff options
-rw-r--r-- | .github/workflows/freebsd.yml | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/.github/workflows/freebsd.yml b/.github/workflows/freebsd.yml new file mode 100644 index 0000000..0aa64d8 --- /dev/null +++ b/.github/workflows/freebsd.yml | |||
@@ -0,0 +1,71 @@ | |||
1 | # GitHub Actions workflow to run tests on a FreeBSD VM. | ||
2 | name: "FreeBSD" | ||
3 | |||
4 | on: | ||
5 | workflow_dispatch: | ||
6 | schedule: | ||
7 | - cron: "0 0 * * *" # At 00:00 daily. | ||
8 | |||
9 | concurrency: | ||
10 | group: "${{ github.workflow }}-${{ github.event.number || github.ref }}" | ||
11 | cancel-in-progress: true | ||
12 | |||
13 | env: | ||
14 | FREEBSD_VERSION: "14.1" | ||
15 | |||
16 | jobs: | ||
17 | autoconf: | ||
18 | name: "autoconf" | ||
19 | runs-on: ubuntu-latest | ||
20 | if: github.repository_owner == 'libressl' || github.event_name != 'schedule' | ||
21 | permissions: | ||
22 | contents: read | ||
23 | steps: | ||
24 | - name: "Checkout repository" | ||
25 | uses: actions/checkout@v4 | ||
26 | |||
27 | - name: "Setup" | ||
28 | run: | | ||
29 | sudo apt-get update | ||
30 | sudo apt-get install -y automake autoconf libtool | ||
31 | ./autogen.sh | ||
32 | |||
33 | - name: "Build on VM" | ||
34 | uses: vmactions/freebsd-vm@v1 | ||
35 | with: | ||
36 | release: "${{ env.FREEBSD_VERSION }}" | ||
37 | copyback: false | ||
38 | prepare: | | ||
39 | pkg install -y autoconf automake libtool | ||
40 | run: | | ||
41 | ./configure | ||
42 | make -j2 check || (cat tests/test-suite.log && exit 1) | ||
43 | |||
44 | cmake: | ||
45 | name: "cmake" | ||
46 | runs-on: ubuntu-latest | ||
47 | if: github.repository_owner == 'libressl' || github.event_name != 'schedule' | ||
48 | permissions: | ||
49 | contents: read | ||
50 | steps: | ||
51 | - name: "Checkout repository" | ||
52 | uses: actions/checkout@v4 | ||
53 | |||
54 | - name: "Setup" | ||
55 | run: | | ||
56 | sudo apt-get update | ||
57 | sudo apt-get install -y automake autoconf libtool | ||
58 | ./autogen.sh | ||
59 | |||
60 | - name: "Build on VM" | ||
61 | uses: vmactions/freebsd-vm@v1 | ||
62 | with: | ||
63 | release: "${{ env.FREEBSD_VERSION }}" | ||
64 | copyback: false | ||
65 | prepare: | | ||
66 | pkg install -y cmake ninja | ||
67 | run: | | ||
68 | export CTEST_OUTPUT_ON_FAILURE=1 | ||
69 | cmake -G Ninja -B build | ||
70 | ninja -C build | ||
71 | ninja -C build test | ||