aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/ci.yml
blob: 964d7a8fec3efd5b84bcc058269217b311d9607a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: ci

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:
  ci:
    runs-on: ${{ matrix.host_os }}

    env:
      ANDROID_NDK: android-ndk-r21d

    strategy:
      fail-fast: false

      matrix:
        include:
          - target: coverage
            compiler: gcc
            host_os: ubuntu-20.04
          - target: shared
            compiler: gcc
            host_os: ubuntu-20.04
          - target: shared
            compiler: clang
            host_os: ubuntu-20.04
          - target: valgrind
            compiler: gcc
            host_os: ubuntu-20.04
          - target: fuzzers
            compiler: gcc
            host_os: ubuntu-20.04
          - target: cross-i386
            compiler: gcc
            host_os: ubuntu-20.04
          - target: cross-arm64
            compiler: gcc
            host_os: ubuntu-20.04
          - target: cross-ppc64
            compiler: gcc
            host_os: ubuntu-20.04
          - target: cross-android-arm32
            compiler: clang
            host_os: ubuntu-20.04
          - target: cross-android-arm64
            compiler: clang
            host_os: ubuntu-20.04
          - target: cross-win64
            compiler: gcc
            host_os: ubuntu-20.04
          - target: baremetal
            compiler: gcc
            host_os: ubuntu-20.04
          - target: minimized
            compiler: gcc
            host_os: ubuntu-20.04
          - target: bsi
            compiler: gcc
            host_os: ubuntu-20.04
          - target: lint
            compiler: gcc
            host_os: ubuntu-20.04
          - target: shared
            compiler: clang
            host_os: macos-latest
          - target: cross-ios-arm64
            compiler: clang
            host_os: macos-latest

    steps:
      - uses: actions/checkout@v2
      - uses: actions/cache@v2
        with:
            path: |
              ~/.ccache
              /Users/runner/Library/Caches/ccache
            key: ${{ runner.os }}-${{ matrix.compiler }}-${{ matrix.target }}-${{ github.run_id }}
            restore-keys: |
               ${{ runner.os }}-${{ matrix.compiler }}-${{ matrix.target }}-
      - run: ./src/scripts/ci/setup_gh_actions.sh ${{ matrix.target }}
      - run: ./src/scripts/ci_build.py --cc '${{ matrix.compiler }}' ${{ matrix.target }}